Could you give us a pointer to where this "special trickery" exists in
the code?  We would like to see if we can figure out a fix.  A pointer
to likely places in the code would be really helpful.  Thanks.

________________________________

From: android-framework@googlegroups.com
[mailto:android-framew...@googlegroups.com] On Behalf Of Dianne Hackborn
Sent: Monday, July 13, 2009 4:01 PM
To: android-framework@googlegroups.com
Subject: Re: screen Y position not changing after soft keyboard pushes
window up.


If it is a dialog, it is in scroll mode by default.


On Mon, Jul 13, 2009 at 3:57 PM, Quiring, Sam
<sam.quir...@windriver.com> wrote:


        Hello, I don't think the window is in scroll mode, how can I
tell?  The window is pretty small, consisting of just a title, a text
box, and one or two buttons.  It is an EditTextPreference, for entering
the text value of an preference.  In the example below the window is
used for giving a name (i.e., a Label) to an alarm.  The entire window
moves when the soft keyboard appears, including the borders.

________________________________

        From: android-framework@googlegroups.com
[mailto:android-framew...@googlegroups.com] On Behalf Of Dianne Hackborn
        Sent: Monday, July 13, 2009 3:37 PM
        To: android-framework@googlegroups.com
        Subject: Re: screen Y position not changing after soft keyboard
pushes window up.
        
        
        Hi, if you are using a window in scroll mode, there is actually
some special trickery going on to scroll the window (the window doesn't
move, but drawing inside of it is offset), which probably isn't being
taken into account when you ask for the location on the screen.  Please
file a bug report and we'll try to get it fixed at some point, though I
can't guarantee when.
        
        
        On Mon, Jul 13, 2009 at 2:16 PM, Sam <sam.quir...@windriver.com>
wrote:
        


                I previously posted this question on July 3 deep in an
existing
                thread.  I have not received an answer.  I've been
advised to
                start a new thread.
                
                We have a case where View.getLocationOnScreen() seems
                to have a bug.  The window where this happens is an
                EditTextPreference.  To reproduce the problem:
                
                1. bring up the AlarmClock app
                2. click Menu
                3. click Add Alarm
                4. click Label
                5. observe (either with HierarchyViewer or your eyes)
the position of
                this window
                6. click the "Alarm" EditText box
                7. observe (eyes, HV) the new position of this window
                
                I have modified ViewDebug so it returns two more values
for each view:
                the
                two values returned by View.getLocationOnScreen().  I
named them
                screenX
                and screenY.  HierarchyViewer (unchanged) displays these
values.
                
                Before the window moves (step 5) I see these values from
                HierrarchyViewer:
                
                screenX:     27
                screenY:   229
                
                After the soft keyboard is displayed and the window is
pushed up,
                (after step 6), I completely refresh the information in
                HierarchyViewer,
                these values have not changed.  Since the window has
definitely
                 moved, I suspect this is a bug.
                
                Is there an alternative way using ViewDebug to getting
the screen
                position
                of the EditText box under these circumstances?  I'm
stumped.
                
                -Sam
                
                
                




        -- 
        
        Dianne Hackborn
        Android framework engineer
        hack...@android.com
        
        Note: please don't send private questions to me, as I don't have
time to provide private support, and so won't reply to such e-mails.
All such questions should be posted on public forums, where I and others
can see and answer them.
        
        





-- 
Dianne Hackborn
Android framework engineer
hack...@android.com

Note: please don't send private questions to me, as I don't have time to
provide private support, and so won't reply to such e-mails.  All such
questions should be posted on public forums, where I and others can see
and answer them.





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

Reply via email to