List of usage examples for android.view.inputmethod InputMethodManager HIDE_IMPLICIT_ONLY
int HIDE_IMPLICIT_ONLY
To view the source code for android.view.inputmethod InputMethodManager HIDE_IMPLICIT_ONLY.
Click Source Link
From source file:Main.java
public static void hideKeyboard(Activity activity) { InputMethodManager imm = (InputMethodManager) activity.getSystemService(Activity.INPUT_METHOD_SERVICE); imm.toggleSoftInput(InputMethodManager.HIDE_IMPLICIT_ONLY, 0); }
From source file:Main.java
public static void hideKeyBoard(Context context) { InputMethodManager imm = (InputMethodManager) context.getSystemService(Context.INPUT_METHOD_SERVICE); imm.toggleSoftInput(0, InputMethodManager.HIDE_IMPLICIT_ONLY); }
From source file:Main.java
public static void toggleSoftInput(Context context) { InputMethodManager imm = (InputMethodManager) context.getSystemService(Context.INPUT_METHOD_SERVICE); imm.toggleSoftInput(InputMethodManager.SHOW_FORCED, InputMethodManager.HIDE_IMPLICIT_ONLY); }
From source file:Main.java
public static void hideSoft(View view) { ((InputMethodManager) view.getContext().getSystemService(Context.INPUT_METHOD_SERVICE)) .hideSoftInputFromWindow(view.getWindowToken(), InputMethodManager.HIDE_IMPLICIT_ONLY); }
From source file:Main.java
public static void showKeyBoard(Context context, View view) { view.requestFocus();/*from ww w .j ava 2 s . c om*/ InputMethodManager imm = (InputMethodManager) context.getSystemService(Context.INPUT_METHOD_SERVICE); imm.toggleSoftInput(InputMethodManager.SHOW_FORCED, InputMethodManager.HIDE_IMPLICIT_ONLY); }
From source file:Main.java
public static void showSoftKeyBoard(Context context, EditText edit) { InputMethodManager imm = (InputMethodManager) context.getSystemService(Context.INPUT_METHOD_SERVICE); imm.showSoftInput(edit, InputMethodManager.RESULT_SHOWN); imm.toggleSoftInput(InputMethodManager.SHOW_FORCED, InputMethodManager.HIDE_IMPLICIT_ONLY); }
From source file:Main.java
public static void hideSoftKeyboard(Activity activity) { InputMethodManager inputMethodManager = (InputMethodManager) activity .getSystemService(Context.INPUT_METHOD_SERVICE); inputMethodManager.hideSoftInputFromWindow(activity.getCurrentFocus().getWindowToken(), InputMethodManager.HIDE_IMPLICIT_ONLY); }
From source file:Main.java
/** * Toggle Soft Input./*from w w w . j a va2 s. c om*/ * @param context */ public static void toggleSoftInput(Context context) { InputMethodManager inputManager = (InputMethodManager) context .getSystemService(Context.INPUT_METHOD_SERVICE); inputManager.toggleSoftInput(InputMethodManager.SHOW_IMPLICIT, InputMethodManager.HIDE_IMPLICIT_ONLY); }
From source file:Main.java
/** * Shows the keyboard.// w w w.j a va 2s. c o m * @param view */ private static void showKeyboard(View view) { Context context = view.getContext(); InputMethodManager imm = (InputMethodManager) context.getSystemService(Context.INPUT_METHOD_SERVICE); imm.toggleSoftInput(InputMethodManager.SHOW_FORCED, InputMethodManager.HIDE_IMPLICIT_ONLY); }
From source file:Main.java
/** * Shows the keyboard./*from w ww . j a v a 2s .com*/ * * @param view */ public static void showKeyboard(View view) { Context context = view.getContext(); InputMethodManager imm = (InputMethodManager) context.getSystemService(Context.INPUT_METHOD_SERVICE); imm.toggleSoftInput(InputMethodManager.SHOW_FORCED, InputMethodManager.HIDE_IMPLICIT_ONLY); }