mirror of
https://github.com/Helium314/HeliBoard.git
synced 2025-05-21 01:10:24 +00:00
Avoid hiding the toolbar and pinned keys during inline autofill (#474)
This commit is contained in:
parent
ea2e2b301b
commit
abc23d23be
3 changed files with 137 additions and 14 deletions
|
@ -112,6 +112,7 @@ public final class SuggestionStripView extends RelativeLayout implements OnClick
|
|||
|
||||
private final SuggestionStripLayoutHelper mLayoutHelper;
|
||||
private final StripVisibilityGroup mStripVisibilityGroup;
|
||||
private boolean isInlineAutofillSuggestionsVisible = false; // Required to disable the more suggestions if inline autofill suggestions are visible
|
||||
|
||||
private static class StripVisibilityGroup {
|
||||
private final View mSuggestionStripView;
|
||||
|
@ -259,7 +260,7 @@ public final class SuggestionStripView extends RelativeLayout implements OnClick
|
|||
: km.isKeyguardLocked();
|
||||
mToolbarExpandKey.setOnClickListener(hideToolbarKeys ? null : this);
|
||||
mPinnedKeys.setVisibility(hideToolbarKeys ? GONE : VISIBLE);
|
||||
mToolbarExpandKey.setVisibility(VISIBLE);
|
||||
isInlineAutofillSuggestionsVisible = false;
|
||||
}
|
||||
|
||||
public void setRtl(final boolean isRtlLanguage) {
|
||||
|
@ -278,8 +279,7 @@ public final class SuggestionStripView extends RelativeLayout implements OnClick
|
|||
|
||||
public void setInlineSuggestionsView(final View view) {
|
||||
clear();
|
||||
mToolbarExpandKey.setVisibility(GONE);
|
||||
mPinnedKeys.setVisibility(GONE);
|
||||
isInlineAutofillSuggestionsVisible = true;
|
||||
mSuggestionsStrip.addView(view);
|
||||
}
|
||||
|
||||
|
@ -552,7 +552,7 @@ public final class SuggestionStripView extends RelativeLayout implements OnClick
|
|||
public boolean onInterceptTouchEvent(final MotionEvent me) {
|
||||
|
||||
// Disable More Suggestions if inline autofill suggestions is visible
|
||||
if(mToolbarExpandKey.getVisibility() != VISIBLE && mPinnedKeys.getVisibility() != VISIBLE) {
|
||||
if(isInlineAutofillSuggestionsVisible) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue