[gnome-control-center] online-accounts: Fix the use of GtkGrids for showing an account
- From: Debarshi Ray <debarshir src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-control-center] online-accounts: Fix the use of GtkGrids for showing an account
- Date: Fri, 23 Aug 2013 14:20:19 +0000 (UTC)
commit 15b4c7a1bbc17a7d0c9b8ee5fc3a526a24f8c2c2
Author: Debarshi Ray <debarshir gnome org>
Date: Fri Aug 23 16:12:58 2013 +0200
online-accounts: Fix the use of GtkGrids for showing an account
This has the nice side-effect that rows in the different grids can no
longer get misaligned.
https://bugzilla.gnome.org/show_bug.cgi?id=706645
panels/online-accounts/cc-online-accounts-panel.c | 27 +++++---------------
1 files changed, 7 insertions(+), 20 deletions(-)
---
diff --git a/panels/online-accounts/cc-online-accounts-panel.c
b/panels/online-accounts/cc-online-accounts-panel.c
index bcec4fc..2edacf8 100644
--- a/panels/online-accounts/cc-online-accounts-panel.c
+++ b/panels/online-accounts/cc-online-accounts-panel.c
@@ -446,8 +446,6 @@ show_page_account (CcGoaPanel *panel,
GtkWidget *box;
GtkWidget *button;
GtkWidget *grid;
- GtkWidget *left_grid;
- GtkWidget *right_grid;
GtkWidget *label;
GoaProvider *provider;
GoaAccount *account;
@@ -513,16 +511,11 @@ show_page_account (CcGoaPanel *panel,
gtk_box_pack_end (GTK_BOX (panel->accounts_vbox), grid, FALSE, TRUE, 0);
}
- left_grid = gtk_grid_new ();
- gtk_widget_set_halign (left_grid, GTK_ALIGN_END);
- gtk_widget_set_hexpand (left_grid, TRUE);
- gtk_orientable_set_orientation (GTK_ORIENTABLE (left_grid), GTK_ORIENTATION_VERTICAL);
- gtk_grid_set_row_spacing (GTK_GRID (left_grid), 0);
-
- right_grid = gtk_grid_new ();
- gtk_widget_set_hexpand (right_grid, TRUE);
- gtk_orientable_set_orientation (GTK_ORIENTABLE (right_grid), GTK_ORIENTATION_VERTICAL);
- gtk_grid_set_row_spacing (GTK_GRID (right_grid), 0);
+ grid = gtk_grid_new ();
+ gtk_widget_set_halign (grid, GTK_ALIGN_CENTER);
+ gtk_widget_set_hexpand (grid, TRUE);
+ gtk_grid_set_column_spacing (GTK_GRID (grid), 12);
+ gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
if (provider != NULL)
{
@@ -530,17 +523,11 @@ show_page_account (CcGoaPanel *panel,
panel->client,
object,
GTK_BOX (panel->accounts_vbox),
- GTK_GRID (left_grid),
- GTK_GRID (right_grid));
+ GTK_GRID (grid),
+ GTK_GRID (grid));
}
- grid = gtk_grid_new ();
- gtk_orientable_set_orientation (GTK_ORIENTABLE (grid), GTK_ORIENTATION_HORIZONTAL);
- gtk_grid_set_column_spacing (GTK_GRID (grid), 12);
- gtk_container_add (GTK_CONTAINER (grid), left_grid);
- gtk_container_add (GTK_CONTAINER (grid), right_grid);
gtk_box_pack_start (GTK_BOX (panel->accounts_vbox), grid, FALSE, TRUE, 0);
-
gtk_widget_show_all (panel->accounts_vbox);
g_clear_object (&provider);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]