@Override
public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {
inflater.inflate(R.menu.cab_requests, menu);
super.onCreateOptionsMenu(menu, inflater);
synchronized (LOCK) {
MenuItem selectAll = menu.findItem(R.id.selectAll);
try {
final Activity act = getActivity();
final int tintColor = DialogUtils.resolveColor(act, R.attr.toolbar_icons_color);
if (mAdapter == null || mAdapter.getSelectedCount() == 0) {
selectAll.setIcon(
TintUtils.createTintedDrawable(act, R.drawable.ic_action_selectall, tintColor));
} else {
selectAll.setIcon(
TintUtils.createTintedDrawable(act, R.drawable.ic_action_close, tintColor));
}
} catch (Throwable e) {
e.printStackTrace();
selectAll.setVisible(false);
}
selectAll.setVisible(mAppsLoaded);
}
}
RequestsFragment.java 文件源码
java
阅读 19
收藏 0
点赞 0
评论 0
项目:polar-dashboard
作者:
评论列表
文章目录