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

Commit 603f4d00 authored by Yohei Yukawa's avatar Yohei Yukawa
Browse files

Move InputMethodManagerService to com.android.server.inputmethod

This CL moves InputMethodManagerService (IMMS)
  from com.android.server
    to com.android.server.inputmethod
so that we can mechanically factor out inner classes from IMMS to
separate package private classes.

This is purely a mechanical refactoring of an implementation detail.
There should be no observable behavior difference.

Fix: 114660660
Test: atest CtsInputMethodTestCases CtsInputMethodServiceHostTestCases
Test: atest FrameworksCoreTests:com.android.internal.inputmethod
Change-Id: I023d8f2863601ee54f304988117d8ea750770f70
parent e3427ee4
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -87,8 +87,8 @@ class IInputMethodWrapper extends IInputMethod.Stub
     * guarantees that {@link #bindInput(InputBinding)},
     * {@link #startInput(IBinder, IInputContext, int, EditorInfo, boolean)}, and
     * {@link #unbindInput()} are called with the same order as the original calls
     * in {@link com.android.server.InputMethodManagerService}.  See {@link IBinder#FLAG_ONEWAY}
     * for detailed semantics.</p>
     * in {@link com.android.server.inputmethod.InputMethodManagerService}.
     * See {@link IBinder#FLAG_ONEWAY} for detailed semantics.</p>
     */
    AtomicBoolean mIsUnbindIssued = null;

+9 −7
Original line number Diff line number Diff line
@@ -60,7 +60,7 @@ public final class InputBindResult implements Parcelable {
        /**
         * Indicates that this is a temporary binding until the
         * {@link android.inputmethodservice.InputMethodService} (IMS) establishes a valid session
         * to {@link com.android.server.InputMethodManagerService} (IMMS).
         * to {@link com.android.server.inputmethod.InputMethodManagerService} (IMMS).
         *
         * <p>Note that in this state the IMS is already bound to IMMS but the logical session
         * is not yet established on top of the IPC channel.</p>
@@ -73,7 +73,7 @@ public final class InputBindResult implements Parcelable {
        /**
         * Indicates that this is a temporary binding until the
         * {@link android.inputmethodservice.InputMethodService} (IMS) establishes a valid session
         * to {@link com.android.server.InputMethodManagerService} (IMMS).
         * to {@link com.android.server.inputmethod.InputMethodManagerService} (IMMS).
         *
         * <p>Note that in this state the IMMS has already initiated a connection to the IMS but
         * the binding process is not completed yet.</p>
@@ -91,12 +91,14 @@ public final class InputBindResult implements Parcelable {
        int SUCCESS_REPORT_WINDOW_FOCUS_ONLY = 3;
        /**
         * Indicates somehow
         * {@link com.android.server.InputMethodManagerService#startInputOrWindowGainedFocus} is
         * trying to return null {@link InputBindResult}, which must never happen.
         * {@link
         * com.android.server.inputmethod.InputMethodManagerService#startInputOrWindowGainedFocus}
         * is trying to return null {@link InputBindResult}, which must never happen.
         */
        int ERROR_NULL = 4;
        /**
         * Indicates that {@link com.android.server.InputMethodManagerService} recognizes no IME.
         * Indicates that {@link com.android.server.inputmethod.InputMethodManagerService}
         * recognizes no IME.
         */
        int ERROR_NO_IME = 5;
        /**
@@ -114,8 +116,8 @@ public final class InputBindResult implements Parcelable {
         */
        int ERROR_SYSTEM_NOT_READY = 7;
        /**
         * Indicates that {@link com.android.server.InputMethodManagerService} tried to connect to
         * an {@link android.inputmethodservice.InputMethodService} but failed.
         * Indicates that {@link com.android.server.inputmethod.InputMethodManagerService} tried to
         * connect to an {@link android.inputmethodservice.InputMethodService} but failed.
         *
         * @see android.content.Context#bindServiceAsUser(Intent, ServiceConnection, int, UserHandle)
         */
+1 −1
Original line number Diff line number Diff line
@@ -584,7 +584,7 @@
    <protected-broadcast android:name="android.media.tv.action.PREVIEW_PROGRAM_BROWSABLE_DISABLED" />
    <protected-broadcast android:name="android.media.tv.action.WATCH_NEXT_PROGRAM_BROWSABLE_DISABLED" />
    <protected-broadcast android:name="android.media.tv.action.CHANNEL_BROWSABLE_REQUESTED" />
    <protected-broadcast android:name="com.android.server.InputMethodManagerService.SHOW_INPUT_METHOD_PICKER" />
    <protected-broadcast android:name="com.android.server.inputmethod.InputMethodManagerService.SHOW_INPUT_METHOD_PICKER" />

    <!-- Time zone rules update intents fired by the system server -->
    <protected-broadcast android:name="com.android.intent.action.timezone.RULES_UPDATE_OPERATION" />
+2 −2
Original line number Diff line number Diff line
@@ -14,11 +14,10 @@
** limitations under the License.
*/

package com.android.server;
package com.android.server.inputmethod;

import android.annotation.NonNull;
import android.annotation.UserIdInt;
import android.app.ActivityManager;
import android.app.UriGrantsManager;
import android.content.Intent;
import android.net.Uri;
@@ -28,6 +27,7 @@ import android.os.RemoteException;

import com.android.internal.annotations.GuardedBy;
import com.android.internal.inputmethod.IInputContentUriToken;
import com.android.server.LocalServices;
import com.android.server.uri.UriGrantsManagerInternal;

final class InputContentUriTokenHandler extends IInputContentUriToken.Stub {
+5 −3
Original line number Diff line number Diff line
@@ -13,7 +13,7 @@
 * the License.
 */

package com.android.server;
package com.android.server.inputmethod;

import static android.view.Display.DEFAULT_DISPLAY;
import static android.view.WindowManager.LayoutParams.PRIVATE_FLAG_SHOW_FOR_ALL_USERS;
@@ -149,7 +149,9 @@ import com.android.internal.view.IInputMethodSession;
import com.android.internal.view.IInputSessionCallback;
import com.android.internal.view.InputBindResult;
import com.android.internal.view.InputMethodClient;
import com.android.server.inputmethod.InputMethodManagerInternal;
import com.android.server.EventLogTags;
import com.android.server.LocalServices;
import com.android.server.SystemService;
import com.android.server.statusbar.StatusBarManagerService;
import com.android.server.wm.WindowManagerInternal;

@@ -253,7 +255,7 @@ public class InputMethodManagerService extends IInputMethodManager.Stub
     * the notification.
     */
    private static final String ACTION_SHOW_INPUT_METHOD_PICKER =
            "com.android.server.InputMethodManagerService.SHOW_INPUT_METHOD_PICKER";
            "com.android.server.inputmethod.InputMethodManagerService.SHOW_INPUT_METHOD_PICKER";

    /**
     * Debug flag for overriding runtime {@link SystemProperties}.
Loading