android - the setting options in another activity -
in app on top right of action bar, have setting 3 dots (as usual setting). when click on it, shows white rectangle has word "setting" on it! don't want that!! want 3 dots , when click want take me activity right away(without showing option setting on rectangle). code setting xml:
<item android:id="@+id/action_settings" android:orderincategory="0" android:title="@string/action_settings" android:textcolor="@color/colorbackground" app:showasaction="never" /> </menu>
the 3 dots you're talking there if don't have enough room in action bar , want of menu items show in menu instead of directly displaying action bar. best thing create item , set app:showasaction
, call method using onoptionsitemselected
event:
<item android:id="@+id/your_id" android:title="your title" app:showasaction="always" />
call this:
@override public boolean onoptionsitemselected(menuitem item) { switch (item.getitemid()){ case r.id.your_id: //code here... } return super.onoptionsitemselected(item); }
Comments
Post a Comment