ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/CV/bin/cv
(Generate patch)

Comparing CV/bin/cv (file contents):
Revision 1.68 by root, Mon Oct 23 17:52:37 2006 UTC vs.
Revision 1.72 by root, Tue Oct 16 22:44:26 2007 UTC

1#!/opt/bin/perl 1#!/opt/bin/perl
2 2
3use Cwd (); 3use Cwd ();
4use Encode (); 4use Encode ();
5use File::Glob ();
5 6
6use Gtk2 -init; 7use Gtk2 -init;
7use Gtk2::Gdk::Keysyms; 8use Gtk2::Gdk::Keysyms;
8 9
9use Gtk2::CV; 10use Gtk2::CV;
166 $schnauzer->show_all; 167 $schnauzer->show_all;
167 $schnauzer->handle_key ($Gtk2::Gdk::Keysyms{space}, []); 168 $schnauzer->handle_key ($Gtk2::Gdk::Keysyms{space}, []);
168 $viewer->show_all; 169 $viewer->show_all;
169 }; 170 };
170 171
172 if (@ARGV == 1 && $ARGV[0] eq "-0r") {
173 local $/;
174 $schnauzer->set_paths ([map Glib::filename_to_unicode $_, split /\x00/, <STDIN>], 1, $show_first);
171 @ARGV == 1 && -d $ARGV[0] 175 } elsif (@ARGV == 1 && -d $ARGV[0]) {
172 ? $schnauzer->set_dir (Glib::filename_to_unicode shift, $show_first) 176 $schnauzer->set_dir (Glib::filename_to_unicode shift, $show_first);
177 } else {
178 if ($ARGV[0] eq "-g") {
179 shift @ARGV;
180 @ARGV = map +(File::Glob::bsd_glob $_, File::Glob::GLOB_BRACE | File::Glob::GLOB_QUOTE), @ARGV;
181 }
173 : $schnauzer->set_paths ([map Glib::filename_to_unicode $_, @ARGV], 1, $show_first); 182 $schnauzer->set_paths ([map Glib::filename_to_unicode $_, @ARGV], 1, $show_first);
183 }
174} else { 184} else {
175 $schnauzer->set_dir (File::Spec->curdir, sub { 185 $schnauzer->set_dir (File::Spec->curdir, sub {
176 $mainwin->show_all; 186 $mainwin->show_all;
177 $viewer->show_all; 187 $viewer->show_all;
178 }); 188 });
179} 189}
180 190
181main Gtk2; 191main Gtk2;
192
193Gtk2::CV::flush_aio;
182 194
183__DATA__ 195__DATA__
184 196
185=encoding utf-8 197=encoding utf-8
186 198
426=item CV_EDITOR 438=item CV_EDITOR
427 439
428The program that gets executed when the user presses C<CTRL-e> in the 440The program that gets executed when the user presses C<CTRL-e> in the
429Schnauzer or image window. The default is C<gimp>. 441Schnauzer or image window. The default is C<gimp>.
430 442
443=item CV_AUDIO_PLAYER
444
445Program used to play all sorts of audio (wav, aif, mp3, ogg...), default "play".
446Will be called like C<< $CV_AUDIO_PLAYER -- <path> >>.
447
431=item CV_PRINT_DESTINATION 448=item CV_PRINT_DESTINATION
432 449
433The default (perl-style) destination to use in the print dialog. 450The default (perl-style) destination to use in the print dialog.
434 451
435=item CV_TRASHCAN 452=item CV_TRASHCAN

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines