Resolve auto close on widget swipe
Bug: 172891360 Test: Manual Change-Id: Icb384b6dc5ec9a29b6a9a7811b862a2d83ca11a7 (cherry picked from commit 5fa6f3ce503cde51687985ebc9dee6f163b9b1ea)
This commit is contained in:
1 parent
54834b0909
commit
2c86122fa4
2 files changed
+7
-5
No files matched your search
@@ -150,12 +150,14 @@ public class SearchResultWidget extends RelativeLayout implements
|
||||
public boolean onInterceptTouchEvent(MotionEvent ev) {
|
||||
mLongPressHelper.onTouchEvent(ev);
|
||||
mClickDetector.onTouchEvent(ev);
|
||||
if (ev.getAction() == MotionEvent.ACTION_UP && !mLongPressHelper.hasPerformedLongPress()) {
|
||||
handleSelection(SearchTargetEvent.CHILD_SELECT);
|
||||
}
|
||||
return super.onInterceptTouchEvent(ev);
|
||||
return mLongPressHelper.hasPerformedLongPress();
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onTouchEvent(MotionEvent ev) {
|
||||
mLongPressHelper.onTouchEvent(ev);
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void cancelLongPress() {
|
||||
|
||||
Reference in new issue
Block a user