Friday, 15 February 2013

android - Get item view from ActionBar -



android - Get item view from ActionBar -

i have actionbarsherlock 1 menu item in bar. when i'm phone call view item = findviewbyid(r.id.my_item);in activity's button onclick works fine expected. when seek in oncreate or onresume or in onpostresume null. tryed in oncreateoptionsmenu(menu menu) after inflating menu resource, without succes.

therefore can't understand when actionbar items created , how grab moment?

as has been said here , here, getactionview returns view sets in setactionview. therefore, 1 way customize action bar menu item described here

android actionbarsherlock activity-lifecycle android-inflate

No comments:

Post a Comment