Skip to content

Commit

Permalink
Dismiss the library menu when the list is focused (#2815)
Browse files Browse the repository at this point in the history
  • Loading branch information
keianhzo committed Feb 21, 2020
1 parent 889049d commit 6e949a2
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,10 @@ public void updateUI() {
mBinding.setCallback(mBookmarksCallback);
mBookmarkAdapter = new BookmarkAdapter(mBookmarkItemCallback, getContext());
mBinding.bookmarksList.setAdapter(mBookmarkAdapter);
mBinding.bookmarksList.setOnTouchListener((v, event) -> {
v.requestFocusFromTouch();
return false;
});
mBinding.bookmarksList.addOnScrollListener(mScrollListener);
mBinding.bookmarksList.setHasFixedSize(true);
mBinding.bookmarksList.setItemViewCacheSize(20);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,10 @@ public void updateUI() {
mBinding.setCallback(mHistoryCallback);
mHistoryAdapter = new HistoryAdapter(mHistoryItemCallback, getContext());
mBinding.historyList.setAdapter(mHistoryAdapter);
mBinding.historyList.setOnTouchListener((v, event) -> {
v.requestFocusFromTouch();
return false;
});
mBinding.historyList.addOnScrollListener(mScrollListener);
mBinding.historyList.setHasFixedSize(true);
mBinding.historyList.setItemViewCacheSize(20);
Expand Down

0 comments on commit 6e949a2

Please sign in to comment.