Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5cd2e537 authored by Mayank Garg's avatar Mayank Garg
Browse files

Expose IMMI object for Proxy class

Expose IMMI object from IMMS so that IMMSProxy can redirect the internal
call based on user to respective IMMI.

IMMSProxy is a temporary plan. Once the long-term solution for concurrent multi-user IME is implemented, this change will be reverted since this IMMI ref is not going to be used anymore.

Flag: NONE <Exposing package scoped method>
Bug: 350790759
Test: m

Change-Id: Ia3cfcef9c5d176c74dff8120e2474263e3e73a9f
parent 8e6236d7
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
@@ -325,6 +325,7 @@ public final class InputMethodManagerService implements IInputMethodManagerImpl.
    final Resources mRes;
    private final Handler mHandler;

    private final InputMethodManagerInternal mInputMethodManagerInternal;
    @NonNull
    private final Handler mIoHandler;

@@ -1315,6 +1316,7 @@ public final class InputMethodManagerService implements IInputMethodManagerImpl.
            mHwController = new HandwritingModeController(mContext, thread.getLooper(),
                    new InkWindowInitializer(), discardDelegationTextRunnable);
            registerDeviceListenerAndCheckStylusSupport();
            mInputMethodManagerInternal = new LocalServiceImpl();
        }
    }

@@ -5651,7 +5653,12 @@ public final class InputMethodManagerService implements IInputMethodManagerImpl.
    }

    private void publishLocalService() {
        LocalServices.addService(InputMethodManagerInternal.class, new LocalServiceImpl());
        LocalServices.addService(InputMethodManagerInternal.class, mInputMethodManagerInternal);
    }

    // TODO(b/352228316): Remove it once IMMIProxy is removed.
    InputMethodManagerInternal getLocalService(){
        return mInputMethodManagerInternal;
    }

    private final class LocalServiceImpl extends InputMethodManagerInternal {