mostly fix 2392102 by overriding the force-open input thing
This commit is contained in:
@@ -61,6 +61,7 @@ import android.view.MenuItem;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.view.View.OnLongClickListener;
|
||||
import android.view.WindowManager;
|
||||
import android.view.inputmethod.InputMethodManager;
|
||||
import android.widget.EditText;
|
||||
import android.widget.TextView;
|
||||
@@ -397,6 +398,15 @@ public final class Launcher extends Activity
|
||||
protected void onResume() {
|
||||
super.onResume();
|
||||
|
||||
/*
|
||||
// We can't hide the IME if it was forced open. So don't bother.
|
||||
final InputMethodManager inputManager = (InputMethodManager)
|
||||
getSystemService(Context.INPUT_METHOD_SERVICE);
|
||||
WindowManager.LayoutParams lp = getWindow().getAttributes();
|
||||
inputManager.hideSoftInputFromWindow(lp.token, 0);
|
||||
Log.d(TAG, "called hideSoftInputFromWindow");
|
||||
*/
|
||||
|
||||
mPaused = false;
|
||||
|
||||
if (mRestoring) {
|
||||
@@ -448,6 +458,11 @@ public final class Launcher extends Activity
|
||||
}
|
||||
}
|
||||
|
||||
// Eat the long press event so the keyboard doesn't come up.
|
||||
if (keyCode == KeyEvent.KEYCODE_MENU && event.isLongPress()) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return handled;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user