Changeset 1677 for branches/blt4/gui/scripts/filechoiceentry.tcl
- Timestamp:
- Mar 29, 2010, 4:28:58 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/blt4/gui/scripts/filechoiceentry.tcl
r1675 r1677 79 79 set i1 [expr $first + 2] 80 80 set i2 [expr $last - 2] 81 set path [string range $glob $i1 $i2] 82 set value [$_owner xml get $_path.$cname] 83 set value [$_owner xml get $path] 81 set cpath [string range $glob $i1 $i2] 82 set value [$_owner xml get $cpath.$cname] 84 83 set glob [string replace $glob $first $last $value] 85 $_owner notify add $this $ path [itcl::code $this _whenidle]84 $_owner notify add $this $cpath [itcl::code $this _whenidle] 86 85 } 87 86 } … … 205 204 set i1 [expr $first + 2] 206 205 set i2 [expr $last - 2] 207 set path [string range $glob $i1 $i2]208 set value [$_owner xml get $ path.current]209 puts stderr "$ path.current: value=$value"206 set cpath [string range $glob $i1 $i2] 207 set value [$_owner xml get $cpath.current] 208 puts stderr "$cpath.current: value=$value" 210 209 if { $value == "" } { 211 set value [$_owner xml get $path.default] 212 puts stderr "$path.default: value=$value" 210 puts stderr "$_owner xml get $cpath.default" 211 set value [$_owner xml get $cpath.default] 212 puts stderr "$cpath.default: value=$value" 213 213 } 214 214 set glob [string replace $glob $first $last $value] 215 215 } 216 puts stderr "after glob=$glob"217 216 # Replace the template with the substituted value. 218 217 set files [glob -nocomplain $glob] 219 puts stderr "files=$files"220 218 set allfiles [concat $allfiles $files] 221 219 } … … 254 252 itcl::body Rappture::FileChoiceEntry::_tooltip {} { 255 253 set tip [string trim [$_owner xml get $_path.about.description]] 256 254 puts stderr "tip=$tip, $_owner=$_owner path=$_path.about.description" 257 255 # get the description for the current choice, if there is one 258 256 set str [$itk_component(choice) value] 259 257 set path [$itk_component(choice) translate $str] 260 set desc ""261 if {$path != ""} {262 set desc [$_owner xml get $ path.about.description]258 set desc $path 259 if {$path == ""} { 260 set desc [$_owner xml get $_path.about.description] 263 261 } 264 262
Note: See TracChangeset
for help on using the changeset viewer.