android.transition.Explode.setDuration()方法的使用及代码示例

x33g5p2x  于2022-01-19 转载在 其他  
字(3.0k)|赞(0)|评价(0)|浏览(122)

本文整理了Java中android.transition.Explode.setDuration()方法的一些代码示例,展示了Explode.setDuration()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Explode.setDuration()方法的具体详情如下:
包路径:android.transition.Explode
类名称:Explode
方法名:setDuration

Explode.setDuration介绍

暂无

代码示例

代码示例来源:origin: fanrunqi/MaterialLogin

@Override
  protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.a_activity_three);

    Explode explode = new Explode();
    explode.setDuration(500);
    getWindow().setExitTransition(explode);
    getWindow().setEnterTransition(explode);
  }
}

代码示例来源:origin: fanrunqi/MaterialLogin

@Override
  public void onClick(View view) {
    Explode explode = new Explode();
    explode.setDuration(500);
    getWindow().setExitTransition(explode);
    getWindow().setEnterTransition(explode);
    ActivityOptionsCompat oc2 = ActivityOptionsCompat.makeSceneTransitionAnimation(AActivityOne.this);
    Intent i2 = new Intent(AActivityOne.this,AActivityThree.class);
    startActivity(i2, oc2.toBundle());
  }
});

代码示例来源:origin: OCNYang/Android-Animation-Set

private Transition buildEnterTransitionByCode() {
  Explode enterTransition = new Explode();
  enterTransition.setDuration(500);
  return enterTransition;
}

代码示例来源:origin: GuoFeilong/BehivorDemo

private Explode buildMyExplodeInstance() {
  Explode explode = new Explode();
  explode.setDuration(animDuration);
  return explode;
}

代码示例来源:origin: RealMoMo/Study_Android_Demo

private Transition buildEnterTransitionByCode() {
  Explode enterTransition = new Explode();
  enterTransition.setDuration(500);
  return enterTransition;
}

代码示例来源:origin: JustinRoom/JSCKit

@TargetApi(Build.VERSION_CODES.LOLLIPOP)
public static Explode createExplode(long duration) {
  Explode explode = new Explode();
  explode.setDuration(duration);
  return explode;
}

代码示例来源:origin: Wing-Li/Material-Animations-CN

private Transition buildEnterTransition() {
    Explode enterTransition = new Explode();
    enterTransition.setDuration(getResources().getInteger(R.integer.anim_duration_long));
    // 修饰动画,定义动画的变化率
    enterTransition.setInterpolator(new AccelerateInterpolator());
    return enterTransition;
  }
}

代码示例来源:origin: Trisaa/MaterialTranstion

private void initTransition() {
  Explode explode = new Explode();
  explode.setDuration(1000L);
  getWindow().setEnterTransition(explode);
  explode.addListener(new Transition.TransitionListener() {

代码示例来源:origin: WakeHao/TransitionExample

@Override
protected void onCreate(Bundle savedInstanceState) {
  super.onCreate(savedInstanceState);
  setContentView(R.layout.activity_content_transitions);
  initToolbar();
  Slide slide=new Slide();
  slide.setDuration(500);
  slide.setSlideEdge(Gravity.LEFT);
  getWindow().setEnterTransition(slide);
  getWindow().setReenterTransition(new Explode().setDuration(600));
}

代码示例来源:origin: DingMouRen/DingDingMusic

private void setupWindowAnimation() {
  Explode explode = new Explode();
  explode.setDuration(1000);
  Fade fade = new Fade();
  fade.setDuration(500);
  getWindow().setReenterTransition(fade);
  getWindow().setExitTransition(explode);
  getWindow().setSharedElementExitTransition(new ChangeImageTransform());
  getWindow().setSharedElementReenterTransition(new ChangeImageTransform());
}

相关文章