79 |
|
|
80 |
|
proc delpic {} { # Delete selected pictures |
81 |
|
global curmess |
82 |
< |
set selected_pics [get_selpics] |
83 |
< |
if {"$selected_pics" == {}} { |
82 |
> |
set selected_pics [get_selpics 1] |
83 |
> |
if {$selected_pics == {}} { |
84 |
|
set curmess "No pictures selected." |
85 |
|
return |
86 |
|
} |
95 |
|
list_views |
96 |
|
} |
97 |
|
|
98 |
< |
proc get_selpics {} { # return selected pictures |
98 |
> |
proc get_selpics {{getall 0}} { # return selected pictures |
99 |
|
global fvwbox ufvwbox radvar rawfroot |
100 |
|
set sl {} |
101 |
|
foreach i [$fvwbox curselection] { |
102 |
|
testappend sl $radvar(PICTURE)_[$fvwbox get $i].pic |
103 |
< |
if {$rawfroot != $radvar(PICTURE)} { |
103 |
> |
if {$getall && $rawfroot != $radvar(PICTURE)} { |
104 |
|
testappend sl ${rawfroot}_[$fvwbox get $i].pic |
105 |
|
} |
106 |
< |
if {$radvar(ZFILE) != {}} { |
106 |
> |
if {$getall && $radvar(ZFILE) != {}} { |
107 |
|
testappend sl $radvar(ZFILE)_[$fvwbox get $i].zbf |
108 |
|
} |
109 |
|
} |
110 |
|
foreach i [$ufvwbox curselection] { |
111 |
|
testappend sl ${rawfroot}_[$ufvwbox get $i].unf |
112 |
< |
if {$radvar(ZFILE) != {}} { |
112 |
> |
if {$getall && $radvar(ZFILE) != {}} { |
113 |
|
testappend sl $radvar(ZFILE)_[$ufvwbox get $i].zbf |
114 |
|
} |
115 |
|
} |
119 |
|
proc dsppic {} { # Display selected pictures |
120 |
|
global curmess dispcom radvar |
121 |
|
set selected_pics [get_selpics] |
122 |
< |
if {"$selected_pics" == {}} { |
122 |
> |
if {$selected_pics == {}} { |
123 |
|
set curmess "No pictures selected." |
124 |
|
return |
125 |
|
} |
126 |
< |
if {"$radvar(EXPOSURE)" == {}} { |
126 |
> |
if {$radvar(EXPOSURE) == {}} { |
127 |
|
set ev 0 |
128 |
|
} else { |
129 |
|
if [regexp {^[+-]} $radvar(EXPOSURE)] { |
138 |
|
} |
139 |
|
} |
140 |
|
foreach p $selected_pics { |
141 |
< |
if [string match *.unf $p] { |
141 |
> |
if {[string match *.unf $p] || |
142 |
> |
$radvar(PICTURE) == "$radvar(RAWFILE)"} { |
143 |
|
set dc [format $dispcom $ev $p] |
144 |
|
} else { |
145 |
|
set dc [format $dispcom 0 $p] |
262 |
|
place $w.prte -relwidth .5714 -relheight .0610 -relx .3571 -rely .8537 |
263 |
|
helplink $w.prte trad results printcommand |
264 |
|
# Fill in views |
265 |
< |
if {[info exists radvar(RAWFILE)] && $radvar(RAWFILE) != {}} { |
265 |
> |
if {$radvar(RAWFILE) != {}} { |
266 |
|
set rawfroot $radvar(RAWFILE) |
267 |
|
} else { |
268 |
|
set rawfroot $radvar(PICTURE) |
268 |
– |
} |
269 |
– |
if {! [info exists radvar(ZFILE)]} { |
270 |
– |
set radvar(ZFILE) {} |
269 |
|
} |
270 |
|
list_views |
271 |
|
} |