Merge "hwc: Fix Idle fall back when external connected."
diff --git a/libhwcomposer/hwc_fbupdate.cpp b/libhwcomposer/hwc_fbupdate.cpp
index bfa33ca..7b34df9 100644
--- a/libhwcomposer/hwc_fbupdate.cpp
+++ b/libhwcomposer/hwc_fbupdate.cpp
@@ -231,7 +231,8 @@
const int halfWidth = (displayFrame.right - displayFrame.left) / 2;
const int height = displayFrame.bottom - displayFrame.top;
- ovutils::Dim dposL(MAX_DISPLAY_DIM - halfWidth,
+ const int halfDpy = ctx->dpyAttr[mDpy].xres / 2;
+ ovutils::Dim dposL(halfDpy - halfWidth,
displayFrame.top,
halfWidth,
height);