user1854555
user1854555

Reputation: 323

Android clickable Custom Action Provider

I'm using ActionBarSherlock and creating a custom ActionProvider. When clicking on the custom action provider, I've managed to make the topmost LinearLayout clickable and set a custom selector on it.

The problem is that compared to simple menu item with an icon, the custom action provider doesn't use the selector to highlight the action bar entirely from top to bottom. A few pixels on top and bottom are not being highlighted.

enter image description here

There is probably an elegant solution to make the entire custom action provider behave like a simple clickable menu item with an icon. Any help will be greatly appreciated.

Upvotes: 2

Views: 1443

Answers (1)

user1854555
user1854555

Reputation: 323

I figured it out. Instead of using an Action Provider, I used the actionLayout for the menu item and made it clickable as shown in this post.

Upvotes: 1

Related Questions