Changeset 9585
- Timestamp:
- 2005-04-07T15:05:10+12:00 (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gsdl/perllib/plugins/ImagePlug.pm
r9574 r9585 145 145 my $outhandle = $self->{'outhandle'}; 146 146 147 # None of this works very well on Windows 95/98...148 if ($ENV{'GSDLOS'} eq "windows" && !Win32::IsWinNT()) {149 print $outhandle "ImagePlug: Windows 95/98 not supported\n" if ($verbosity > 1);150 return undef;151 }152 153 # None of this is going to work very well without ImageMagick...154 if ($self->{'imagemagick_not_installed'}) {155 print $outhandle "ImagePlug: ImageMagick not installed\n" if ($verbosity > 1);156 return undef;157 }158 159 147 # check the filename is okay 160 148 return 0 if ($file eq "" || $filename eq ""); … … 388 376 if $self->{'verbosity'} > 1; 389 377 378 # None of this works very well on Windows 95/98... 379 if ($ENV{'GSDLOS'} eq "windows" && !Win32::IsWinNT()) { 380 if ($gli) { 381 print STDERR "<ProcessingError n='$file' r='Windows 95/98 not supported'>\n"; 382 } 383 else { 384 print $outhandle "ImagePlug: Windows 95/98 not supported\n"; 385 } 386 return -1; 387 } 388 389 # None of this is going to work very well without ImageMagick... 390 if ($self->{'imagemagick_not_installed'}) { 391 if ($gli) { 392 print STDERR "<ProcessingError n='$file' r='ImageMagick not installed'>\n"; 393 } 394 else { 395 print $outhandle "ImagePlug: ImageMagick not installed\n"; 396 } 397 return -1; 398 } 399 390 400 #if there's a leading directory name, eat it... 391 401 $file =~ s/^.*[\/\\]//; … … 401 411 if (!defined $result) 402 412 { 403 print "ImagePlug: couldn't process \"$filename\"\n"; 413 if ($gli) { 414 print STDERR "<ProcessingError n='$file'>\n"; 415 } 416 else { 417 print $outhandle "ImagePlug: couldn't process \"$filename\"\n"; 418 } 404 419 return -1; # error during processing 405 420 } … … 413 428 414 429 # do plugin specific processing of doc_obj 415 return -1 unless defined ($self->process (\$text, $pluginfo, $base_dir, 416 $file, $metadata, $doc_obj)); 430 unless (defined ($self->process(\$text, $pluginfo, $base_dir, $file, $metadata, $doc_obj))) { 431 print STDERR "<ProcessingError n='$file'>\n" if ($gli); 432 return -1; 433 } 417 434 418 435 # do any automatic metadata extraction
Note:
See TracChangeset
for help on using the changeset viewer.