# Album Plugin: dir_thumbs/file # For info: 'album -plugin_info dir_thumbs/file' # For usage: 'album -plugin_usage dir_thumbs/file' use strict; my $DESC = < 'Joey Richards', href => 'http://www.borkbork.org/~bigjoe', version => '0.1', description => 'Specify an image for the directory thumbnail.' }; } sub dirthumb { my ($opt, $data, $s, $child) = @_; my $dir = $data->{paths}{dir}; my $child_path = "$dir/$child"; if (-e "$child_path/dirthumb.jpg") { return ($child_path, $child, "$child_path/dirthumb.jpg", "dirthumb.jpg"); } else { return undef; } }