summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
Diffstat (limited to 'services')
-rw-r--r--services/java/com/android/server/AppWidgetService.java2
-rw-r--r--services/java/com/android/server/InputMethodManagerService.java14
-rw-r--r--services/java/com/android/server/PackageManagerService.java2
-rw-r--r--services/java/com/android/server/WindowManagerService.java39
-rw-r--r--services/java/com/android/server/status/StatusBarPolicy.java6
5 files changed, 49 insertions, 14 deletions
diff --git a/services/java/com/android/server/AppWidgetService.java b/services/java/com/android/server/AppWidgetService.java
index 24526af..dc5fd30 100644
--- a/services/java/com/android/server/AppWidgetService.java
+++ b/services/java/com/android/server/AppWidgetService.java
@@ -869,7 +869,7 @@ class AppWidgetService extends IAppWidgetService.Stub
out.startTag(null, "p");
out.attribute(null, "pkg", p.info.provider.getPackageName());
out.attribute(null, "cl", p.info.provider.getClassName());
- out.endTag(null, "h");
+ out.endTag(null, "p");
p.tag = providerIndex;
providerIndex++;
}
diff --git a/services/java/com/android/server/InputMethodManagerService.java b/services/java/com/android/server/InputMethodManagerService.java
index 0c205ca..5bf66e4 100644
--- a/services/java/com/android/server/InputMethodManagerService.java
+++ b/services/java/com/android/server/InputMethodManagerService.java
@@ -889,13 +889,27 @@ public class InputMethodManagerService extends IInputMethodManager.Stub
MSG_UNBIND_METHOD, mCurSeq, mCurClient.client));
}
}
+
+ private void finishSession(SessionState sessionState) {
+ if (sessionState != null && sessionState.session != null) {
+ try {
+ sessionState.session.finishSession();
+ } catch (RemoteException e) {
+ Slog.w(TAG, "Session failed to close due to remote exception", e);
+ }
+ }
+ }
void clearCurMethodLocked() {
if (mCurMethod != null) {
for (ClientState cs : mClients.values()) {
cs.sessionRequested = false;
+ finishSession(cs.curSession);
cs.curSession = null;
}
+
+ finishSession(mEnabledSession);
+ mEnabledSession = null;
mCurMethod = null;
}
mStatusBar.setIconVisibility(mInputMethodIcon, false);
diff --git a/services/java/com/android/server/PackageManagerService.java b/services/java/com/android/server/PackageManagerService.java
index 49d2a76..d23c16a 100644
--- a/services/java/com/android/server/PackageManagerService.java
+++ b/services/java/com/android/server/PackageManagerService.java
@@ -2363,7 +2363,7 @@ class PackageManagerService extends IPackageManager.Stub {
&& (p.applicationInfo.flags&ApplicationInfo.FLAG_PERSISTENT) != 0
&& (!mSafeMode || (p.applicationInfo.flags
&ApplicationInfo.FLAG_SYSTEM) != 0)) {
- finalList.add(p.applicationInfo);
+ finalList.add(PackageParser.generateApplicationInfo(p, flags));
}
}
}
diff --git a/services/java/com/android/server/WindowManagerService.java b/services/java/com/android/server/WindowManagerService.java
index e13f0af..3a181b2 100644
--- a/services/java/com/android/server/WindowManagerService.java
+++ b/services/java/com/android/server/WindowManagerService.java
@@ -6551,18 +6551,30 @@ public class WindowManagerService extends IWindowManager.Stub
case RawInputEvent.CLASS_KEYBOARD:
KeyEvent ke = (KeyEvent)ev.event;
if (ke.isDown()) {
- lastKey = ke;
- downTime = curTime;
- keyRepeatCount = 0;
lastKeyTime = curTime;
- nextKeyTime = lastKeyTime
- + ViewConfiguration.getLongPressTimeout();
- if (DEBUG_INPUT) Slog.v(
- TAG, "Received key down: first repeat @ "
- + nextKeyTime);
+ if (lastKey != null &&
+ ke.getKeyCode() == lastKey.getKeyCode()) {
+ keyRepeatCount++;
+ // Arbitrary long timeout to block
+ // repeating here since we know that
+ // the device driver takes care of it.
+ nextKeyTime = lastKeyTime + LONG_WAIT;
+ if (DEBUG_INPUT) Slog.v(
+ TAG, "Received repeated key down");
+ } else {
+ downTime = curTime;
+ keyRepeatCount = 0;
+ nextKeyTime = lastKeyTime
+ + ViewConfiguration.getLongPressTimeout();
+ if (DEBUG_INPUT) Slog.v(
+ TAG, "Received key down: first repeat @ "
+ + nextKeyTime);
+ }
+ lastKey = ke;
} else {
lastKey = null;
downTime = 0;
+ keyRepeatCount = 0;
// Arbitrary long timeout.
lastKeyTime = curTime;
nextKeyTime = curTime + LONG_WAIT;
@@ -6570,7 +6582,12 @@ public class WindowManagerService extends IWindowManager.Stub
TAG, "Received key up: ignore repeat @ "
+ nextKeyTime);
}
- dispatchKey((KeyEvent)ev.event, 0, 0);
+ if (keyRepeatCount > 0) {
+ dispatchKey(KeyEvent.changeTimeRepeat(ke,
+ ke.getEventTime(), keyRepeatCount), 0, 0);
+ } else {
+ dispatchKey(ke, 0, 0);
+ }
mQueue.recycleEvent(ev);
break;
case RawInputEvent.CLASS_TOUCHSCREEN:
@@ -8709,7 +8726,8 @@ public class WindowManagerService extends IWindowManager.Stub
for (int i=0; i<N; i++) {
WindowState win = allAppWindows.get(i);
if (win == startingWindow || win.mAppFreezing
- || win.mViewVisibility != View.VISIBLE) {
+ || win.mViewVisibility != View.VISIBLE
+ || win.mAttrs.type == TYPE_APPLICATION_STARTING) {
continue;
}
if (DEBUG_VISIBILITY) {
@@ -11353,6 +11371,7 @@ public class WindowManagerService extends IWindowManager.Stub
"DimSurface",
-1, 16, 16, PixelFormat.OPAQUE,
Surface.FX_SURFACE_DIM);
+ mDimSurface.setAlpha(0.0f);
} catch (Exception e) {
Slog.e(TAG, "Exception creating Dim surface", e);
}
diff --git a/services/java/com/android/server/status/StatusBarPolicy.java b/services/java/com/android/server/status/StatusBarPolicy.java
index 94d1cb4..3b0c436 100644
--- a/services/java/com/android/server/status/StatusBarPolicy.java
+++ b/services/java/com/android/server/status/StatusBarPolicy.java
@@ -954,7 +954,9 @@ public class StatusBarPolicy {
&& ((mServiceState.getRadioTechnology()
== ServiceState.RADIO_TECHNOLOGY_EVDO_0)
|| (mServiceState.getRadioTechnology()
- == ServiceState.RADIO_TECHNOLOGY_EVDO_A)));
+ == ServiceState.RADIO_TECHNOLOGY_EVDO_A)
+ || (mServiceState.getRadioTechnology()
+ == ServiceState.RADIO_TECHNOLOGY_EVDO_B)));
}
private boolean hasService() {
@@ -1070,7 +1072,6 @@ public class StatusBarPolicy {
}
private final void updateDataNetType(int net) {
-
switch (net) {
case TelephonyManager.NETWORK_TYPE_EDGE:
mDataIconList = sDataNetType_e;
@@ -1096,6 +1097,7 @@ public class StatusBarPolicy {
break;
case TelephonyManager.NETWORK_TYPE_EVDO_0: //fall through
case TelephonyManager.NETWORK_TYPE_EVDO_A:
+ case TelephonyManager.NETWORK_TYPE_EVDO_B:
mDataIconList = sDataNetType_3g;
break;
default: