1. #1
    Sencha User
    Join Date
    Aug 2008
    Posts
    226
    Vote Rating
    2
    TheBuzzer is on a distinguished road

      0  

    Default Answered: Focusing on textfield

    Answered: Focusing on textfield


    I am trying to make a textfield get focus when it is first shown. Trying to make a window that is a login form, however if I try doing show() and than focus() on the textfield object it does not focus. I even have usernamefield.setSelectOnFocus(true). I am guessing it is not rendered yet, however I am not sure when is the field rendered for me to be able to focus.

  2. Try using a scheduler to set the focus on that field, like this:

    Code:
    Scheduler.get().scheduleDeferred(new Command() {
            @Override
            public void execute() {
                textField.focus();
            }
      });
    This way is only gets run after the browser event loop returns.

  3. #2
    Ext GWT Premium Member lefke123's Avatar
    Join Date
    Dec 2011
    Location
    Belgium
    Posts
    77
    Answers
    2
    Vote Rating
    3
    lefke123 is on a distinguished road

      0  

    Default


    Try using a scheduler to set the focus on that field, like this:

    Code:
    Scheduler.get().scheduleDeferred(new Command() {
            @Override
            public void execute() {
                textField.focus();
            }
      });
    This way is only gets run after the browser event loop returns.

Thread Participants: 1

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi