android - Add dropdown on custom action bar view at left, with checkable items -
i have lot of problems development of action bar. here needs:
i want add dropdown in action bar, using custom view because of custom comportment (animation example).
the dropdown have accessible image button (not spinner show text area of selected element).
the image button allow show dropdown have @ left of action bar.
the dropdown appear have contain checkable items, and, when user check item, dropdown have not hidden (this allow user check multiple items @ once).
my application have work android 2.3 (i'm using action bar sherlock that, specify because of can't use popupmenu on android 2.3).
i have added dropdown in action bar combining custom view (actionbar.setcustomview(...)) menu (menuinflater.inflate(...)). think code of customview not important, here code of menu :
<item android:title="test" android:drawable="@drawable/dropdown_icon" android:showasaction="always"> <menu> <item android:id="@+id/item1" android:title="item 1" android:checkable="true"/> <item android:id="@+id/item2" android:title="item 2" android:checkable="true"/> <item android:id="@+id/item3" android:title="item 3" android:checkable="true"/> </menu> </item>
with solution, have following problems :
- i'm not able put dropdown item @ left (it's @ right moment)
- when check item on dropdown list, dropdown hide itself. want dropdown keep showing state.
how can achieve want ?
p.s : can read, english not native language. these problems difficult explain (even in native language), if sentences not understandable, please tell me , try improve them.
i suggest doing simplest thing possible: remove actionbarsherlock related code , add own views in layout , program them animate, pop-up, show , hide.
Comments
Post a Comment