protected void hideSoftKeyboard() { if (getActivity().getWindow().getAttributes().softInputMode != WindowManager.LayoutParams.SOFT_INPUT_STATE_HIDDEN) { if (getActivity().getCurrentFocus() != null) inputMethodManager.hideSoftInputFromWindow(getActivity().getCurrentFocus().getWindowToken(), InputMethodManager.HIDE_NOT_ALWAYS); } }
protected void hideSoftKeyboard() { if (getActivity().getWindow().getAttributes().softInputMode != WindowManager.LayoutParams.SOFT_INPUT_STATE_HIDDEN) { if (getActivity().getCurrentFocus() != null) inputMethodManager.hideSoftInputFromWindow(getActivity().getCurrentFocus().getWindowToken(), InputMethodManager.HIDE_NOT_ALWAYS); } }
protected void hideSoftKeyboard() { if (getActivity().getWindow().getAttributes().softInputMode != WindowManager.LayoutParams.SOFT_INPUT_STATE_HIDDEN) { if (getActivity().getCurrentFocus() != null) inputMethodManager.hideSoftInputFromWindow(getActivity().getCurrentFocus().getWindowToken(), InputMethodManager.HIDE_NOT_ALWAYS); } }
protected void hideSoftKeyboard() { if (getActivity().getWindow().getAttributes().softInputMode != WindowManager.LayoutParams.SOFT_INPUT_STATE_HIDDEN) { if (getActivity().getCurrentFocus() != null) inputMethodManager.hideSoftInputFromWindow(getActivity().getCurrentFocus().getWindowToken(), InputMethodManager.HIDE_NOT_ALWAYS); } }
protected void hideSoftKeyboard() { if (getActivity().getWindow().getAttributes().softInputMode != WindowManager.LayoutParams.SOFT_INPUT_STATE_HIDDEN) { if (getActivity().getCurrentFocus() != null) inputMethodManager.hideSoftInputFromWindow(getActivity().getCurrentFocus().getWindowToken(), InputMethodManager.HIDE_NOT_ALWAYS); } }
@Override protected void initView() { inputMethodManager = (InputMethodManager) getActivity().getSystemService(Context.INPUT_METHOD_SERVICE); //会话列表控件 conversationListView = (EaseConversationList) getView().findViewById(R.id.list); // 搜索框 query = (EditText) getView().findViewById(R.id.query); // 搜索框中清除button clearSearch = (ImageButton) getView().findViewById(R.id.search_clear); errorItemContainer = (FrameLayout) getView().findViewById(R.id.fl_error_item); }
@Override protected void initView() { inputMethodManager = (InputMethodManager) getActivity().getSystemService(Context.INPUT_METHOD_SERVICE); conversationListView = (EaseConversationList) getView().findViewById(R.id.list); query = (EditText) getView().findViewById(R.id.query); // button to clear content in search bar clearSearch = (ImageButton) getView().findViewById(R.id.search_clear); errorItemContainer = (FrameLayout) getView().findViewById(R.id.fl_error_item); }
@Override protected void initView() { inputMethodManager = (InputMethodManager) getActivity().getSystemService(Context.INPUT_METHOD_SERVICE); conversationListView = (EaseConversationList) getView().findViewById(R.id.list); query = (EditText) getView().findViewById(R.id.query); // button to clear content in search bar clearSearch = (ImageButton) getView().findViewById(R.id.search_clear); errorItemContainer = (FrameLayout) getView().findViewById(R.id.fl_error_item); }
@Override protected void initView() { inputMethodManager = (InputMethodManager) getActivity().getSystemService(Context.INPUT_METHOD_SERVICE); conversationListView = (EaseConversationList) getView().findViewById(R.id.list); query = (EditText) getView().findViewById(R.id.query); // button to clear content in search bar clearSearch = (ImageButton) getView().findViewById(R.id.search_clear); errorItemContainer = (FrameLayout) getView().findViewById(R.id.fl_error_item); }
@Override protected void initView() { inputMethodManager = (InputMethodManager) getActivity().getSystemService(Context.INPUT_METHOD_SERVICE); conversationListView = (EaseConversationList) getView().findViewById(R.id.list); query = (EditText) getView().findViewById(R.id.query); // button to clear content in search bar clearSearch = (ImageButton) getView().findViewById(R.id.search_clear); errorItemContainer = (FrameLayout) getView().findViewById(R.id.fl_error_item); title_bar= (EaseTitleBar) getView().findViewById(R.id.title_bar); title_bar.setVisibility(View.GONE); }