Android Button Bar in Holo

后端 未结 2 1049
感动是毒
感动是毒 2021-02-06 20:03

I am creating an Android app that uses the Holo theme when available and falls back to the black theme when it isn\'t available. I am accomplishing this by using the value

2条回答
  •  情歌与酒
    2021-02-06 20:42

    I solved this by using two separate layout files, one located in the layout folder and one located in layout-v11. They are almost the same except that they contain different values for the style attribute.

    The first one looks like this (in layout):

    
    
        

    The second one looks like this (in layout-v11):

    
    
        

    I am not completely satisfied with this approach because of the amount of duplicate information. I would like to find a way to use ?android:attr/buttonBarButtonStyle as a parent style, but I couldn't find a way to accomplish this.

提交回复
热议问题