end
}
- gammacorrect_and_cleanup_real = proc { |values|
- perform_change_gammacorrect_and_cleanup = Proc.new { |val|
- cleanup_all_thumbnails.call
- change_gammacorrect($xmldir.elements["*[@filename='#{filename}']"], '', val)
- recalc_gammacorrect(val, fullpath, thumbnail_img, img,
- $xmldir.elements["*[@filename='#{filename}']"], '', $default_thumbnails[:x], $default_thumbnails[:y], '')
- }
- perform_change_gammacorrect_and_cleanup.call(values[:new])
-
- save_undo(_("gamma correction"),
- Proc.new {
- perform_change_gammacorrect_and_cleanup.call(values[:old])
- textview.grab_focus
- autoscroll_if_needed($autotable_sw, img, textview)
- $notebook.set_page(1)
- Proc.new {
- perform_change_gammacorrect_and_cleanup.call(values[:new])
- textview.grab_focus
- autoscroll_if_needed($autotable_sw, img, textview)
- $notebook.set_page(1)
- }
- })
- }
-
- gammacorrect_and_cleanup = Proc.new {
- if values = ask_gammacorrect(fullpath, thumbnail_img, img,
- $xmldir.elements["*[@filename='#{filename}']"], '', $default_thumbnails[:x], $default_thumbnails[:y], '')
- gammacorrect_and_cleanup_real.call(values)
- end
- }
-
+ gammacorrect_and_cleanup_real = proc { |values|
+ perform_change_gammacorrect_and_cleanup = Proc.new { |val|
+ cleanup_all_thumbnails.call
+ change_gammacorrect($xmldir.elements["*[@filename='#{filename}']"], '', val)
+ recalc_gammacorrect(val, fullpath, thumbnail_img, img,
+ $xmldir.elements["*[@filename='#{filename}']"], '', $default_thumbnails[:x], $default_thumbnails[:y], '')
+ }
+ perform_change_gammacorrect_and_cleanup.call(values[:new])
+
+ save_undo(_("gamma correction"),
+ Proc.new {
+ perform_change_gammacorrect_and_cleanup.call(values[:old])
+ textview.grab_focus
+ autoscroll_if_needed($autotable_sw, img, textview)
+ $notebook.set_page(1)
+ Proc.new {
+ perform_change_gammacorrect_and_cleanup.call(values[:new])
+ textview.grab_focus
+ autoscroll_if_needed($autotable_sw, img, textview)
+ $notebook.set_page(1)
+ }
+ })
+ }
+
+ gammacorrect_and_cleanup = Proc.new {
+ if values = ask_gammacorrect(fullpath, thumbnail_img, img,
+ $xmldir.elements["*[@filename='#{filename}']"], '', $default_thumbnails[:x], $default_thumbnails[:y], '')
+ gammacorrect_and_cleanup_real.call(values)
+ end
+ }
+
enhance_and_cleanup = proc {
perform_enhance_and_cleanup = proc {
cleanup_all_thumbnails.call
enhance($xmldir.elements["*[@filename='#{filename}']"], '')
my_gen_real_thumbnail.call
}
-
+
cleanup_all_thumbnails.call
perform_enhance_and_cleanup.call