summaryrefslogtreecommitdiff
path: root/panels/info
diff options
context:
space:
mode:
authorThomas Wood <thomas.wood@intel.com>2012-11-13 14:08:41 +0000
committerThomas Wood <thomas.wood@intel.com>2012-11-13 14:12:09 +0000
commit6528b4d789fdf800c5e77c487d1f31440552a19b (patch)
tree457b64c9adc8373e92941cbb1f5869291fbda8e8 /panels/info
parent7dab589e9e4044ba9f250f90d044f661b99becb5 (diff)
downloadgnome-control-center-6528b4d789fdf800c5e77c487d1f31440552a19b.tar.gz
info: remove the use of the deprecated GtkTable class
GtkTable was deprecated in GTK+ 3.4. https://bugzilla.gnome.org/show_bug.cgi?id=688254
Diffstat (limited to 'panels/info')
-rw-r--r--panels/info/cc-info-panel.c15
-rw-r--r--panels/info/info.ui34
2 files changed, 13 insertions, 36 deletions
diff --git a/panels/info/cc-info-panel.c b/panels/info/cc-info-panel.c
index f50781b39..e5ff4d263 100644
--- a/panels/info/cc-info-panel.c
+++ b/panels/info/cc-info-panel.c
@@ -978,23 +978,20 @@ static void
info_panel_setup_default_app (CcInfoPanel *self,
DefaultAppData *data,
guint left_attach,
- guint right_attach,
- guint top_attach,
- guint bottom_attach)
+ guint top_attach)
{
GtkWidget *button;
- GtkWidget *table;
+ GtkWidget *grid;
GtkWidget *label;
- table = WID ("default_apps_table");
+ grid = WID ("default_apps_grid");
button = gtk_app_chooser_button_new (data->content_type);
g_object_set_data (G_OBJECT (button), "cc-default-app-data", data);
gtk_app_chooser_button_set_show_default_item (GTK_APP_CHOOSER_BUTTON (button), TRUE);
- gtk_table_attach (GTK_TABLE (table), button,
- left_attach, right_attach,
- top_attach, bottom_attach, GTK_FILL, 0, 0, 0);
+ gtk_grid_attach (GTK_GRID (grid), button, left_attach, top_attach,
+ 1, 1);
g_signal_connect (G_OBJECT (button), "changed",
G_CALLBACK (default_app_changed), self);
gtk_widget_show (button);
@@ -1024,7 +1021,7 @@ info_panel_setup_default_apps (CcInfoPanel *self)
for (i = 0; i < G_N_ELEMENTS(preferred_app_infos); i++)
{
info_panel_setup_default_app (self, &preferred_app_infos[i],
- 1, 2, i, i+1);
+ 1, i);
}
}
diff --git a/panels/info/info.ui b/panels/info/info.ui
index c97a87e92..844da4e5a 100644
--- a/panels/info/info.ui
+++ b/panels/info/info.ui
@@ -627,13 +627,9 @@
<property name="spacing">10</property>
<property name="orientation">vertical</property>
<child>
- <object class="GtkTable" id="default_apps_table">
+ <object class="GtkGrid" id="default_apps_grid">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="halign">start</property>
- <property name="valign">start</property>
- <property name="n_rows">6</property>
- <property name="n_columns">3</property>
<property name="column_spacing">12</property>
<property name="row_spacing">12</property>
<child>
@@ -661,7 +657,7 @@
</object>
<packing>
<property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
+ <property name="left_attach">0</property>
</packing>
</child>
<child>
@@ -677,7 +673,7 @@
</object>
<packing>
<property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
+ <property name="left_attach">0</property>
</packing>
</child>
<child>
@@ -693,7 +689,7 @@
</object>
<packing>
<property name="top_attach">3</property>
- <property name="bottom_attach">4</property>
+ <property name="left_attach">0</property>
</packing>
</child>
<child>
@@ -709,7 +705,7 @@
</object>
<packing>
<property name="top_attach">4</property>
- <property name="bottom_attach">5</property>
+ <property name="left_attach">0</property>
</packing>
</child>
<child>
@@ -720,8 +716,7 @@
</object>
<packing>
<property name="left_attach">2</property>
- <property name="right_attach">3</property>
- <property name="x_options">GTK_FILL</property>
+ <property name="top_attach">0</property>
</packing>
</child>
<child>
@@ -732,10 +727,7 @@
</object>
<packing>
<property name="left_attach">2</property>
- <property name="right_attach">3</property>
<property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="x_options">GTK_FILL</property>
</packing>
</child>
<child>
@@ -746,10 +738,7 @@
</object>
<packing>
<property name="left_attach">2</property>
- <property name="right_attach">3</property>
<property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
- <property name="x_options">GTK_FILL</property>
</packing>
</child>
<child>
@@ -760,10 +749,7 @@
</object>
<packing>
<property name="left_attach">2</property>
- <property name="right_attach">3</property>
<property name="top_attach">3</property>
- <property name="bottom_attach">4</property>
- <property name="x_options">GTK_FILL</property>
</packing>
</child>
<child>
@@ -774,10 +760,7 @@
</object>
<packing>
<property name="left_attach">2</property>
- <property name="right_attach">3</property>
<property name="top_attach">4</property>
- <property name="bottom_attach">5</property>
- <property name="x_options">GTK_FILL</property>
</packing>
</child>
<child>
@@ -793,7 +776,7 @@
</object>
<packing>
<property name="top_attach">5</property>
- <property name="bottom_attach">6</property>
+ <property name="left_attach">0</property>
</packing>
</child>
<child>
@@ -804,10 +787,7 @@
</object>
<packing>
<property name="left_attach">2</property>
- <property name="right_attach">3</property>
<property name="top_attach">5</property>
- <property name="bottom_attach">6</property>
- <property name="x_options">GTK_FILL</property>
</packing>
</child>
<child>