Success! Looks like we've fixed this one. According to our records the fix was applied for TOUCH-2856 in a recent build.
  1. #1
    Sencha User
    Join Date
    Mar 2012
    Location
    Washington, DC
    Posts
    11
    Vote Rating
    2
    yury.sannikov is on a distinguished road

      0  

    Default Ext.field.Toggle doesn't fire 'change' event when tapped

    Ext.field.Toggle doesn't fire 'change' event when tapped


    Sencha Touch 2.0.1-RC

    Toggle element doesn't raise change event when tapped.

    The code below doesn't raise change event in onComponentTap method.
    Code:
        toggle: function() {
            var value = this.getValue();
            this.setValue((value == 1) ? 0 : 1);
    
    
            return this;
        },
    
    
        onComponentTap: function() {
            // Toggle the value, and return false so the normal slider functionality doesn't happen
            this.toggle();
    
    
            return false;
        }
    Actually, change event is raised by Slider's onThumbDragEnd
    Code:
        onThumbDragEnd: function(thumb, e) {
    .....
            this.fireEvent('dragend', this, thumb, this.getValue(), e);
            if (oldValue !== newValue) {
                this.fireEvent('change', this, thumb, newValue, oldValue);
            }
        },

  2. #2
    Sencha - Sencha Touch Dev Team Jamie Avins's Avatar
    Join Date
    Mar 2007
    Location
    Redwood City, California
    Posts
    3,661
    Vote Rating
    19
    Jamie Avins is a jewel in the rough Jamie Avins is a jewel in the rough Jamie Avins is a jewel in the rough

      0  

    Default


    Thank you for the report.

    Sencha Inc

    Jamie Avins

    @jamieavins

  3. #3
    Sencha User
    Join Date
    Mar 2012
    Location
    Washington, DC
    Posts
    11
    Vote Rating
    2
    yury.sannikov is on a distinguished road

      0  

    Default


    Temporary workaround that works for me is:
    Code:
    Ext.define('your.name.space', {
        override: 'Ext.field.Toggle',
        onComponentTap: function() {
            this.callParent(arguments);
            this.fireEvent('change');
            return false;
        }
    });
    Beware: It doesn't supply parameters to the event.
    I'v just place the code at the beginning of the view file.

  4. #4
    Sencha - Sencha Touch Dev Team rdougan's Avatar
    Join Date
    Oct 2008
    Posts
    1,158
    Vote Rating
    6
    rdougan will become famous soon enough

      0  

    Default


    Can't reproduce in 2.0.1 final. Please repost if it is still an issue for you.

    Thanks!
    Sencha Inc.
    Robert Dougan - @rdougan
    Sencha Touch 2 and Ext JS 4 Core Team Member, SASS/Theming Wizard.

  5. #5
    Sencha User
    Join Date
    Mar 2012
    Location
    Washington, DC
    Posts
    11
    Vote Rating
    2
    yury.sannikov is on a distinguished road

      0  

    Default


    I'm not planning to switch to 2.0.1 before release. But, I'v reviewed the source code and it seems, it should work well.
    Thank you for your business!

  6. #6
    Sencha - Sencha Touch Dev Team rdougan's Avatar
    Join Date
    Oct 2008
    Posts
    1,158
    Vote Rating
    6
    rdougan will become famous soon enough

      0  

    Default


    Sencha Touch 2.0.1 is already final FYI: http://www.sencha.com/forum/announcement.php?f=92&a=30
    Sencha Inc.
    Robert Dougan - @rdougan
    Sencha Touch 2 and Ext JS 4 Core Team Member, SASS/Theming Wizard.

  7. #7
    Sencha User
    Join Date
    Mar 2012
    Location
    Washington, DC
    Posts
    11
    Vote Rating
    2
    yury.sannikov is on a distinguished road

      0  

    Default


    Yes, I see. I mean our product release. Thanks.

  8. #8
    Sencha Premium Member
    Join Date
    Jan 2012
    Posts
    131
    Vote Rating
    -2
    YomeKitsuma has a little shameless behaviour in the past

      0  

    Default


    Quote Originally Posted by yury.sannikov View Post
    Temporary workaround that works for me is:
    Code:
    Ext.define('your.name.space', {
        override: 'Ext.field.Toggle',
        onComponentTap: function() {
            this.callParent(arguments);
            this.fireEvent('change');
            return false;
        }
    });
    Beware: It doesn't supply parameters to the event.
    I'v just place the code at the beginning of the view file.
    Juste add 'this' to get the Component =D

    Code:
    Ext.define('your.name.space', {    override: 'Ext.field.Toggle',
        onComponentTap: function() {
            this.callParent(arguments);
            this.fireEvent('change', this);
            return false;
        }
    });

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar