mirror of
https://github.com/Ryujinx/GtkSharp.git
synced 2025-01-22 21:51:08 +00:00
* gtk/Widget.custom: Add a nice overload, rename it to
'RequestSize' instead of 'SizeRequest' to avoid a name clash. * api/gtk-api.xml: * sources/Gtk.metadata: out param for gtk_widget_get_size_request. svn path=/trunk/gtk-sharp/; revision=11046
This commit is contained in:
parent
87387bc38b
commit
4d694b215f
|
@ -9477,8 +9477,8 @@
|
|||
<method name="GetSizeRequest" cname="gtk_widget_get_size_request">
|
||||
<return-type type="void"/>
|
||||
<parameters>
|
||||
<parameter type="gint*" name="width"/>
|
||||
<parameter type="gint*" name="height"/>
|
||||
<parameter type="gint*" name="width" pass_as="out"/>
|
||||
<parameter type="gint*" name="height" pass_as="out"/>
|
||||
</parameters>
|
||||
</method>
|
||||
<method name="GetStyle" cname="gtk_widget_get_style" needs_ref="1">
|
||||
|
|
|
@ -29,4 +29,19 @@ public Gdk.Window GdkWindow {
|
|||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public System.Drawing.Size RequestSize {
|
||||
get {
|
||||
int x, y;
|
||||
GetSizeRequest (out x, out y);
|
||||
|
||||
return new System.Drawing.Size (x, y);
|
||||
}
|
||||
set {
|
||||
int x = value.Width;
|
||||
int y = value.Height;
|
||||
SetSizeRequest (x, y);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -40,17 +40,6 @@
|
|||
}
|
||||
}
|
||||
|
||||
public System.Drawing.Size SizeRequest {
|
||||
get {
|
||||
return new System.Drawing.Size (
|
||||
DefaultWidth, DefaultHeight);
|
||||
}
|
||||
set {
|
||||
DefaultWidth = value.Width;
|
||||
DefaultHeight = value.Height;
|
||||
}
|
||||
}
|
||||
|
||||
public System.Drawing.Size Position {
|
||||
get {
|
||||
int x, y;
|
||||
|
|
|
@ -1881,6 +1881,18 @@ z<rule>
|
|||
</attribute>
|
||||
</data>
|
||||
</rule>
|
||||
<rule>
|
||||
<class name="GtkWidget">
|
||||
<method>GetSizeRequest</method>
|
||||
</class>
|
||||
<data>
|
||||
<attribute target="param">
|
||||
<filter level="type">gint*</filter>
|
||||
<name>pass_as</name>
|
||||
<value>out</value>
|
||||
</attribute>
|
||||
</data>
|
||||
</rule>
|
||||
<rule>
|
||||
<class name="GtkMenuItem">
|
||||
<method>SetSubmenu</method>
|
||||
|
|
Loading…
Reference in a new issue