Hide keyboard when navigating from a fragment to another
问题 I have a Fragment that contains an Edit Text. When the Edit Text is pressed, the keyboard is being shown. When pressed the Save button in the upper corner, the application returns to the previous fragment, but the keyboard persists. I would like the keyboard to be hidden when navigating to the previous fragment. Please, note that I tried this solution: Close/hide the Android Soft Keyboard. InputMethodManager imm = (InputMethodManager)getActivity().getSystemService(Context.INPUT_METHOD_SERVICE