summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWilliam Joye <wjoye@cfa.harvard.edu>2017-09-18 21:16:13 (GMT)
committerWilliam Joye <wjoye@cfa.harvard.edu>2017-09-18 21:16:13 (GMT)
commitc12545d99c1f762218a2687f9ef48d6de9febef5 (patch)
tree3ce1a225002e34c95e7ec8051907c60c4f7b0789
parentb8675e2b5b56786b6f6277b5517ec08591cd0eab (diff)
downloadblt-c12545d99c1f762218a2687f9ef48d6de9febef5.zip
blt-c12545d99c1f762218a2687f9ef48d6de9febef5.tar.gz
blt-c12545d99c1f762218a2687f9ef48d6de9febef5.tar.bz2
Update info box when new file loaded
-rw-r--r--ds9/library/colorbar.tcl4
-rw-r--r--ds9/library/crop.tcl2
-rw-r--r--ds9/library/cube.tcl2
-rw-r--r--ds9/library/info.tcl30
-rw-r--r--ds9/library/mwcs.tcl2
-rw-r--r--ds9/library/scale.tcl2
-rw-r--r--ds9/library/wcs.tcl4
7 files changed, 22 insertions, 24 deletions
diff --git a/ds9/library/colorbar.tcl b/ds9/library/colorbar.tcl
index 712f34a..6928aed 100644
--- a/ds9/library/colorbar.tcl
+++ b/ds9/library/colorbar.tcl
@@ -218,8 +218,8 @@ proc ColorbarEnter {x y} {
$ds9(canvas) focus $current(colorbar)
switch -- $current(colorbar) {
- colorbar {UpdateFrameInfoBox base}
- colorbarrgb {UpdateFrameInfoBox rgb}
+ colorbar {LayoutFrameInfoBox base}
+ colorbarrgb {LayoutFrameInfoBox rgb}
}
}
diff --git a/ds9/library/crop.tcl b/ds9/library/crop.tcl
index ddf8a6f..0fbba8a 100644
--- a/ds9/library/crop.tcl
+++ b/ds9/library/crop.tcl
@@ -75,7 +75,7 @@ proc UpdateCrop {which} {
UpdateScaleDialog
GridUpdateZoom
UpdateGraphAxis $which
- UpdateInfoBoxBase
+ UpdateInfoBoxFrame $which
UpdateMain
}
diff --git a/ds9/library/cube.tcl b/ds9/library/cube.tcl
index 38c1024..27cc485 100644
--- a/ds9/library/cube.tcl
+++ b/ds9/library/cube.tcl
@@ -304,7 +304,7 @@ proc UpdateCube {} {
UpdateContourScale
UpdateContourDialog
UpdateGraphAxis $current(frame)
- UpdateInfoBoxBase
+ UpdateInfoBoxFrame $current(frame)
UpdateMain
}
diff --git a/ds9/library/info.tcl b/ds9/library/info.tcl
index 3bc7434..bc0d1c7 100644
--- a/ds9/library/info.tcl
+++ b/ds9/library/info.tcl
@@ -148,13 +148,13 @@ proc CreateInfoPanel {} {
-textvariable infobox(angle) -anchor center
}
-proc UpdateFrameInfoBox {which} {
+proc LayoutFrameInfoBox {which} {
global ds9
global view
global debug
if {$debug(tcl,events)} {
- puts stderr "UpdateFrameInfoBox"
+ puts stderr "LayoutFrameInfoBox"
}
switch -- $which {
@@ -383,11 +383,11 @@ proc EnterInfoBox {which} {
global debug
if {$debug(tcl,events)} {
- puts stderr "EnterInfo $which"
+ puts stderr "EnterInfoBox $which"
}
- UpdateFrameInfoBox [$which get type]
- UpdateWCSInfoBox $which
+ LayoutFrameInfoBox [$which get type]
+ LayoutWCSInfoBox $which
set infobox(frame) "[msgcat::mc {Frame}] [string range $which 5 end]"
set infobox(angle) [$which get rotate]
@@ -483,8 +483,9 @@ proc RefreshInfoBox {which} {
global debug
if {$debug(tcl,info)} {
- puts stderr "RefreshInfoBox"
+ puts stderr "RefreshInfoBox $which"
}
+ DumpCallStack
if {$which != {}} {
switch -- $current(mode) {
@@ -508,30 +509,27 @@ proc RefreshInfoBox {which} {
examine -
iexam {
EnterInfoBox $which
- ClearInfoBoxCoords
+ UpdateInfoBoxFrame $which
}
}
}
return
}
-proc UpdateInfoBoxBase {} {
+proc UpdateInfoBoxFrame {which} {
global debug
if {$debug(tcl,info)} {
- puts stderr "UpdateInfoBoxBase"
+ puts stderr "UpdateInfoBoxFrame $which"
}
- global current
global infobox
- if {$current(frame) != {}} {
- $current(frame) get info infobox
- }
+ $which get info infobox
}
proc UpdateInfoBox {which x y sys} {
global debug
if {$debug(tcl,info)} {
- puts stderr "UpdateInfoBox $sys"
+ puts stderr "UpdateInfoBox $which $sys"
}
global ds9
@@ -746,7 +744,7 @@ proc LayoutInfoPanelHorz {} {
set ds9(info,row,value,green) $row
set ds9(info,row,value,blue) $row
incr row
- UpdateFrameInfoBox base
+ LayoutFrameInfoBox base
# unit
if {$view(info,bunit)} {
@@ -1013,7 +1011,7 @@ proc LayoutInfoPanelVert {} {
incr row
set ds9(info,row,value,blue) $row
incr row
- UpdateFrameInfoBox base
+ LayoutFrameInfoBox base
# units
if {$view(info,bunit)} {
diff --git a/ds9/library/mwcs.tcl b/ds9/library/mwcs.tcl
index bdc25aa..4d9b214 100644
--- a/ds9/library/mwcs.tcl
+++ b/ds9/library/mwcs.tcl
@@ -41,7 +41,7 @@ proc UpdateWCSMenu {} {
} else {
CoordMenuReset $ds9(mb).wcs wcs system 0 sky skyformat
}
- UpdateWCSInfoBox $current(frame)
+ LayoutWCSInfoBox $current(frame)
} else {
$ds9(mb) entryconfig [msgcat::mc {WCS}] -state disabled
}
diff --git a/ds9/library/scale.tcl b/ds9/library/scale.tcl
index c4cbb2d..bac4e9a 100644
--- a/ds9/library/scale.tcl
+++ b/ds9/library/scale.tcl
@@ -172,7 +172,7 @@ proc UpdateScale {} {
UpdateScaleDialog
UpdateContourScale
UpdateGraphAxis $current(frame)
- UpdateInfoBoxBase
+ UpdateInfoBoxFrame $current(frame)
UpdateMain
}
diff --git a/ds9/library/wcs.tcl b/ds9/library/wcs.tcl
index fb3b7dc..f51d1d9 100644
--- a/ds9/library/wcs.tcl
+++ b/ds9/library/wcs.tcl
@@ -35,7 +35,7 @@ proc UpdateWCS {} {
} else {
CoordMenuReset $ds9(mb).wcs wcs system 0 sky skyformat
}
- UpdateWCSInfoBox $current(frame)
+ LayoutWCSInfoBox $current(frame)
}
# grid
@@ -84,7 +84,7 @@ proc UpdateWCS {} {
AdjustCoordSystem marker system
}
-proc UpdateWCSInfoBox {which} {
+proc LayoutWCSInfoBox {which} {
global wcs
global view