Weird behavior need more investigations
This commit is contained in:
parent
d2def723e9
commit
cebfc126a8
|
@ -7,7 +7,7 @@ android {
|
||||||
applicationId "fr.gouv.etalab.mastodon"
|
applicationId "fr.gouv.etalab.mastodon"
|
||||||
minSdkVersion 15
|
minSdkVersion 15
|
||||||
targetSdkVersion 28
|
targetSdkVersion 28
|
||||||
versionCode 177
|
versionCode 178
|
||||||
versionName "1.19.2"
|
versionName "1.19.2"
|
||||||
}
|
}
|
||||||
flavorDimensions "default"
|
flavorDimensions "default"
|
||||||
|
|
|
@ -1415,16 +1415,12 @@ public class Helper {
|
||||||
|
|
||||||
if( actionButton != null) {
|
if( actionButton != null) {
|
||||||
actionButton.setFocusableInTouchMode(true);
|
actionButton.setFocusableInTouchMode(true);
|
||||||
|
actionButton.setFocusable(true);
|
||||||
actionButton.setOnFocusChangeListener(new View.OnFocusChangeListener() {
|
actionButton.setOnFocusChangeListener(new View.OnFocusChangeListener() {
|
||||||
@Override
|
@Override
|
||||||
public void onFocusChange(View v, boolean hasFocus) {
|
public void onFocusChange(View v, boolean hasFocus) {
|
||||||
try {
|
try {
|
||||||
if( !activity.isFinishing() ){
|
actionMenu.close(true);
|
||||||
if( hasFocus && !actionMenu.isOpen())
|
|
||||||
actionMenu.open(true);
|
|
||||||
else if( !hasFocus && actionMenu.isOpen())
|
|
||||||
actionMenu.close(true);
|
|
||||||
}
|
|
||||||
}catch (Exception ignored){}
|
}catch (Exception ignored){}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue