M
M
Mikhail Chvarkov2017-09-26 12:46:03
Android
Mikhail Chvarkov, 2017-09-26 12:46:03

How to change/remove popup on icons in toolbar?

I use android.support.design.widget.AppBarLayout and android.support.v7.widget.Toolbar
With a long tap on the icon from the menu, a pop-up with a title appears. Here's how to customize it or remove it altogether?
2af8ee74f0194a2999e1e617a0a72366.jpg

Answer the question

In order to leave comments, you need to log in

2 answer(s)
R
rainmatic, 2017-09-28
@KuSu

Replace your android:icon="@drawable/ic_android" with a custom layout, as you were advised above:

android:actionLayout="@layout/item_layout"

And already in it place your icon ic_android. In general, this toast is made specifically to prescribe in it what happens when you click. And judging by the "informativeness" of your icon, I would advise you to leave it.

D
del del, 2017-09-26
@PeterSamokhin

Show your markup. If you do something like this:

<menu xmlns:android="http://schemas.android.com/apk/res/android" >
    <item
        android:id="@+id/item_id"
        android:actionLayout="@layout/item_layout"
        android:showAsAction="always"/>
</menu>

There should be no pop-up Toast.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question