summaryrefslogtreecommitdiff
path: root/libs/hwui/renderthread
diff options
context:
space:
mode:
authorAlec Mouri <alecmouri@google.com>2019-10-25 16:18:16 -0700
committerAlec Mouri <alecmouri@google.com>2019-10-25 16:18:16 -0700
commitda819e47f14657c6eddf4905da99b92743aaa2c0 (patch)
tree991cbe6de0c62e8e6292d53ab7ba45e79151f9f9 /libs/hwui/renderthread
parent8018eeace2a71c598e8da678845f960314acceea (diff)
[HWUI] Use ANativeWindow_get{Height, Width}
gui/Surface will eventually be removed since HWUI needs to depend on a stable ABI, so use the NDK methods for querying width and height that operates on ANativeWindow instead. Bug: 137012798 Test: builds Change-Id: I1309e31992190e7b44c6ea83f962f372b6b0afcf
Diffstat (limited to 'libs/hwui/renderthread')
-rw-r--r--libs/hwui/renderthread/CanvasContext.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/libs/hwui/renderthread/CanvasContext.cpp b/libs/hwui/renderthread/CanvasContext.cpp
index 93fd0c87a361..294a6b8baceb 100644
--- a/libs/hwui/renderthread/CanvasContext.cpp
+++ b/libs/hwui/renderthread/CanvasContext.cpp
@@ -565,8 +565,8 @@ SkISize CanvasContext::getNextFrameSize() const {
ReliableSurface* surface = mNativeSurface.get();
if (surface) {
SkISize size;
- surface->query(NATIVE_WINDOW_WIDTH, &size.fWidth);
- surface->query(NATIVE_WINDOW_HEIGHT, &size.fHeight);
+ size.fWidth = ANativeWindow_getWidth(surface);
+ size.fHeight = ANativeWindow_getHeight(surface);
return size;
}
return {INT32_MAX, INT32_MAX};