use of android.support.v7.internal.view.menu.ListMenuPresenter in project HoloEverywhere by Prototik.
the class ActionBarActivityDelegateBase method getListMenuView.
private MenuView getListMenuView(Context context, MenuPresenter.Callback cb) {
if (mMenu == null) {
return null;
}
if (mListMenuPresenter == null) {
TypedArray a = context.obtainStyledAttributes(R.styleable.Theme);
final int listPresenterTheme = a.getResourceId(R.styleable.Theme_panelMenuListTheme, R.style.Theme_AppCompat_CompactMenu);
a.recycle();
mListMenuPresenter = new ListMenuPresenter(R.layout.abc_list_menu_item_layout, listPresenterTheme);
mListMenuPresenter.setCallback(cb);
mMenu.addMenuPresenter(mListMenuPresenter);
} else {
// Make sure we update the ListView
mListMenuPresenter.updateMenuView(false);
}
return mListMenuPresenter.getMenuView(new FrameLayout(context));
}
Aggregations