github
Advanced Search
  • Home
  • Pricing and Signup
  • Explore GitHub
  • Blog
  • Login

jquery / jquery-ui

  • Admin
  • Watch Unwatch
  • Fork
  • Your Fork
  • Pull Request
  • Download Source
    • 835
    • 188
  • Source
  • Commits
  • Network (188)
  • Graphs
  • Tree: 5b00c21

click here to add a description

click here to add a homepage

  • Switch Branches (8)
    • bind
    • devpreview
    • formcontrols
    • master
    • menu
    • panel
    • tooltip
    • widget-super
  • Switch Tags (19)
    • 1.9m2
    • 1.9m1
    • 1.8rc3
    • 1.8rc2
    • 1.8rc1
    • 1.8b1
    • 1.8a2
    • 1.8a1
    • 1.8.2
    • 1.8.1
    • 1.8
    • 1.7
    • 1.6rc6
    • 1.6rc5
    • 1.6rc3
    • 1.6rc2
    • 1.6
    • 1.5.2
    • 1.5.1
  • Comments
  • Contributors
Sending Request…

The official jQuery user interface library. — Read more

  Cancel

http://jqueryui.com/

  Cancel
  • HTTP
  • Git Read-Only

This URL has Read+Write access

slider: use handle width / 2 instead of marginLeft to find offset of mousedown 
relative to center of handle (fixes #4063 - slider: horizontal slider handle 
jumps up when you click on it IE6)
rdworth (author)
Sat Feb 28 12:45:05 -0800 2009
commit  5b00c217190538fc1e03
tree    62c633c5936cda0457bb
parent  cacb2acee4c618fc9be1
M ui/ui.slider.js 2 ••
Txt ui/ui.slider.js
  • View file @ 5b00c21
... ...
@@ -222,7 +222,7 @@ $.widget("ui.slider", $.extend({}, $.ui.mouse, {
222 222
     var offset = closestHandle.offset();
223 223
     var mouseOverHandle = !$(event.target).parents().andSelf().is('.ui-slider-handle');
224 224
     this._clickOffset = mouseOverHandle ? { left: 0, top: 0 } : {
225  
-      left: event.pageX - offset.left + (parseInt(closestHandle.css('marginLeft'),10) || 0),
  225
+      left: event.pageX - offset.left - (closestHandle.width() / 2),
226 226
       top: event.pageY - offset.top
227 227
         - (closestHandle.height() / 2)
228 228
         - (parseInt(closestHandle.css('borderTopWidth'),10) || 0)

0 notes on commit 5b00c21

Please log in to comment.
Blog | Support | Training | Contact | API | Status | Twitter | Help | Security
© 2010 GitHub Inc. All rights reserved. | Terms of Service | Privacy Policy
Powered by the Dedicated Servers and
Cloud Computing of Rackspace Hosting®
Dedicated Server
  • English
  • Català
  • Čeština
  • Deutsch
  • Español
  • Français
  • Hrvatski
  • Indonesia
  • Italiano
  • 日本語
  • Nederlands
  • Norsk
  • Polski
  • Português (BR)
  • Српски
  • Svenska
  • 中文