使用setOnClickFillInIntent()后,Android小部件列表视图动画消失了

时间:2017-02-10 20:59:14

标签: android listview animation widget

我有一个显示列表视图的小部件。单击列表视图中的某个项目时,默认动画将显示为我的触摸反馈。

将clickHandler添加到项目后(请参阅下面的代码),动画不再显示。如何获取(默认)动画?

    // Pseudo-Code: After setting setOnClickFillInIntent() the animation is gone
    RemoteViews rv = new RemoteViews(mContext.getPackageName(),R.layout.simple_list_item_layout);
    Intent fillInIntent = new Intent();
    rv.setOnClickFillInIntent(R.id.textView, fillInIntent);

1 个答案:

答案 0 :(得分:0)

确保R.id.textView中的R.layout.simple_list_item_layout 是根元素