Results 1 to 3 of 3

Thread: Sencha Touch 1.1, PhoneGap 1.2, Android Text Area/Text Field scrolling issue.

  1. #1
    Sencha User
    Join Date
    Dec 2011

    Default Sencha Touch 1.1, PhoneGap 1.2, Android Text Area/Text Field scrolling issue.

    Hi Sencha Forum, this is my first post.

    I have spent a lot of time researching this issue and even more time trying to solve it. I am hoping someone on this forum knows a good solution for this. The issue involves Sencha Touch 1.1, PhoneGap 1.2 and Android. I am months into the project and have encountered an issue with panels sliding up when a text area or text field receives focus and when soft keyboard input is received while the input has focus.

    I have read several stack overflow and other sencha forum threads that describe variations of the same problem. The usual solution provided is to set android:windowSoftInputMode to adjustPan instead of adjustResize. This does get rid of the problem of having the panel slide up but is not acceptable in my case because one of the panels in the application is a chat window. The input field must always stay docked against the bottom visible area on the screen. For example, it should stay docked to the bottom of the screen when no soft keyboard is visible and it should stay docked just above the soft keyboard when the keyboard is out. I am able to accomplish this if I resize the panel to the viewport height when Ext.EventManager.onWindowResize is called (using android:windowSoftInputMode=adjustResize). The problem is that any keyboard input causes the entire panel to slide up. A very hacky and ultimately unacceptable solution has been to listen for key events and then manually slide the panel back to 0,0 by setting it's position and also calling window.scrollTo(0,0). This does cause the panel to get back into place but is a poor user experience (having the screen bounce up and down with each letter input).

    Using android:windowSoftInputMode=adjustPan does not cause any panel shifting but does not provide any means of obtaining the soft keyboard's height so that I can properly position the chat's input field directly above the soft keyboard (none that I am aware of anyway).

    Question 1: Is there a way to programmatically determine the height of a soft keyboard without using android:windowSoftInputMode=adjustResize and listening to the Ext.EventManager.onWindowResize event to read the size of the resized viewport?

    Question 2: Is there a way to use android:windowSoftInputMode=adjustResize and prevent the browser from sliding up when a text field or text area receives focus?

    Thanks in advance for any help. This has consumed 30+ hours of time and is pretty much a show stopper for this app that is now several months into development.


  2. #2


    Have you found a solution to this problem Sean? I am experiencing the same issue and am getting nervous as our team just made the decision to rewrite our mobile app in Sencha (from jquery mobile). Like you mentioned this is a very big issue that would really put us in a bind if we cannot get it solved.

    Does anyone from the Sencha team have any input on this issue?

    Happy Holidays to everyone.
    Zyndeo - Real Estate Reversed

  3. #3

    Default scroll issue.

    Hi ,

    I am facing the exact same issue.
    I wanted to know if there is any event or listener of an android keyboard down.key .

    If there is a keycode for the key.( android soft keyboard down).

    Please let me know.
    Its urgent.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts