| Revision: | 1.2 |
| Committed: | Mon Nov 3 01:27:37 2003 UTC (22 years, 11 months ago) by root |
| Branch: | MAIN |
| Changes since 1.1: | +14 -0 lines |
| Log Message: | *** empty log message *** |
| # | User | Rev | Content |
|---|---|---|---|
| 1 | root | 1.1 | package Gtk2::CV; |
| 2 | |||
| 3 | use XSLoader; | ||
| 4 | |||
| 5 | XSLoader::load "Gtk2::CV", 0.0001; | ||
| 6 | |||
| 7 | root | 1.2 | use Gtk2; |
| 8 | |||
| 9 | sub require_image { | ||
| 10 | my $path; | ||
| 11 | |||
| 12 | for (@INC) { | ||
| 13 | $path = "$_/Gtk2/CV/images/$_[0]"; | ||
| 14 | last if -r $path; | ||
| 15 | } | ||
| 16 | |||
| 17 | eval { new_from_file Gtk2::Gdk::Pixbuf $path } | ||
| 18 | or die "can't find image $_[0] in \@INC"; | ||
| 19 | } | ||
| 20 | |||
| 21 | root | 1.1 | 1; |
| 22 |