Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Sencha User tobiu's Avatar
    Join Date
    May 2007
    Location
    Munich (Germany)
    Posts
    2,676
    Vote Rating
    112
    tobiu is a name known to all tobiu is a name known to all tobiu is a name known to all tobiu is a name known to all tobiu is a name known to all tobiu is a name known to all

      0  

    Default [OPEN-979] Ext.form.SliderField -> Slider events

    [OPEN-979] Ext.form.SliderField -> Slider events


    hi team,

    the Ext.form.SliderField does not listen to the changecomplete-event of the slider.
    the event "change" is still from the field, so it does not get changes when the slider is dragged and dropped.

    as a really fast written hack i use:

    Code:
    Ext.sequence(Ext.form.SliderField.prototype, 'setValue', function() {
    	this.fireEvent('change', this, this.getValue());
    });
    but it should get implemented cleander (returning the thumb etc.).


    kind regards,
    tobiu
    Best regards
    Tobias Uhlig
    __________

    S-CIRCLES Social Network Engine

  2. #2
    Sencha - Ext JS Dev Team evant's Avatar
    Join Date
    Apr 2007
    Location
    Sydney, Australia
    Posts
    16,901
    Vote Rating
    623
    evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute

      0  

    Default


    I'm not really clear on what you're saying here.
    Evan Trimboli
    Sencha Developer
    Twitter - @evantrimboli
    Don't be afraid of the source code!

  3. #3
    Sencha User tobiu's Avatar
    Join Date
    May 2007
    Location
    Munich (Germany)
    Posts
    2,676
    Vote Rating
    112
    tobiu is a name known to all tobiu is a name known to all tobiu is a name known to all tobiu is a name known to all tobiu is a name known to all tobiu is a name known to all

      0  

    Default


    hi evan,

    i would like to listen to the change-event of the sliderField, when a user changes the value via drag&drop. this is why i set up this small sequence-workaround -> the field never fires "blur" without an input-textfield.


    kind regards,
    tobias
    Best regards
    Tobias Uhlig
    __________

    S-CIRCLES Social Network Engine

  4. #4
    Sencha Premium Member
    Join Date
    Nov 2007
    Location
    Sydney
    Posts
    38
    Vote Rating
    5
    CaCtus491 is on a distinguished road

      0  

    Default


    I'd just like to say that this 'fix' works perfectly for my application where I want to enable / disable some other fields depending on the slider value.

  5. #5
    Sencha User
    Join Date
    Jan 2011
    Posts
    2
    Vote Rating
    0
    ta4ka is on a distinguished road

      0  

    Default Thank you

    Thank you


    This really works. Thank your for sharing it.

  6. #6
    Ext JS Premium Member
    Join Date
    Aug 2010
    Location
    Santa Clara, California
    Posts
    9
    Vote Rating
    0
    nikolai.efimov is on a distinguished road

      0  

    Default


    Thank you!!! This helped me a lot!!! Hopefully Sencha will fix this ...

  7. #7
    Ext JS Premium Member
    Join Date
    Feb 2011
    Posts
    38
    Vote Rating
    1
    rijkvanwel is on a distinguished road

      0  

    Default


    Here's an improved version of the great fix by tobiu which calls the event handler with the proper arguments (slider, value, thumb), and also enables a "changecomplete" listener! The changecomplete event is more useful if for instance you want to post the updated value instantly by Ajax (you don't want to do that while the user is still sliding as that could potentially trigger hundreds of requests).

    Code:
    Ext.sequence( Ext.form.SliderField.prototype, 'initComponent', function() {
    	this.slider.on( 'change', this.fireEvent.createDelegate( this, 'change', 0 ) );
    	this.slider.on( 'changecomplete', this.fireEvent.createDelegate( this, 'changecomplete', 0 ) );
    });
    @Sencha: I also agree that it would make a lot more sense if the SliderField would just relay the Slider's events like change and changecomplete!