]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
mx-1.0: Fix several regressions introduced by the switch to GIR
authorLuca Bruno <lucabru@src.gnome.org>
Tue, 6 Sep 2011 20:26:07 +0000 (22:26 +0200)
committerLuca Bruno <lucabru@src.gnome.org>
Wed, 7 Sep 2011 09:40:43 +0000 (11:40 +0200)
vapi/Makefile.am
vapi/metadata/Mx-1.0-custom.vala [new file with mode: 0644]
vapi/metadata/Mx-1.0.metadata
vapi/mx-1.0.vapi

index 34512dc13c36a309471949efbf4dc24718be833e..2dfa4c34be4fd46903e4b5f5634f13630296aaad 100644 (file)
@@ -455,7 +455,7 @@ loudmouth-1.0:
        $(GENVAPI) --library $(srcdir)/loudmouth-1.0 $(PACKAGESDIR)/loudmouth-1.0/loudmouth-1.0-custom.vala $(PACKAGESDIR)/loudmouth-1.0/loudmouth-1.0.gi
 
 mx-1.0:
-       $(GENVAPI) --library $(srcdir)/mx-1.0 --metadatadir $(METADATADIR) $(GIRDIR)/Mx-1.0.gir
+       $(GENVAPI) --library $(srcdir)/mx-1.0 --metadatadir $(METADATADIR) $(METADATADIR)/Mx-1.0-custom.vala $(GIRDIR)/Mx-1.0.gir
 
 pango:
        $(GENVAPI) --library $(srcdir)/pango $(PACKAGESDIR)/pango/pango-custom.vala $(PACKAGESDIR)/pango/pango.gi
diff --git a/vapi/metadata/Mx-1.0-custom.vala b/vapi/metadata/Mx-1.0-custom.vala
new file mode 100644 (file)
index 0000000..89032c7
--- /dev/null
@@ -0,0 +1,87 @@
+namespace Mx {
+       [CCode (cheader_filename = "mx/mx.h", type_id = "mx_box_layout_child_get_type ()")]
+       public class BoxLayoutChild : Clutter.ChildMeta {
+               [Deprecated (since = "vala-0.14", replacement = "BoxLayout.child_get_expand")]
+               public static bool get_expand (Mx.BoxLayout box_layout, Clutter.Actor child);
+               [Deprecated (since = "vala-0.14", replacement = "BoxLayout.child_get_x_align")]
+               public static Mx.Align get_x_align (Mx.BoxLayout box_layout, Clutter.Actor child);
+               [Deprecated (since = "vala-0.14", replacement = "BoxLayout.child_get_x_fill")]
+               public static bool get_x_fill (Mx.BoxLayout box_layout, Clutter.Actor child);
+               [Deprecated (since = "vala-0.14", replacement = "BoxLayout.child_get_y_align")]
+               public static Mx.Align get_y_align (Mx.BoxLayout box_layout, Clutter.Actor child);
+               [Deprecated (since = "vala-0.14", replacement = "BoxLayout.child_get_y_fill")]
+               public static bool get_y_fill (Mx.BoxLayout box_layout, Clutter.Actor child);
+               [Deprecated (since = "vala-0.14", replacement = "BoxLayout.child_set_expand")]
+               public static void set_expand (Mx.BoxLayout box_layout, Clutter.Actor child, bool expand);
+               [Deprecated (since = "vala-0.14", replacement = "BoxLayout.child_set_x_align")]
+               public static void set_x_align (Mx.BoxLayout box_layout, Clutter.Actor child, Mx.Align x_align);
+               [Deprecated (since = "vala-0.14", replacement = "BoxLayout.child_set_x_fill")]
+               public static void set_x_fill (Mx.BoxLayout box_layout, Clutter.Actor child, bool x_fill);
+               [Deprecated (since = "vala-0.14", replacement = "BoxLayout.child_set_y_align")]
+               public static void set_y_align (Mx.BoxLayout box_layout, Clutter.Actor child, Mx.Align y_align);
+               [Deprecated (since = "vala-0.14", replacement = "BoxLayout.child_set_y_fill")]
+               public static void set_y_fill (Mx.BoxLayout box_layout, Clutter.Actor child, bool y_fill);
+       }
+
+       [CCode (cheader_filename = "mx/mx.h", type_id = "mx_floating_widget_get_type ()")]
+       public abstract class FloatingWidget : Mx.Widget {
+               [NoWrapper]
+               public virtual void floating_paint (Clutter.Actor actor);
+               [NoWrapper]
+               public virtual void floating_pick (Clutter.Actor actor, Clutter.Color color);
+       }
+
+       [CCode (cheader_filename = "mx/mx.h", cprefix = "MX_STYLE_ERROR_INVALID_")]
+       public enum StyleError {
+               [Deprecated (since = "vala-0.14", replacement = "StyleError.INVALID_FILE")]
+               FILE
+       }
+
+       [CCode (cheader_filename = "mx/mx.h", type_id = "mx_table_child_get_type ()")]
+       public class TableChild : Clutter.ChildMeta {
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_get_column")]
+               public static int get_column (Mx.Table table, Clutter.Actor child);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_get_column_span")]
+               public static int get_column_span (Mx.Table table, Clutter.Actor child);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_get_row")]
+               public static int get_row (Mx.Table table, Clutter.Actor child);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_get_row_span")]
+               public static int get_row_span (Mx.Table table, Clutter.Actor child);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_get_x_align")]
+               public static Mx.Align get_x_align (Mx.Table table, Clutter.Actor child);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_get_x_expand")]
+               public static bool get_x_expand (Mx.Table table, Clutter.Actor child);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_get_x_fill")]
+               public static bool get_x_fill (Mx.Table table, Clutter.Actor child);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_get_y_align")]
+               public static Mx.Align get_y_align (Mx.Table table, Clutter.Actor child);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_get_y_expand")]
+               public static bool get_y_expand (Mx.Table table, Clutter.Actor child);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_get_y_fill")]
+               public static bool get_y_fill (Mx.Table table, Clutter.Actor child);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_set_column")]
+               public static void set_column (Mx.Table table, Clutter.Actor child, int col);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_set_column_span")]
+               public static void set_column_span (Mx.Table table, Clutter.Actor child, int span);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_set_row")]
+               public static void set_row (Mx.Table table, Clutter.Actor child, int row);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_set_row_span")]
+               public static void set_row_span (Mx.Table table, Clutter.Actor child, int span);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_set_x_align")]
+               public static void set_x_align (Mx.Table table, Clutter.Actor child, Mx.Align align);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_set_x_expand")]
+               public static void set_x_expand (Mx.Table table, Clutter.Actor child, bool expand);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_set_x_fill")]
+               public static void set_x_fill (Mx.Table table, Clutter.Actor child, bool fill);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_set_y_align")]
+               public static void set_y_align (Mx.Table table, Clutter.Actor child, Mx.Align align);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_set_y_expand")]
+               public static void set_y_expand (Mx.Table table, Clutter.Actor child, bool expand);
+               [Deprecated (since = "vala-0.14", replacement = "Table.child_set_y_fill")]
+               public static void set_y_fill (Mx.Table table, Clutter.Actor child, bool fill);
+       }
+
+
+       [Deprecated (since = "vala-0.14", replacement = "FontWeight.set_from_string")]
+       public static void font_weight_set_from_string (GLib.Value value, string str);
+}
index 9f7e4d949bd3fb49d10bcd0ca0a721617f826486..3ea193829994c53f0081f902d2da132a14340801 100644 (file)
@@ -1,5 +1,13 @@
-BoxLayout.add_actor name="add_child"
-Table.add_actor name="add_child"
+Application.new.argv unowned
+BoxLayout
+       .add_actor name="add_child"
+       .add_actor_with_properties skip=false
+Padding struct
+Style.* skip=false
+Stylable.get skip=false
+Table
+       .add_actor name="add_child"
+       .add_actor_with_properties skip=false
 
 // Fixed upstream in mx 1.3.1
 ButtonGroup
@@ -13,8 +21,8 @@ ItemFactory.create skip=false unowned=false
 Notebook.get_current_page skip=false
 Offscreen.buffer type="Cogl.Handle"
 Scrollable.get_adjustments
-        .hadjustment out nullable unowned=false
-        .vadjustment out nullable unowned=false
+        .hadjustment out nullable
+        .vadjustment out nullable
 TextureCache
         .get_meta_texture skip=false unowned=false
         .get_meta_cogl_texture skip=false unowned=false
index 72989de0c2cc6437940508920bb6acec47111273..d4f8a73cd317ba89396b639497b0b50f4cc737fe 100644 (file)
@@ -87,7 +87,7 @@ namespace Mx {
        [CCode (cheader_filename = "mx/mx.h", type_id = "mx_application_get_type ()")]
        public class Application : GLib.Object {
                [CCode (has_construct_function = false)]
-               public Application ([CCode (array_length_cname = "argc", array_length_pos = 0.5)] ref string[]? argv, string name, Mx.ApplicationFlags flags);
+               public Application ([CCode (array_length_cname = "argc", array_length_pos = 0.5)] ref unowned string[]? argv, string name, Mx.ApplicationFlags flags);
                public void add_action (Mx.Action action);
                public void add_window (owned Mx.Window window);
                public virtual unowned Mx.Window create_window ();
@@ -142,6 +142,7 @@ namespace Mx {
        public class BoxLayout : Mx.Widget, Atk.Implementor, Clutter.Animatable, Clutter.Container, Clutter.Scriptable, Mx.Focusable, Mx.Scrollable, Mx.Stylable {
                [CCode (has_construct_function = false, type = "ClutterActor*")]
                public BoxLayout ();
+               public void add_actor_with_properties (Clutter.Actor actor, int position, ...);
                [CCode (cname = "mx_box_layout_add_actor")]
                public void add_child (Clutter.Actor actor, int position);
                public bool child_get_expand (Clutter.Actor child);
@@ -171,6 +172,26 @@ namespace Mx {
        public class BoxLayoutChild : Clutter.ChildMeta {
                [CCode (has_construct_function = false)]
                protected BoxLayoutChild ();
+               [Deprecated (replacement = "BoxLayout.child_get_expand", since = "vala-0.14")]
+               public static bool get_expand (Mx.BoxLayout box_layout, Clutter.Actor child);
+               [Deprecated (replacement = "BoxLayout.child_get_x_align", since = "vala-0.14")]
+               public static Mx.Align get_x_align (Mx.BoxLayout box_layout, Clutter.Actor child);
+               [Deprecated (replacement = "BoxLayout.child_get_x_fill", since = "vala-0.14")]
+               public static bool get_x_fill (Mx.BoxLayout box_layout, Clutter.Actor child);
+               [Deprecated (replacement = "BoxLayout.child_get_y_align", since = "vala-0.14")]
+               public static Mx.Align get_y_align (Mx.BoxLayout box_layout, Clutter.Actor child);
+               [Deprecated (replacement = "BoxLayout.child_get_y_fill", since = "vala-0.14")]
+               public static bool get_y_fill (Mx.BoxLayout box_layout, Clutter.Actor child);
+               [Deprecated (replacement = "BoxLayout.child_set_expand", since = "vala-0.14")]
+               public static void set_expand (Mx.BoxLayout box_layout, Clutter.Actor child, bool expand);
+               [Deprecated (replacement = "BoxLayout.child_set_x_align", since = "vala-0.14")]
+               public static void set_x_align (Mx.BoxLayout box_layout, Clutter.Actor child, Mx.Align x_align);
+               [Deprecated (replacement = "BoxLayout.child_set_x_fill", since = "vala-0.14")]
+               public static void set_x_fill (Mx.BoxLayout box_layout, Clutter.Actor child, bool x_fill);
+               [Deprecated (replacement = "BoxLayout.child_set_y_align", since = "vala-0.14")]
+               public static void set_y_align (Mx.BoxLayout box_layout, Clutter.Actor child, Mx.Align y_align);
+               [Deprecated (replacement = "BoxLayout.child_set_y_fill", since = "vala-0.14")]
+               public static void set_y_fill (Mx.BoxLayout box_layout, Clutter.Actor child, bool y_fill);
                [NoAccessorMethod]
                public bool expand { get; set; }
                [NoAccessorMethod]
@@ -399,6 +420,10 @@ namespace Mx {
        public abstract class FloatingWidget : Mx.Widget, Atk.Implementor, Clutter.Animatable, Clutter.Scriptable, Mx.Stylable {
                [CCode (has_construct_function = false)]
                protected FloatingWidget ();
+               [NoWrapper]
+               public virtual void floating_paint (Clutter.Actor actor);
+               [NoWrapper]
+               public virtual void floating_pick (Clutter.Actor actor, Clutter.Color color);
        }
        [CCode (cheader_filename = "mx/mx.h", type_id = "mx_focus_manager_get_type ()")]
        public class FocusManager : GLib.Object {
@@ -650,14 +675,6 @@ namespace Mx {
                public bool pick_child { get; set; }
                public bool redirect_enabled { get; set; }
        }
-       [CCode (cheader_filename = "mx/mx.h", copy_function = "g_boxed_copy", free_function = "g_boxed_free", type_id = "mx_padding_get_type ()")]
-       [Compact]
-       public class Padding {
-               public float bottom;
-               public float left;
-               public float right;
-               public float top;
-       }
        [CCode (cheader_filename = "mx/mx.h", type_id = "mx_path_bar_get_type ()")]
        public class PathBar : Mx.Widget, Atk.Implementor, Clutter.Animatable, Clutter.Scriptable, Mx.Focusable, Mx.Stylable {
                [CCode (has_construct_function = false, type = "ClutterActor*")]
@@ -796,8 +813,10 @@ namespace Mx {
        public class Style : GLib.Object {
                [CCode (has_construct_function = false)]
                public Style ();
+               public void @get (Mx.Stylable stylable, ...);
                public static unowned Mx.Style get_default ();
                public GLib.Value get_property (Mx.Stylable stylable, GLib.ParamSpec pspec);
+               public void get_valist (Mx.Stylable stylable, string first_property_name, va_list va_args);
                public bool load_from_file (string filename) throws GLib.Error;
                public virtual signal void changed ();
        }
@@ -805,6 +824,7 @@ namespace Mx {
        public class Table : Mx.Widget, Atk.Implementor, Clutter.Animatable, Clutter.Container, Clutter.Scriptable, Mx.Focusable, Mx.Stylable {
                [CCode (has_construct_function = false, type = "ClutterActor*")]
                public Table ();
+               public void add_actor_with_properties (Clutter.Actor actor, int row, int column, ...);
                [CCode (cname = "mx_table_add_actor")]
                public void add_child (Clutter.Actor actor, int row, int column);
                public int child_get_column (Clutter.Actor child);
@@ -842,6 +862,46 @@ namespace Mx {
        public class TableChild : Clutter.ChildMeta {
                [CCode (has_construct_function = false)]
                protected TableChild ();
+               [Deprecated (replacement = "Table.child_get_column", since = "vala-0.14")]
+               public static int get_column (Mx.Table table, Clutter.Actor child);
+               [Deprecated (replacement = "Table.child_get_column_span", since = "vala-0.14")]
+               public static int get_column_span (Mx.Table table, Clutter.Actor child);
+               [Deprecated (replacement = "Table.child_get_row", since = "vala-0.14")]
+               public static int get_row (Mx.Table table, Clutter.Actor child);
+               [Deprecated (replacement = "Table.child_get_row_span", since = "vala-0.14")]
+               public static int get_row_span (Mx.Table table, Clutter.Actor child);
+               [Deprecated (replacement = "Table.child_get_x_align", since = "vala-0.14")]
+               public static Mx.Align get_x_align (Mx.Table table, Clutter.Actor child);
+               [Deprecated (replacement = "Table.child_get_x_expand", since = "vala-0.14")]
+               public static bool get_x_expand (Mx.Table table, Clutter.Actor child);
+               [Deprecated (replacement = "Table.child_get_x_fill", since = "vala-0.14")]
+               public static bool get_x_fill (Mx.Table table, Clutter.Actor child);
+               [Deprecated (replacement = "Table.child_get_y_align", since = "vala-0.14")]
+               public static Mx.Align get_y_align (Mx.Table table, Clutter.Actor child);
+               [Deprecated (replacement = "Table.child_get_y_expand", since = "vala-0.14")]
+               public static bool get_y_expand (Mx.Table table, Clutter.Actor child);
+               [Deprecated (replacement = "Table.child_get_y_fill", since = "vala-0.14")]
+               public static bool get_y_fill (Mx.Table table, Clutter.Actor child);
+               [Deprecated (replacement = "Table.child_set_column", since = "vala-0.14")]
+               public static void set_column (Mx.Table table, Clutter.Actor child, int col);
+               [Deprecated (replacement = "Table.child_set_column_span", since = "vala-0.14")]
+               public static void set_column_span (Mx.Table table, Clutter.Actor child, int span);
+               [Deprecated (replacement = "Table.child_set_row", since = "vala-0.14")]
+               public static void set_row (Mx.Table table, Clutter.Actor child, int row);
+               [Deprecated (replacement = "Table.child_set_row_span", since = "vala-0.14")]
+               public static void set_row_span (Mx.Table table, Clutter.Actor child, int span);
+               [Deprecated (replacement = "Table.child_set_x_align", since = "vala-0.14")]
+               public static void set_x_align (Mx.Table table, Clutter.Actor child, Mx.Align align);
+               [Deprecated (replacement = "Table.child_set_x_expand", since = "vala-0.14")]
+               public static void set_x_expand (Mx.Table table, Clutter.Actor child, bool expand);
+               [Deprecated (replacement = "Table.child_set_x_fill", since = "vala-0.14")]
+               public static void set_x_fill (Mx.Table table, Clutter.Actor child, bool fill);
+               [Deprecated (replacement = "Table.child_set_y_align", since = "vala-0.14")]
+               public static void set_y_align (Mx.Table table, Clutter.Actor child, Mx.Align align);
+               [Deprecated (replacement = "Table.child_set_y_expand", since = "vala-0.14")]
+               public static void set_y_expand (Mx.Table table, Clutter.Actor child, bool expand);
+               [Deprecated (replacement = "Table.child_set_y_fill", since = "vala-0.14")]
+               public static void set_y_fill (Mx.Table table, Clutter.Actor child, bool fill);
                [NoAccessorMethod]
                public int column { get; set; }
                [NoAccessorMethod]
@@ -1073,7 +1133,7 @@ namespace Mx {
        }
        [CCode (cheader_filename = "mx/mx.h", type_id = "mx_scrollable_get_type ()")]
        public interface Scrollable : GLib.Object {
-               public abstract void get_adjustments (out Mx.Adjustment? hadjustment, out Mx.Adjustment? vadjustment);
+               public abstract void get_adjustments (out unowned Mx.Adjustment? hadjustment, out unowned Mx.Adjustment? vadjustment);
                public abstract void set_adjustments (Mx.Adjustment hadjustment, Mx.Adjustment vadjustment);
                [NoAccessorMethod]
                public abstract Mx.Adjustment horizontal_adjustment { owned get; set; }
@@ -1085,6 +1145,7 @@ namespace Mx {
                public void apply_clutter_text_attributes (Clutter.Text text);
                public void connect_change_notifiers ();
                public unowned GLib.ParamSpec find_property (string property_name);
+               public void @get (...);
                public bool get_default_value (string property_name, out GLib.Value value_out);
                public GLib.Value get_property (string property_name);
                public abstract unowned Mx.Style get_style ();
@@ -1105,6 +1166,13 @@ namespace Mx {
                public virtual signal void style_changed (Mx.StyleChangedFlags flags);
        }
        [CCode (cheader_filename = "mx/mx.h")]
+       public struct Padding {
+               public float top;
+               public float right;
+               public float bottom;
+               public float left;
+       }
+       [CCode (cheader_filename = "mx/mx.h")]
        public struct SettingsProviderIface {
        }
        [CCode (cheader_filename = "mx/mx.h", cprefix = "MX_ACTOR_MANAGER_")]
@@ -1201,6 +1269,8 @@ namespace Mx {
        }
        [CCode (cheader_filename = "mx/mx.h", cprefix = "MX_STYLE_ERROR_INVALID_")]
        public enum StyleError {
+               [Deprecated (replacement = "StyleError.INVALID_FILE", since = "vala-0.14")]
+               FILE,
                [CCode (cname = "MX_STYLE_ERROR_INVALID_FILE")]
                INVALID_FILE
        }
@@ -1249,6 +1319,9 @@ namespace Mx {
        [CCode (cheader_filename = "mx/mx.h")]
        public static void allocate_align_fill (Clutter.Actor child, Clutter.ActorBox childbox, Mx.Align x_alignment, Mx.Align y_alignment, bool x_fill, bool y_fill);
        [CCode (cheader_filename = "mx/mx.h")]
+       [Deprecated (replacement = "FontWeight.set_from_string", since = "vala-0.14")]
+       public static void font_weight_set_from_string (GLib.Value value, string str);
+       [CCode (cheader_filename = "mx/mx.h")]
        public static void set_locale ();
        [CCode (cheader_filename = "mx/mx.h")]
        public static string utils_format_time (GLib.TimeVal time_);