From: Rico Tzschichholz Date: Thu, 21 Aug 2014 16:17:14 +0000 (+0200) Subject: gtk+-2.0, gtk+-3.0: more various fixes X-Git-Tag: 0.25.2~8 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b3629d8515fd13e84779125977d486d0d928930a;p=thirdparty%2Fvala.git gtk+-2.0, gtk+-3.0: more various fixes --- diff --git a/vapi/gtk+-2.0.vapi b/vapi/gtk+-2.0.vapi index 9725868be..6b3f83efb 100644 --- a/vapi/gtk+-2.0.vapi +++ b/vapi/gtk+-2.0.vapi @@ -1,6 +1,6 @@ /* gtk+-2.0.vapi generated by vapigen, do not modify. */ -[CCode (gir_namespace = "Gtk", gir_version = "2.0")] +[CCode (cprefix = "Gtk", gir_namespace = "Gtk", gir_version = "2.0", lower_case_cprefix = "gtk_")] [Deprecated (replacement = "gtk+-3.0")] namespace Gtk { namespace Idle { diff --git a/vapi/gtk+-3.0.vapi b/vapi/gtk+-3.0.vapi index 41714653f..47dad180c 100644 --- a/vapi/gtk+-3.0.vapi +++ b/vapi/gtk+-3.0.vapi @@ -1,6 +1,6 @@ /* gtk+-3.0.vapi generated by vapigen, do not modify. */ -[CCode (gir_namespace = "Gtk", gir_version = "3.0")] +[CCode (cprefix = "Gtk", gir_namespace = "Gtk", gir_version = "3.0", lower_case_cprefix = "gtk_")] namespace Gtk { [Deprecated (since = "3.10")] namespace Stock { @@ -283,7 +283,7 @@ namespace Gtk { public bool wrap_license { get; set; } public virtual signal bool activate_link (string uri); } - [CCode (cheader_filename = "gtk/gtk.h")] + [CCode (cheader_filename = "gtk/gtk.h", type_id = "gtk_accel_group_get_type ()")] public class AccelGroup : GLib.Object { [CCode (has_construct_function = false)] public AccelGroup (); @@ -1607,7 +1607,7 @@ namespace Gtk { [CCode (has_construct_function = false, type = "GtkWidget*")] public ComboBoxText.with_entry (); } - [CCode (cheader_filename = "gtk/gtk.h")] + [CCode (cheader_filename = "gtk/gtk.h", type_id = "gtk_container_get_type ()")] public abstract class Container : Gtk.Widget, Atk.Implementor, Gtk.Buildable { [CCode (has_construct_function = false)] protected Container (); @@ -3444,7 +3444,7 @@ namespace Gtk { public Gtk.Window parent { get; set; } public Gdk.Screen screen { get; set; } } - [CCode (cheader_filename = "gtk/gtk.h")] + [CCode (cheader_filename = "gtk/gtk.h", type_id = "gtk_notebook_get_type ()")] public class Notebook : Gtk.Container, Atk.Implementor, Gtk.Buildable { [CCode (has_construct_function = false, type = "GtkWidget*")] public Notebook (); @@ -4695,7 +4695,7 @@ namespace Gtk { public void set_stack (Gtk.Stack stack); public Gtk.Stack stack { get; set construct; } } - [CCode (cheader_filename = "gtk/gtk.h")] + [CCode (cheader_filename = "gtk/gtk.h", type_id = "gtk_status_icon_get_type ()")] public class StatusIcon : GLib.Object { [CCode (has_construct_function = false)] public StatusIcon (); @@ -4884,7 +4884,7 @@ namespace Gtk { public virtual signal void realize (); public virtual signal void unrealize (); } - [CCode (cheader_filename = "gtk/gtk.h")] + [CCode (cheader_filename = "gtk/gtk.h", type_id = "gtk_style_context_get_type ()")] public class StyleContext : GLib.Object { [CCode (has_construct_function = false)] public StyleContext (); @@ -4952,7 +4952,7 @@ namespace Gtk { [CCode (cname = "gtk_render_icon")] public void render_icon (Cairo.Context cr, Gdk.Pixbuf pixbuf, double x, double y); [CCode (cname = "gtk_render_icon_pixbuf")] - public unowned Gdk.Pixbuf render_icon_pixbuf (Gtk.IconSource source, Gtk.IconSize size); + public Gdk.Pixbuf render_icon_pixbuf (Gtk.IconSource source, Gtk.IconSize size); [CCode (cname = "gtk_render_layout")] public void render_layout (Cairo.Context cr, double x, double y, Pango.Layout layout); [CCode (cname = "gtk_render_line")] @@ -6166,7 +6166,7 @@ namespace Gtk { [HasEmitter] public virtual signal void clicked (); } - [CCode (cheader_filename = "gtk/gtk.h")] + [CCode (cheader_filename = "gtk/gtk.h", type_id = "gtk_ui_manager_get_type ()")] public class UIManager : GLib.Object, Gtk.Buildable { [CCode (has_construct_function = false)] public UIManager (); @@ -6256,7 +6256,7 @@ namespace Gtk { [NoAccessorMethod] public bool use_symbolic { get; set construct; } } - [CCode (cheader_filename = "gtk/gtk.h")] + [CCode (cheader_filename = "gtk/gtk.h", type_id = "gtk_widget_get_type ()")] public class Widget : GLib.InitiallyUnowned, Atk.Implementor, Gtk.Buildable { public class uint activate_signal; [CCode (construct_function = "gtk_widget_new", has_new_function = false)] @@ -6907,7 +6907,7 @@ namespace Gtk { public GLib.List list_windows (); public void remove_window (Gtk.Window window); } - [CCode (cheader_filename = "gtk/gtk.h")] + [CCode (cheader_filename = "gtk/gtk.h", type_cname = "GtkActionableInterface")] public interface Actionable : Gtk.Widget { public abstract unowned string get_action_name (); public abstract unowned GLib.Variant get_action_target_value (); @@ -6987,7 +6987,7 @@ namespace Gtk { public void set_attributes (Gtk.CellRenderer cell, ...); public abstract void set_cell_data_func (Gtk.CellRenderer cell, owned Gtk.CellLayoutDataFunc func); } - [CCode (cheader_filename = "gtk/gtk.h")] + [CCode (cheader_filename = "gtk/gtk.h", type_cname = "GtkColorChooserInterface")] public interface ColorChooser : GLib.Object { public abstract void add_palette (Gtk.Orientation orientation, int colors_per_line, [CCode (array_length_pos = 2.9)] Gdk.RGBA[]? colors); public abstract Gdk.RGBA get_rgba (); @@ -9592,7 +9592,7 @@ namespace Gtk { public static void render_icon (Gtk.StyleContext context, Cairo.Context cr, Gdk.Pixbuf pixbuf, double x, double y); [CCode (cheader_filename = "gtk/gtk.h")] [Deprecated (replacement = "StyleContext.render_icon_pixbuf", since = "vala-0.16")] - public static unowned Gdk.Pixbuf render_icon_pixbuf (Gtk.StyleContext context, Gtk.IconSource source, Gtk.IconSize size); + public static Gdk.Pixbuf render_icon_pixbuf (Gtk.StyleContext context, Gtk.IconSource source, Gtk.IconSize size); [CCode (cheader_filename = "gtk/gtk.h")] public static void render_icon_surface (Gtk.StyleContext context, Cairo.Context cr, Cairo.Surface surface, double x, double y); [CCode (cheader_filename = "gtk/gtk.h")] diff --git a/vapi/packages/gtk+-2.0/gtk+-2.0-custom.vala b/vapi/packages/gtk+-2.0/gtk+-2.0-custom.vala index 3064a7037..8a7f0b72e 100644 --- a/vapi/packages/gtk+-2.0/gtk+-2.0-custom.vala +++ b/vapi/packages/gtk+-2.0/gtk+-2.0-custom.vala @@ -284,14 +284,8 @@ namespace Gtk { public delegate void ActionCallback (Action action); - public delegate void MenuPositionFunc (Gtk.Menu menu, out int x, out int y, out bool push_in); - public delegate void RadioActionCallback (Action action, Action current); - public delegate bool TreeViewSearchEqualFunc (TreeModel model, int column, string key, TreeIter iter); - - public delegate string CalendarDetailFunc (Gtk.Calendar calendar, uint year, uint month, uint day); - [CCode (cheader_filename = "gtk/gtk.h")] public static unowned string set_locale (); diff --git a/vapi/packages/gtk+-2.0/gtk+-2.0.metadata b/vapi/packages/gtk+-2.0/gtk+-2.0.metadata index c10f8e628..e35ea77d0 100644 --- a/vapi/packages/gtk+-2.0/gtk+-2.0.metadata +++ b/vapi/packages/gtk+-2.0/gtk+-2.0.metadata @@ -1,4 +1,4 @@ -Gtk cheader_filename="gtk/gtk.h" gir_namespace="Gtk" gir_version="2.0" replacement="gtk+-3.0" +Gtk cheader_filename="gtk/gtk.h" gir_namespace="Gtk" gir_version="2.0" cprefix="Gtk" lower_case_cprefix="gtk_" replacement="gtk+-3.0" gtk_about_dialog_get_artists is_array="1" no_array_length="1" array_null_terminated="1" gtk_about_dialog_get_authors is_array="1" no_array_length="1" array_null_terminated="1" gtk_about_dialog_get_documenters is_array="1" no_array_length="1" array_null_terminated="1" @@ -115,7 +115,7 @@ gtk_calendar_get_date.day is_out="1" gtk_calendar_set_detail_func.func transfer_ownership="1" gtk_calendar_set_detail_func.data hidden="1" gtk_calendar_set_detail_func.destroy hidden="1" -GtkCalendarDetailFunc hidden="1" +GtkCalendarDetailFunc transfer_ownership="1" GtkCallbackMarshal hidden="1" GtkCell.u hidden="1" GtkCellEditable::editing_done has_emitter="1" @@ -417,7 +417,9 @@ gtk_menu_popup.data hidden="1" gtk_menu_popup.func nullable="1" gtk_menu_popup.parent_menu_shell nullable="1" gtk_menu_popup.parent_menu_item nullable="1" -GtkMenuPositionFunc hidden="1" +GtkMenuPositionFunc.x is_out="1" +GtkMenuPositionFunc.y is_out="1" +GtkMenuPositionFunc.push_in is_out="1" gtk_menu_item_deselect hidden="1" gtk_menu_item_select hidden="1" GtkMenuItem::activate has_emitter="1" @@ -1044,7 +1046,8 @@ gtk_tree_view_column_new_with_attributes ellipsis="1" gtk_tree_view_column_new_with_attributes.title nullable="1" gtk_tree_view_column_set_attributes ellipsis="1" gtk_tree_view_column_set_model.model nullable="1" -GtkTreeViewSearchEqualFunc hidden="1" +GtkTreeViewSearchEqualFunc has_target="1" +GtkTreeViewSearchEqualFunc.search_data hidden="1" gtk_true hidden="1" GtkUIManager:ui owned_get="1" gtk_ui_manager_add_ui.action nullable="1" diff --git a/vapi/packages/gtk+-3.0/gtk+-3.0-custom.vala b/vapi/packages/gtk+-3.0/gtk+-3.0-custom.vala index 58f385183..4ee9b2d6d 100644 --- a/vapi/packages/gtk+-3.0/gtk+-3.0-custom.vala +++ b/vapi/packages/gtk+-3.0/gtk+-3.0-custom.vala @@ -21,6 +21,7 @@ */ namespace Gtk { + [CCode (type_id = "gtk_accel_group_get_type ()")] public class AccelGroup { public Gtk.AccelKey* find (Gtk.AccelGroupFindFunc find_func); } @@ -42,25 +43,30 @@ namespace Gtk { public static unowned BindingSet @new (string name); } + [CCode (type_id = "gtk_container_get_type ()")] public abstract class Container { [CCode (vfunc_name = "forall")] [NoWrapper] public virtual void forall_internal(bool include_internal, Gtk.Callback callback); } + [CCode (type_id = "gtk_notebook_get_type ()")] public class Notebook { public int page_num (Widget child); } + [CCode (type_id = "gtk_status_icon_get_type ()")] public class StatusIcon { [CCode (instance_pos = -1)] public void position_menu (Gtk.Menu menu, out int x, out int y, out bool push_in); } + [CCode (type_id = "gtk_ui_manager_get_type ()")] public class UIManager { public uint new_merge_id (); } + [CCode (type_id = "gtk_widget_get_type ()")] public class Widget { [CCode (has_new_function = false, construct_function = "gtk_widget_new")] public extern Widget (GLib.Type type, ...); @@ -111,7 +117,7 @@ namespace Gtk { public virtual void copy_to (Gtk.Style dest); } - [CCode (cheader_filename = "gtk/gtk.h")] + [CCode (cheader_filename = "gtk/gtk.h", type_id = "gtk_style_context_get_type ()")] public class StyleContext { [CCode (cname = "gtk_render_activity")] public void render_activity (Cairo.Context cr, double x, double y, double width, double height); @@ -136,7 +142,7 @@ namespace Gtk { [CCode (cname = "gtk_render_icon")] public void render_icon (Cairo.Context cr, Gdk.Pixbuf pixbuf, double x, double y); [CCode (cname = "gtk_render_icon_pixbuf")] - public unowned Gdk.Pixbuf render_icon_pixbuf (Gtk.IconSource source, Gtk.IconSize size); + public Gdk.Pixbuf render_icon_pixbuf (Gtk.IconSource source, Gtk.IconSize size); [CCode (cname = "gtk_render_layout")] public void render_layout (Cairo.Context cr, double x, double y, Pango.Layout layout); [CCode (cname = "gtk_render_line")] @@ -149,14 +155,8 @@ namespace Gtk { public delegate void ActionCallback (Action action); - public delegate void MenuPositionFunc (Gtk.Menu menu, out int x, out int y, out bool push_in); - public delegate void RadioActionCallback (Action action, Action current); - public delegate bool TreeViewSearchEqualFunc (TreeModel model, int column, string key, TreeIter iter); - - public delegate string CalendarDetailFunc (Gtk.Calendar calendar, uint year, uint month, uint day); - [Deprecated (since = "vala-0.12", replacement = "Gtk.Stock.ABOUT")] public const string STOCK_ABOUT; [Deprecated (since = "vala-0.12", replacement = "Gtk.Stock.ADD")] diff --git a/vapi/packages/gtk+-3.0/gtk+-3.0.metadata b/vapi/packages/gtk+-3.0/gtk+-3.0.metadata index e55f590e9..8f8603b44 100644 --- a/vapi/packages/gtk+-3.0/gtk+-3.0.metadata +++ b/vapi/packages/gtk+-3.0/gtk+-3.0.metadata @@ -1,4 +1,4 @@ -Gtk cheader_filename="gtk/gtk.h" gir_namespace="Gtk" gir_version="3.0" +Gtk cheader_filename="gtk/gtk.h" gir_namespace="Gtk" gir_version="3.0" cprefix="Gtk" lower_case_cprefix="gtk_" gtk_about_dialog_add_credit_section.people is_array="1" no_array_length="1" array_null_terminated="1" gtk_about_dialog_get_artists is_array="1" no_array_length="1" array_null_terminated="1" gtk_about_dialog_get_authors is_array="1" no_array_length="1" array_null_terminated="1" @@ -59,6 +59,7 @@ gtk_action_group_set_translate_func.func transfer_ownership="1" gtk_action_group_set_translate_func.data hidden="1" gtk_action_group_set_translate_func.notify hidden="1" gtk_action_group_list_actions transfer_ownership="1" type_arguments="unowned Action" +GtkActionable type_cname="GtkActionableInterface" gtk_actionable_set_action_target ellipsis="1" GtkActivatable deprecated_since="3.10" GtkActivatable:related_action owned_get="1" @@ -149,7 +150,7 @@ gtk_calendar_get_date.day is_out="1" gtk_calendar_set_detail_func.func transfer_ownership="1" gtk_calendar_set_detail_func.data hidden="1" gtk_calendar_set_detail_func.destroy hidden="1" -GtkCalendarDetailFunc hidden="1" +GtkCalendarDetailFunc transfer_ownership="1" GtkCallbackMarshal hidden="1" GtkCell.u hidden="1" GtkCellArea::apply_attributes has_emitter="1" @@ -252,6 +253,7 @@ GtkColorButton:color deprecated_since="3.4" replacement="rgba" gtk_color_button_get_color.color is_out="1" gtk_color_button_get_rgba type_name="Gdk.RGBA" gtk_color_button_get_rgba.rgba hidden="1" +GtkColorChooser type_cname="GtkColorChooserInterface" gtk_color_chooser_get_rgba type_name="Gdk.RGBA" gtk_color_chooser_get_rgba.color hidden="1" gtk_color_chooser_dialog_new.* nullable="1" @@ -636,7 +638,9 @@ gtk_menu_popup.data hidden="1" gtk_menu_popup.func nullable="1" gtk_menu_popup.parent_menu_shell nullable="1" gtk_menu_popup.parent_menu_item nullable="1" -GtkMenuPositionFunc hidden="1" +GtkMenuPositionFunc.x is_out="1" +GtkMenuPositionFunc.y is_out="1" +GtkMenuPositionFunc.push_in is_out="1" gtk_menu_item_deselect hidden="1" gtk_menu_item_set_right_justified deprecated_since="3.2" replacement="Widget.set_hexpand and Widget.set_halign" gtk_menu_item_get_right_justified deprecated_since="3.2" replacement="Widget.get_hexpand and Widget.get_halign" @@ -1383,7 +1387,8 @@ gtk_tree_view_column_new_with_attributes ellipsis="1" gtk_tree_view_column_new_with_attributes.title nullable="1" gtk_tree_view_column_set_attributes ellipsis="1" gtk_tree_view_column_set_model.model nullable="1" -GtkTreeViewSearchEqualFunc hidden="1" +GtkTreeViewSearchEqualFunc has_target="1" +GtkTreeViewSearchEqualFunc.search_data hidden="1" gtk_true hidden="1" GtkUIManager:add-tearoffs deprecated_since="3.4" GtkUIManager:ui owned_get="1" @@ -1605,7 +1610,7 @@ gtk_render_frame deprecated_since="vala-0.16" replacement="StyleContext.render_f gtk_render_frame_gap deprecated_since="vala-0.16" replacement="StyleContext.render_frame_gap" gtk_render_handle deprecated_since="vala-0.16" replacement="StyleContext.render_handle" gtk_render_icon deprecated_since="vala-0.16" replacement="StyleContext.render_icon" -gtk_render_icon_pixbuf deprecated_since="vala-0.16" replacement="StyleContext.render_icon_pixbuf" +gtk_render_icon_pixbuf transfer_ownership="1" deprecated_since="vala-0.16" replacement="StyleContext.render_icon_pixbuf" gtk_render_layout deprecated_since="vala-0.16" replacement="StyleContext.render_layout" gtk_render_line deprecated_since="vala-0.16" replacement="StyleContext.render_line" gtk_render_option deprecated_since="vala-0.16" replacement="StyleContext.render_option" @@ -1874,6 +1879,7 @@ GtkVScrollbar type_id="gtk_vscrollbar_get_type ()" deprecated_since="3.2" replac GtkVSeparator type_id="gtk_vseparator_get_type ()" GtkViewport type_id="gtk_viewport_get_type ()" GtkVolumeButton type_id="gtk_volume_button_get_type ()" +GtkWidget type_id="gtk_widget_get_type ()" GtkWidgetAccessible type_id="gtk_widget_accessible_get_type ()" GtkWindow type_id="gtk_window_get_type ()" GtkWindowAccessible type_id="gtk_window_accessible_get_type ()"