home *** CD-ROM | disk | FTP | other *** search
- #---------------------------------------------------------------------------
- #
- # (c) Cadre Technologies Inc. 1996
- #
- # File: @(#)browsewmta.tcl /main/hindenburg/1
- # Author: <generated>
- # Description:
- #---------------------------------------------------------------------------
- # SccsId = @(#)browsewmta.tcl /main/hindenburg/1 29 Aug 1996 Copyright 1996 Cadre Technologies Inc.
-
- # Start user added include file section
- # End user added include file section
-
-
- Class BrowseWmtArea : {WmtArea} {
- constructor
- method destructor
- method updateContextInfo
- method updateFilterIndicator
- method updateViewInfo
- attribute projectInfo
- attribute configInfo
- attribute phaseInfo
- attribute systemInfo
- attribute filterInfo
- attribute viewInfo
- attribute ccSubscriber
- }
-
- constructor BrowseWmtArea {class this name} {
- set this [WmtArea::constructor $class $this $name]
- # Start constructor user section
-
- interface WaColumn $this.WC0 {
- WaEntry projWE {
- labelText "Project:"
- }
- WaEntry confWE {
- labelText "Configuration Version:"
- }
- WaEntry viewWE {
- labelText "View:"
- }
- }
- interface WaColumn $this.WC1 {
- WaEntry phasWE {
- labelText "Phase:"
- }
- WaEntry systWE {
- labelText "System:"
- }
- WaEntry filtWE {
- labelText "Filter:"
- }
- }
-
- foreach column [$this columnSet] {
- foreach entry [$column entrySet] {
- $entry labelFont \
- [m4_var get M4_contextarea_labelfont -context desk]
- $entry valueFont \
- [m4_var get M4_contextarea_valuefont -context desk]
- }
- }
-
- $this projectInfo $this.WC0.projWE
- $this configInfo $this.WC0.confWE
- $this viewInfo $this.WC0.viewWE
- $this phaseInfo $this.WC1.phasWE
- $this systemInfo $this.WC1.systWE
- $this filterInfo $this.WC1.filtWE
-
- set ccSub [ClContextSubscriber new -notify "$this updateContextInfo"]
- [ClientContext::global] addSubscriber $ccSub
- $this ccSubscriber $ccSub
-
- # End constructor user section
- return $this
- }
-
- method BrowseWmtArea::destructor {this} {
- # Start destructor user section
- [ClientContext::global] removeSubscriber [$this ccSubscriber]
- [$this ccSubscriber] delete
- # End destructor user section
- }
-
- method BrowseWmtArea::updateContextInfo {this} {
- [$this projectInfo] valueText ""
- [$this configInfo] valueText ""
- [$this phaseInfo] valueText ""
- [$this systemInfo] valueText ""
-
- set cc [ClientContext::global]
- set project [$cc currentProject]
- if [$project isNil] {
- return
- }
- [$this projectInfo] valueText [$project name]
-
- set configV [$cc currentConfig]
- if [$configV isNil] {
- return
- }
- set configName [[$configV ConfigVersion::config] name]
- [$this configInfo] valueText "$configName (V[$configV versionNumber])"
-
- set phaseV [$cc currentPhase]
- if [$phaseV isNil] {
- return
- }
- [$this phaseInfo] valueText [[$phaseV phase] name]
-
- set systemV [$cc currentSystem]
- if [$systemV isNil] {
- return
- }
- [$this systemInfo] valueText [[$systemV system] name]
- }
-
- method BrowseWmtArea::updateFilterIndicator {this} {
- if [isCommand [FilterHandler::currentBox]] {
- [$this filterInfo] valueText "On"
- } else {
- [$this filterInfo] valueText "Off"
- }
- }
-
- method BrowseWmtArea::updateViewInfo {this} {
- [$this viewInfo] valueText [[$wmttoolObj infoView] currentViewName]
- }
-
- # Do not delete this line -- regeneration end marker
-
-