aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Bolter <david.bolter@gmail.com>2008-09-11 15:18:33 +0000
committerDavid Bolter <david.bolter@gmail.com>2008-09-11 15:18:33 +0000
commitbb84cbf7fd345d8bf37f637604e607db4ce772a7 (patch)
treed4ca84b6e2f9b7cf1036250becd35cb03d0209eb
parenta681cd97c90b3a1573ba1a9712ab55cd7cc04bb6 (diff)
downloadjquery-ui-bb84cbf7fd345d8bf37f637604e607db4ce772a7.tar.gz
jquery-ui-bb84cbf7fd345d8bf37f637604e607db4ce772a7.zip
Fixes #3342, prevents bubbling (and default key behaviour) for slider based key events.
-rw-r--r--ui/ui.slider.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/ui/ui.slider.js b/ui/ui.slider.js
index e2bdecff1..be466a787 100644
--- a/ui/ui.slider.js
+++ b/ui/ui.slider.js
@@ -113,7 +113,7 @@ $.widget("ui.slider", {
.parent()
.bind('focus', function(e) { self._focus(this.firstChild); })
.bind('blur', function(e) { self._blur(this.firstChild); })
- .bind('keydown', function(e) { if(!self.options.noKeyboard) self._keydown(e.keyCode, this.firstChild); })
+ .bind('keydown', function(e) { if(!self.options.noKeyboard) return self._keydown(e.keyCode, this.firstChild); })
;
// Bind the click to the slider itself
@@ -173,7 +173,9 @@ $.widget("ui.slider", {
x: xpos,
y: ypos
}, handle);
+ return false;
}
+ return true;
},
_focus: function(handle,hard) {
this.currentHandle = $(handle).addClass('ui-slider-handle-active');