OSDN Git Service

Update window surface while activity is set to full screen.
authorsuncx <changyingx.sun@intel.com>
Wed, 23 Mar 2016 07:40:00 +0000 (15:40 +0800)
committerChih-Wei Huang <cwhuang@linux.org.tw>
Wed, 20 Jul 2016 09:53:32 +0000 (17:53 +0800)
Other than surface resized or surface moved, setSurfaceBoundariesLocked
in WindowStateAnimator.java may encounter another scenario that the
flag of window is set to LayoutParams.FLAG_FULLSCREEN. In all of
scenarios, updateSurfaceWindowCrop(...) should be called separately
to avoid float window flickering when it's dragged off screen.

This patch is meant to refine the previous patch:
https://android.intel.com/#/c/468817/

Change-Id: I4ca86588650a58661a13a925b7cb73ac9b0637c0
Tracked-On: https://jira01.devtools.intel.com/browse/OAM-24062
Signed-off-by: suncx <changyingx.sun@intel.com>
Reviewed-on: https://android.intel.com:443/485284

services/core/java/com/android/server/wm/WindowStateAnimator.java

index 40e41ea..c515a63 100644 (file)
@@ -1444,6 +1444,9 @@ class WindowStateAnimator {
             }
         }
 
+        if ((w.mAttrs.flags & LayoutParams.FLAG_FULLSCREEN) != 0) {
+            updateSurfaceWindowCrop(recoveringMemory);
+        }
     }
 
     public void prepareSurfaceLocked(final boolean recoveringMemory) {