diff options
Diffstat (limited to 'services')
-rw-r--r-- | services/java/com/android/server/InputMethodManagerService.java | 17 | ||||
-rw-r--r-- | services/jni/com_android_server_UsbService.cpp | 3 |
2 files changed, 2 insertions, 18 deletions
diff --git a/services/java/com/android/server/InputMethodManagerService.java b/services/java/com/android/server/InputMethodManagerService.java index 9c9d406..1455764 100644 --- a/services/java/com/android/server/InputMethodManagerService.java +++ b/services/java/com/android/server/InputMethodManagerService.java @@ -60,7 +60,6 @@ import android.os.RemoteException; import android.os.ResultReceiver; import android.os.ServiceManager; import android.os.SystemClock; -import android.os.SystemProperties; import android.provider.Settings; import android.provider.Settings.Secure; import android.provider.Settings.SettingNotFoundException; @@ -315,7 +314,6 @@ public class InputMethodManagerService extends IInputMethodManager.Stub int mBackDisposition = InputMethodService.BACK_DISPOSITION_DEFAULT; int mImeWindowVis; - long mOldSystemSettingsVersion; AlertDialog.Builder mDialogBuilder; AlertDialog mSwitchingDialog; @@ -490,8 +488,6 @@ public class InputMethodManagerService extends IInputMethodManager.Stub handleMessage(msg); } }); - // Initialize the system settings version to undefined. - mOldSystemSettingsVersion = -1; (new MyPackageMonitor()).register(mContext, true); @@ -1012,15 +1008,7 @@ public class InputMethodManagerService extends IInputMethodManager.Stub } } - // TODO: Investigate and fix why are settings changes getting processed before the settings seq - // number is updated? - // TODO: Change this stuff to not rely on modifying settings for normal user interactions. void updateFromSettingsLocked() { - long newSystemSettingsVersion = getSystemSettingsVersion(); - // This is a workaround to avoid a situation that old cached value in Settings.Secure - // will be handled. - if (newSystemSettingsVersion == mOldSystemSettingsVersion) return; - // We are assuming that whoever is changing DEFAULT_INPUT_METHOD and // ENABLED_INPUT_METHODS is taking care of keeping them correctly in // sync, so we will never have a DEFAULT_INPUT_METHOD that is not @@ -1989,7 +1977,6 @@ public class InputMethodManagerService extends IInputMethodManager.Stub private void setSelectedInputMethodAndSubtypeLocked(InputMethodInfo imi, int subtypeId, boolean setSubtypeOnly) { - mOldSystemSettingsVersion = getSystemSettingsVersion(); // Update the history of InputMethod and Subtype saveCurrentInputMethodAndSubtypeToHistory(); @@ -2239,10 +2226,6 @@ public class InputMethodManagerService extends IInputMethodManager.Stub } } - private static long getSystemSettingsVersion() { - return SystemProperties.getLong(Settings.Secure.SYS_PROP_SETTING_VERSION, 0); - } - /** * @return Return the current subtype of this input method. */ diff --git a/services/jni/com_android_server_UsbService.cpp b/services/jni/com_android_server_UsbService.cpp index c66f181..816f76f 100644 --- a/services/jni/com_android_server_UsbService.cpp +++ b/services/jni/com_android_server_UsbService.cpp @@ -193,13 +193,14 @@ static jobjectArray android_server_UsbService_getAccessoryStrings(JNIEnv *env, j return NULL; } jclass stringClass = env->FindClass("java/lang/String"); - jobjectArray strArray = env->NewObjectArray(5, stringClass, NULL); + jobjectArray strArray = env->NewObjectArray(6, stringClass, NULL); if (!strArray) goto out; set_accessory_string(env, fd, ACCESSORY_GET_STRING_MANUFACTURER, strArray, 0); set_accessory_string(env, fd, ACCESSORY_GET_STRING_MODEL, strArray, 1); set_accessory_string(env, fd, ACCESSORY_GET_STRING_DESCRIPTION, strArray, 2); set_accessory_string(env, fd, ACCESSORY_GET_STRING_VERSION, strArray, 3); set_accessory_string(env, fd, ACCESSORY_GET_STRING_URI, strArray, 4); + set_accessory_string(env, fd, ACCESSORY_GET_STRING_SERIAL, strArray, 5); out: close(fd); |