【问题标题】:Is it possible to animate a DialogFragment?是否可以为 DialogFragment 设置动画?
【发布时间】:2011-05-25 19:11:57
【问题描述】:

我尝试了有关片段动画的各种示例,但没有任何反应,所以 DialogFragment 不是“正确的”片段吗?或者我在这里错过了什么?

FragmentTransaction ft = getFragmentManager().beginTransaction();                                      
InfoDialogFragment newFragment = InfoDialogFragment.newInstance();
newFragment.setAsset(mainShow, c,backgroundDrawable);
ft.setCustomAnimations(R.anim.grow_in, R.anim.fadeout);
ft.add(newFragment, "dialog");
ft.commit();
...
public class InfoDialogFragment extends DialogFragment {

【问题讨论】:

    标签: android android-3.0-honeycomb android-fragments


    【解决方案1】:

    Here 是 Google 工程师在这个问题上必须说的话。

    【讨论】:

      猜你喜欢
      • 2015-10-22
      • 2012-01-22
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2021-07-05
      • 1970-01-01
      相关资源
      最近更新 更多