diff options
author | Matthew Wong <wongma@protonmail.ch> | 2015-07-28 11:52:59 -0400 |
---|---|---|
committer | Matthew Wong <wongma@protonmail.ch> | 2015-08-14 17:36:46 -0400 |
commit | 0c0054b5656afdf67ba9250669d9a38dae8b24dc (patch) | |
tree | 172e88eebabb608dd9c1469ebe8299a9f3b089ca /app | |
parent | 485b621b042041fb92f9b1c0765ef2edd83745f4 (diff) |
Dialog dismissal behaviour. (com.android.inputmethod, the keyboard, is a TYPE_WINDOW_STATE_CHANGED, so needs an exception)
Diffstat (limited to 'app')
-rw-r--r-- | app/src/main/java/com/zeapo/pwdstore/AutofillService.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/app/src/main/java/com/zeapo/pwdstore/AutofillService.java b/app/src/main/java/com/zeapo/pwdstore/AutofillService.java index 5093dac3..a490fe17 100644 --- a/app/src/main/java/com/zeapo/pwdstore/AutofillService.java +++ b/app/src/main/java/com/zeapo/pwdstore/AutofillService.java @@ -68,12 +68,14 @@ public class AutofillService extends AccessibilityService { if (!event.isPassword() || Build.VERSION.SDK_INT < Build.VERSION_CODES.JELLY_BEAN_MR2 || event.getPackageName().equals("org.sufficientlysecure.keychain")) { - if (dialog != null && dialog.isShowing()) { + if (!(event.getEventType() == AccessibilityEvent.TYPE_WINDOW_STATE_CHANGED + && event.getPackageName().toString().contains("com.android.inputmethod")) + && dialog != null && dialog.isShowing()) { dialog.dismiss(); } return; } - if (!event.getSource().equals(info) && dialog != null && dialog.isShowing()) { + if (dialog != null && dialog.isShowing()) { dialog.dismiss(); } if (ignoreActionFocus) { |