perl-Gtk2 r2084 - in trunk: . t xs
- From: tsch svn gnome org
- To: svn-commits-list gnome org
- Subject: perl-Gtk2 r2084 - in trunk: . t xs
- Date: Sat, 1 Nov 2008 16:27:14 +0000 (UTC)
Author: tsch
Date: Sat Nov 1 16:27:14 2008
New Revision: 2084
URL: http://svn.gnome.org/viewvc/perl-Gtk2?rev=2084&view=rev
Log:
Fix the stack handling in Gtk2::CellRenderer::get_size(). Patch by Kevin Ryde.
Modified:
trunk/ChangeLog
trunk/t/GtkCellRenderer.t
trunk/xs/GtkCellRenderer.xs
Modified: trunk/t/GtkCellRenderer.t
==============================================================================
--- trunk/t/GtkCellRenderer.t (original)
+++ trunk/t/GtkCellRenderer.t Sat Nov 1 16:27:14 2008
@@ -2,7 +2,7 @@
# $Id$
-use Gtk2::TestHelper tests => 9;
+use Gtk2::TestHelper tests => 13;
use strict;
package Mup::CellRendererPopup;
@@ -119,6 +119,10 @@
my $rect = Gtk2::Gdk::Rectangle->new (5, 5, 10, 10);
my @size = $renderer->get_size ($treeview, $rect);
is (@size, 4);
+like($size[0], qr/^\d+$/);
+like($size[1], qr/^\d+$/);
+like($size[2], qr/^\d+$/);
+like($size[3], qr/^\d+$/);
my $event = Gtk2::Gdk::Event->new ("button-press");
Modified: trunk/xs/GtkCellRenderer.xs
==============================================================================
--- trunk/xs/GtkCellRenderer.xs (original)
+++ trunk/xs/GtkCellRenderer.xs Sat Nov 1 16:27:14 2008
@@ -508,8 +508,10 @@
gint width;
gint height;
PPCODE:
+ PUTBACK;
gtk_cell_renderer_get_size(cell, widget, cell_area,
&x_offset, &y_offset, &width, &height);
+ SPAGAIN;
EXTEND(SP,4);
PUSHs(sv_2mortal(newSViv(x_offset)));
PUSHs(sv_2mortal(newSViv(y_offset)));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]