Some people have noticed if you have a fullscreen app,
which you leave and then resume, the status bar pushes your app window
down.

Others have pointed out this can be fixed with:

getWindow().setFlags(WindowManager.LayoutParams.FLAG_LAYOUT_NO_LIMITS,
WindowManager.LayoutParams.FLAG_LAYOUT_NO_LIMITS);


This of course breaks the IME, in that it no longer slides the window
upward - so the soft keyboard hides the editText you are trying to
type in.

I have worked around this issue with

_someEditText.setOnFocusChangeListener(new
View.OnFocusChangeListener() {
                        public void onFocusChange(View v, boolean hasFocus) {
                                if (hasFocus) {
        
getWindow().clearFlags(WindowManager.LayoutParams.FLAG_LAYOUT_NO_LIMITS);
                                } else {
        
getWindow().setFlags(WindowManager.LayoutParams.FLAG_LAYOUT_NO_LIMITS,
WindowManager.LayoutParams.FLAG_LAYOUT_NO_LIMITS);
                                }
                        }
                });

while leaving the initial setflags in onCreate as well.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to