home *** CD-ROM | disk | FTP | other *** search
- #---------------------------------------------------------------------------
- #
- # (c) Cadre Technologies Inc. 1996
- #
- # File: @(#)mtrxvdbobj.tcl /main/hindenburg/2
- # Author: <generated>
- # Description:
- #---------------------------------------------------------------------------
- # SccsId = @(#)mtrxvdbobj.tcl /main/hindenburg/2 22 Nov 1996 Copyright 1996 Cadre Technologies Inc.
-
- # Start user added include file section
- # End user added include file section
-
- require "filevobj.tcl"
-
- Class MtrxVDbObj : {Matrix FileVObj} {
- method destructor
- constructor
- method browserObjType
- method canBeDragged
- method editFile
- method showFile
- }
-
- method MtrxVDbObj::destructor {this} {
- # Start destructor user section
- # End destructor user section
- $this FileVObj::destructor
- }
-
- constructor MtrxVDbObj {class this name} {
- set this [Matrix::constructor $class $this $name]
- set this [FileVObj::constructor $class $this $name]
- return $this
- }
-
- selfPromoter Matrix {this} {
- MtrxVDbObj promote $this
- }
-
- proc MtrxVDbObj::associations {} {
- return "[FileVObj::associations]"
- }
-
- method MtrxVDbObj::browserObjType {this} {
- return "MtrxVDbObj"
- }
-
- method MtrxVDbObj::canBeDragged {this} {
- if {"[$this getInfo Type]" == "dsm"} {
- return 0
- }
- return [$this FileVObj::canBeDragged]
- }
-
- proc MtrxVDbObj::childTypes {assoc} {
- if {[lsearch -exact "[MtrxVDbObj::associations]" "$assoc"] == -1} {
- return ""
- }
- return "[BrowserProcs::childTypes $assoc]"
- }
-
- proc MtrxVDbObj::controlledLists {} {
- return "[FileVObj::controlledLists]"
- }
-
- proc MtrxVDbObj::infoProperties {} {
- return "[FileVObj::infoProperties]"
- }
-
- method MtrxVDbObj::editFile {this {confV ""} {phaseV ""} {sysV ""}} {
- busy {
- set file [$this file]
- case "[$file type]" in {
- {dsm} {
- require "docstructd.tcl"
- global classCount
- incr classCount
- set box .main.documentStructureDialog$classCount
- DocStructDlg new $box $this \
- -modal 1 \
- -editable 1 \
- -title "Edit Document Structure" \
- -helpPressed {.main helpOnName documentStructureDialog}
- $box popUp
- }
- {cdm} {
- require "opencdmdlg.tcl"
- set box .main.openCdm
- OpenCdmDlg new $box \
- -editable 1 \
- -confV $confV \
- -phaseV $phaseV \
- -sysV $sysV \
- -cdm $this
- set popUpState [$box popUp]
- if {! [lindex $popUpState 0]} {
- $box delete
- set message [lindex $popUpState 1]
- if {"$message" != ""} {
- wmtkerror $message
- }
- }
- }
- {default} {
- set obj "[$file qualifiedName :].[$file type]"
- wmtkerror "Don't know how to edit '$obj'"
- }
- }
- }
- }
-
- method MtrxVDbObj::showFile {this {confV ""} {phaseV ""} {sysV ""}} {
- busy {
- set file [$this file]
- case "[$file type]" in {
- {dsm} {
- require "docstructd.tcl"
- global classCount
- incr classCount
- set box .main.documentStructureDialog$classCount
- DocStructDlg new $box $this \
- -editable 0 \
- -title "Show Document Structure" \
- -helpPressed {.main helpOnName documentStructureDialog}
- $box popUp
- }
- {cdm} {
- require "opencdmdlg.tcl"
- set box .main.openCdm
- OpenCdmDlg new $box \
- -editable 0 \
- -confV $confV \
- -phaseV $phaseV \
- -sysV $sysV \
- -cdm $this
- set popUpState [$box popUp]
- if {! [lindex $popUpState 0]} {
- $box delete
- set message [lindex $popUpState 1]
- if {"$message" != ""} {
- wmtkerror $message
- }
- }
- }
- {default} {
- set obj "[$file qualifiedName :].[$file type]"
- wmtkerror "Don't know how to show '$obj'"
- }
- }
- }
- }
-
- # Do not delete this line -- regeneration end marker
-
-