summaryrefslogtreecommitdiffstats
path: root/library/scale.tcl
diff options
context:
space:
mode:
authorfvogelnew1@free.fr <fvogel>2014-10-30 21:50:07 (GMT)
committerfvogelnew1@free.fr <fvogel>2014-10-30 21:50:07 (GMT)
commit66bc66dc5acf703f975eb51eea04a5e3f5242a0d (patch)
tree2bdb69c8446898b0d9c039796a53ef66257991c4 /library/scale.tcl
parenta3ee6db82285bdc49ec84bfeb06b2fead6d7f1d0 (diff)
downloadtk-66bc66dc5acf703f975eb51eea04a5e3f5242a0d.zip
tk-66bc66dc5acf703f975eb51eea04a5e3f5242a0d.tar.gz
tk-66bc66dc5acf703f975eb51eea04a5e3f5242a0d.tar.bz2
Fixed bug [3529885fff]
Diffstat (limited to 'library/scale.tcl')
-rw-r--r--library/scale.tcl8
1 files changed, 7 insertions, 1 deletions
diff --git a/library/scale.tcl b/library/scale.tcl
index b4da824..771c7a4 100644
--- a/library/scale.tcl
+++ b/library/scale.tcl
@@ -223,7 +223,13 @@ proc ::tk::ScaleIncrement {w dir big repeat} {
set inc [$w cget -resolution]
}
if {([$w cget -from] > [$w cget -to]) ^ ($dir eq "up")} {
- set inc [expr {-$inc}]
+ if {$inc > 0} {
+ set inc [expr {-$inc}]
+ }
+ } else {
+ if {$inc < 0} {
+ set inc [expr {-$inc}]
+ }
}
$w set [expr {[$w get] + $inc}]