1. #1
    Sencha User
    Join Date
    Oct 2011
    Posts
    11
    Vote Rating
    0
    AdmSrck is on a distinguished road

      0  

    Default Form and screen keyboard

    Form and screen keyboard


    Hi,

    I noticed that on PR2 when I focus field and click "return" button on screen keyboard it doesn't perform blur on this field, so I have to click hide keyboard button. I tested it using sencha 2.0 PR1 and it is fine. Below you can find code I used for testing (in fact much more configurations were tested - from placing every element in config, to Ext.define everything and add on initComponent).

    Code:
        Ext.define('component.SomeElem', {
          extend: 'Ext.Panel',
          config: {
            layout: 'fit', 
            items: [{
                xtype: 'formpanel',
                width: 300,
                height: 200,
                scrollable: false,
                items: [{
                    xtype: 'searchfield',
                    name: 'productname',
                    placeHolder: 'Name',
                    clearIcon: false,
                    labelWidth: 0
                  }]
              }]
          },
          
        });
    I tried it on iPad 1gen.

    Second thing is that I can't find if it's possible to post a form on click "return" button from screen keyboard using Sencha.

    Thanks,
    Adam

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    36,756
    Vote Rating
    828
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    Used my iPhone 4S and ST2 with the latest code in our git repo and the Done button blurs the field.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  3. #3
    Sencha User
    Join Date
    Oct 2011
    Posts
    11
    Vote Rating
    0
    AdmSrck is on a distinguished road

      0  

    Default


    On iPhone/iPod there's bit different situation, because you have "Done" button displayed and it's something like "hide" button (bottom right corner, keyboard icon) on iPad. For more details about keyboard layout see attached screenshot, "return" button is marked red If field is wrapped in form tag "return" becomes "go" button and it's simply submit whole form.

    So basically what I mean is that not firing blur on tap "return" button might be a bit inconvenient on iPad. I would also like to know if there's a way to call submit on clicking that button, which would be cool for single search fields For now I have to place button and bind it to do this action. Wrapping up field with form tag will do it, but it seems that Sencha never use form tag, am I right?
    Attached Images

  4. #4
    Sencha User
    Join Date
    Nov 2011
    Posts
    2
    Vote Rating
    0
    metabren is on a distinguished road

      0  

    Default


    Quite keen to know what the deal is here too; find any good solution Adam?

    Brendan

  5. #5
    Sencha User
    Join Date
    Oct 2011
    Posts
    11
    Vote Rating
    0
    AdmSrck is on a distinguished road

      0  

    Default


    I've found a way to perform submit on press "return", probably not the best, but works. I managed to wrap field with form tag. To do this I'm extending Ext.form.Panel with method:

    Code:
    getElementConfig: function () {
            return {
                reference: 'element',
                tag: this.config.elConfig.tag,
                method: "POST",
                className: 'x-container',
                children: [{
                    reference: 'innerElement',
                    className: 'x-inner'
                }]
            };
        }
    Of course we have to provide action attribute which triggers certain controller and action in our app.

    Anybody knows other/better way?

    Adam

Thread Participants: 2

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