Ejemplo n.º 1
0
 @Override
 public void onClick(View v) {
   switch (v.getId()) {
     case R.id.subject_search:
       if (filterContent.getVisibility() == 0) {
         mFilterExpand.hideMoreListView();
         //					loadAnim(filterContent);
         filterContent.startAnimation(mAnim);
         filterContent.setVisibility(View.INVISIBLE);
       } else {
         mFilterExpand.openMoreListView();
         filterContent.startAnimation(mLeftAnim);
         filterContent.setVisibility(View.VISIBLE);
       }
       break;
     case R.id.filter_latest:
       mType = 1;
       mFilterLatest.setBackgroundResource(R.drawable.filter_but_l_s);
       mFilterLatest.setTextColor(mColorSelect);
       mFilterPopularity.setTextColor(mColor);
       mFilterStar.setTextColor(mColor);
       mFilterPopularity.setBackgroundResource(R.drawable.filter_but_c);
       mFilterStar.setBackgroundResource(R.drawable.filter_but_r);
       prlistView.setPage(0);
       new GetDataTask().execute();
       break;
     case R.id.filter_popularity:
       mType = 2;
       mFilterLatest.setBackgroundResource(R.drawable.filter_but_l);
       mFilterPopularity.setBackgroundResource(R.drawable.filter_but_c_s);
       mFilterStar.setBackgroundResource(R.drawable.filter_but_r);
       mFilterLatest.setTextColor(mColor);
       mFilterPopularity.setTextColor(mColorSelect);
       mFilterStar.setTextColor(mColor);
       prlistView.setPage(0);
       new GetDataTask().execute();
       break;
     case R.id.filter_price:
       mType = 3;
       mFilterLatest.setBackgroundResource(R.drawable.filter_but_l);
       mFilterPopularity.setBackgroundResource(R.drawable.filter_but_c);
       mFilterStar.setBackgroundResource(R.drawable.filter_but_r_s);
       mFilterLatest.setTextColor(mColor);
       mFilterPopularity.setTextColor(mColor);
       mFilterStar.setTextColor(mColorSelect);
       prlistView.setPage(0);
       new GetDataTask().execute();
       break;
     case R.id.subject_search_value:
       Intent mIntent = new Intent(this, SubjectSearchActivity.class);
       startActivity(mIntent);
       break;
     case R.id.menu_control_level1_but:
       finish();
       break;
   }
 }
Ejemplo n.º 2
0
 private void showLoading(boolean show) {
   if (show) {
     llLoading.startAnimation(AnimationUtils.loadAnimation(getActivity(), android.R.anim.fade_in));
     llLoading.setVisibility(ProgressBar.VISIBLE);
   } else {
     llLoading.startAnimation(
         AnimationUtils.loadAnimation(getActivity(), android.R.anim.fade_out));
     llLoading.setVisibility(ProgressBar.GONE);
   }
 }
  public void setContentEditingModeVisible(boolean isVisible) {
    if (!isAdded()) {
      return;
    }
    ActionBar actionBar = getActionBar();
    if (isVisible) {
      Animation fadeAnimation = new AlphaAnimation(1, 0);
      fadeAnimation.setDuration(CONTENT_ANIMATION_DURATION);
      fadeAnimation.setAnimationListener(
          new Animation.AnimationListener() {
            @Override
            public void onAnimationStart(Animation animation) {
              mTitleEditText.setVisibility(View.GONE);
            }

            @Override
            public void onAnimationEnd(Animation animation) {
              mPostSettingsLinearLayout.setVisibility(View.GONE);
              mFormatBar.setVisibility(View.VISIBLE);
            }

            @Override
            public void onAnimationRepeat(Animation animation) {}
          });

      mPostContentLinearLayout.startAnimation(fadeAnimation);
      if (actionBar != null) {
        actionBar.hide();
      }
    } else {
      mTitleEditText.setVisibility(View.VISIBLE);
      mFormatBar.setVisibility(View.GONE);
      Animation fadeAnimation = new AlphaAnimation(0, 1);
      fadeAnimation.setDuration(CONTENT_ANIMATION_DURATION);
      fadeAnimation.setAnimationListener(
          new Animation.AnimationListener() {
            @Override
            public void onAnimationStart(Animation animation) {}

            @Override
            public void onAnimationEnd(Animation animation) {
              mPostSettingsLinearLayout.setVisibility(View.VISIBLE);
            }

            @Override
            public void onAnimationRepeat(Animation animation) {}
          });
      mPostContentLinearLayout.startAnimation(fadeAnimation);
      getActivity().invalidateOptionsMenu();
      if (actionBar != null) {
        actionBar.show();
      }
    }
  }
  public void changeToNormal() {
    if (mState != HeaderViewState.Simple) {
      return;
    }
    mState = HeaderViewState.Normal;

    Animation normalAnimation = AnimationUtils.loadAnimation(getContext(), R.anim.fade_in);
    Animation simpleAnimation = AnimationUtils.loadAnimation(getContext(), R.anim.fade_out);
    Animation scaleAnimation = getScaleHeightAnimation(0.5f, 1.0f);

    mNormalView.startAnimation(normalAnimation);
    mSimpleView.startAnimation(simpleAnimation);
    mBKImage.startAnimation(scaleAnimation);
  }
Ejemplo n.º 5
0
  public void anim(LinearLayout l, int anim) {

    Animation anim_ee = AnimationUtils.loadAnimation(getApplicationContext(), anim);
    anim_ee.reset();
    l.setVisibility(View.VISIBLE);
    l.startAnimation(anim_ee);
  }
Ejemplo n.º 6
0
  public static void slideDownRoutesListView() {
    final MainActivity mainActivity = _getMainActivity();
    if (mainActivity == null) {
      return;
    }
    final Model model = _getModel();

    LinearLayout listViewAndProgressBarLinearLayout =
        (LinearLayout) mainActivity.findViewById(R.id.listViewAndProgressBarLinearLayout);
    TranslateAnimation animation = null;
    if (model.getFavorite().size() == 1) {
      animation = new TranslateAnimation(0, 0, 0, model.dpToPx(60));
      mainActivity.getLeftMenu().getTicketsTray().setVisibility(View.GONE);
    }
    if (animation != null) {
      animation.setDuration(Animations.ANIMATION_DURATION);
      animation.setAnimationListener(
          new AnimationListener() {

            @Override
            public void onAnimationStart(Animation animation) {}

            @Override
            public void onAnimationRepeat(Animation animation) {}

            @Override
            public void onAnimationEnd(Animation animation) {
              mainActivity.getLeftMenu().getTicketsTray().update();
            }
          });
      listViewAndProgressBarLinearLayout.startAnimation(animation);
    }
  }
Ejemplo n.º 7
0
  /** 显示翻译结果 */
  public void showTranslation(TranslationBean translationBean) {
    isShowing = true;
    boolean noneNull = false;
    if (windowView == null) {
      initWindowView();
      windowView.findViewById(R.id.selectLayout).setVisibility(View.GONE);
    } else {
      noneNull = true;
      displayLayout.setVisibility(View.GONE);
    }
    displayLayout = (LinearLayout) windowView.findViewById(R.id.translationLayout);
    displayLayout.setVisibility(View.VISIBLE);
    setTranslationView(windowView, translationBean);

    if (!noneNull) {
      windowManager.addView(windowView, getWindowLayoutParams());
      Animation showAnim = new TranslateAnimation(0, 0, -164, 0);
      showAnim.setDuration(200);
      showAnim.setAnimationListener(
          new Animation.AnimationListener() {
            @Override
            public void onAnimationStart(Animation animation) {
              displayLayout.setVisibility(View.VISIBLE);
            }

            @Override
            public void onAnimationEnd(Animation animation) {}

            @Override
            public void onAnimationRepeat(Animation animation) {}
          });
      displayLayout.startAnimation(showAnim);
    }
  }
Ejemplo n.º 8
0
  public void removeView() {
    if (windowView != null && !hiding) {
      hiding = true;
      Animation anim = new TranslateAnimation(0, 0, 0, -displayLayout.getHeight());
      anim.setDuration(200);
      anim.setAnimationListener(
          new Animation.AnimationListener() {
            public void onAnimationStart(Animation animation) {}

            public void onAnimationRepeat(Animation animation) {}

            public void onAnimationEnd(Animation animation) {
              hiding = false;
              displayLayout.setVisibility(View.INVISIBLE);
              windowView.setOnKeyListener(null);
              windowView.setOnTouchListener(null);
              if (searchSelect != null) {
                searchSelect.setOnClickListener(null);
                translationSelect.setOnClickListener(null);
                inserteventsSelect.setOnClickListener(null);
              }
              isShowing = false;
              windowManager.removeView(windowView);
              windowView = null;
            }
          });
      displayLayout.startAnimation(anim);
    }
  }
 private void runFadeInAnimation() {
   Animation a = AnimationUtils.loadAnimation(this, R.anim.fadein);
   a.reset();
   LinearLayout ll = (LinearLayout) findViewById(R.id.categories);
   ll.clearAnimation();
   ll.startAnimation(a);
 }
  public void refresherOnTime() {
    CoreMediaPlayer mp = Engine.instance().getMediaPlayer();
    if (mp != null) {
      FileDescriptor fd = mp.getCurrentFD();

      String status = "";
      refreshPlayerStateIndicator();
      if (fd != null) {
        status = fd.artist + " - " + fd.title;
        if (getVisibility() == View.GONE) {
          setVisibility(View.VISIBLE);
          startAnimation(showNotifierAnimation);
        }
      } else {
        if (getVisibility() == View.VISIBLE) {
          startAnimation(hideNotifierAnimation);
          setVisibility(View.GONE);
        }
      }
      if (!status.equals(lastStatusShown)) {
        statusText.setText(status);
        lastStatusShown = status;
        statusContainer.startAnimation(fromRightAnimation);
      }
    }
  }
Ejemplo n.º 11
0
  public void hide() {
    maskView.hide();
    actionSheetView.clearAnimation();
    TranslateAnimation an =
        new TranslateAnimation(
            Animation.RELATIVE_TO_SELF,
            0,
            Animation.RELATIVE_TO_SELF,
            0,
            Animation.RELATIVE_TO_SELF,
            0,
            Animation.RELATIVE_TO_SELF,
            1);
    an.setDuration(durationMillis);
    an.setAnimationListener(
        new AnimationListener() {
          @Override
          public void onAnimationStart(Animation animation) {}

          @Override
          public void onAnimationRepeat(Animation animation) {}

          @Override
          public void onAnimationEnd(Animation animation) {
            actionSheetView.setVisibility(View.GONE);
            if (getParent() != null) windowManager.removeView(ActionSheet.this);
          }
        });
    actionSheetView.startAnimation(an);
  }
Ejemplo n.º 12
0
 public void mostrarVistas(boolean state) {
   if (state) {
     Animation show;
     show = AnimationUtils.loadAnimation(this.getApplicationContext(), R.anim.fade);
     show.reset();
     contenedor_credenciales.startAnimation(show);
   }
 }
Ejemplo n.º 13
0
 public void hideDetailView() {
   if (mDetailViewVisible) {
     Animation bottomDown = AnimationUtils.loadAnimation(getActivity(), R.anim.bottom_down);
     mDetailView.startAnimation(bottomDown);
     mDetailView.setVisibility(View.INVISIBLE);
     mDetailViewVisible = false;
   }
 }
Ejemplo n.º 14
0
 private void showDetailView(String network_name) {
   if (!isDetailViewVisible()) {
     TextView detailTitle = (TextView) mDetailView.findViewById(R.id.network_name);
     detailTitle.setText(getString(R.string.devices_on) + network_name);
     Animation bottomUp = AnimationUtils.loadAnimation(getActivity(), R.anim.bottom_up);
     mDetailView.startAnimation(bottomUp);
     mDetailView.setVisibility(View.VISIBLE);
     mDetailViewVisible = true;
   }
 }
 public void show() {
   if (mState == HeaderViewState.Hiden) {
     Animation animation = AnimationUtils.loadAnimation(getContext(), R.anim.fade_in);
     startAnimation(animation);
     Animation simpleAnimation = AnimationUtils.loadAnimation(getContext(), R.anim.fade_out);
     simpleAnimation.setDuration(0);
     mSimpleView.startAnimation(simpleAnimation);
   }
   mState = HeaderViewState.Normal;
 }
Ejemplo n.º 16
0
  /** Hide send tools */
  public void hideSendTools() {
    MainActivity me = MainActivity.this;
    Context context = me;
    Animation anim;

    anim = AnimationUtils.loadAnimation(context, R.anim.push_up_out);

    anim.setAnimationListener(me);
    mSendTools.startAnimation(anim);
    // mSendTools.setVisibility(LinearLayout.VISIBLE);
  }
  /** Shows search input and close arrow */
  public void disableSearch() {
    searchEnabled = false;
    Animation out = AnimationUtils.loadAnimation(getContext(), R.anim.fade_out);
    Animation in = AnimationUtils.loadAnimation(getContext(), R.anim.fade_in_right);
    out.setAnimationListener(this);
    searchIcon.setVisibility(VISIBLE);
    inputContainer.startAnimation(out);
    searchIcon.startAnimation(in);

    if (listenerExists()) onSearchActionListener.onSearchStateChanged(false);
    if (suggestionsVisible) animateLastRequests(getListHeight(), 0);
  }
Ejemplo n.º 18
0
 @SuppressLint("NewApi")
 private void showVideoControls() {
   videoOverlay.setVisibility(View.VISIBLE);
   butPlay.setVisibility(View.VISIBLE);
   final Animation animation = AnimationUtils.loadAnimation(this, R.anim.fade_in);
   if (animation != null) {
     videoOverlay.startAnimation(animation);
     butPlay.startAnimation(animation);
   }
   if (Build.VERSION.SDK_INT >= 14) {
     videoview.setSystemUiVisibility(View.SYSTEM_UI_FLAG_VISIBLE);
   }
 }
Ejemplo n.º 19
0
  /** 显示选择窗口 */
  public void showSelect(boolean[] visibilityFlag) {
    isShowing = true;
    if (windowView == null) {
      initWindowView();
    }
    displayLayout = (LinearLayout) windowView.findViewById(R.id.selectLayout);

    searchSelect = (LinearLayout) windowView.findViewById(R.id.searchSelect);
    translationSelect = (LinearLayout) windowView.findViewById(R.id.translationSelect);
    inserteventsSelect = (LinearLayout) windowView.findViewById(R.id.inserteventsSelect);
    for (int i = 0; i < visibilityFlag.length; i++) {
      if (!visibilityFlag[i]) {
        switch (i) {
          case WhenCopyService.SELECT_SEARCH_INDEX:
            searchSelect.setVisibility(View.GONE);
            break;
          case WhenCopyService.SELECT_TRANSLATION_INDEX:
            translationSelect.setVisibility(View.GONE);
            break;
          case WhenCopyService.SELECT_INSERTEVENTS_INDEX:
            inserteventsSelect.setVisibility(View.GONE);
            break;
        }
      }
    }

    if (onClickListener != null) {
      searchSelect.setOnClickListener(onClickListener);
      translationSelect.setOnClickListener(onClickListener);
      inserteventsSelect.setOnClickListener(onClickListener);
    }

    windowManager.addView(windowView, getWindowLayoutParams());
    // 此处由于displayLayout.getHeight()为0,所以暂时只能手动设置过度动画高度为246
    Animation showAnim = new TranslateAnimation(0, 0, -164, 0);
    showAnim.setDuration(200);
    showAnim.setAnimationListener(
        new Animation.AnimationListener() {
          @Override
          public void onAnimationStart(Animation animation) {
            displayLayout.setVisibility(View.VISIBLE);
          }

          @Override
          public void onAnimationEnd(Animation animation) {}

          @Override
          public void onAnimationRepeat(Animation animation) {}
        });
    displayLayout.startAnimation(showAnim);
  }
 /** Shows search input and close arrow */
 public void enableSearch() {
   adapter.notifyDataSetChanged();
   searchEnabled = true;
   Animation left_in = AnimationUtils.loadAnimation(getContext(), R.anim.fade_in_left);
   Animation left_out = AnimationUtils.loadAnimation(getContext(), R.anim.fade_out_left);
   left_in.setAnimationListener(this);
   inputContainer.setVisibility(VISIBLE);
   inputContainer.startAnimation(left_in);
   animateLastRequests(0, getListHeight());
   if (listenerExists()) {
     onSearchActionListener.onSearchStateChanged(true);
   }
   searchIcon.startAnimation(left_out);
 }
  @Override
  public void start() {
    if (!shouldAnimateCharging) return;

    if (vertical) {
      TranslateAnimation a =
          new TranslateAnimation(getX(), getX(), getHeight(), mBatteryBarLayout.getHeight());
      a.setInterpolator(new AccelerateInterpolator());
      a.setDuration(ANIM_DURATION);
      a.setRepeatCount(Animation.INFINITE);
      mChargerLayout.startAnimation(a);
      mChargerLayout.setVisibility(View.VISIBLE);
    } else {
      TranslateAnimation a =
          new TranslateAnimation(getWidth(), mBatteryBarLayout.getWidth(), getTop(), getTop());
      a.setInterpolator(new AccelerateInterpolator());
      a.setDuration(ANIM_DURATION);
      a.setRepeatCount(Animation.INFINITE);
      mChargerLayout.startAnimation(a);
      mChargerLayout.setVisibility(View.VISIBLE);
    }
    isAnimating = true;
  }
Ejemplo n.º 22
0
 @Override
 public void onClick(View v) {
   switch (v.getId()) {
     case R.id.activity_profile_btn_back:
       finish();
       break;
     case R.id.activity_profile_ll_avatar:
       llPopUp.startAnimation(
           AnimationUtils.loadAnimation(ProfileActivity.this, R.anim.activity_translate_in));
       pop.showAtLocation(parentView, Gravity.BOTTOM, 0, 0);
       break;
     case R.id.activity_profile_ll_name:
       Intent intent1 = new Intent(this, AlterNameActivity.class);
       intent1.putExtra("user_id", userID);
       intent1.putExtra("user_name", tvUserName.getText().toString());
       startActivity(intent1);
       break;
     case R.id.activity_profile_ll_sex:
       Intent intent2 = new Intent(this, AlterSexActivity.class);
       intent2.putExtra("user_id", userID);
       if ("男".equals(tvUserSex.getText().toString())) {
         intent2.putExtra("user_sex", "01");
       } else if ("女".equals(tvUserSex.getText().toString())) {
         intent2.putExtra("user_sex", "02");
       } else {
         intent2.putExtra("user_sex", "03");
       }
       startActivity(intent2);
       break;
     case R.id.activity_profile_ll_city:
       Intent intent5 = new Intent(this, AlterCityActivity.class);
       intent5.putExtra("user_id", userID);
       startActivity(intent5);
       break;
     case R.id.activity_profile_ll_signature:
       Intent intent3 = new Intent(this, AlterSignatureActivity.class);
       intent3.putExtra("user_id", userID);
       intent3.putExtra("signature", tvSignature.getText().toString());
       startActivity(intent3);
       break;
     case R.id.activity_profile_ll_pwd:
       Intent intent4 = new Intent(this, AlterPsdActivity.class);
       intent4.putExtra("user_id", userID);
       startActivity(intent4);
       break;
     case R.id.activity_profile_ll_logout:
       showLogoutTipDialog();
       break;
   }
 }
Ejemplo n.º 23
0
  @SuppressWarnings("deprecation")
  public void onClickButtonCancel(View v) {
    isAccept = false;

    mNextBtnLayout.setSoundEffectsEnabled(false);
    mFadeOutAnime = AnimationUtils.loadAnimation(this, R.anim.welcome_intro_fade_out);
    if (mFadeOutAnime != null) {
      mBottomLayout.startAnimation(mFadeOutAnime);
    }
    mBottomLayout.setBackgroundDrawable(null);
    if (mFadeOutAnime != null) {
      mFadeOutAnime.setAnimationListener(fadeOutAniListener);
    }
  }
 private void fadeZoom() {
   // #ifdef pro
   //     	if (this.textReflowMode) {
   //     		this.zoomLayout.setVisibility(View.GONE);
   //     		return;
   //     	}
   // #endif
   if (eink || zoomAnim == null) {
     zoomLayout.setVisibility(View.GONE);
   } else {
     zoomAnim.setStartOffset(0);
     zoomAnim.setFillAfter(true);
     zoomLayout.startAnimation(zoomAnim);
   }
 }
Ejemplo n.º 25
0
  public void doNav() {

    String url = urlField.getText().toString();

    if (URLUtil.isValidUrl(url) == false) {
      url = "http://" + url;
    }

    urlField.setText(url);

    webView.requestFocus();

    webView.loadUrl(url);

    navbar.startAnimation(slideUp);
  }
Ejemplo n.º 26
0
 @Override
 public void onDestroyView() {
   super.onDestroyView();
   Animation animation = AnimationUtils.loadAnimation(getActivity(), R.anim.push_left_out);
   animation.setDuration(duration);
   menuLayout.startAnimation(animation);
   mView.postDelayed(
       new Runnable() {
         @Override
         public void run() {
           mView.setVisibility(View.GONE);
           mGroup.removeView(mView);
         }
       },
       duration);
   ButterKnife.reset(this);
 }
 public void show(boolean animate) {
   menuSize = dpToPx(250, act);
   content = ((LinearLayout) act.findViewById(android.R.id.content).getParent());
   FrameLayout.LayoutParams parm = (FrameLayout.LayoutParams) content.getLayoutParams();
   parm.gravity = Gravity.TOP;
   statusHeight = 0;
   parm.setMargins(menuSize, 0, -menuSize, 0);
   content.setLayoutParams(parm);
   // animation for smooth slide-out
   TranslateAnimation ta = new TranslateAnimation(-menuSize, 0, 0, 0);
   ta.setDuration(500);
   if (animate) content.startAnimation(ta);
   parent = (FrameLayout) content.getParent();
   LayoutInflater inflater =
       (LayoutInflater) act.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
   menu = inflater.inflate(R.layout.menu, null);
   FrameLayout.LayoutParams lays = new FrameLayout.LayoutParams(-1, -1, 3);
   lays.setMargins(0, statusHeight, 0, 0);
   menu.setLayoutParams(lays);
   parent.addView(menu);
   ListView list = (ListView) act.findViewById(R.id.menu_listview);
   list.setBackgroundResource(R.drawable.shadow);
   list.setOnItemClickListener(
       new OnItemClickListener() {
         @Override
         public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
           // handle your menu-click
         }
       });
   if (animate) menu.startAnimation(ta);
   menu.findViewById(R.id.overlay)
       .setOnClickListener(
           new OnClickListener() {
             @Override
             public void onClick(View v) {
               NewsgroupListMenu.this.hide();
             }
           });
   enableDisableViewGroup(
       (LinearLayout) parent.findViewById(android.R.id.content).getParent(), false);
   // ((ExtendedViewPager) act.findViewById(R.id.viewpager)).setPagingEnabled(false);
   // ((ExtendedPagerTabStrip) act.findViewById(R.id.viewpager_tabs)).setNavEnabled(false);
   menuShown = true;
   this.fill();
 }
  public void hide() {
    TranslateAnimation ta = new TranslateAnimation(0, -menuSize, 0, 0);
    ta.setDuration(500);
    menu.startAnimation(ta);
    parent.removeView(menu);

    TranslateAnimation tra = new TranslateAnimation(menuSize, 0, 0, 0);
    tra.setDuration(500);
    content.startAnimation(tra);
    FrameLayout.LayoutParams parm = (FrameLayout.LayoutParams) content.getLayoutParams();
    parm.setMargins(0, 0, 0, 0);
    content.setLayoutParams(parm);
    enableDisableViewGroup(
        (LinearLayout) parent.findViewById(android.R.id.content).getParent(), true);
    // ((ExtendedViewPager) act.findViewById(R.id.viewpager)).setPagingEnabled(true);
    // ((ExtendedPagerTabStrip) act.findViewById(R.id.viewpager_tabs)).setNavEnabled(true);
    menuShown = false;
  }
Ejemplo n.º 29
0
  private void rmTopBarView() {
    mTopLayout.startAnimation(mAnimationHide);
    mAnimationHide.setAnimationListener(
        new AnimationListener() {

          @Override
          public void onAnimationStart(Animation arg0) {}

          @Override
          public void onAnimationRepeat(Animation arg0) {}

          @Override
          public void onAnimationEnd(Animation arg0) {
            addTopBarView();
          }
        });
    mTopLayout.setVisibility(View.GONE);
  }
Ejemplo n.º 30
0
  /** 开启动画 */
  private void startAnim() {
    // 动画集合
    AnimationSet set = new AnimationSet(false);

    // 旋转动画
    RotateAnimation rotate =
        new RotateAnimation(
            0, 360, Animation.RELATIVE_TO_SELF, 0.5f, Animation.RELATIVE_TO_SELF, 0.5f);
    rotate.setDuration(2000); // 旋转时间
    rotate.setFillAfter(true); // 保持动画状态
    // 缩放动画
    ScaleAnimation scale =
        new ScaleAnimation(
            0, 1, 0, 1, Animation.RELATIVE_TO_SELF, 0.5f, Animation.RELATIVE_TO_SELF, 0.5f);
    scale.setDuration(2000); // 时间
    scale.setFillAfter(true); // 保持动画状态
    // 渐变动画
    AlphaAnimation alpha = new AlphaAnimation(0, 1);
    alpha.setDuration(2000); // 时间
    alpha.setFillAfter(true); // 保持动画状态

    set.addAnimation(rotate);
    set.addAnimation(scale);
    set.addAnimation(alpha);
    // 设定动画监听
    set.setAnimationListener(
        new Animation.AnimationListener() {
          @Override
          public void onAnimationStart(Animation animation) {}

          @Override
          public void onAnimationEnd(Animation animation) {
            // 动画结束后跳转到GuideActivity中
            jumpNextPage();
          }

          @Override
          public void onAnimationRepeat(Animation animation) {}
        });

    rlRoot.startAnimation(set);
  }