Loading libs/gui/Choreographer.cpp +7 −1 Original line number Diff line number Diff line Loading @@ -324,6 +324,12 @@ void Choreographer::dispatchHotplug(nsecs_t, PhysicalDisplayId displayId, bool c to_string(displayId).c_str(), toString(connected)); } void Choreographer::dispatchHotplugConnectionError(nsecs_t, int32_t connectionError) { ALOGV("choreographer %p ~ received hotplug connection error event (connectionError=%d), " "ignoring.", this, connectionError); } void Choreographer::dispatchModeChanged(nsecs_t, PhysicalDisplayId, int32_t, nsecs_t) { LOG_ALWAYS_FATAL("dispatchModeChanged was called but was never registered"); } Loading libs/gui/DisplayEventDispatcher.cpp +7 −1 Original line number Diff line number Diff line Loading @@ -173,7 +173,13 @@ bool DisplayEventDispatcher::processPendingEvents(nsecs_t* outTimestamp, *outVsyncEventData = ev.vsync.vsyncData; break; case DisplayEventReceiver::DISPLAY_EVENT_HOTPLUG: dispatchHotplug(ev.header.timestamp, ev.header.displayId, ev.hotplug.connected); if (ev.hotplug.connectionError == 0) { dispatchHotplug(ev.header.timestamp, ev.header.displayId, ev.hotplug.connected); } else { dispatchHotplugConnectionError(ev.header.timestamp, ev.hotplug.connectionError); } break; case DisplayEventReceiver::DISPLAY_EVENT_MODE_CHANGE: dispatchModeChanged(ev.header.timestamp, ev.header.displayId, Loading libs/gui/fuzzer/libgui_displayEvent_fuzzer.cpp +4 −1 Original line number Diff line number Diff line Loading @@ -62,7 +62,10 @@ DisplayEventReceiver::Event buildDisplayEvent(FuzzedDataProvider* fdp, uint32_t } case DisplayEventReceiver::DISPLAY_EVENT_HOTPLUG: { event.hotplug = DisplayEventReceiver::Event::Hotplug{fdp->ConsumeBool() /*connected*/}; event.hotplug = DisplayEventReceiver::Event::Hotplug{fdp->ConsumeBool() /*connected*/, fdp->ConsumeIntegral< int32_t>() /*connectionError*/}; break; } case DisplayEventReceiver::DISPLAY_EVENT_MODE_CHANGE: { Loading libs/gui/fuzzer/libgui_fuzzer_utils.h +1 −0 Original line number Diff line number Diff line Loading @@ -197,6 +197,7 @@ public: MOCK_METHOD4(dispatchVsync, void(nsecs_t, PhysicalDisplayId, uint32_t, VsyncEventData)); MOCK_METHOD3(dispatchHotplug, void(nsecs_t, PhysicalDisplayId, bool)); MOCK_METHOD2(dispatchHotplugConnectionError, void(nsecs_t, int32_t)); MOCK_METHOD4(dispatchModeChanged, void(nsecs_t, PhysicalDisplayId, int32_t, nsecs_t)); MOCK_METHOD2(dispatchNullEvent, void(nsecs_t, PhysicalDisplayId)); MOCK_METHOD3(dispatchFrameRateOverrides, Loading libs/gui/include/gui/Choreographer.h +2 −1 Original line number Diff line number Diff line Loading @@ -110,6 +110,7 @@ private: void dispatchVsync(nsecs_t timestamp, PhysicalDisplayId displayId, uint32_t count, VsyncEventData vsyncEventData) override; void dispatchHotplug(nsecs_t timestamp, PhysicalDisplayId displayId, bool connected) override; void dispatchHotplugConnectionError(nsecs_t timestamp, int32_t connectionError) override; void dispatchModeChanged(nsecs_t timestamp, PhysicalDisplayId displayId, int32_t modeId, nsecs_t vsyncPeriod) override; void dispatchNullEvent(nsecs_t, PhysicalDisplayId) override; Loading Loading
libs/gui/Choreographer.cpp +7 −1 Original line number Diff line number Diff line Loading @@ -324,6 +324,12 @@ void Choreographer::dispatchHotplug(nsecs_t, PhysicalDisplayId displayId, bool c to_string(displayId).c_str(), toString(connected)); } void Choreographer::dispatchHotplugConnectionError(nsecs_t, int32_t connectionError) { ALOGV("choreographer %p ~ received hotplug connection error event (connectionError=%d), " "ignoring.", this, connectionError); } void Choreographer::dispatchModeChanged(nsecs_t, PhysicalDisplayId, int32_t, nsecs_t) { LOG_ALWAYS_FATAL("dispatchModeChanged was called but was never registered"); } Loading
libs/gui/DisplayEventDispatcher.cpp +7 −1 Original line number Diff line number Diff line Loading @@ -173,7 +173,13 @@ bool DisplayEventDispatcher::processPendingEvents(nsecs_t* outTimestamp, *outVsyncEventData = ev.vsync.vsyncData; break; case DisplayEventReceiver::DISPLAY_EVENT_HOTPLUG: dispatchHotplug(ev.header.timestamp, ev.header.displayId, ev.hotplug.connected); if (ev.hotplug.connectionError == 0) { dispatchHotplug(ev.header.timestamp, ev.header.displayId, ev.hotplug.connected); } else { dispatchHotplugConnectionError(ev.header.timestamp, ev.hotplug.connectionError); } break; case DisplayEventReceiver::DISPLAY_EVENT_MODE_CHANGE: dispatchModeChanged(ev.header.timestamp, ev.header.displayId, Loading
libs/gui/fuzzer/libgui_displayEvent_fuzzer.cpp +4 −1 Original line number Diff line number Diff line Loading @@ -62,7 +62,10 @@ DisplayEventReceiver::Event buildDisplayEvent(FuzzedDataProvider* fdp, uint32_t } case DisplayEventReceiver::DISPLAY_EVENT_HOTPLUG: { event.hotplug = DisplayEventReceiver::Event::Hotplug{fdp->ConsumeBool() /*connected*/}; event.hotplug = DisplayEventReceiver::Event::Hotplug{fdp->ConsumeBool() /*connected*/, fdp->ConsumeIntegral< int32_t>() /*connectionError*/}; break; } case DisplayEventReceiver::DISPLAY_EVENT_MODE_CHANGE: { Loading
libs/gui/fuzzer/libgui_fuzzer_utils.h +1 −0 Original line number Diff line number Diff line Loading @@ -197,6 +197,7 @@ public: MOCK_METHOD4(dispatchVsync, void(nsecs_t, PhysicalDisplayId, uint32_t, VsyncEventData)); MOCK_METHOD3(dispatchHotplug, void(nsecs_t, PhysicalDisplayId, bool)); MOCK_METHOD2(dispatchHotplugConnectionError, void(nsecs_t, int32_t)); MOCK_METHOD4(dispatchModeChanged, void(nsecs_t, PhysicalDisplayId, int32_t, nsecs_t)); MOCK_METHOD2(dispatchNullEvent, void(nsecs_t, PhysicalDisplayId)); MOCK_METHOD3(dispatchFrameRateOverrides, Loading
libs/gui/include/gui/Choreographer.h +2 −1 Original line number Diff line number Diff line Loading @@ -110,6 +110,7 @@ private: void dispatchVsync(nsecs_t timestamp, PhysicalDisplayId displayId, uint32_t count, VsyncEventData vsyncEventData) override; void dispatchHotplug(nsecs_t timestamp, PhysicalDisplayId displayId, bool connected) override; void dispatchHotplugConnectionError(nsecs_t timestamp, int32_t connectionError) override; void dispatchModeChanged(nsecs_t timestamp, PhysicalDisplayId displayId, int32_t modeId, nsecs_t vsyncPeriod) override; void dispatchNullEvent(nsecs_t, PhysicalDisplayId) override; Loading