|
@@ -30,7 +30,6 @@ import android.util.Base64;
|
|
|
import android.util.Log;
|
|
import android.util.Log;
|
|
|
import android.view.Gravity;
|
|
import android.view.Gravity;
|
|
|
import android.view.View;
|
|
import android.view.View;
|
|
|
-import android.view.WindowManager;
|
|
|
|
|
import android.view.inputmethod.InputMethodManager;
|
|
import android.view.inputmethod.InputMethodManager;
|
|
|
import android.widget.EditText;
|
|
import android.widget.EditText;
|
|
|
import android.widget.ImageView;
|
|
import android.widget.ImageView;
|
|
@@ -895,17 +894,18 @@ public class CommonUtil {
|
|
|
* @param mContext 上下文
|
|
* @param mContext 上下文
|
|
|
*/
|
|
*/
|
|
|
public static void closeKeybord( final Activity mContext) {
|
|
public static void closeKeybord( final Activity mContext) {
|
|
|
|
|
+
|
|
|
if (mContext != null) {
|
|
if (mContext != null) {
|
|
|
- if(mContext.getWindow().getAttributes().softInputMode == WindowManager.LayoutParams.SOFT_INPUT_STATE_VISIBLE){
|
|
|
|
|
- OAHttpHelper.getInstance().postDelayed(new Runnable() {
|
|
|
|
|
- @Override
|
|
|
|
|
- public void run() {
|
|
|
|
|
- InputMethodManager imm = (InputMethodManager) mContext
|
|
|
|
|
- .getSystemService(Context.INPUT_METHOD_SERVICE);
|
|
|
|
|
- imm.hideSoftInputFromWindow(mContext.getWindow().getDecorView().getWindowToken(), 0);
|
|
|
|
|
- }
|
|
|
|
|
- }, 100);
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ LogUtil.i("gong","closeKeybord");
|
|
|
|
|
+ OAHttpHelper.getInstance().postDelayed(new Runnable() {
|
|
|
|
|
+ @Override
|
|
|
|
|
+ public void run() {
|
|
|
|
|
+ InputMethodManager imm = (InputMethodManager) mContext
|
|
|
|
|
+ .getSystemService(Context.INPUT_METHOD_SERVICE);
|
|
|
|
|
+ LogUtil.i("gong", "closeKeybord showshow");
|
|
|
|
|
+ imm.hideSoftInputFromWindow(mContext.getWindow().getDecorView().getWindowToken(), 0);
|
|
|
|
|
+ }
|
|
|
|
|
+ }, 100);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
}
|
|
}
|