android - 如何将android上的三点按钮更改为其他按钮

标签 android

我想将 Android 上的三点按钮更改为其他按钮,即“添加”按钮。怎么做?我已经更改了在我的 drawable 中设置按钮,但它一直提示三点按钮。

谢谢

最佳答案

抱歉,我不能作为评论回复,但我猜你想更改操作栏溢出菜单图标。如果是这样,您可以在 styles.xml 中完成。

 <!-- Application theme. -->
<style name="AppTheme" parent="AppBaseTheme">
    <!-- All customizations that are NOT specific to a particular API-level can go here. -->
    <item name="android:actionOverflowButtonStyle">@style/MyActionButtonOverflow</item>
</style>

<!-- Style to replace actionbar overflow icon. set item 'android:actionOverflowButtonStyle' in AppTheme -->
<style name="MyActionButtonOverflow" parent="android:style/Widget.Holo.Light.ActionButton.Overflow">
    <item name="android:src">@drawable/ic_launcher</item>
</style>

原帖:How to change option menu icon in the action bar?

关于android - 如何将android上的三点按钮更改为其他按钮,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/30267758/

相关文章:

java - 如何在Android中的AsyncTask中应用此代码?

android - 禁用单用户

java - 什么时候应该使用公共(public)变量?

android - Espresso 2.1 找不到我的测试

android - 在 UiAutomator 测试中检测或抑制键盘

android - 异步任务在不同的 Activity 中开始和结束

java - 为什么我会收到错误 : cannot find symbol variable in R class

Android 支持库 v4 对话框 fragment

java - 使用自定义对象数组列表实例化 fragment

android - 添加一个用C编写的新SDK到android中