From 4f2dd40cd731a52debecedbef845c2d6e2de5e06 Mon Sep 17 00:00:00 2001 From: chaviw Date: Wed, 26 Dec 2018 15:30:27 -0800 Subject: Fix drag and drop (3/3) Remove reference to old transferTouchInput that was used from InputManager Test: Builds Bug: 120463595 Change-Id: Id7cb864fdec898fc1a2a4b90245efe2187c72031 --- services/inputflinger/InputDispatcher.cpp | 13 ++++--------- services/inputflinger/InputDispatcher.h | 5 ----- 2 files changed, 4 insertions(+), 14 deletions(-) diff --git a/services/inputflinger/InputDispatcher.cpp b/services/inputflinger/InputDispatcher.cpp index 7997928624..8e3aa5fd2f 100644 --- a/services/inputflinger/InputDispatcher.cpp +++ b/services/inputflinger/InputDispatcher.cpp @@ -3374,11 +3374,6 @@ void InputDispatcher::setInputFilterEnabled(bool enabled) { mLooper->wake(); } -bool InputDispatcher::transferTouchFocus(const sp& fromChannel, - const sp& toChannel) { - return transferTouchFocus(fromChannel->getToken(), toChannel->getToken()); -} - bool InputDispatcher::transferTouchFocus(const sp& fromToken, const sp& toToken) { if (fromToken == toToken) { #if DEBUG_FOCUS @@ -3392,14 +3387,14 @@ bool InputDispatcher::transferTouchFocus(const sp& fromToken, const sp< sp fromWindowHandle = getWindowHandleLocked(fromToken); sp toWindowHandle = getWindowHandleLocked(toToken); -#if DEBUG_FOCUS - ALOGD("transferTouchFocus: fromWindowHandle=%s, toWindowHandle=%s", - fromWindowHandle->getName().c_str(), toWindowHandle->getName().c_str()); -#endif if (fromWindowHandle == nullptr || toWindowHandle == nullptr) { ALOGW("Cannot transfer focus because from or to window not found."); return false; } +#if DEBUG_FOCUS + ALOGD("transferTouchFocus: fromWindowHandle=%s, toWindowHandle=%s", + fromWindowHandle->getName().c_str(), toWindowHandle->getName().c_str()); +#endif if (fromWindowHandle->getInfo()->displayId != toWindowHandle->getInfo()->displayId) { #if DEBUG_FOCUS ALOGD("Cannot transfer focus because windows are on different displays."); diff --git a/services/inputflinger/InputDispatcher.h b/services/inputflinger/InputDispatcher.h index 970632e5e2..41f7dee7d6 100644 --- a/services/inputflinger/InputDispatcher.h +++ b/services/inputflinger/InputDispatcher.h @@ -349,9 +349,6 @@ public: */ virtual bool transferTouchFocus(const sp& fromToken, const sp& toToken) = 0; - virtual bool transferTouchFocus(const sp& fromChannel, - const sp& toChannel) = 0; - /* Registers input channels that may be used as targets for input events. * If inputWindowHandle is null, and displayId is not ADISPLAY_ID_NONE, * the channel will receive a copy of all input events form the specific displayId. @@ -416,8 +413,6 @@ public: virtual void setInputFilterEnabled(bool enabled); virtual bool transferTouchFocus(const sp& fromToken, const sp& toToken); - virtual bool transferTouchFocus(const sp& fromChannel, - const sp& toChannel); virtual status_t registerInputChannel(const sp& inputChannel, int32_t displayId); -- cgit v1.2.3-59-g8ed1b