Reconciling Status Bar Bug with IME (soft keyboard) interaction

by Paul Pucciarelli » Tue, 25 Jan 2011 02:53:17 GMT


Sponsored Links
 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.

-- 



Other Threads

1. Get all text (including encoded) from XML Text Node

Hi,

I have a very basic question regarding encoded text in an XML Text node.

I am using the DOM parser
javax.xml.parsers.DocumentBuilder
to parse some xml. The xml has some international characters which are encoded 
in decimal unicode - eg. '' is 'ó'.

The parser takes the encoded character out of the word for example jbb and the 
Text node is left with jbb as the node value. If I use getData() on the Text 
node it returns jbb also. The character is not lost though - a sibling Node, an 
Entity Reference Node, has the decimal value and an index. The index value 
corresponds to where this character should be inserted. In this case for 
example if would have an index of 1 and value of '#234'.

This indicates that there must be a simple way of accessing the value of the 
Text node of its parent in such a way as to get 'jbb'. It seems unlikely that 
I need to reconstruct this by doing a lookup to convert the encoded character 
to utf8 and then insert it into the string for the Text node. Does anyone know 
how this works?

Sorry for asking what is probably a really basic question, but I can't find the 
answer.

Thank you for any help.

Regards,
Julius.


-- 

2. Yahoo Mail & Yahoo messenger has been updated to 1.01

As subject sudah updates ya,

Atau gua yang ketinggalan berita ya?

Hahaha

-- 
"Indonesian Android Community [id-android]" 

3. How to remove a HeaderView from a ListView?

4. screen resolution 800x480

5. why is there no android tablet nearly as good as ipad?

6. Market Search Not Displaying All the Results

7. Auto Scrolling Text in Canvas