summaryrefslogtreecommitdiffstats
path: root/library/ttk
diff options
context:
space:
mode:
authorjenglish <jenglish@noemail.net>2009-12-23 04:30:51 (GMT)
committerjenglish <jenglish@noemail.net>2009-12-23 04:30:51 (GMT)
commit8ff9b2b2a18d4ba20bbf7adc57c48907c180a67a (patch)
treec282a8a896446b8b23c6056f48e71f58fb91816c /library/ttk
parent6d661abb53bfe25cc442a58e8c7c64fdbef03ca7 (diff)
downloadtk-8ff9b2b2a18d4ba20bbf7adc57c48907c180a67a.zip
tk-8ff9b2b2a18d4ba20bbf7adc57c48907c180a67a.tar.gz
tk-8ff9b2b2a18d4ba20bbf7adc57c48907c180a67a.tar.bz2
ttk::sizegrip: Patch to avoid bizarro behavior under compiz [Bug 2912356].
FossilOrigin-Name: 7ec712cd2195454af7e17383485a5c8df0c8937c
Diffstat (limited to 'library/ttk')
-rw-r--r--library/ttk/sizegrip.tcl9
1 files changed, 6 insertions, 3 deletions
diff --git a/library/ttk/sizegrip.tcl b/library/ttk/sizegrip.tcl
index f1b87b1..f167b00 100644
--- a/library/ttk/sizegrip.tcl
+++ b/library/ttk/sizegrip.tcl
@@ -1,5 +1,5 @@
#
-# $Id: sizegrip.tcl,v 1.1 2006/10/31 01:42:27 hobbs Exp $
+# $Id: sizegrip.tcl,v 1.1.4.1 2009/12/23 04:30:51 jenglish Exp $
#
# Ttk widget set -- sizegrip widget bindings.
#
@@ -37,7 +37,7 @@ proc ttk::sizegrip::Press {W X Y} {
# If a negative X or Y position was specified for [wm geometry],
# just bail out -- there's no way to handle this cleanly.
#
- if {[scan [wm geometry $top] "%dx%d+%d+%d" width height _x _y] != 4} {
+ if {[scan [wm geometry $top] "%dx%d+%d+%d" width height x y] != 4} {
return;
}
@@ -56,6 +56,8 @@ proc ttk::sizegrip::Press {W X Y} {
set State(pressY) $Y
set State(width) $width
set State(height) $height
+ set State(x) $x
+ set State(y) $y
set State(pressed) 1
}
@@ -66,7 +68,8 @@ proc ttk::sizegrip::Drag {W X Y} {
set h [expr {$State(height) + ($Y - $State(pressY))/$State(heightInc)}]
if {$w <= 0} { set w 1 }
if {$h <= 0} { set h 1 }
- wm geometry $State(toplevel) ${w}x${h}
+ set x $State(x) ; set y $State(y)
+ wm geometry $State(toplevel) ${w}x${h}+${x}+${y}
}
proc ttk::sizegrip::Release {W X Y} {