diff options
author | 2022-03-08 14:50:45 -0800 | |
---|---|---|
committer | 2022-04-07 20:53:48 +0000 | |
commit | 36b55bc2acc8a7aa9a8ba41a9c7a21aa0626b0f7 (patch) | |
tree | 13028589e08988734aacfd604afd8183e23201b6 | |
parent | 4fed9b4544a6f8e1819dfde45bc6d8eeeb89aa2e (diff) |
Sync with ISurfaceComposerClient changes
ISurfaceComposerClient in libgui is migrated to AIDL interface.
Bug: 172002646
Test: atest libgui_test
Change-Id: I5301a710a84bcf90ca4a789e184748e889115045
-rw-r--r-- | libs/input/SpriteController.cpp | 3 | ||||
-rw-r--r-- | native/android/surface_control.cpp | 9 |
2 files changed, 4 insertions, 8 deletions
diff --git a/libs/input/SpriteController.cpp b/libs/input/SpriteController.cpp index 2b809eab4ae4..a5ca49847bb6 100644 --- a/libs/input/SpriteController.cpp +++ b/libs/input/SpriteController.cpp @@ -249,8 +249,7 @@ void SpriteController::doUpdateSprites() { // Pass cursor metadata in the sprite surface so that when Android is running as a // client OS (e.g. ARC++) the host OS can get the requested cursor metadata and // update mouse cursor in the host OS. - t.setMetadata( - update.state.surfaceControl, METADATA_MOUSE_CURSOR, p); + t.setMetadata(update.state.surfaceControl, gui::METADATA_MOUSE_CURSOR, p); } int32_t surfaceLayer = mOverlayLayer + update.state.layer; diff --git a/native/android/surface_control.cpp b/native/android/surface_control.cpp index 98edcc30f985..c2afc609e947 100644 --- a/native/android/surface_control.cpp +++ b/native/android/surface_control.cpp @@ -80,7 +80,7 @@ ASurfaceControl* ASurfaceControl_createFromWindow(ANativeWindow* window, const c Surface* surface = static_cast<Surface*>(window); sp<IBinder> parentHandle = surface->getSurfaceControlHandle(); - uint32_t flags = ISurfaceComposerClient::eFXSurfaceBufferState; + int32_t flags = ISurfaceComposerClient::eFXSurfaceBufferState; sp<SurfaceControl> surfaceControl; if (parentHandle) { surfaceControl = @@ -88,11 +88,8 @@ ASurfaceControl* ASurfaceControl_createFromWindow(ANativeWindow* window, const c // Format is only relevant for buffer queue layers. PIXEL_FORMAT_UNKNOWN /* format */, flags, parentHandle); } else { - surfaceControl = - client->createWithSurfaceParent(String8(debug_name), 0 /* width */, 0 /* height */, - // Format is only relevant for buffer queue layers. - PIXEL_FORMAT_UNKNOWN /* format */, flags, - static_cast<Surface*>(window)); + // deprecated, this should no longer be used + surfaceControl = nullptr; } if (!surfaceControl) { |