Commit 6ee41771 authored by Colomban Wendling's avatar Colomban Wendling

OVCCGtk: port OVCCGtkConnectionDialog to GTK3

parent efeaeca8
...@@ -61,8 +61,8 @@ static void ovccgtk_connection_dialog_set_propery (GObject *object, ...@@ -61,8 +61,8 @@ static void ovccgtk_connection_dialog_set_propery (GObject *object,
guint prop_id, guint prop_id,
const GValue *value, const GValue *value,
GParamSpec *pspec); GParamSpec *pspec);
static gboolean ovccgtk_connection_dialog_delete_event (GtkWidget *widget, static gboolean ovccgtk_connection_dialog_delete_event (GtkWidget *widget,
GdkEvent *event); GdkEventAny *event);
static void ovccgtk_connection_dialog_constructed (GObject *object); static void ovccgtk_connection_dialog_constructed (GObject *object);
static void ovccgtk_connection_dialog_response (GtkDialog *dialog, static void ovccgtk_connection_dialog_response (GtkDialog *dialog,
gint response); gint response);
...@@ -145,7 +145,6 @@ ovccgtk_connection_dialog_class_init (OVCCGtkConnectionDialogClass *klass) ...@@ -145,7 +145,6 @@ ovccgtk_connection_dialog_class_init (OVCCGtkConnectionDialogClass *klass)
object_class->constructed = ovccgtk_connection_dialog_constructed; object_class->constructed = ovccgtk_connection_dialog_constructed;
widget_class->show_all = gtk_widget_show; widget_class->show_all = gtk_widget_show;
widget_class->hide_all = gtk_widget_hide;
widget_class->delete_event = ovccgtk_connection_dialog_delete_event; widget_class->delete_event = ovccgtk_connection_dialog_delete_event;
dialog_class->response = ovccgtk_connection_dialog_response; dialog_class->response = ovccgtk_connection_dialog_response;
...@@ -211,7 +210,7 @@ ovccgtk_connection_dialog_init (OVCCGtkConnectionDialog *self) ...@@ -211,7 +210,7 @@ ovccgtk_connection_dialog_init (OVCCGtkConnectionDialog *self)
content_area = gtk_dialog_get_content_area (GTK_DIALOG (self)); content_area = gtk_dialog_get_content_area (GTK_DIALOG (self));
vbox = gtk_vbox_new (FALSE, 12); vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 12);
gtk_container_set_border_width (GTK_CONTAINER (vbox), 6); gtk_container_set_border_width (GTK_CONTAINER (vbox), 6);
gtk_box_pack_start (GTK_BOX (content_area), vbox, TRUE, TRUE, 0); gtk_box_pack_start (GTK_BOX (content_area), vbox, TRUE, TRUE, 0);
...@@ -226,10 +225,10 @@ ovccgtk_connection_dialog_init (OVCCGtkConnectionDialog *self) ...@@ -226,10 +225,10 @@ ovccgtk_connection_dialog_init (OVCCGtkConnectionDialog *self)
/* server frame */ /* server frame */
frame = ovccgtk_frame_new (_("Server")); frame = ovccgtk_frame_new (_("Server"));
gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE, TRUE, 0); gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE, TRUE, 0);
box = gtk_hbox_new (FALSE, 6); box = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);
gtk_container_add (GTK_CONTAINER (frame), box); gtk_container_add (GTK_CONTAINER (frame), box);
box2 = gtk_hbox_new (FALSE, 6); box2 = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);
gtk_box_pack_start (GTK_BOX (box), box2, TRUE, TRUE, 0); gtk_box_pack_start (GTK_BOX (box), box2, TRUE, TRUE, 0);
label = gtk_label_new (_("Host:")); label = gtk_label_new (_("Host:"));
...@@ -241,7 +240,7 @@ ovccgtk_connection_dialog_init (OVCCGtkConnectionDialog *self) ...@@ -241,7 +240,7 @@ ovccgtk_connection_dialog_init (OVCCGtkConnectionDialog *self)
gtk_entry_set_activates_default (GTK_ENTRY (self->priv->host), TRUE); gtk_entry_set_activates_default (GTK_ENTRY (self->priv->host), TRUE);
gtk_box_pack_start (GTK_BOX (box2), self->priv->host, TRUE, TRUE, 0); gtk_box_pack_start (GTK_BOX (box2), self->priv->host, TRUE, TRUE, 0);
box2 = gtk_hbox_new (FALSE, 6); box2 = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);
gtk_box_pack_start (GTK_BOX (box), box2, FALSE, TRUE, 0); gtk_box_pack_start (GTK_BOX (box), box2, FALSE, TRUE, 0);
label = gtk_label_new (_("Port:")); label = gtk_label_new (_("Port:"));
...@@ -256,10 +255,10 @@ ovccgtk_connection_dialog_init (OVCCGtkConnectionDialog *self) ...@@ -256,10 +255,10 @@ ovccgtk_connection_dialog_init (OVCCGtkConnectionDialog *self)
/* user frame */ /* user frame */
frame = ovccgtk_frame_new (_("User")); frame = ovccgtk_frame_new (_("User"));
gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE, TRUE, 0); gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE, TRUE, 0);
box = gtk_vbox_new (FALSE, 6); box = gtk_box_new (GTK_ORIENTATION_VERTICAL, 6);
gtk_container_add (GTK_CONTAINER (frame), box); gtk_container_add (GTK_CONTAINER (frame), box);
box2 = gtk_hbox_new (FALSE, 6); box2 = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);
gtk_box_pack_start (GTK_BOX (box), box2, TRUE, TRUE, 0); gtk_box_pack_start (GTK_BOX (box), box2, TRUE, TRUE, 0);
label = gtk_label_new (_("Name:")); label = gtk_label_new (_("Name:"));
...@@ -270,7 +269,7 @@ ovccgtk_connection_dialog_init (OVCCGtkConnectionDialog *self) ...@@ -270,7 +269,7 @@ ovccgtk_connection_dialog_init (OVCCGtkConnectionDialog *self)
gtk_entry_set_activates_default (GTK_ENTRY (self->priv->username), TRUE); gtk_entry_set_activates_default (GTK_ENTRY (self->priv->username), TRUE);
gtk_box_pack_start (GTK_BOX (box2), self->priv->username, TRUE, TRUE, 0); gtk_box_pack_start (GTK_BOX (box2), self->priv->username, TRUE, TRUE, 0);
box2 = gtk_hbox_new (FALSE, 6); box2 = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);
gtk_box_pack_start (GTK_BOX (box), box2, TRUE, TRUE, 0); gtk_box_pack_start (GTK_BOX (box), box2, TRUE, TRUE, 0);
label = gtk_label_new (_("Password:")); label = gtk_label_new (_("Password:"));
...@@ -355,8 +354,8 @@ ovccgtk_connection_dialog_constructed (GObject *object) ...@@ -355,8 +354,8 @@ ovccgtk_connection_dialog_constructed (GObject *object)
} }
static gboolean static gboolean
ovccgtk_connection_dialog_delete_event (GtkWidget *widget, ovccgtk_connection_dialog_delete_event (GtkWidget *widget,
GdkEvent *event) GdkEventAny *event)
{ {
/* never destroy the dialog automatically, just emit let the response be /* never destroy the dialog automatically, just emit let the response be
* emitted and the user do what she wants with it */ * emitted and the user do what she wants with it */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment