Skip to main content

Search and Top Navigation

#3797 closed bug (worksforme)

Opened January 09, 2009 04:59PM UTC

Closed January 28, 2009 09:56PM UTC

Slider doesn't always return whole numbers

Reported by: fracmak Owned by:
Priority: major Milestone: 1.7
Component: ui.slider Version: 1.6rc4
Keywords: Cc:
Blocked by: Blocking:
Description

Sometimes when dragging the mouse around, I get a decimal rounding error, so even though I specify a step of 1, I sometimes get values like 23.9999999999999. This is easily fixed by returning a Math.round() of the value. I've attached a patch.

Attachments (1)
  • slider.patch.txt (0.4 KB) - added by fracmak January 09, 2009 05:00PM UTC.

    Rounding error patch

Change History (2)

Changed January 15, 2009 02:26AM UTC by scottgonzalez comment:1

milestone: TBD1.6
priority: minormajor

The patch is invalid since decimals are valid values. I haven't looked into this at all, but this may be related to some of the dimensions methods from core returning crazy values.

Changed January 28, 2009 09:56PM UTC by paul comment:2

resolution: → worksforme
status: newclosed

Not reproducable for me anymore.