mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-03-01 00:06:47 +00:00
Merge "Show IME switcher only when physical keyboard is connected in 3 button nav (instead of also when virtual keyboard is visible)" into tm-qpr-dev
This commit is contained in:
@@ -108,8 +108,6 @@ public class NavbarButtonsViewController implements TaskbarControllers.LoggableT
|
||||
private static final int FLAG_SCREEN_PINNING_ACTIVE = 1 << 11;
|
||||
private static final int FLAG_VOICE_INTERACTION_WINDOW_SHOWING = 1 << 12;
|
||||
|
||||
private static final int MASK_IME_SWITCHER_VISIBLE = FLAG_SWITCHER_SUPPORTED | FLAG_IME_VISIBLE;
|
||||
|
||||
private static final String NAV_BUTTONS_SEPARATE_WINDOW_TITLE = "Taskbar Nav Buttons";
|
||||
|
||||
public static final int ALPHA_INDEX_IMMERSIVE_MODE = 0;
|
||||
@@ -191,7 +189,7 @@ public class NavbarButtonsViewController implements TaskbarControllers.LoggableT
|
||||
isThreeButtonNav ? mStartContextualContainer : mEndContextualContainer,
|
||||
mControllers.navButtonController, R.id.ime_switcher);
|
||||
mPropertyHolders.add(new StatePropertyHolder(imeSwitcherButton,
|
||||
flags -> ((flags & MASK_IME_SWITCHER_VISIBLE) != 0)
|
||||
flags -> ((flags & FLAG_SWITCHER_SUPPORTED) != 0)
|
||||
&& ((flags & FLAG_ROTATION_BUTTON_VISIBLE) == 0)));
|
||||
}
|
||||
|
||||
@@ -506,6 +504,13 @@ public class NavbarButtonsViewController implements TaskbarControllers.LoggableT
|
||||
return (mState & FLAG_IME_VISIBLE) != 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns true if IME switcher is visible
|
||||
*/
|
||||
public boolean isImeSwitcherVisible() {
|
||||
return (mState & FLAG_SWITCHER_SUPPORTED) != 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns true if the home button is disabled
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user