Android View Close closeSoftInput(Context context, View focusingView)

Here you can find the source of closeSoftInput(Context context, View focusingView)

Description

close Soft Input

Declaration

public static void closeSoftInput(Context context, View focusingView) 

Method Source Code

//package com.java2s;

import android.content.Context;

import android.view.View;

import android.view.inputmethod.InputMethodManager;

public class Main {
    public static void closeSoftInput(Context context, View focusingView) {
        InputMethodManager imm = (InputMethodManager) context
                .getSystemService(Context.INPUT_METHOD_SERVICE);
        imm.hideSoftInputFromWindow(focusingView.getWindowToken(),
                InputMethodManager.RESULT_UNCHANGED_SHOWN);
    }//from   www  .  j a v a2  s. c o m
}