mirror of
https://github.com/nextcloud/talk-android
synced 2025-02-02 20:53:09 +00:00
avoid NPE
trying to avoid #1976 Signed-off-by: Marcel Hibbe <dev@mhibbe.de>
This commit is contained in:
parent
bddbf48198
commit
59f1f003ca
@ -715,9 +715,13 @@ public class ConversationsListController extends BaseController implements Searc
|
||||
});
|
||||
|
||||
recyclerView.setOnTouchListener((v, event) -> {
|
||||
InputMethodManager imm =
|
||||
(InputMethodManager) getActivity().getSystemService(Context.INPUT_METHOD_SERVICE);
|
||||
imm.hideSoftInputFromWindow(v.getWindowToken(), 0);
|
||||
if (isAttached() && (!isBeingDestroyed() || !isDestroyed())) {
|
||||
InputMethodManager imm =
|
||||
(InputMethodManager) getActivity().getSystemService(Context.INPUT_METHOD_SERVICE);
|
||||
if (imm != null) {
|
||||
imm.hideSoftInputFromWindow(v.getWindowToken(), 0);
|
||||
}
|
||||
}
|
||||
return false;
|
||||
});
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user