[perl-Glib-IO] Specify sub name corrections for Glib::IO::File



commit 61deb13f5d839efa02f9e22ae6f13f7012a2c07e
Author: Torsten Schönfeld <kaffeetisch gmx de>
Date:   Sat Apr 17 20:08:21 2010 +0200

    Specify sub name corrections for Glib::IO::File

 lib/Glib/IO.pm |   11 ++++++++++-
 t/file.t       |    2 +-
 2 files changed, 11 insertions(+), 2 deletions(-)
---
diff --git a/lib/Glib/IO.pm b/lib/Glib/IO.pm
index f677ef5..005a63e 100644
--- a/lib/Glib/IO.pm
+++ b/lib/Glib/IO.pm
@@ -8,9 +8,18 @@ our $GIO_VERSION = '2.0';
 our $GIO_PACKAGE = 'Glib::IO';
 
 sub import {
+  my %name_corrections = (
+    'Glib::IO::file_hash'                    => 'Glib::IO::File::hash',
+    'Glib::IO::file_new_for_commandline_arg' => 'Glib::IO::File::new_for_commandline_arg',
+    'Glib::IO::file_new_for_path'            => 'Glib::IO::File::new_for_path',
+    'Glib::IO::file_new_for_uri'             => 'Glib::IO::File::new_for_uri',
+    'Glib::IO::file_parse_name'              => 'Glib::IO::File::parse_name',
+  );
+
   Glib::Object::Introspection->setup(basename => $GIO_BASENAME,
                                      version => $GIO_VERSION,
-                                     package => $GIO_PACKAGE);
+                                     package => $GIO_PACKAGE,
+                                     name_corrections => \%name_corrections);
 }
 
 1;
diff --git a/t/file.t b/t/file.t
index b92bcfe..e746d60 100644
--- a/t/file.t
+++ b/t/file.t
@@ -7,7 +7,7 @@ use Glib::IO;
 my $loop = Glib::MainLoop->new ();
 
 # FIXME: Glib::IO::File->new_for_path?
-my $file = Glib::IO::file_new_for_path ($0);
+my $file = Glib::IO::File::new_for_path ($0);
 
 $file->query_info_async ('*', [], 0, undef, \&info, [ 23, 'bla' ]);
 sub info {



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]