[PATCH] Core changes needed for ext/libglade support

From: Date: Fri, 23 Sep 2005 10:50:37 +0000
Subject: [PATCH] Core changes needed for ext/libglade support
Groups: php.gtk.dev 
Request: Send a blank email to php-gtk-dev+get-1688@lists.php.net to get a copy of this message
Andrei, hi, If you can't/aren't prepared to bump the version requirement for ATK, let me know and I'll find an earlier libglade to work with. Please let me know fairly soon though, as some of the GladeXML functions have changed too. (I haven't started work on the overrides yet.) Question: how worried would you be if the gobject methods turned up in an extension class? Any clues as to what's happening here would be very welcome. C:\php5>php -r "print_r(get_class_methods('GladeXML'))"; Array ( [0] => __construct [1] => construct [2] => get_widget [3] => relative_file [4] => signal_autoconnect // so far so good, this part matches gen_libglade.c [5] => __tostring // enter chaos... [6] => connect [7] => connect_after [8] => connect_object [9] => connect_object_after [10] => get_property [11] => set_property [12] => get_data [13] => set_data [14] => block [15] => unblock [16] => disconnect [17] => is_connected [18] => signal_list_ids [19] => signal_list_names [20] => signal_query ) C:\php5>php -r "print_r(get_class_methods('Libglade'))"; Array ( [0] => get_widget_name // no problems here whatsoever [1] => get_widget_tree ) Could it be anything to do with gobject also having __construct() and construct() methods declared? - Steph

Index: ext/gtk+/atk.defs =================================================================== RCS file: /repository/php-gtk/ext/gtk+/atk.defs,v retrieving revision 1.1 diff -u -r1.1 atk.defs --- ext/gtk+/atk.defs 14 Aug 2004 21:10:26 -0000 1.1 +++ ext/gtk+/atk.defs 22 Sep 2005 19:25:51 -0000 @@ -801,7 +801,15 @@ ) ) - +(define-method add_relation_by_type + (of-object "AtkRelationSet") + (c-name "atk_relation_set_add_relation_by_type") + (return-type "none") + (parameters + '("AtkRelationType" "relationship") + '("AtkObject*" "target") + ) +) ;; From /usr/include/atk-1.0/atk/atkselection.h Index: ext/gtk+/config.m4 =================================================================== RCS file: /repository/php-gtk/ext/gtk+/config.m4,v retrieving revision 1.13 diff -u -r1.13 config.m4 --- ext/gtk+/config.m4 3 Sep 2005 00:40:16 -0000 1.13 +++ ext/gtk+/config.m4 23 Sep 2005 10:27:06 -0000 @@ -4,7 +4,7 @@ define(glib_required_version, 2.6.0) define(gtk_required_version, 2.6.0) define(pango_required_version, 1.8.0) -define(atk_required_version, 1.8.0) +define(atk_required_version, 1.9.0) dnl Check for glib AM_PATH_GLIB_2_0(glib_required_version,,[AC_MSG_ERROR(PHP-GTK 2.x requires GLib glib_required_version or higher)],gobject) Index: ext/gtk+/php_gtk+.h =================================================================== RCS file: /repository/php-gtk/ext/gtk+/php_gtk+.h,v retrieving revision 1.21 diff -u -r1.21 php_gtk+.h --- ext/gtk+/php_gtk+.h 16 May 2005 21:00:02 -0000 1.21 +++ ext/gtk+/php_gtk+.h 22 Sep 2005 17:32:22 -0000 @@ -49,6 +49,8 @@ void php_gtk_plus_register_types(); +#include "gen_gtk.h" + #if 0 PHP_GTK_API extern int le_gtk_object; PHP_GTK_API extern int le_php_gtk_wrapper;
« previous php.gtk.dev (#1688) next »