summaryrefslogtreecommitdiff
path: root/app/src
diff options
context:
space:
mode:
authorMatthew Wong <wongma@protonmail.ch>2015-07-28 11:52:59 -0400
committerMatthew Wong <wongma@protonmail.ch>2015-08-14 17:36:46 -0400
commit0c0054b5656afdf67ba9250669d9a38dae8b24dc (patch)
tree172e88eebabb608dd9c1469ebe8299a9f3b089ca /app/src
parent485b621b042041fb92f9b1c0765ef2edd83745f4 (diff)
Dialog dismissal behaviour. (com.android.inputmethod, the keyboard, is a TYPE_WINDOW_STATE_CHANGED, so needs an exception)
Diffstat (limited to 'app/src')
-rw-r--r--app/src/main/java/com/zeapo/pwdstore/AutofillService.java6
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) {