Hello community,

here is the log from the commit of package perl-Glib-Object-Introspection for 
openSUSE:Factory checked in at 2018-10-11 11:53:49
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/perl-Glib-Object-Introspection (Old)
 and      /work/SRC/openSUSE:Factory/.perl-Glib-Object-Introspection.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "perl-Glib-Object-Introspection"

Thu Oct 11 11:53:49 2018 rev:10 rq:640621 version:0.046

Changes:
--------
--- 
/work/SRC/openSUSE:Factory/perl-Glib-Object-Introspection/perl-Glib-Object-Introspection.changes
    2017-05-16 14:44:18.850219740 +0200
+++ 
/work/SRC/openSUSE:Factory/.perl-Glib-Object-Introspection.new/perl-Glib-Object-Introspection.changes
       2018-10-11 11:54:58.234060265 +0200
@@ -1,0 +2,23 @@
+Mon Oct  8 12:02:09 UTC 2018 - Dirk Stoecker <[email protected]>
+
+- Fix autogenerated changes
+
+-------------------------------------------------------------------
+Thu Sep 27 05:18:46 UTC 2018 - Stephan Kulow <[email protected]>
+
+- updated to 0.046
+   see /usr/share/doc/packages/perl-Glib-Object-Introspection/
+
+-------------------------------------------------------------------
+Wed May 23 05:24:14 UTC 2018 - [email protected]
+
+- updated to 0.045
+   see /usr/share/doc/packages/perl-Glib-Object-Introspection/
+
+-------------------------------------------------------------------
+Wed Feb  7 16:35:37 UTC 2018 - [email protected]
+
+- updated to 0.044
+   see /usr/share/doc/packages/perl-Glib-Object-Introspection/
+
+-------------------------------------------------------------------

Old:
----
  Glib-Object-Introspection-0.042.tar.gz

New:
----
  Glib-Object-Introspection-0.046.tar.gz
  cpanspec.yml

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ perl-Glib-Object-Introspection.spec ++++++
--- /var/tmp/diff_new_pack.9kGd22/_old  2018-10-11 11:54:59.070059201 +0200
+++ /var/tmp/diff_new_pack.9kGd22/_new  2018-10-11 11:54:59.074059197 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package perl-Glib-Object-Introspection
 #
-# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -12,28 +12,32 @@
 # license that conforms to the Open Source Definition (Version 1.9)
 # published by the Open Source Initiative.
 
-# Please submit bugfixes or comments via http://bugs.opensuse.org/
+# Please submit bugfixes or comments via https://bugs.opensuse.org/
 #
 
 
-%define cpan_name Glib-Object-Introspection
 Name:           perl-Glib-Object-Introspection
-Version:        0.042
+Version:        0.046
 Release:        0
+%define cpan_name Glib-Object-Introspection
 Summary:        GObject Introspection bindings for Perl
-License:        LGPL-2.1+
-Group:          Development/Languages/Perl
-Url:            https://metacpan.org/pod/Glib::Object::Introspection
-Source:         
https://cpan.metacpan.org/authors/id/X/XA/XAOC/%{cpan_name}-%{version}.tar.gz
+License:        LGPL-2.1-or-later
+Group:          Development/Libraries/Perl
+Url:            https://metacpan.org/release/%{cpan-name}
+Source0:        
https://cpan.metacpan.org/authors/id/X/XA/XAOC/%{cpan_name}-%{version}.tar.gz
+Source1:        cpanspec.yml
+BuildRoot:      %{_tmppath}/%{name}-%{version}-build
 BuildRequires:  perl
 BuildRequires:  perl-macros
+BuildRequires:  perl(ExtUtils::Depends) >= 0.3
+BuildRequires:  perl(ExtUtils::PkgConfig) >= 1
+BuildRequires:  perl(Glib) >= 1.32
 BuildRequires:  pkgconfig
-BuildRequires:  perl(ExtUtils::Depends)
-BuildRequires:  perl(ExtUtils::PkgConfig)
-BuildRequires:  perl(Glib) >= 1.320
 BuildRequires:  pkgconfig(gobject-introspection-1.0)
-Requires:       perl(Glib) >= 1.320
-%perl_requires
+Requires:       perl(ExtUtils::Depends) >= 0.3
+Requires:       perl(ExtUtils::PkgConfig) >= 1
+Requires:       perl(Glib) >= 1.32
+%{perl_requires}
 
 %description
 This package provides perl bindings for GObject Introspection.
@@ -47,7 +51,10 @@
 
 %build
 perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="%{optflags}"
-make %{?_smp_mflags} V=1
+make %{?_smp_mflags}
+
+%check
+make test
 
 %install
 %perl_make_install
@@ -55,7 +62,8 @@
 %perl_gen_filelist
 
 %files -f %{name}.files
-%defattr(-,root,root)
-%doc LICENSE NEWS README
+%defattr(-,root,root,755)
+%doc NEWS perl-Glib-Object-Introspection.doap README
+%license LICENSE
 
 %changelog

++++++ Glib-Object-Introspection-0.042.tar.gz -> 
Glib-Object-Introspection-0.046.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/Glib-Object-Introspection-0.042/GObjectIntrospection.xs 
new/Glib-Object-Introspection-0.046/GObjectIntrospection.xs
--- old/Glib-Object-Introspection-0.042/GObjectIntrospection.xs 2016-11-21 
14:44:53.000000000 +0100
+++ new/Glib-Object-Introspection-0.046/GObjectIntrospection.xs 2017-05-21 
21:02:28.000000000 +0200
@@ -1019,6 +1019,26 @@
     OUTPUT:
        RETVAL
 
+gint
+convert_sv_to_flags (class, const gchar *package, SV *sv)
+    PREINIT:
+       GType gtype;
+    CODE:
+       gtype = gperl_type_from_package (package);
+       RETVAL = gperl_convert_flags (gtype, sv);
+    OUTPUT:
+       RETVAL
+
+SV *
+convert_flags_to_sv (class, const gchar *package, gint n)
+    PREINIT:
+       GType gtype;
+    CODE:
+       gtype = gperl_type_from_package (package);
+       RETVAL = gperl_convert_back_flags (gtype, n);
+    OUTPUT:
+       RETVAL
+
 # --------------------------------------------------------------------------- #
 
 MODULE = Glib::Object::Introspection   PACKAGE = 
Glib::Object::Introspection::GValueWrapper
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Glib-Object-Introspection-0.042/META.json 
new/Glib-Object-Introspection-0.046/META.json
--- old/Glib-Object-Introspection-0.042/META.json       2016-12-23 
23:34:38.000000000 +0100
+++ new/Glib-Object-Introspection-0.046/META.json       2018-09-26 
07:05:12.000000000 +0200
@@ -5,7 +5,7 @@
       "Glib::Object::Introspection Team <gtk-perl-list at gnome dot org>"
    ],
    "dynamic_config" : 1,
-   "generated_by" : "ExtUtils::MakeMaker version 7.18, CPAN::Meta::Converter 
version 2.150005",
+   "generated_by" : "ExtUtils::MakeMaker version 7.3, CPAN::Meta::Converter 
version 2.150010",
    "license" : [
       "unknown",
       "lgpl_2_1"
@@ -62,12 +62,11 @@
       ],
       "repository" : {
          "type" : "git",
-         "url" : "git://git.gnome.org/perl-Glib-Object-Introspection",
-         "web" : "http://git.gnome.org/browse/perl-Glib-Object-Introspection";
+         "web" : 
"https://gitlab.gnome.org/GNOME/perl-glib-object-introspection";
       },
       "x_IRC" : "irc://irc.gimp.org/#gtk-perl",
       "x_MailingList" : "https://mail.gnome.org/mailman/listinfo/gtk-perl-list";
    },
-   "version" : "0.042",
-   "x_serialization_backend" : "JSON::PP version 2.27300"
+   "version" : "0.046",
+   "x_serialization_backend" : "JSON::PP version 2.27400_02"
 }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Glib-Object-Introspection-0.042/META.yml 
new/Glib-Object-Introspection-0.046/META.yml
--- old/Glib-Object-Introspection-0.042/META.yml        2016-12-23 
23:34:38.000000000 +0100
+++ new/Glib-Object-Introspection-0.046/META.yml        2018-09-26 
07:05:12.000000000 +0200
@@ -11,7 +11,7 @@
   ExtUtils::PkgConfig: '1'
   Glib: '1.32'
 dynamic_config: 1
-generated_by: 'ExtUtils::MakeMaker version 7.18, CPAN::Meta::Converter version 
2.150005'
+generated_by: 'ExtUtils::MakeMaker version 7.3, CPAN::Meta::Converter version 
2.150010'
 license: unknown
 meta-spec:
   url: http://module-build.sourceforge.net/META-spec-v1.4.html
@@ -36,6 +36,6 @@
   bugtracker: 
http://rt.cpan.org/Public/Dist/Display.html?Name=Glib-Object-Introspection
   homepage: http://gtk2-perl.sourceforge.net
   license: http://www.gnu.org/licenses/lgpl-2.1.html
-  repository: git://git.gnome.org/perl-Glib-Object-Introspection
-version: '0.042'
+  repository: https://gitlab.gnome.org/GNOME/perl-glib-object-introspection
+version: '0.046'
 x_serialization_backend: 'CPAN::Meta::YAML version 0.018'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Glib-Object-Introspection-0.042/Makefile.PL 
new/Glib-Object-Introspection-0.046/Makefile.PL
--- old/Glib-Object-Introspection-0.042/Makefile.PL     2016-11-21 
14:44:53.000000000 +0100
+++ new/Glib-Object-Introspection-0.046/Makefile.PL     2018-09-26 
07:02:20.000000000 +0200
@@ -71,9 +71,9 @@
                     mailto  => 'bug-Glib-Object-Introspection [at] 
rt.cpan.org',
             },
             repository  => {
-                    url     => 
'git://git.gnome.org/perl-Glib-Object-Introspection',
+                    url     => 
'[email protected]:GNOME/perl-glib-object-introspection.git',
                     type    => 'git',
-                    web     => 
'http://git.gnome.org/browse/perl-Glib-Object-Introspection',
+                    web     => 
'https://gitlab.gnome.org/GNOME/perl-glib-object-introspection',
             },
         },
         prereqs => {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Glib-Object-Introspection-0.042/NEWS 
new/Glib-Object-Introspection-0.046/NEWS
--- old/Glib-Object-Introspection-0.042/NEWS    2016-12-23 23:25:56.000000000 
+0100
+++ new/Glib-Object-Introspection-0.046/NEWS    2018-09-26 07:03:40.000000000 
+0200
@@ -1,3 +1,29 @@
+Overview of changes in Glib::Object::Introspection 0.046
+========================================================
+
+* Makefile.PL: changed location of Git repo/web page
+* perli11ndoc: add support for links in the results display
+* Fix a test failure in t/arrays.t on older versions of gobject-introspection
+* Improve some debug output
+* Hush two compiler warnings by adding missing 'break' statements
+
+Overview of changes in Glib::Object::Introspection 0.045
+========================================================
+
+* Correctly marshal arrays with length arguments in signal callbacks
+* Add some docs about overriding virtual functions
+
+Overview of changes in Glib::Object::Introspection 0.044
+========================================================
+
+* perli11ndoc: properly handle callback fields without return value
+∗ interface -> SV: correctly marshal class struct args of functions
+
+Overview of changes in Glib::Object::Introspection 0.043
+========================================================
+
+* Add functions for handling raw flags values
+
 Overview of changes in Glib::Object::Introspection 0.042
 ========================================================
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Glib-Object-Introspection-0.042/bin/perli11ndoc 
new/Glib-Object-Introspection-0.046/bin/perli11ndoc
--- old/Glib-Object-Introspection-0.042/bin/perli11ndoc 2016-12-19 
13:48:30.000000000 +0100
+++ new/Glib-Object-Introspection-0.046/bin/perli11ndoc 2018-09-26 
06:44:28.000000000 +0200
@@ -255,9 +255,12 @@
   if ($callback_list->size == 1) {
     my $callback = $callback_list->pop;
     my ($in, $retval, $out) = $self->find_parameters_and_return_value 
($callback);
+    unshift @$out, $retval if defined $retval;
     my $in_list = join ', ', map { $self->find_type_name ($_) } @$in;
-    my $out_list = join ', ', map { $self->find_type_name ($_) } ($retval, 
@$out);
-    return "callback (in: $in_list; out: $out_list)";
+    my $out_list = join ', ', map { $self->find_type_name ($_) } @$out;
+    my $in_text = $in_list ne '' ? "in: $in_list" : '';
+    my $out_text = $out_list ne '' ? "; out: $out_list" : '';
+    return "callback ($in_text$out_text)";
   }
 
   # bare types
@@ -378,7 +381,7 @@
     next unless @$entries;
     $text .= "$heading\n\n";
     foreach my $entry (@$entries) {
-      $text .= '  ' . $entry->{name} . "\n";
+      $text .= sprintf "  [%s](%s)\n", $entry->{name}, $entry->{path};
     }
     $text .= "\n";
   }
@@ -829,9 +832,10 @@
     $text .= "\nCONSTRUCTORS\n\n";
     foreach my $ctor ($ctor_list->get_nodelist) {
       my $name = $self->find_attribute ($ctor, 'name');
+      my $path = $ctor->nodePath;
       my $flags = $self->format_callable_flags ($ctor,
                                                 qw/introspectable version/);
-      $text .= "  • $name$flags\n";
+      $text .= "  • [$name]($path)$flags\n";
     }
   }
   return $text;
@@ -845,10 +849,11 @@
     $text .= "\nFIELDS\n\n";
     foreach my $field ($field_list->get_nodelist) {
       my $name = $self->find_attribute ($field, 'name');
+      my $path = $field->nodePath;
       my $type_name = $self->find_type_name ($field);
       my $full_type_name = $self->format_full_type_name ($type_name);
       my $flags = $self->format_field_flags ($field, qw/introspectable/);
-      $text .= "  • $name: $full_type_name$flags\n";
+      $text .= "  • [$name]($path): $full_type_name$flags\n";
     }
   }
   return $text;
@@ -862,9 +867,10 @@
     $text .= "\n$heading\n\n";
     foreach my $function ($function_list->get_nodelist) {
       my $name = $self->find_attribute ($function, 'name');
+      my $path = $function->nodePath;
       my $flags = $self->format_callable_flags ($function,
                                                 qw/introspectable version/);
-      $text .= "  • $name$flags\n";
+      $text .= "  • [$name]($path)$flags\n";
     }
   }
   return $text;
@@ -897,9 +903,10 @@
     $text .= "\nMETHODS\n\n";
     foreach my $method ($method_list->get_nodelist) {
       my $name = $self->find_attribute ($method, 'name');
+      my $path = $method->nodePath;
       my $flags = $self->format_callable_flags ($method,
                                                 qw/introspectable version/);
-      $text .= "  • $name$flags\n";
+      $text .= "  • [$name]($path)$flags\n";
     }
   }
   return $text;
@@ -913,10 +920,11 @@
     $text .= "\nPROPERTIES\n\n";
     foreach my $property ($property_list->get_nodelist) {
       my $name = $self->find_attribute ($property, 'name');
+      my $path = $property->nodePath;
       my $type_name = $self->find_type_name ($property);
       my $full_type_name = $self->format_full_type_name ($type_name);
       my $flags = $self->format_property_flags ($property, qw/version/);
-      $text .= "  • $name: $full_type_name$flags\n";
+      $text .= "  • [$name]($path): $full_type_name$flags\n";
     }
   }
   return $text;
@@ -930,8 +938,9 @@
     $text .= "\nSIGNALS\n\n";
     foreach my $signal ($signal_list->get_nodelist) {
       my $name = $self->find_attribute ($signal, 'name');
+      my $path = $signal->nodePath;
       my $flags = $self->format_signal_flags ($signal, qw/version/);
-      $text .= "  • $name$flags\n";
+      $text .= "  • [$name]($path)$flags\n";
     }
   }
   return $text;
@@ -945,8 +954,9 @@
     $text .= "\nVIRTUAL METHODS\n\n";
     foreach my $vfunc ($vfunc_list->get_nodelist) {
       my $name = $self->find_attribute ($vfunc, 'name');
+      my $path = $vfunc->nodePath;
       my $flags = $self->format_virtual_method_flags ($vfunc);
-      $text .= "  • $name$flags\n";
+      $text .= "  • [$name]($path)$flags\n";
     }
   }
   return $text;
@@ -1311,7 +1321,35 @@
 
 sub display_results {
   my ($self, $results) = @_;
-  $self->{result_buffer}->set_text ($results);
+
+  my $b = $self->{result_buffer};
+  $b->delete ($b->get_start_iter (), $b->get_end_iter ());
+
+  my $iter = $b->get_start_iter ();
+  my $insert_part = sub {
+    my ($start, $end) = @_;
+    $b->insert ($iter, substr ($results, $start, $end - $start));
+  };
+
+  my ($prev_match_start, $prev_match_end) = (0, 0);
+  while ($results =~ m/\[([^\n\]]+)\]\(([^\n\)]+)\)/g) {
+    my ($link_text, $link_target) = ($1, $2);
+    my ($match_start, $match_end) = ($-[0], $+[0]);
+
+    if ($match_start != $prev_match_end) {
+      $insert_part->($prev_match_end, $match_start);
+    }
+
+    my $tag = $b->create_tag (undef, foreground => 'blue');
+    $tag->{__target} = $link_target;
+    $b->insert_with_tags ($iter, $link_text, $tag);
+
+    ($prev_match_start, $prev_match_end) = ($match_start, $match_end);
+  }
+  my $end_offset = length ($results);
+  if ($prev_match_end != $end_offset) {
+    $insert_part->($prev_match_end, $end_offset);
+  }
 }
 
 sub run {
@@ -1406,7 +1444,7 @@
   });
 
   $gir_view->get_selection->signal_connect (changed => sub {
-    $self->update_results_from_selection
+    $self->go_to_selection
       unless $self->{suppress_gir_view_selection_changes};
   });
 
@@ -1428,9 +1466,19 @@
 sub setup_search_entry {
   my ($self) = @_;
 
+  my $wait_time_ms = 500;
   my $search_entry = Gtk3::SearchEntry->new;
   $search_entry->signal_connect (search_changed => sub {
-    $self->filter_gir_view ($search_entry->get_text);
+    # Use a timeout which is reset when the search text changes so that we do
+    # not filter the view too often.
+    if (defined $search_entry->{__timer_id}) {
+      Glib::Source->remove ($search_entry->{__timer_id});
+    }
+    $search_entry->{__timer_id} = Glib::Timeout->add ($wait_time_ms, sub {
+      $self->filter_gir_view ($search_entry->get_text);
+      $search_entry->{__timer_id} = undef;
+      return Glib::SOURCE_REMOVE ();
+    });
   });
 
   $self->{search_entry} = $search_entry;
@@ -1440,9 +1488,66 @@
   my ($self) = @_;
 
   my $result_buffer = Gtk3::TextBuffer->new (undef);
+
   my $result_view = Gtk3::TextView->new_with_buffer ($result_buffer);
   $result_view->set (editable => FALSE, margin => 2);
 
+  my $display = $result_view->get_display ();
+  $result_view->{__hand_cursor} = Gtk3::Gdk::Cursor->new_from_name ($display, 
'pointer');
+  $result_view->{__regular_cursor} = Gtk3::Gdk::Cursor->new_from_name 
($display, 'text');
+
+  my $hovering_over_link = sub {
+    my ($event) = @_;
+    my ($x, $y) = $result_view->window_to_buffer_coords ('widget', $event->x, 
$event->y);
+    my $iter = $result_view->get_iter_at_location ($x, $y);
+    if (!$iter) {
+      return undef;
+    }
+    my $tags = $iter->get_tags ();
+    foreach my $tag (@$tags) {
+      if (defined $tag->{__target}) {
+        return $tag;
+      }
+    }
+    return undef;
+  };
+
+  $result_view->{__hovering} = FALSE;
+  $result_view->signal_connect (motion_notify_event => sub {
+    my ($result_view, $event) = @_;
+    my $hovering = defined $hovering_over_link->($event);
+    if ($result_view->{__hovering} != $hovering) {
+      $result_view->{__hovering} = $hovering;
+      $result_view->get_window ('text')->set_cursor (
+        $hovering ? $result_view->{__hand_cursor} : 
$result_view->{__regular_cursor});
+    }
+    return Gtk3::EVENT_PROPAGATE ();
+  });
+
+  my $handle_button = sub {
+    my ($event, $cb) = @_;
+    if ($event->button == Gtk3::Gdk::BUTTON_PRIMARY ()) {
+      my $tag = $hovering_over_link->($event);
+      if (defined $tag) {
+        if (defined $cb) {
+          $cb->($tag);
+        }
+        return Gtk3::EVENT_STOP ();
+      }
+    }
+    return Gtk3::EVENT_PROPAGATE ();
+  };
+  $result_view->signal_connect (button_press_event => sub {
+    my ($result_view, $event) = @_;
+    return $handle_button->($event);
+  });
+  $result_view->signal_connect (button_release_event => sub {
+    my ($result_view, $event) = @_;
+    return $handle_button->($event, sub {
+      $self->go_to_path ($_[0]->{__target});
+    });
+  });
+
   $self->{result_buffer} = $result_buffer;
   $self->{result_view} = $result_view;
 }
@@ -1454,6 +1559,7 @@
 
   $self->{gir_model}->clear;
   $self->{search_entry}->set_text ('');
+  $self->{path_bar}->clear;
 
   my $inserter = sub {
     my ($iter, $text, $path, $is_cat, $is_vis) = @_;
@@ -1499,7 +1605,7 @@
   $self->display_results ($self->{parser}->format_namespace);
 }
 
-sub update_results_from_selection {
+sub go_to_selection {
   my ($self) = @_;
   my $selection = $self->{gir_view}->get_selection;
   my ($model, $iter) = $selection->get_selected;
@@ -1507,28 +1613,36 @@
     $self->display_results ($self->{parser}->format_namespace);
   } elsif (!$model->get ($iter, GIR_VIEW_COL_IS_CATEGORY)) {
     my $path = $model->get ($iter, GIR_VIEW_COL_PATH);
-    my $name = $self->{parser}->format_node_name_by_path ($path);
-    $self->{path_bar}->append ($name, $path); # indirectly calls update_results
+    $self->go_to_path ($path);
   }
 }
 
+sub go_to_path {
+  my ($self, $path) = @_;
+  my $name = $self->{parser}->format_node_name_by_path ($path);
+  $self->{path_bar}->append ($name, $path); # indirectly calls update_results
+}
+
 sub update_results {
   my ($self, $path) = @_;
   $self->display_results ($self->{parser}->format_node_by_path ($path));
 
-  # If display and selection are out-of-sync, clear the selection.
-  my $selection = $self->{gir_view}->get_selection;
-  my ($model, $iter) = $selection->get_selected;
-  if (defined $iter) {
-    my $sel_path = $model->get ($iter, GIR_VIEW_COL_PATH);
-    if ($sel_path ne $path) {
+  # Show and select the correponding tree entry.
+  $self->{gir_model}->foreach (sub {
+    my ($model, $tree_path, $iter) = @_;
+    my $this_path = $model->get ($iter, GIR_VIEW_COL_PATH);
+    if (defined $this_path && $this_path eq $path) {
+      $self->{gir_view}->expand_to_path ($tree_path);
+      $self->{gir_view}->scroll_to_cell ($tree_path, undef, FALSE, 0.0, 0.0);
       $self->{suppress_gir_view_selection_changes} = TRUE;
       {
-        $selection->unselect_all;
+        $self->{gir_view}->get_selection ()->select_path ($tree_path);
       }
       $self->{suppress_gir_view_selection_changes} = FALSE;
+      return TRUE; # stop
     }
-  }
+    return FALSE; # continue
+  });
 }
 
 sub quit {
@@ -1585,6 +1699,12 @@
   return $self;
 }
 
+sub clear {
+  my ($self) = @_;
+  $self->{path_label}->clear ();
+  $self->update_buttons ();
+}
+
 sub append {
   my ($self, $name, $path) = @_;
   $self->{path_label}->append ($name, $path);
@@ -1616,20 +1736,35 @@
     my (undef, $index) = @_;
     $self->{current_child} = $index;
     $self->update;
-    return TRUE; # handled
+    return Gtk3::EVENT_STOP ();
   });
   $self->set_track_visited_links (FALSE);
 
+  $self->clear ();
+}
+
+sub clear {
+  my ($self) = @_;
   $self->{children} = [];
   $self->{current_child} = undef;
   $self->{natural_width} = 0;
+  $self->update ();
 }
 
 sub append {
   my ($self, $name, $path) = @_;
-  if (defined $self->{current_child} &&
-      $self->{current_child} < $#{$self->{children}}) {
-    splice @{$self->{children}}, $self->{current_child}+1;
+  my $cur = $self->{current_child};
+  # If the new entry is equal to the current entry, do nothing.
+  if (defined $cur) {
+    my $child = $self->{children}->[$cur];
+    if ($child->{name} eq $name && $child->{path} eq $path) {
+      return;
+    }
+  }
+  # If the current entry is not the last entry, remove all entries after the
+  # current one before appending the new entry.
+  if (defined $cur && $cur < $#{$self->{children}}) {
+    splice @{$self->{children}}, $cur+1;
   }
   push @{$self->{children}}, {name => $name, path => $path};
   $self->{current_child} = $#{$self->{children}};
@@ -1638,12 +1773,12 @@
 
 sub can_go_back {
   my ($self) = @_;
-  return $self->{current_child} > 0;
+  return defined $self->{current_child} && $self->{current_child} > 0;
 }
 
 sub can_go_forward {
   my ($self) = @_;
-  return $self->{current_child} < $#{$self->{children}};
+  return defined $self->{current_child} && $self->{current_child} < 
$#{$self->{children}};
 }
 
 sub go_back {
@@ -1668,7 +1803,7 @@
 sub update {
   my ($self) = @_;
   $self->set_markup ($self->_format_children);
-  if (defined $self->{update_func}) {
+  if (defined $self->{current_child} && defined $self->{update_func}) {
     my $child = $self->{children}->[$self->{current_child}];
     $self->{update_func}->($child->{name}, $child->{path});
   }
@@ -1684,7 +1819,6 @@
 sub SIZE_ALLOCATE {
   #say 'SIZE_ALLOCATE';
   my ($self, $allocation) = @_;
-  #print "$_ => $allocation->{$_}, " for sort keys %$allocation; print "\n";
   if ($self->{natural_width} > $allocation->{width}) {
     my @selected = ($self->{current_child});
     while (1) {
@@ -1712,6 +1846,9 @@
  # Use undef as an indicator for left-out children.
 sub _add_omission_markers {
   my ($self, @indices) = @_;
+  if (!@indices) {
+    return @indices;
+  }
   if ($indices[0] > 0) {
     unshift @indices, undef;
   }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/Glib-Object-Introspection-0.042/gperl-i11n-invoke-perl.c 
new/Glib-Object-Introspection-0.046/gperl-i11n-invoke-perl.c
--- old/Glib-Object-Introspection-0.042/gperl-i11n-invoke-perl.c        
2016-11-21 14:44:53.000000000 +0100
+++ new/Glib-Object-Introspection-0.046/gperl-i11n-invoke-perl.c        
2018-05-22 04:51:32.000000000 +0200
@@ -358,8 +358,10 @@
                if (arg_tag == GI_TYPE_TAG_ARRAY) {
                        gint pos = g_type_info_get_array_length (arg_type);
                        if (pos >= 0) {
-                               GITypeInfo *length_arg_type = 
&(iinfo->base.arg_types[pos]);
-                               raw_to_arg (args[pos], 
&iinfo->base.aux_args[pos], length_arg_type);
+                               GITypeInfo *length_arg_type;
+                               guint args_pos = iinfo->base.is_signal ? pos+1 
: pos;
+                               length_arg_type = &(iinfo->base.arg_types[pos]);
+                               raw_to_arg (args[args_pos], 
&iinfo->base.aux_args[pos], length_arg_type);
                                dwarn ("  pos %d is array length => 
%"G_GSIZE_FORMAT"\n",
                                       pos, iinfo->base.aux_args[pos].v_size);
                        }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/Glib-Object-Introspection-0.042/gperl-i11n-marshal-interface.c 
new/Glib-Object-Introspection-0.046/gperl-i11n-marshal-interface.c
--- old/Glib-Object-Introspection-0.042/gperl-i11n-marshal-interface.c  
2016-11-21 14:44:53.000000000 +0100
+++ new/Glib-Object-Introspection-0.046/gperl-i11n-marshal-interface.c  
2018-09-26 06:44:28.000000000 +0200
@@ -1,34 +1,8 @@
 /* -*- mode: c; indent-tabs-mode: t; c-basic-offset: 8; -*- */
 
-void _store_enum (GIEnumInfo * info, gint value, GIArgument * arg);
-gint _retrieve_enum (GIEnumInfo * info, GIArgument * arg);
-
-static gpointer
-instance_sv_to_class_struct_pointer (SV *sv, GPerlI11nInvocationInfo *iinfo)
-{
-       gpointer pointer = NULL;
-       GType class_type = 0;
-       dwarn ("  -> gtype struct?\n");
-       if (gperl_sv_is_ref (sv)) { /* instance? */
-               const char *package = sv_reftype (SvRV (sv), TRUE);
-               class_type = gperl_type_from_package (package);
-       } else { /* package? */
-               class_type = gperl_type_from_package (SvPV_nolen (sv));
-       }
-       dwarn ("     class_type = %s (%lu), is_classed = %d\n",
-              g_type_name (class_type), class_type, G_TYPE_IS_CLASSED 
(class_type));
-       if (G_TYPE_IS_CLASSED (class_type)) {
-               pointer = g_type_class_peek (class_type);
-               if (!pointer) {
-                       /* If peek() produced NULL, the class has not been
-                        * instantiated yet and needs to be created. */
-                       pointer = g_type_class_ref (class_type);
-                       free_after_call (iinfo, (GFunc) g_type_class_unref, 
pointer);
-               }
-               dwarn ("     type class = %p\n", pointer);
-       }
-       return pointer;
-}
+static gpointer _sv_to_class_struct_pointer (SV *sv, GPerlI11nInvocationInfo 
*iinfo);
+static void _store_enum (GIEnumInfo * info, gint value, GIArgument * arg);
+static gint _retrieve_enum (GIEnumInfo * info, GIArgument * arg);
 
 static gpointer
 instance_sv_to_pointer (GICallableInfo *info, SV *sv, GPerlI11nInvocationInfo 
*iinfo)
@@ -58,7 +32,7 @@
                GType type = get_gtype ((GIRegisteredTypeInfo *) container);
                if (!type || type == G_TYPE_NONE) {
                        if (g_struct_info_is_gtype_struct (container)) {
-                               pointer = instance_sv_to_class_struct_pointer 
(sv, iinfo);
+                               pointer = _sv_to_class_struct_pointer (sv, 
iinfo);
                        }
                        if (!pointer) {
                                dwarn ("  -> untyped record\n");
@@ -200,29 +174,33 @@
                        && !g_type_info_is_pointer (type_info);
                GType type = get_gtype ((GIRegisteredTypeInfo *) interface);
                if (!type || type == G_TYPE_NONE) {
-                       const gchar *namespace, *name, *package;
-                       GType parent_type;
                        dwarn ("  -> untyped record\n");
                        g_assert (!need_value_semantics);
-                       /* Find out whether this untyped record is a member of
-                        * a boxed union before using raw hash-to-struct
-                        * conversion. */
-                       name = g_base_info_get_name (interface);
-                       namespace = g_base_info_get_namespace (interface);
-                       package = get_package_for_basename (namespace);
-                       parent_type = package ? find_union_member_gtype 
(package, name) : 0;
-                       if (parent_type && parent_type != G_TYPE_NONE) {
-                               arg->v_pointer = gperl_get_boxed_check (
-                                                  sv, parent_type);
-                               if (GI_TRANSFER_EVERYTHING == transfer)
-                                       arg->v_pointer =
-                                               g_boxed_copy (parent_type,
-                                                             arg->v_pointer);
+                       if (g_struct_info_is_gtype_struct (interface)) {
+                               arg->v_pointer = _sv_to_class_struct_pointer 
(sv, invocation_info);
                        } else {
-                               arg->v_pointer = sv_to_struct (transfer,
-                                                              interface,
-                                                              info_type,
-                                                              sv);
+                               const gchar *namespace, *name, *package;
+                               GType parent_type;
+                               /* Find out whether this untyped record is a 
member of
+                                * a boxed union before using raw hash-to-struct
+                                * conversion. */
+                               name = g_base_info_get_name (interface);
+                               namespace = g_base_info_get_namespace 
(interface);
+                               package = get_package_for_basename (namespace);
+                               parent_type = package ? find_union_member_gtype 
(package, name) : 0;
+                               if (parent_type && parent_type != G_TYPE_NONE) {
+                                       arg->v_pointer = gperl_get_boxed_check (
+                                                          sv, parent_type);
+                                       if (GI_TRANSFER_EVERYTHING == transfer)
+                                               arg->v_pointer =
+                                                       g_boxed_copy 
(parent_type,
+                                                                     
arg->v_pointer);
+                               } else {
+                                       arg->v_pointer = sv_to_struct (transfer,
+                                                                      
interface,
+                                                                      
info_type,
+                                                                      sv);
+                               }
                        }
                }
 
@@ -256,7 +234,7 @@
                        dwarn ("  -> boxed: type=%s, name=%s, 
caller-allocates=%d, is-pointer=%d\n",
                               g_type_name (type),
                               g_base_info_get_name (interface),
-                              g_arg_info_is_caller_allocates (arg_info),
+                              (arg_info ? g_arg_info_is_caller_allocates 
(arg_info) : INT_MAX),
                               g_type_info_is_pointer (type_info));
                        if (need_value_semantics) {
                                if (may_be_null && !gperl_sv_is_defined (sv)) {
@@ -402,8 +380,8 @@
                }
 
                else if (g_type_is_a (type, G_TYPE_BOXED)) {
-                       dwarn ("  -> boxed: type=%"G_GSIZE_FORMAT" (%s)\n",
-                              type, g_type_name (type));
+                       dwarn ("  -> boxed: pointer=%p, type=%"G_GSIZE_FORMAT" 
(%s), own=%d\n",
+                              arg->v_pointer, type, g_type_name (type), own);
                        sv = gperl_new_boxed (arg->v_pointer, type, own);
                }
 
@@ -464,6 +442,35 @@
 }
 
 /* ------------------------------------------------------------------------- */
+
+static gpointer
+_sv_to_class_struct_pointer (SV *sv, GPerlI11nInvocationInfo *iinfo)
+{
+       gpointer pointer = NULL;
+       GType class_type = 0;
+       dwarn ("  -> gtype struct?\n");
+       if (gperl_sv_is_ref (sv)) { /* instance? */
+               const char *package = sv_reftype (SvRV (sv), TRUE);
+               class_type = gperl_type_from_package (package);
+       } else { /* package? */
+               class_type = gperl_type_from_package (SvPV_nolen (sv));
+       }
+       dwarn ("     class_type = %s (%lu), is_classed = %d\n",
+              g_type_name (class_type), class_type, G_TYPE_IS_CLASSED 
(class_type));
+       if (G_TYPE_IS_CLASSED (class_type)) {
+               pointer = g_type_class_peek (class_type);
+               if (!pointer) {
+                       /* If peek() produced NULL, the class has not been
+                        * instantiated yet and needs to be created. */
+                       pointer = g_type_class_ref (class_type);
+                       free_after_call (iinfo, (GFunc) g_type_class_unref, 
pointer);
+               }
+               dwarn ("     type class = %p\n", pointer);
+       }
+       return pointer;
+}
+
+/* ------------------------------------------------------------------------- */
 
 void
 _store_enum (GIEnumInfo * info, gint value, GIArgument * arg)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/Glib-Object-Introspection-0.042/gperl-i11n-marshal-struct.c 
new/Glib-Object-Introspection-0.046/gperl-i11n-marshal-struct.c
--- old/Glib-Object-Introspection-0.042/gperl-i11n-marshal-struct.c     
2015-04-24 02:10:35.000000000 +0200
+++ new/Glib-Object-Introspection-0.046/gperl-i11n-marshal-struct.c     
2018-09-26 06:44:28.000000000 +0200
@@ -81,6 +81,7 @@
 
            case GI_INFO_TYPE_UNION:
                ccroak ("%s: unions not handled yet", G_STRFUNC);
+               break;
 
            default:
                ccroak ("%s: unhandled info type %d", G_STRFUNC, info_type);
@@ -187,6 +188,7 @@
 
            case GI_INFO_TYPE_UNION:
                ccroak ("%s: unions not handled yet", G_STRFUNC);
+               break;
 
            default:
                ccroak ("%s: unhandled info type %d", G_STRFUNC, info_type);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/Glib-Object-Introspection-0.042/lib/Glib/Object/Introspection.pm 
new/Glib-Object-Introspection-0.046/lib/Glib/Object/Introspection.pm
--- old/Glib-Object-Introspection-0.042/lib/Glib/Object/Introspection.pm        
2016-12-23 23:26:08.000000000 +0100
+++ new/Glib-Object-Introspection-0.046/lib/Glib/Object/Introspection.pm        
2018-09-26 06:57:34.000000000 +0200
@@ -19,7 +19,7 @@
 use warnings;
 use Glib;
 
-our $VERSION = '0.042';
+our $VERSION = '0.046';
 
 use Carp;
 $Carp::Internal{(__PACKAGE__)}++;
@@ -527,6 +527,21 @@
   my $button = Gtk3::Button->new;
   Gtk3::WidgetClass::find_style_property ($button, 'image-spacing')
 
+=head2 Overriding virtual functions
+
+When subclassing a gtk+ class or when implementing a gtk+ interface with
+L<Glib::Object::Subclass>, you can override any virtual functions that the
+class has by simply defining sub routines with names obtained by capitalizing
+the original names of the virtual functions.  So, for example, if you implement
+a custom subclass of C<Gtk3::CellRenderer> and want to override its virtual
+function C<render>, you provide a sub routine with the name C<RENDER> in your
+package.
+
+  sub RENDER {
+    my ($cell, $cr, $widget, $background_area, $cell_area, $flags) = @_;
+    # do something
+  }
+
 =head1 DESCRIPTION FOR LIBRARY BINDING AUTHORS
 
 =head2 C<< Glib::Object::Introspection->setup >>
@@ -688,18 +703,23 @@
   $box->child_get_property ($label, 'expand', $gvalue);
   my $value = $gvalue->get_value
 
-=head2 Handling extendable enumerations
+=head2 Handling raw enumerations and flags
 
-If you need to handle extendable enumerations for which more than the
-pre-defined values might be valid, then use C<<
-Glib::Object::Introspection->convert_enum_to_sv >> and C<<
-Glib::Object::Introspection->convert_sv_to_enum >>.  They will raise an
+If you need to handle raw enumerations/flags or extendable enumerations for
+which more than the pre-defined values might be valid, then use C<<
+Glib::Object::Introspection->convert_enum_to_sv >>, C<<
+Glib::Object::Introspection->convert_sv_to_enum >>, C<<
+Glib::Object::Introspection->convert_flags_to_sv >> and C<<
+Glib::Object::Introspection->convert_sv_to_flags >>.  They will raise an
 exception on unknown values; catching it then allows you to implement fallback
 behavior.
 
   Glib::Object::Introspection->convert_enum_to_sv (package, enum_value)
   Glib::Object::Introspection->convert_sv_to_enum (package, sv)
 
+  Glib::Object::Introspection->convert_flags_to_sv (package, flags_value)
+  Glib::Object::Introspection->convert_sv_to_flags (package, sv)
+
 =head1 SEE ALSO
 
 =over
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Glib-Object-Introspection-0.042/t/arrays.t 
new/Glib-Object-Introspection-0.046/t/arrays.t
--- old/Glib-Object-Introspection-0.042/t/arrays.t      2015-08-10 
02:02:13.000000000 +0200
+++ new/Glib-Object-Introspection-0.046/t/arrays.t      2018-09-26 
06:44:28.000000000 +0200
@@ -6,7 +6,7 @@
 use warnings;
 use utf8;
 
-plan tests => 68;
+plan tests => 72;
 
 ok (Regress::test_strv_in ([ '1', '2', '3' ]));
 
@@ -163,3 +163,19 @@
   is_deeply (GI::bytearray_full_return (), $byte_array_ref);
   GI::bytearray_none_in ($byte_array_ref);
 }
+
+# -----------------------------------------------------------------------------
+
+SKIP: {
+  skip 'emit_sig_with_array_len_prop', 4
+    unless check_gi_version (1, 42, 92);
+  my $obj = Regress::TestObj->constructor ();
+  $obj->signal_connect ('sig-with-array-len-prop' => sub {
+    my ($self, $array, $len, $data) = @_;
+    is ($self, $obj);
+    is_deeply ($array, [0, 1, 2, 3, 4]);
+    is ($len, 5);
+    is ($data, 'user23');
+  }, 'user23');
+  $obj->emit_sig_with_array_len_prop ();
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Glib-Object-Introspection-0.042/t/inc/setup.pl 
new/Glib-Object-Introspection-0.046/t/inc/setup.pl
--- old/Glib-Object-Introspection-0.042/t/inc/setup.pl  2015-08-25 
22:44:26.000000000 +0200
+++ new/Glib-Object-Introspection-0.046/t/inc/setup.pl  2018-05-22 
04:51:32.000000000 +0200
@@ -34,7 +34,10 @@
   basename => 'Regress',
   version => '1.0',
   package => 'Regress',
-  search_path => 'build');
+  search_path => 'build',
+  use_generic_signal_marshaller_for => [
+    ['Regress::TestObj', 'sig-with-array-len-prop'],
+  ]);
 
 Glib::Object::Introspection->setup(
   basename => 'GIMarshallingTests',

++++++ cpanspec.yml ++++++
---
#description_paragraphs: 3
#description: |-
#  override description from CPAN
#summary: override summary from CPAN
#no_testing: broken upstream
#sources:
#  - source1
#  - source2
#patches:
#  foo.patch: -p1
#  bar.patch:
#preamble: |-
# BuildRequires:  gcc-c++
#post_prep: |-
# hunspell=`pkg-config --libs hunspell | sed -e 's,-l,,; s,  *,,g'`
# sed -i -e "s,hunspell-X,$hunspell," t/00-prereq.t Makefile.PL 
#post_build: |-
# rm unused.files
#post_install: |-
# sed on %{name}.files
#license: SUSE-NonFree
#skip_noarch: 1
#custom_build: |-
#./Build build flags=%{?_smp_mflags} --myflag
#custom_test: |-
#startserver && make test
#ignore_requires: Bizarre::Module

Reply via email to