[317580] fix issue where the screen wouldn't be rotated properly in bypass mode
In some situations, the screen transformation would not be
applied while in bypass mode.
Change-Id: I3d6dd52e4c12b11aae97b54bf8e2322536eee37f
diff --git a/services/surfaceflinger/SurfaceFlinger.cpp b/services/surfaceflinger/SurfaceFlinger.cpp
index 5e9e06c..af0f95a 100644
--- a/services/surfaceflinger/SurfaceFlinger.cpp
+++ b/services/surfaceflinger/SurfaceFlinger.cpp
@@ -725,8 +725,12 @@
{
// if this layer is already the bypass layer, do nothing
sp<Layer> cur(mBypassLayer.promote());
- if (mBypassLayer == layer)
+ if (mBypassLayer == layer) {
+ if (cur != NULL) {
+ cur->updateBuffersOrientation();
+ }
return;
+ }
// clear the current bypass layer
mBypassLayer.clear();