summaryrefslogtreecommitdiffstats
path: root/tools/layoutlib
diff options
context:
space:
mode:
authorDianne Hackborn <hackbod@google.com>2012-12-03 14:09:06 -0800
committerDianne Hackborn <hackbod@google.com>2012-12-03 14:09:06 -0800
commitbb4ca5271a806c94a59d98c5c718db7b89728246 (patch)
tree26e3c86678c04445c774e7e5856dd8d0b3e896d1 /tools/layoutlib
parentf87488095e49028eb3be5a8a53a372e38eba537c (diff)
downloadframeworks_base-bb4ca5271a806c94a59d98c5c718db7b89728246.zip
frameworks_base-bb4ca5271a806c94a59d98c5c718db7b89728246.tar.gz
frameworks_base-bb4ca5271a806c94a59d98c5c718db7b89728246.tar.bz2
Fix issue #7649590: Background windows sometimes not being hidden for secondary users
There are two things going on here: (1) In secondary users, some times theme information such as whether the window is full screen opaque was not being retrieved, so the window manager didn't know that it could hide the windows behind the app. This would just be a performance problem, except that: (2) There appear to be a number of applications that declare that they are full screen opaque, when in fact they are not. Instead they are using window surfaces with an alpha channel, and setting some pixels in their window to a non-opaque alpha level. This will allow you to see whatever is behind the app. If the system happens to completely remove the windows behind the app, and somebody is filling the frame buffer with black, then you will see what the app intends -- those parts of its UI blended with black. If one of those cases doesn't hold (and though we have never guaranteed they would, in practice this is generally what happens), then you will see something else. At any rate, if nothing else than for performance reasons, we need to fix issue #1. It turns out what is happening here is that the AttributeCache used by the activity manager and window manager to retreive theme and other information about applications has not yet been updated for multi-user. One of the things we retrieve from this is the theme information telling the window manager whether an application's window should be treated as full screen opaque, allowing it to hide any windows behind it. In the current implementation, the AttributeCache always retrieves this information about the application as the primary user (user 0). So, if you have an application that is installed on a secondary user but not installed on the primary user, when the AttributeCache tries to retrieve the requested information for it, then from the perspective of the primary user it considers the application not installed, and is not able to retrieve that info. The change here makes AttributeCache multi-user aware, keeping all of its data separately per-user, and requiring that callers now provide the user they want to retrieve information for. Activity manager and window manager are updated to be able to pass in the user when needed. This required some fiddling of the window manager to have that information available -- in particular it needs to be associated with the AppWindowToken. Change-Id: I4b50b4b3a41bab9d4689e61f3584778e451343c8
Diffstat (limited to 'tools/layoutlib')
-rw-r--r--tools/layoutlib/bridge/src/android/view/IWindowManagerImpl.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/layoutlib/bridge/src/android/view/IWindowManagerImpl.java b/tools/layoutlib/bridge/src/android/view/IWindowManagerImpl.java
index 3e625f9..091c6e5 100644
--- a/tools/layoutlib/bridge/src/android/view/IWindowManagerImpl.java
+++ b/tools/layoutlib/bridge/src/android/view/IWindowManagerImpl.java
@@ -87,7 +87,7 @@ public class IWindowManagerImpl implements IWindowManager {
// ---- unused implementation of IWindowManager ----
@Override
- public void addAppToken(int arg0, IApplicationToken arg1, int arg2, int arg3, boolean arg4,
+ public void addAppToken(int arg0, int arg1p5, IApplicationToken arg1, int arg2, int arg3, boolean arg4,
boolean arg5)
throws RemoteException {
// TODO Auto-generated method stub