From: Juerg Billeter Date: Tue, 17 Jul 2007 13:25:22 +0000 (+0000) Subject: generate more ellipsis parameters regenerated to add ellipsis parameters X-Git-Tag: VALA_0_1_2~48 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7fe2912a6077cd1adf6720dcd58c6f1de424b989;p=thirdparty%2Fvala.git generate more ellipsis parameters regenerated to add ellipsis parameters 2007-07-17 Juerg Billeter * vapigen/valagidlparser.vala: generate more ellipsis parameters * vapi/gstreamer-0.10.vala, vapi/gtk+-2.0.vala, vapi/pango.vala: regenerated to add ellipsis parameters where appropriate svn path=/trunk/; revision=359 --- diff --git a/ChangeLog b/ChangeLog index 08e4f9551..cf8062cc8 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2007-07-17 Jürg Billeter + + * vapigen/valagidlparser.vala: generate more ellipsis parameters + * vapi/gstreamer-0.10.vala, vapi/gtk+-2.0.vala, vapi/pango.vala: + regenerated to add ellipsis parameters where appropriate + 2007-07-17 Jürg Billeter * vapigen/valagidlparser.vala, vapi/glib-2.0.vala, diff --git a/vapi/gstreamer-0.10.vala b/vapi/gstreamer-0.10.vala index 62771b5d3..81116b7e1 100644 --- a/vapi/gstreamer-0.10.vala +++ b/vapi/gstreamer-0.10.vala @@ -625,7 +625,7 @@ namespace Gst { public static void class_add_pad_template (pointer klass, Gst.PadTemplate templ); public static weak Gst.PadTemplate class_get_pad_template (pointer element_class, string name); public static weak GLib.List class_get_pad_template_list (pointer element_class); - public static void class_install_std_props (pointer klass, string first_name); + public static void class_install_std_props (pointer klass, ...); public static void class_set_details (pointer klass, Gst.ElementDetails details); public Gst.StateChangeReturn continue_state (Gst.StateChangeReturn ret); public void create_all_pads (); @@ -1165,7 +1165,7 @@ namespace Gst { [CCode (cheader_filename = "gst/gst.h")] public interface ChildProxy { public static void child_added (Gst.Object object, Gst.Object child); - public static void get (Gst.Object object, string first_property_name); + public static void get (Gst.Object object, ...); public virtual weak Gst.Object get_child_by_index (uint index); public weak Gst.Object get_child_by_name (string name); public virtual uint get_children_count (); @@ -1173,7 +1173,7 @@ namespace Gst { public static GLib.Type get_type (); public static void get_valist (Gst.Object object, string first_property_name, pointer var_args); public static bool lookup (Gst.Object object, string name, Gst.Object target, GLib.ParamSpec pspec); - public static void set (Gst.Object object, string first_property_name); + public static void set (Gst.Object object, ...); public static void set_property (Gst.Object object, string name, GLib.Value value); public static void set_valist (Gst.Object object, string first_property_name, pointer var_args); [HasEmitter] diff --git a/vapi/gtk+-2.0.vala b/vapi/gtk+-2.0.vala index c3d2bc465..04dfee009 100644 --- a/vapi/gtk+-2.0.vala +++ b/vapi/gtk+-2.0.vala @@ -1724,11 +1724,11 @@ namespace Gtk { } [CCode (cheader_filename = "gtk/gtk.h")] public class Container : Gtk.Widget, Gtk.Buildable { - public void add_with_properties (Gtk.Widget widget, string first_prop_name); - public void child_get (Gtk.Widget child, string first_prop_name); + public void add_with_properties (Gtk.Widget widget, ...); + public void child_get (Gtk.Widget child, ...); public void child_get_property (Gtk.Widget child, string property_name, GLib.Value value); public void child_get_valist (Gtk.Widget child, string first_property_name, pointer var_args); - public void child_set (Gtk.Widget child, string first_prop_name); + public void child_set (Gtk.Widget child, ...); public void child_set_property (Gtk.Widget child, string property_name, GLib.Value value); public void child_set_valist (Gtk.Widget child, string first_property_name, pointer var_args); public virtual GLib.Type child_type (); @@ -1796,14 +1796,14 @@ namespace Gtk { public weak Gtk.Widget action_area; public void add_action_widget (Gtk.Widget child, int response_id); public weak Gtk.Widget add_button (string button_text, int response_id); - public void add_buttons (string first_button_text); + public void add_buttons (...); public bool get_has_separator (); public int get_response_for_widget (Gtk.Widget widget); public static GLib.Type get_type (); public Dialog (); - public Dialog.with_buttons (string title, Gtk.Window parent, Gtk.DialogFlags @flags, string first_button_text); + public Dialog.with_buttons (string title, Gtk.Window parent, Gtk.DialogFlags @flags, ...); public int run (); - public void set_alternative_button_order (int first_response_id); + public void set_alternative_button_order (...); public void set_alternative_button_order_from_array (int n_params, int new_order); public void set_default_response (int response_id); public void set_has_separator (bool setting); @@ -1980,8 +1980,8 @@ namespace Gtk { [CCode (cheader_filename = "gtk/gtk.h")] public class FileChooserDialog : Gtk.Dialog, Gtk.FileChooser { public static GLib.Type get_type (); - public FileChooserDialog (string title, Gtk.Window parent, Gtk.FileChooserAction action, string first_button_text); - public FileChooserDialog.with_backend (string title, Gtk.Window parent, Gtk.FileChooserAction action, string backend, string first_button_text); + public FileChooserDialog (string title, Gtk.Window parent, Gtk.FileChooserAction action, ...); + public FileChooserDialog.with_backend (string title, Gtk.Window parent, Gtk.FileChooserAction action, string backend, ...); } [CCode (cheader_filename = "gtk/gtk.h")] public class FileChooserWidget : Gtk.VBox, Gtk.FileChooser { @@ -3302,8 +3302,8 @@ namespace Gtk { [CCode (cheader_filename = "gtk/gtk.h")] public class RecentChooserDialog : Gtk.Dialog, Gtk.RecentChooser { public static GLib.Type get_type (); - public RecentChooserDialog (string title, Gtk.Window parent, string first_button_text); - public RecentChooserDialog.for_manager (string title, Gtk.Window parent, Gtk.RecentManager manager, string first_button_text); + public RecentChooserDialog (string title, Gtk.Window parent, ...); + public RecentChooserDialog.for_manager (string title, Gtk.Window parent, Gtk.RecentManager manager, ...); } [CCode (cheader_filename = "gtk/gtk.h")] public class RecentChooserMenu : Gtk.Menu, Gtk.RecentChooser { @@ -3700,7 +3700,7 @@ namespace Gtk { public void copy_clipboard (Gtk.Clipboard clipboard); public weak Gtk.TextChildAnchor create_child_anchor (out Gtk.TextIter iter); public weak Gtk.TextMark create_mark (string mark_name, out Gtk.TextIter where, bool left_gravity); - public weak Gtk.TextTag create_tag (string tag_name, string first_property_name); + public weak Gtk.TextTag create_tag (string tag_name, ...); public void cut_clipboard (Gtk.Clipboard clipboard, bool default_editable); public void delete (out Gtk.TextIter start, out Gtk.TextIter end); public bool delete_interactive (out Gtk.TextIter start_iter, out Gtk.TextIter end_iter, bool default_editable); @@ -3742,8 +3742,8 @@ namespace Gtk { public bool insert_interactive_at_cursor (string text, int len, bool default_editable); public void insert_range (out Gtk.TextIter iter, out Gtk.TextIter start, out Gtk.TextIter end); public bool insert_range_interactive (out Gtk.TextIter iter, out Gtk.TextIter start, out Gtk.TextIter end, bool default_editable); - public void insert_with_tags (out Gtk.TextIter iter, string text, int len, Gtk.TextTag first_tag); - public void insert_with_tags_by_name (out Gtk.TextIter iter, string text, int len, string first_tag_name); + public void insert_with_tags (out Gtk.TextIter iter, string text, int len, ...); + public void insert_with_tags_by_name (out Gtk.TextIter iter, string text, int len, ...); public void move_mark (Gtk.TextMark mark, out Gtk.TextIter where); public void move_mark_by_name (string name, out Gtk.TextIter where); public TextBuffer (Gtk.TextTagTable table); @@ -4598,7 +4598,7 @@ namespace Gtk { public void modify_font (Pango.FontDescription font_desc); public void modify_style (Gtk.RcStyle style); public void modify_text (Gtk.StateType state, Gdk.Color color); - public Widget (GLib.Type type, string first_property_name); + public Widget (GLib.Type type, ...); public void path (uint path_length, string path, string path_reversed); public static void pop_colormap (); public static void pop_composite_child (); @@ -4643,7 +4643,7 @@ namespace Gtk { public void shape_combine_mask (Gdk.Bitmap shape_mask, int offset_x, int offset_y); public virtual void show_all (); public void show_now (); - public void style_get (string first_property_name); + public void style_get (...); public void style_get_property (string property_name, GLib.Value value); public void style_get_valist (string first_property_name, pointer var_args); public void thaw_child_notify (); @@ -5874,7 +5874,7 @@ namespace Gtk { public bool is_descendant (Gtk.TreePath ancestor); public TreePath (); public TreePath.first (); - public TreePath.from_indices (int first_index); + public TreePath.from_indices (...); public TreePath.from_string (string path); public void next (); public void prepend_index (int index_); @@ -6324,7 +6324,7 @@ namespace Gtk { public static void propagate_event (Gtk.Widget widget, Gdk.Event event); public static void rgb_to_hsv (double r, double g, double b, double h, double s, double v); public static weak string set_locale (); - public static void show_about_dialog (Gtk.Window parent, string first_property_name, ...); + public static void show_about_dialog (Gtk.Window parent, ...); public static void text_layout_draw (pointer layout, Gtk.Widget widget, Gdk.Drawable drawable, Gdk.GC cursor_gc, int x_offset, int y_offset, int x, int y, int width, int height, GLib.List widgets); } [CCode (cprefix = "Gtk", lower_case_cprefix = "gtk_", cheader_filename = "gtk/gtk.h")] diff --git a/vapi/pango.vala b/vapi/pango.vala index 3643406ce..3835fbf5e 100644 --- a/vapi/pango.vala +++ b/vapi/pango.vala @@ -722,7 +722,7 @@ namespace Pango { public void get_tabs (Pango.TabAlign alignments, int locations); public static GLib.Type get_type (); public TabArray (int initial_size, bool positions_in_pixels); - public TabArray.with_positions (int size, bool positions_in_pixels, Pango.TabAlign first_alignment, int first_position); + public TabArray.with_positions (int size, bool positions_in_pixels, Pango.TabAlign first_alignment, ...); public void resize (int new_size); public void set_tab (int tab_index, Pango.TabAlign alignment, int location); } diff --git a/vapigen/valagidlparser.vala b/vapigen/valagidlparser.vala index d2e5dab95..bb446dc82 100644 --- a/vapigen/valagidlparser.vala +++ b/vapigen/valagidlparser.vala @@ -784,8 +784,10 @@ public class Vala.GIdlParser : CodeVisitor { // no parameters => static method m.instance = false; } - - if (add_ellipsis) { + + if (last_param != null && last_param.name.has_prefix ("first_")) { + last_param.ellipsis = true; + } else if (add_ellipsis) { m.add_parameter (new FormalParameter.with_ellipsis ()); }