mirror of
https://gitlab.gnome.org/GNOME/calls.git
synced 2024-09-29 15:25:24 +00:00
sip-account-widget: compose with GtkBin instead of subclassing GtkBox
Part-of: <https://gitlab.gnome.org/GNOME/calls/-/merge_requests/714>
This commit is contained in:
parent
2141c1ffc2
commit
9fa0539ad6
3 changed files with 228 additions and 223 deletions
|
@ -51,7 +51,7 @@ static GParamSpec *props[PROP_LAST_PROP];
|
||||||
|
|
||||||
|
|
||||||
struct _CallsSipAccountWidget {
|
struct _CallsSipAccountWidget {
|
||||||
GtkBox parent;
|
GtkBin parent;
|
||||||
|
|
||||||
/* Header bar */
|
/* Header bar */
|
||||||
GtkWidget *header_add;
|
GtkWidget *header_add;
|
||||||
|
@ -87,7 +87,7 @@ struct _CallsSipAccountWidget {
|
||||||
gboolean port_self_change;
|
gboolean port_self_change;
|
||||||
};
|
};
|
||||||
|
|
||||||
G_DEFINE_TYPE (CallsSipAccountWidget, calls_sip_account_widget, GTK_TYPE_BOX)
|
G_DEFINE_TYPE (CallsSipAccountWidget, calls_sip_account_widget, GTK_TYPE_BIN)
|
||||||
|
|
||||||
|
|
||||||
static gboolean
|
static gboolean
|
||||||
|
|
|
@ -32,7 +32,7 @@ G_BEGIN_DECLS
|
||||||
|
|
||||||
#define CALLS_TYPE_SIP_ACCOUNT_WIDGET (calls_sip_account_widget_get_type ())
|
#define CALLS_TYPE_SIP_ACCOUNT_WIDGET (calls_sip_account_widget_get_type ())
|
||||||
|
|
||||||
G_DECLARE_FINAL_TYPE (CallsSipAccountWidget, calls_sip_account_widget, CALLS, SIP_ACCOUNT_WIDGET, GtkBox)
|
G_DECLARE_FINAL_TYPE (CallsSipAccountWidget, calls_sip_account_widget, CALLS, SIP_ACCOUNT_WIDGET, GtkBin)
|
||||||
|
|
||||||
CallsSipAccountWidget *calls_sip_account_widget_new (CallsSipProvider *provider);
|
CallsSipAccountWidget *calls_sip_account_widget_new (CallsSipProvider *provider);
|
||||||
void calls_sip_account_widget_set_origin (CallsSipAccountWidget *self,
|
void calls_sip_account_widget_set_origin (CallsSipAccountWidget *self,
|
||||||
|
|
|
@ -2,7 +2,10 @@
|
||||||
<interface>
|
<interface>
|
||||||
<requires lib="gtk+" version="3.24"/>
|
<requires lib="gtk+" version="3.24"/>
|
||||||
<requires lib="libhandy" version="1.0"/>
|
<requires lib="libhandy" version="1.0"/>
|
||||||
<template class="CallsSipAccountWidget" parent="GtkBox">
|
<template class="CallsSipAccountWidget" parent="GtkBin">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<child>
|
||||||
|
<object class="GtkBox">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="orientation">vertical</property>
|
<property name="orientation">vertical</property>
|
||||||
|
|
||||||
|
@ -225,7 +228,7 @@
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</template>
|
</object>
|
||||||
<object class="GtkSizeGroup">
|
<object class="GtkSizeGroup">
|
||||||
<widgets>
|
<widgets>
|
||||||
<widget name="host"/>
|
<widget name="host"/>
|
||||||
|
@ -235,5 +238,7 @@
|
||||||
<widget name="port"/>
|
<widget name="port"/>
|
||||||
</widgets>
|
</widgets>
|
||||||
</object>
|
</object>
|
||||||
|
</child>
|
||||||
|
</template>
|
||||||
</interface>
|
</interface>
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue