home *** CD-ROM | disk | FTP | other *** search
- #---------------------------------------------------------------------------
- #
- # (c) Cadre Technologies Inc. 1996
- #
- # File: @(#)newlocalse.tcl 1.3
- # Author: <generated>
- # Description:
- #---------------------------------------------------------------------------
- # SccsId = @(#)newlocalse.tcl 1.3 21 Mar 1996 Copyright 1996 Cadre Technologies Inc.
-
- # Start user added include file section
- # End user added include file section
-
- require "newobjentr.tcl"
-
- Class NewLocalSectionDlg : {NewObjEntryDlg} {
- constructor
- method destructor
- method handleEdit
- method handleOk
- method handleTextModified
- method popUp
- }
-
- constructor NewLocalSectionDlg {class this name} {
- set this [NewObjEntryDlg::constructor $class $this $name]
- # Start constructor user section
-
- Label new $this.top.typeLab \
- -text "Local Section Type:"
- OptionMenu new $this.top.type
-
- $this config \
- -title "New Local Section" \
- -message "Local Section Name:" \
- -okPressed "$this handleOk"
- PushButton new $this.edit \
- -label Edit \
- -activated "$this handleEdit"
-
- # End constructor user section
- return $this
- }
-
- method NewLocalSectionDlg::destructor {this} {
- # Start destructor user section
- # End destructor user section
- $this NewObjEntryDlg::destructor
- }
-
- method NewLocalSectionDlg::handleEdit {this} {
- $this popDown
- $this handleOk
- if [isCommand [$this createdObj]] {
- [$this createdObj] editFile
- }
- }
-
- method NewLocalSectionDlg::handleOk {this} {
- set sectionName [$this entry]
- set sectionType [$this.top.type selected]
-
- set script "$this createdObj \"\""
- append script " ;"
- append script \
- " DocStructPart new .docStrucPart \
- -documentVersion [$this dbObj] \
- -sectionName \"$sectionName\" \
- -sectionType \"$sectionType\""
- append script " ;"
- append script " $this createdObj \[\
- DocGenerator::createSection .docStrucPart \
- \]"
- append script " ;"
- append script " .docStrucPart delete"
-
- require "docgenerat.tcl"
- require "docstructp.tcl"
- $wmttoolObj startCommand tcl \
- "$script" "" \
- "Creating $sectionType section '$sectionName'..." \
- {1 0} 1
- }
-
- method NewLocalSectionDlg::handleTextModified {this} {
- $this NewObjEntryDlg::handleTextModified
- $this.edit sensitive [$this okSensitive]
- }
-
- method NewLocalSectionDlg::popUp {this} {
- set entrySet [[[$this dbObj] editor] localSectionTypes]
- $this.top.type config \
- -entrySet $entrySet \
- -selected [lindex $entrySet 0]
- $this NewObjEntryDlg::popUp
- }
-
- # Do not delete this line -- regeneration end marker
-
-