Changeset 607 for trunk/profcons.tcl
- Timestamp:
- Dec 4, 2009 5:09:00 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/profcons.tcl
- Property rcs:date changed from 2001/09/04 22:03:57 to 2002/07/03 21:06:49
- Property rcs:lines changed from +3 -5 to +37 -5
- Property rcs:rev changed from 1.4 to 1.5
r414 r607 357 357 ] -column 0 -row 5 -sticky ns 358 358 grid [button $top.quit -text "Cancel\nChanges" \ 359 -command "CancelEdit Constraint $top" \359 -command "CancelEditProfileConstraint $top $num" \ 360 360 ] -column 1 -row 5 361 361 grid [button $top.help -text Help -bg yellow \ … … 412 412 tkwait window $top 413 413 afterputontop 414 } 415 416 # called when the "Cancel Changes" button is pressed 417 proc CancelEditProfileConstraint {top num} { 418 global expcons 419 if {$num == "add"} {destroy $top; return} 420 set ans [MyMessageBox -type "{Abandon Changes} {Continue Edit}" \ 421 -parent [winfo toplevel $top] -default "abandon changes" \ 422 -helplink "expguierr.html AbandonEditConstraints" \ 423 -icon warning -message \ 424 {Do you want to lose any changes made to this constraint?}] 425 if {$ans == "abandon changes"} {destroy $top} 414 426 } 415 427 … … 659 671 -text $i] -column $i -row 3 660 672 } 661 grid [button $top.b1 -text Continue \ 662 -command "set expcons(createflag) 1"] -column 0 -row 5 673 grid [set expcons(ProfileCreateContinueButton) [button $top.b1 \ 674 -text Continue -command "set expcons(createflag) 1"]] \ 675 -column 0 -row 5 663 676 grid [button $top.b2 -text Cancel \ 664 677 -command "set expcons(createflag) 0"] -sticky w -column 1 -row 5 … … 720 733 } 721 734 grid [checkbutton $top.$i -text "#$i ($lbl)" \ 722 -variable expcons(newcons$i) \735 -variable expcons(newcons$i) -command DisableProfileContinue \ 723 736 ] -column $col -row $row -sticky w 724 737 } 725 } 738 DisableProfileContinue 739 } 740 741 proc DisableProfileContinue {} { 742 global expcons 743 set p $expcons(ProfilePhase) 744 set ptype $expcons(ProfileFunction) 745 set htype $expcons(ProfileHistType) 746 set termlist {} 747 set i 0 748 foreach lbl [GetProfileTerms $p $htype $ptype] { 749 incr i 750 if {$expcons(newcons$i)} {lappend termlist $i} 751 } 752 if {$termlist == ""} { 753 $expcons(ProfileCreateContinueButton) config -state disabled 754 } else { 755 $expcons(ProfileCreateContinueButton) config -state normal 756 } 757 }
Note: See TracChangeset
for help on using the changeset viewer.