Loading core/java/android/view/inputmethod/flags.aconfig +11 −0 Original line number Diff line number Diff line Loading @@ -203,3 +203,14 @@ flag { description: "Adding animating insets types and report IME visibility at the beginning of hiding" bug: "393049691" } flag { name: "lower_ime_oom_importance" namespace: "input_method" description: "Lower keyboard app process oom importance to PERCEPTIBLE_APP_ADJ + 1." bug: "372511805" is_fixed_read_only: true metadata { purpose: PURPOSE_BUGFIX } } services/core/java/com/android/server/inputmethod/InputMethodBindingController.java +11 −2 Original line number Diff line number Diff line Loading @@ -120,12 +120,21 @@ final class InputMethodBindingController { * Binding flags for establishing connection to the {@link InputMethodService}. */ @VisibleForTesting static final int IME_CONNECTION_BIND_FLAGS = Context.BIND_AUTO_CREATE static final int IME_CONNECTION_BIND_FLAGS; static { if (android.view.inputmethod.Flags.lowerImeOomImportance()) { IME_CONNECTION_BIND_FLAGS = Context.BIND_AUTO_CREATE | Context.BIND_ALMOST_PERCEPTIBLE | Context.BIND_IMPORTANT_BACKGROUND | Context.BIND_SCHEDULE_LIKE_TOP_APP; } else { IME_CONNECTION_BIND_FLAGS = Context.BIND_AUTO_CREATE | Context.BIND_NOT_VISIBLE | Context.BIND_NOT_FOREGROUND | Context.BIND_IMPORTANT_BACKGROUND | Context.BIND_SCHEDULE_LIKE_TOP_APP; } } private final int mImeConnectionBindFlags; Loading Loading
core/java/android/view/inputmethod/flags.aconfig +11 −0 Original line number Diff line number Diff line Loading @@ -203,3 +203,14 @@ flag { description: "Adding animating insets types and report IME visibility at the beginning of hiding" bug: "393049691" } flag { name: "lower_ime_oom_importance" namespace: "input_method" description: "Lower keyboard app process oom importance to PERCEPTIBLE_APP_ADJ + 1." bug: "372511805" is_fixed_read_only: true metadata { purpose: PURPOSE_BUGFIX } }
services/core/java/com/android/server/inputmethod/InputMethodBindingController.java +11 −2 Original line number Diff line number Diff line Loading @@ -120,12 +120,21 @@ final class InputMethodBindingController { * Binding flags for establishing connection to the {@link InputMethodService}. */ @VisibleForTesting static final int IME_CONNECTION_BIND_FLAGS = Context.BIND_AUTO_CREATE static final int IME_CONNECTION_BIND_FLAGS; static { if (android.view.inputmethod.Flags.lowerImeOomImportance()) { IME_CONNECTION_BIND_FLAGS = Context.BIND_AUTO_CREATE | Context.BIND_ALMOST_PERCEPTIBLE | Context.BIND_IMPORTANT_BACKGROUND | Context.BIND_SCHEDULE_LIKE_TOP_APP; } else { IME_CONNECTION_BIND_FLAGS = Context.BIND_AUTO_CREATE | Context.BIND_NOT_VISIBLE | Context.BIND_NOT_FOREGROUND | Context.BIND_IMPORTANT_BACKGROUND | Context.BIND_SCHEDULE_LIKE_TOP_APP; } } private final int mImeConnectionBindFlags; Loading