home *** CD-ROM | disk | FTP | other *** search
- #---------------------------------------------------------------------------
- #
- # (c) Cadre Technologies Inc. 1996
- #
- # File: @(#)openlocdia.tcl /main/titanic/1
- # Author: <generated>
- # Description:
- #---------------------------------------------------------------------------
- # SccsId = @(#)openlocdia.tcl /main/titanic/1 14 Mar 1997 Copyright 1996 Cadre Technologies Inc.
-
- # Start user added include file section
- # End user added include file section
-
- require "locdialog.tcl"
-
- Class OpenLocDialog : {LocDialog} {
- constructor
- method destructor
- method createInterface
- method clearInterface
- method fromInterface
- method toInterface
- method objName
- attribute itemDDL
- attribute nameDDL
- attribute editorArea
- }
-
- constructor OpenLocDialog {class this name} {
- set this [LocDialog::constructor $class $this $name]
- # Start constructor user section
-
- $this helpPressed { .main helpOnName editOpenlocProperties }
-
- # End constructor user section
- return $this
- }
-
- method OpenLocDialog::destructor {this} {
- # Start destructor user section
- # End destructor user section
- $this LocDialog::destructor
- }
-
- method OpenLocDialog::createInterface {this} {
- interface NoteBkPage $this.locationNBP {
- label Location
- DlgColumn DC {
- NamedGroup nameNG {
- DlgRow DR {
- DlgColumn nameDC {
- Label nameL { text Strategy: }
- DropDwnList nameDDL {
- entrySet {}
- rowCount 5
- }
- }
- DlgColumn itemDC {
- Label itemL { text "Item Type:" }
- DropDwnList itemDDL {
- entrySet {}
- rowCount 5
- }
- }
- }
- }
- NamedGroup ctxtNG {
- label Context
- DlgColumn DC {
- DlgRow fileDR {
- DlgColumn phaseDC {
- Label phaseL { text Phase: }
- DropDwnList phaseDDL {
- entrySet {}
- rowCount 5
- }
- }
- DlgColumn fileDC {
- Label fileL { text "Diagram Type:" }
- DropDwnList fileDDL {
- entrySet {}
- rowCount 5
- }
- }
- }
- DlgRow compDR {
- DlgColumn compDC {
- Label compL { text "Component Type:" }
- DropDwnList compDDL {
- entrySet {}
- rowCount 5
- }
- }
- DlgColumn labelDC {
- Label labelL { text "Label Type:" }
- DropDwnList labelDDL {
- entrySet {}
- rowCount 5
- }
- }
- DlgColumn condDC {
- Label condL { text Condition: }
- DropDwnList condDDL {
- entrySet {}
- rowCount 5
- }
- }
- }
- }
- }
- }
- }
- $this lPage $this.locationNBP.DC
-
- $this nameDDL [$this lPage].nameNG.DR.nameDC.nameDDL
- $this itemDDL [$this lPage].nameNG.DR.itemDC.itemDDL
-
- $this phaseDDL [$this lPage].ctxtNG.DC.fileDR.phaseDC.phaseDDL
- $this fileDDL [$this lPage].ctxtNG.DC.fileDR.fileDC.fileDDL
- $this compDDL [$this lPage].ctxtNG.DC.compDR.compDC.compDDL
- $this labelDDL [$this lPage].ctxtNG.DC.compDR.labelDC.labelDDL
- $this condDDL [$this lPage].ctxtNG.DC.compDR.condDC.condDDL
-
- [$this itemDDL] entrySet {{} cl de pe et st Clear}
- $this init
-
- set phaselist {}
- foreach phaseType [[$this phaseDDL] entrySet] {
- if {"$phaseType" != "Implementation"} {
- lappend phaseList $phaseType
- }
- }
-
- [$this phaseDDL] entrySet $phaseList
- }
-
- method OpenLocDialog::clearInterface {this} {
- [$this nameDDL] entrySet [lsort [[[$this editorArea] strategyType] \
- names]]
- [$this nameDDL] selected [lindex [[$this nameDDL] entrySet] 0]
- [$this itemDDL] selected [lindex [[$this itemDDL] entrySet] 0]
- $this LocDialog::clearInterface
- }
-
- method OpenLocDialog::fromInterface {this} {
- set type [[$this editorArea] getStrategyType [[$this nameDDL] selected]]
- [$this curObject] type $type
- [$this curObject] itemType [[$this itemDDL] selected]
- return [$this LocDialog::fromInterface]
- }
-
- method OpenLocDialog::toInterface {this} {
- set object [$this curObject]
- [$this itemDDL] selected [$object itemType]
- $this title "Usage of [$object type]Strategy '[$object name]'"
- $this LocDialog::toInterface
- }
-
- method OpenLocDialog::objName {this args} {
- if {$args == ""} {
- return [[$this lPage].nameNG.DR.nameDC.nameDDL selected]
- } else {
- [$this lPage].nameNG.DR.nameDC.nameDDL selected [join $args]
- }
- }
-
- # Do not delete this line -- regeneration end marker
-
-