android - Inflate context menu in a SherlockListFragment -
how create contextmenu xml in sherlocklistfragment
. know (see in examples)
@override public void oncreatecontextmenu(contextmenu menu, view v, contextmenu.contextmenuinfo menuinfo) { menu.add("one"); menu.add("two"); menu.add("three"); menu.add("four"); }
this work sherlocklistfragment
wanna inflate menu/context_menu.xml
after while found solution
@override public void oncreatecontextmenu(contextmenu menu, view v, contextmenuinfo menuinfo) { getsherlockactivity().getmenuinflater().inflate(r.menu.context_menu, menu); }
Comments
Post a Comment