summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorhobbs <hobbs>2005-02-12 00:47:57 (GMT)
committerhobbs <hobbs>2005-02-12 00:47:57 (GMT)
commit5e83e727f6281d30ba6ba2a3855046d5212e3649 (patch)
tree3deb5180e14d98632db8884ced38f091c5a2b7f8
parent9ba23872ac80c26fd68bb2c895b7c186f6fd8543 (diff)
downloadtk-5e83e727f6281d30ba6ba2a3855046d5212e3649.zip
tk-5e83e727f6281d30ba6ba2a3855046d5212e3649.tar.gz
tk-5e83e727f6281d30ba6ba2a3855046d5212e3649.tar.bz2
* library/panedwindow.tcl (::tk::panedwindow::Cursor): check
window existence on delayed call. [Bug 949792]
-rw-r--r--ChangeLog3
-rw-r--r--library/panedwindow.tcl5
2 files changed, 6 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index f67c26a..a1d6d3d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
2005-02-11 Jeff Hobbs <jeffh@ActiveState.com>
+ * library/panedwindow.tcl (::tk::panedwindow::Cursor): check
+ window existence on delayed call. [Bug 949792]
+
* doc/text.n: note 'image' key in 'dump' command. [Bug 1115907]
* win/tkWinWm.c (TkWinGetIcon): fix toplevel retrieval for
diff --git a/library/panedwindow.tcl b/library/panedwindow.tcl
index d4abd73..5bf72f6 100644
--- a/library/panedwindow.tcl
+++ b/library/panedwindow.tcl
@@ -3,7 +3,7 @@
# This file defines the default bindings for Tk panedwindow widgets and
# provides procedures that help in implementing those bindings.
#
-# RCS: @(#) $Id: panedwindow.tcl,v 1.6.2.2 2004/05/03 19:36:56 hobbs Exp $
+# RCS: @(#) $Id: panedwindow.tcl,v 1.6.2.3 2005/02/12 00:48:05 hobbs Exp $
#
bind Panedwindow <Button-1> { ::tk::panedwindow::MarkSash %W %x %y 1 }
@@ -155,7 +155,8 @@ proc ::tk::panedwindow::Motion {w x y} {
#
proc ::tk::panedwindow::Cursor {w} {
variable ::tk::Priv
- if {[info exists Priv($w,panecursor)]} {
+ # Make sure to check window existence in case it is destroyed.
+ if {[info exists Priv($w,panecursor)] && [winfo exists $w]} {
if {[winfo containing [winfo pointerx $w] [winfo pointery $w]] eq $w} {
set Priv($w,pwAfterId) [after 150 \
[list ::tk::panedwindow::Cursor $w]]