Marilia
Marilia

Reputation: 1981

Navigation bar back button custom icon?

Is it possible to change the navigation bar (image bellow for reference) back button icon programmatically? Let's say in a certain moment I'd like to change it to be the arrow down icon (normally used to hide the soft input) then change it back to the default after some user interaction.

navigation bar

Upvotes: 2

Views: 1178

Answers (1)

Marilia
Marilia

Reputation: 1981

What I ended up doing was creating a popup window over the soft input and making the soft input "arrow down" button do what I wanted on that pop up window. To control what the soft input "arrow down" button does I had to create a class that extends EditText and override:

public boolean onKeyPreIme(int keyCode, KeyEvent event)

Upvotes: 1

Related Questions