Loading services/core/java/com/android/server/wm/ImeInsetsSourceProvider.java +1 −1 Original line number Diff line number Diff line Loading @@ -48,7 +48,7 @@ import java.io.PrintWriter; * Controller for IME inset source on the server. It's called provider as it provides the * {@link InsetsSource} to the client that uses it in {@link InsetsSourceConsumer}. */ final class ImeInsetsSourceProvider extends WindowContainerInsetsSourceProvider { final class ImeInsetsSourceProvider extends InsetsSourceProvider { /** The token tracking the current IME request or {@code null} otherwise. */ @Nullable Loading services/core/java/com/android/server/wm/InsetsPolicy.java +4 −5 Original line number Diff line number Diff line Loading @@ -223,10 +223,10 @@ class InsetsPolicy { startAnimation(false /* show */, () -> { synchronized (mDisplayContent.mWmService.mGlobalLock) { final SparseArray<WindowContainerInsetsSourceProvider> providers = final SparseArray<InsetsSourceProvider> providers = mStateController.getSourceProviders(); for (int i = providers.size() - 1; i >= 0; i--) { final WindowContainerInsetsSourceProvider provider = providers.valueAt(i); final InsetsSourceProvider provider = providers.valueAt(i); if (!isTransient(provider.getSource().getType())) { continue; } Loading Loading @@ -341,11 +341,10 @@ class InsetsPolicy { } } final SparseArray<WindowContainerInsetsSourceProvider> providers = mStateController.getSourceProviders(); final SparseArray<InsetsSourceProvider> providers = mStateController.getSourceProviders(); final int windowType = attrs.type; for (int i = providers.size() - 1; i >= 0; i--) { final WindowContainerInsetsSourceProvider otherProvider = providers.valueAt(i); final InsetsSourceProvider otherProvider = providers.valueAt(i); if (otherProvider.overridesFrame(windowType)) { if (state == originalState) { state = new InsetsState(state); Loading services/core/java/com/android/server/wm/InsetsSourceProvider.java +1 −1 Original line number Diff line number Diff line Loading @@ -58,7 +58,7 @@ import java.util.function.Consumer; * Controller for a specific inset source on the server. It's called provider as it provides the * {@link InsetsSource} to the client that uses it in {@link android.view.InsetsSourceConsumer}. */ abstract class InsetsSourceProvider { class InsetsSourceProvider { protected final DisplayContent mDisplayContent; protected final @NonNull InsetsSource mSource; Loading services/core/java/com/android/server/wm/InsetsStateController.java +6 −6 Original line number Diff line number Diff line Loading @@ -56,7 +56,7 @@ class InsetsStateController { private final InsetsState mState = new InsetsState(); private final DisplayContent mDisplayContent; private final SparseArray<WindowContainerInsetsSourceProvider> mProviders = new SparseArray<>(); private final SparseArray<InsetsSourceProvider> mProviders = new SparseArray<>(); private final ArrayMap<InsetsControlTarget, ArrayList<InsetsSourceProvider>> mControlTargetProvidersMap = new ArrayMap<>(); private final SparseArray<InsetsControlTarget> mIdControlTargetMap = new SparseArray<>(); Loading Loading @@ -106,22 +106,22 @@ class InsetsStateController { return result; } SparseArray<WindowContainerInsetsSourceProvider> getSourceProviders() { SparseArray<InsetsSourceProvider> getSourceProviders() { return mProviders; } /** * @return The provider of a specific source ID. */ WindowContainerInsetsSourceProvider getOrCreateSourceProvider(int id, @InsetsType int type) { WindowContainerInsetsSourceProvider provider = mProviders.get(id); InsetsSourceProvider getOrCreateSourceProvider(int id, @InsetsType int type) { InsetsSourceProvider provider = mProviders.get(id); if (provider != null) { return provider; } final InsetsSource source = mState.getOrCreateSource(id, type); provider = id == ID_IME ? new ImeInsetsSourceProvider(source, this, mDisplayContent) : new WindowContainerInsetsSourceProvider(source, this, mDisplayContent); : new InsetsSourceProvider(source, this, mDisplayContent); mProviders.put(id, provider); return provider; } Loading Loading @@ -334,7 +334,7 @@ class InsetsStateController { } mDisplayContent.mWmService.mAnimator.addAfterPrepareSurfacesRunnable(() -> { for (int i = mProviders.size() - 1; i >= 0; i--) { final WindowContainerInsetsSourceProvider provider = mProviders.valueAt(i); final InsetsSourceProvider provider = mProviders.valueAt(i); provider.onSurfaceTransactionApplied(); } final ArraySet<InsetsControlTarget> newControlTargets = new ArraySet<>(); Loading services/core/java/com/android/server/wm/WindowContainer.java +1 −1 Original line number Diff line number Diff line Loading @@ -4122,7 +4122,7 @@ class WindowContainer<E extends WindowContainer> extends ConfigurationContainer< } private void hideInsetSourceViewOverflows() { final SparseArray<WindowContainerInsetsSourceProvider> providers = final SparseArray<InsetsSourceProvider> providers = getDisplayContent().getInsetsStateController().getSourceProviders(); for (int i = providers.size(); i >= 0; i--) { final InsetsSourceProvider insetProvider = providers.valueAt(i); Loading Loading
services/core/java/com/android/server/wm/ImeInsetsSourceProvider.java +1 −1 Original line number Diff line number Diff line Loading @@ -48,7 +48,7 @@ import java.io.PrintWriter; * Controller for IME inset source on the server. It's called provider as it provides the * {@link InsetsSource} to the client that uses it in {@link InsetsSourceConsumer}. */ final class ImeInsetsSourceProvider extends WindowContainerInsetsSourceProvider { final class ImeInsetsSourceProvider extends InsetsSourceProvider { /** The token tracking the current IME request or {@code null} otherwise. */ @Nullable Loading
services/core/java/com/android/server/wm/InsetsPolicy.java +4 −5 Original line number Diff line number Diff line Loading @@ -223,10 +223,10 @@ class InsetsPolicy { startAnimation(false /* show */, () -> { synchronized (mDisplayContent.mWmService.mGlobalLock) { final SparseArray<WindowContainerInsetsSourceProvider> providers = final SparseArray<InsetsSourceProvider> providers = mStateController.getSourceProviders(); for (int i = providers.size() - 1; i >= 0; i--) { final WindowContainerInsetsSourceProvider provider = providers.valueAt(i); final InsetsSourceProvider provider = providers.valueAt(i); if (!isTransient(provider.getSource().getType())) { continue; } Loading Loading @@ -341,11 +341,10 @@ class InsetsPolicy { } } final SparseArray<WindowContainerInsetsSourceProvider> providers = mStateController.getSourceProviders(); final SparseArray<InsetsSourceProvider> providers = mStateController.getSourceProviders(); final int windowType = attrs.type; for (int i = providers.size() - 1; i >= 0; i--) { final WindowContainerInsetsSourceProvider otherProvider = providers.valueAt(i); final InsetsSourceProvider otherProvider = providers.valueAt(i); if (otherProvider.overridesFrame(windowType)) { if (state == originalState) { state = new InsetsState(state); Loading
services/core/java/com/android/server/wm/InsetsSourceProvider.java +1 −1 Original line number Diff line number Diff line Loading @@ -58,7 +58,7 @@ import java.util.function.Consumer; * Controller for a specific inset source on the server. It's called provider as it provides the * {@link InsetsSource} to the client that uses it in {@link android.view.InsetsSourceConsumer}. */ abstract class InsetsSourceProvider { class InsetsSourceProvider { protected final DisplayContent mDisplayContent; protected final @NonNull InsetsSource mSource; Loading
services/core/java/com/android/server/wm/InsetsStateController.java +6 −6 Original line number Diff line number Diff line Loading @@ -56,7 +56,7 @@ class InsetsStateController { private final InsetsState mState = new InsetsState(); private final DisplayContent mDisplayContent; private final SparseArray<WindowContainerInsetsSourceProvider> mProviders = new SparseArray<>(); private final SparseArray<InsetsSourceProvider> mProviders = new SparseArray<>(); private final ArrayMap<InsetsControlTarget, ArrayList<InsetsSourceProvider>> mControlTargetProvidersMap = new ArrayMap<>(); private final SparseArray<InsetsControlTarget> mIdControlTargetMap = new SparseArray<>(); Loading Loading @@ -106,22 +106,22 @@ class InsetsStateController { return result; } SparseArray<WindowContainerInsetsSourceProvider> getSourceProviders() { SparseArray<InsetsSourceProvider> getSourceProviders() { return mProviders; } /** * @return The provider of a specific source ID. */ WindowContainerInsetsSourceProvider getOrCreateSourceProvider(int id, @InsetsType int type) { WindowContainerInsetsSourceProvider provider = mProviders.get(id); InsetsSourceProvider getOrCreateSourceProvider(int id, @InsetsType int type) { InsetsSourceProvider provider = mProviders.get(id); if (provider != null) { return provider; } final InsetsSource source = mState.getOrCreateSource(id, type); provider = id == ID_IME ? new ImeInsetsSourceProvider(source, this, mDisplayContent) : new WindowContainerInsetsSourceProvider(source, this, mDisplayContent); : new InsetsSourceProvider(source, this, mDisplayContent); mProviders.put(id, provider); return provider; } Loading Loading @@ -334,7 +334,7 @@ class InsetsStateController { } mDisplayContent.mWmService.mAnimator.addAfterPrepareSurfacesRunnable(() -> { for (int i = mProviders.size() - 1; i >= 0; i--) { final WindowContainerInsetsSourceProvider provider = mProviders.valueAt(i); final InsetsSourceProvider provider = mProviders.valueAt(i); provider.onSurfaceTransactionApplied(); } final ArraySet<InsetsControlTarget> newControlTargets = new ArraySet<>(); Loading
services/core/java/com/android/server/wm/WindowContainer.java +1 −1 Original line number Diff line number Diff line Loading @@ -4122,7 +4122,7 @@ class WindowContainer<E extends WindowContainer> extends ConfigurationContainer< } private void hideInsetSourceViewOverflows() { final SparseArray<WindowContainerInsetsSourceProvider> providers = final SparseArray<InsetsSourceProvider> providers = getDisplayContent().getInsetsStateController().getSourceProviders(); for (int i = providers.size(); i >= 0; i--) { final InsetsSourceProvider insetProvider = providers.valueAt(i); Loading