Loading services/inputflinger/benchmarks/InputDispatcher_benchmarks.cpp +2 −2 Original line number Diff line number Diff line Loading @@ -268,7 +268,7 @@ static void benchmarkNotifyMotion(benchmark::State& state) { sp<FakeWindowHandle> window = sp<FakeWindowHandle>::make(application, dispatcher, "Fake Window"); dispatcher.setInputWindows({{ADISPLAY_ID_DEFAULT, {window}}}); dispatcher.onWindowInfosChanged({{*window->getInfo()}, {}, 0, 0}); NotifyMotionArgs motionArgs = generateMotionArgs(); Loading Loading @@ -303,7 +303,7 @@ static void benchmarkInjectMotion(benchmark::State& state) { sp<FakeWindowHandle> window = sp<FakeWindowHandle>::make(application, dispatcher, "Fake Window"); dispatcher.setInputWindows({{ADISPLAY_ID_DEFAULT, {window}}}); dispatcher.onWindowInfosChanged({{*window->getInfo()}, {}, 0, 0}); for (auto _ : state) { MotionEvent event = generateMotionEvent(); Loading services/inputflinger/dispatcher/InputDispatcher.cpp +0 −13 Original line number Diff line number Diff line Loading @@ -5057,19 +5057,6 @@ void InputDispatcher::updateWindowHandlesForDisplayLocked( mWindowHandlesByDisplay[displayId] = newHandles; } void InputDispatcher::setInputWindows( const std::unordered_map<int32_t, std::vector<sp<WindowInfoHandle>>>& handlesPerDisplay) { // TODO(b/198444055): Remove setInputWindows from InputDispatcher. { // acquire lock std::scoped_lock _l(mLock); for (const auto& [displayId, handles] : handlesPerDisplay) { setInputWindowsLocked(handles, displayId); } } // Wake up poll loop since it may need to make new input dispatching choices. mLooper->wake(); } /** * Called from InputManagerService, update window handle list by displayId that can receive input. * A window handle contains information about InputChannel, Touch Region, Types, Focused,... Loading services/inputflinger/dispatcher/InputDispatcher.h +0 −3 Original line number Diff line number Diff line Loading @@ -109,9 +109,6 @@ public: std::unique_ptr<VerifiedInputEvent> verifyInputEvent(const InputEvent& event) override; void setInputWindows( const std::unordered_map<int32_t, std::vector<sp<android::gui::WindowInfoHandle>>>& handlesPerDisplay) override; void setFocusedApplication( int32_t displayId, const std::shared_ptr<InputApplicationHandle>& inputApplicationHandle) override; Loading services/inputflinger/dispatcher/include/InputDispatcherInterface.h +0 −8 Original line number Diff line number Diff line Loading @@ -87,14 +87,6 @@ public: */ virtual std::unique_ptr<VerifiedInputEvent> verifyInputEvent(const InputEvent& event) = 0; /* Sets the list of input windows per display. * * This method may be called on any thread (usually by the input manager). */ virtual void setInputWindows( const std::unordered_map<int32_t, std::vector<sp<gui::WindowInfoHandle>>>& handlesPerDisplay) = 0; /* Sets the focused application on the given display. * * This method may be called on any thread (usually by the input manager). Loading services/inputflinger/tests/InputDispatcher_test.cpp +328 −227 File changed.Preview size limit exceeded, changes collapsed. Show changes Loading
services/inputflinger/benchmarks/InputDispatcher_benchmarks.cpp +2 −2 Original line number Diff line number Diff line Loading @@ -268,7 +268,7 @@ static void benchmarkNotifyMotion(benchmark::State& state) { sp<FakeWindowHandle> window = sp<FakeWindowHandle>::make(application, dispatcher, "Fake Window"); dispatcher.setInputWindows({{ADISPLAY_ID_DEFAULT, {window}}}); dispatcher.onWindowInfosChanged({{*window->getInfo()}, {}, 0, 0}); NotifyMotionArgs motionArgs = generateMotionArgs(); Loading Loading @@ -303,7 +303,7 @@ static void benchmarkInjectMotion(benchmark::State& state) { sp<FakeWindowHandle> window = sp<FakeWindowHandle>::make(application, dispatcher, "Fake Window"); dispatcher.setInputWindows({{ADISPLAY_ID_DEFAULT, {window}}}); dispatcher.onWindowInfosChanged({{*window->getInfo()}, {}, 0, 0}); for (auto _ : state) { MotionEvent event = generateMotionEvent(); Loading
services/inputflinger/dispatcher/InputDispatcher.cpp +0 −13 Original line number Diff line number Diff line Loading @@ -5057,19 +5057,6 @@ void InputDispatcher::updateWindowHandlesForDisplayLocked( mWindowHandlesByDisplay[displayId] = newHandles; } void InputDispatcher::setInputWindows( const std::unordered_map<int32_t, std::vector<sp<WindowInfoHandle>>>& handlesPerDisplay) { // TODO(b/198444055): Remove setInputWindows from InputDispatcher. { // acquire lock std::scoped_lock _l(mLock); for (const auto& [displayId, handles] : handlesPerDisplay) { setInputWindowsLocked(handles, displayId); } } // Wake up poll loop since it may need to make new input dispatching choices. mLooper->wake(); } /** * Called from InputManagerService, update window handle list by displayId that can receive input. * A window handle contains information about InputChannel, Touch Region, Types, Focused,... Loading
services/inputflinger/dispatcher/InputDispatcher.h +0 −3 Original line number Diff line number Diff line Loading @@ -109,9 +109,6 @@ public: std::unique_ptr<VerifiedInputEvent> verifyInputEvent(const InputEvent& event) override; void setInputWindows( const std::unordered_map<int32_t, std::vector<sp<android::gui::WindowInfoHandle>>>& handlesPerDisplay) override; void setFocusedApplication( int32_t displayId, const std::shared_ptr<InputApplicationHandle>& inputApplicationHandle) override; Loading
services/inputflinger/dispatcher/include/InputDispatcherInterface.h +0 −8 Original line number Diff line number Diff line Loading @@ -87,14 +87,6 @@ public: */ virtual std::unique_ptr<VerifiedInputEvent> verifyInputEvent(const InputEvent& event) = 0; /* Sets the list of input windows per display. * * This method may be called on any thread (usually by the input manager). */ virtual void setInputWindows( const std::unordered_map<int32_t, std::vector<sp<gui::WindowInfoHandle>>>& handlesPerDisplay) = 0; /* Sets the focused application on the given display. * * This method may be called on any thread (usually by the input manager). Loading
services/inputflinger/tests/InputDispatcher_test.cpp +328 −227 File changed.Preview size limit exceeded, changes collapsed. Show changes