Opened 15 years ago
Closed 15 years ago
#3797 closed bug (worksforme)
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)
Change History (3)
Changed 15 years ago by
Attachment: | slider.patch.txt added |
---|
comment:1 Changed 15 years ago by
Milestone: | TBD → 1.6 |
---|---|
Priority: | minor → major |
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.
comment:2 Changed 15 years ago by
Resolution: | → worksforme |
---|---|
Status: | new → closed |
Not reproducable for me anymore.
Note: See
TracTickets for help on using
tickets.
Rounding error patch