Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

ShareActionProvider menu style

I have this menu when the user clicks on the ShareActionProvider: enter image description here

How can I change its background color. I suppose I have to style it but I cannot find anywhere how.

like image 863
alecnash Avatar asked Sep 12 '13 12:09

alecnash


1 Answers

You might want to take a look at the source code, if there is no documentation on how to apply a style. I haven't actually tried to style the ShareActionProvider, but I got quite some clues from the code:

  1. ShareActionProvider.java is probably responsible in the first place
  2. ActivityChooserView.java looks like the used view class which leads to ...
  3. abc_activity_chooser_view.xml is most likely the used view, which has ?attr/activityChooserViewStyle applied as the style reference
  4. looking into themes.xml yields in line 75:

    <item name="activityChooserViewStyle">@style/Widget.AppCompat.ActivityChooserView</item>
    

Would love to hear if this works, as I might be in the same situation soon ;)

like image 107
Brian Avatar answered Oct 22 '22 05:10

Brian