summaryrefslogtreecommitdiff
path: root/services/surfaceflinger/Layer.cpp
diff options
context:
space:
mode:
author Gil Dekel <gildekel@google.com> 2025-03-13 15:06:23 -0700
committer Android (Google) Code Review <android-gerrit@google.com> 2025-03-13 15:06:23 -0700
commitc28b463221a7516fa8e9aa30dfd33f290f635e99 (patch)
tree2d4965a18e9f6d2c551016fdc651ee78ebec1033 /services/surfaceflinger/Layer.cpp
parent961b0183bf2d5256f19e9425dabe78e995e3486f (diff)
parent9897d79b9e0f6b961ca693f37716260372aa945c (diff)
Merge changes from topic "make-displayid-opaque" into main
* changes: SF: Remove PhysicalDisplayId::getPort() SF: Remove *DisplayId::tryCast and DisplayId::isVirtual() SF: Remove *DisplayId::tryCast usage from ScreenCaptureOutput SF: Remove *DisplayId::tryCast usage from VirtualDisplaySurface SF: Remove *DisplayId::tryCast usage from Output
Diffstat (limited to 'services/surfaceflinger/Layer.cpp')
-rw-r--r--services/surfaceflinger/Layer.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/services/surfaceflinger/Layer.cpp b/services/surfaceflinger/Layer.cpp
index 95a7170fbb..3a884d6a0b 100644
--- a/services/surfaceflinger/Layer.cpp
+++ b/services/surfaceflinger/Layer.cpp
@@ -1433,8 +1433,8 @@ void Layer::onCompositionPresented(const DisplayDevice* display,
presentFence,
FrameTracer::FrameEvent::PRESENT_FENCE);
mDeprecatedFrameTracker.setActualPresentFence(std::shared_ptr<FenceTime>(presentFence));
- } else if (const auto displayId = PhysicalDisplayId::tryCast(display->getId());
- displayId && mFlinger->getHwComposer().isConnected(*displayId)) {
+ } else if (const auto displayId = asPhysicalDisplayId(display->getDisplayIdVariant());
+ displayId.has_value() && mFlinger->getHwComposer().isConnected(*displayId)) {
// The HWC doesn't support present fences, so use the present timestamp instead.
const nsecs_t presentTimestamp =
mFlinger->getHwComposer().getPresentTimestamp(*displayId);