[gnome-software/wip/gtk4: 134/134] Rough gtk4 port
- From: Timm Bäder <baedert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software/wip/gtk4: 134/134] Rough gtk4 port
- Date: Fri, 21 Jul 2017 10:15:17 +0000 (UTC)
commit e5e8f20dce94c0ca9ff7d0b0deeeac810b9f0588
Author: Timm Bäder <mail baedert org>
Date: Wed Jun 14 12:17:24 2017 +0200
Rough gtk4 port
lib/gs-cmd.c | 3 +-
meson.build | 2 +-
src/gnome-software.ui | 71 +-------------------
src/gs-app-addon-row.ui | 18 -----
src/gs-app-folder-dialog.c | 9 +--
src/gs-app-folder-dialog.ui | 4 -
src/gs-app-row.ui | 76 +--------------------
src/gs-app-tile.ui | 1 -
src/gs-application.c | 2 +-
src/gs-auth-dialog.ui | 9 ---
src/gs-category-page.ui | 9 ---
src/gs-common.c | 13 ++--
src/gs-css.c | 2 +-
src/gs-details-page.c | 13 ++--
src/gs-details-page.ui | 128 ------------------------------------
src/gs-editor.c | 14 ++--
src/gs-editor.ui | 72 --------------------
src/gs-feature-tile.ui | 3 -
src/gs-first-run-dialog.ui | 10 ---
src/gs-fixed-size-bin.c | 148 ++++++++++++++----------------------------
src/gs-hiding-box.c | 133 ++++++++++++++-----------------------
src/gs-history-dialog.c | 8 +-
src/gs-history-dialog.ui | 3 -
src/gs-info-bar.ui | 3 -
src/gs-installed-page.c | 2 -
src/gs-installed-page.ui | 1 -
src/gs-loading-page.ui | 6 +--
src/gs-moderate-page.ui | 2 +-
src/gs-overview-page.ui | 39 +-----------
src/gs-page.c | 4 +-
src/gs-popular-tile.ui | 15 +----
src/gs-progress-button.c | 2 +-
src/gs-removal-dialog.c | 2 +-
src/gs-review-bar.c | 26 ++++++--
src/gs-review-dialog.ui | 29 --------
src/gs-review-histogram.ui | 24 ++++----
src/gs-review-row.ui | 14 ----
src/gs-screenshot-image.c | 19 ------
src/gs-screenshot-image.ui | 4 -
src/gs-sources-dialog-row.ui | 20 ------
src/gs-sources-dialog.c | 2 +-
src/gs-sources-dialog.ui | 30 ---------
src/gs-summary-tile.c | 42 ++++++++----
src/gs-summary-tile.ui | 3 +-
src/gs-update-dialog.c | 10 +--
src/gs-update-dialog.ui | 21 ------
src/gs-updates-page.c | 18 ++---
src/gs-updates-page.ui | 27 +-------
src/gs-upgrade-banner.ui | 20 ------
49 files changed, 221 insertions(+), 915 deletions(-)
---
diff --git a/lib/gs-cmd.c b/lib/gs-cmd.c
index 0f726fe..efa5f0d 100644
--- a/lib/gs-cmd.c
+++ b/lib/gs-cmd.c
@@ -362,12 +362,11 @@ main (int argc, char **argv)
bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
textdomain (GETTEXT_PACKAGE);
- gtk_init (&argc, &argv);
+ gtk_init ();
context = g_option_context_new (NULL);
g_option_context_set_summary (context, "GNOME Software Test Program");
g_option_context_add_main_entries (context, options, NULL);
- g_option_context_add_group (context, gtk_get_option_group (TRUE));
ret = g_option_context_parse (context, &argc, &argv, &error);
if (!ret) {
g_print ("Failed to parse options: %s\n", error->message);
diff --git a/meson.build b/meson.build
index c0afd77..bf789ba 100644
--- a/meson.build
+++ b/meson.build
@@ -93,7 +93,7 @@ appstream_glib = dependency('appstream-glib', version : '>= 0.7.0')
gdk_pixbuf = dependency('gdk-pixbuf-2.0', version : '>= 2.31.5')
gio_unix = dependency('gio-unix-2.0')
gmodule = dependency('gmodule-2.0')
-gtk = dependency('gtk+-3.0', version : '>= 3.20.0')
+gtk = dependency('gtk+-4.0', version : '>= 3.89.5')
json_glib = dependency('json-glib-1.0', version : '>= 1.1.1')
libm = cc.find_library('libm', required: false)
libsecret = dependency('libsecret-1')
diff --git a/src/gnome-software.ui b/src/gnome-software.ui
index c551ceb..9b85b7e 100644
--- a/src/gnome-software.ui
+++ b/src/gnome-software.ui
@@ -80,8 +80,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -107,10 +105,6 @@
<class name="text-button"/>
</style>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkLabel" id="button_installed_counter">
@@ -119,10 +113,6 @@
<class name="counter-label"/>
</style>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- </packing>
</child>
</object>
</child>
@@ -131,8 +121,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -158,10 +146,6 @@
<class name="text-button"/>
</style>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkLabel" id="button_updates_counter">
@@ -170,10 +154,6 @@
<class name="counter-label"/>
</style>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- </packing>
</child>
</object>
</child>
@@ -182,15 +162,11 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -204,8 +180,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -225,17 +199,15 @@
</object>
</child>
<child>
- <object class="GtkArrow" id="header_selection_arrow">
+ <object class="GtkImage" id="header_selection_arrow">
<property name="visible">True</property>
- <property name="arrow_type">down</property>
+ <property name="icon-name">pan-down-symbolic</property>
</object>
</child>
</object>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
@@ -269,8 +241,6 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -288,16 +258,9 @@
<property name="hexpand">True</property>
<property name="halign">center</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- <property name="position">1</property>
- </packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -335,10 +298,6 @@
<attribute name="weight" value="bold"/>
</attributes>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkButtonBox">
@@ -351,10 +310,6 @@
<property name="can_focus">True</property>
<property name="receives_default">True</property>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkButton" id="button_events_no_space">
@@ -362,10 +317,6 @@
<property name="can_focus">True</property>
<property name="receives_default">True</property>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkButton" id="button_events_network_settings">
@@ -373,10 +324,6 @@
<property name="can_focus">True</property>
<property name="receives_default">True</property>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkButton" id="button_events_restart_required">
@@ -384,10 +331,6 @@
<property name="can_focus">True</property>
<property name="receives_default">True</property>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkButton" id="button_events_more_info">
@@ -395,16 +338,8 @@
<property name="can_focus">True</property>
<property name="receives_default">True</property>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
<child>
<object class="GtkButton" id="button_events_dismiss">
@@ -509,8 +444,6 @@
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
diff --git a/src/gs-app-addon-row.ui b/src/gs-app-addon-row.ui
index 0eb451f..e88f7f2 100644
--- a/src/gs-app-addon-row.ui
+++ b/src/gs-app-addon-row.ui
@@ -16,10 +16,6 @@
<property name="visible">True</property>
<property name="valign">center</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
<child>
<object class="GtkBox" id="name_box">
@@ -35,10 +31,6 @@
<property name="xalign">0.0</property>
<property name="yalign">0.5</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
<child>
<object class="GtkLabel" id="description_label">
@@ -51,16 +43,8 @@
<class name="dim-label"/>
</style>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkLabel" id="label">
@@ -70,8 +54,6 @@
</object>
<packing>
<property name="pack_type">end</property>
- <property name="expand">False</property>
- <property name="fill">False</property>
</packing>
</child>
</object>
diff --git a/src/gs-app-folder-dialog.c b/src/gs-app-folder-dialog.c
index bef8dd0..416b2ca 100644
--- a/src/gs-app-folder-dialog.c
+++ b/src/gs-app-folder-dialog.c
@@ -177,9 +177,8 @@ create_row (GsAppFolderDialog *dialog, const gchar *folder)
NULL);
gtk_widget_set_valign (label, GTK_ALIGN_CENTER);
gtk_widget_set_halign (label, GTK_ALIGN_START);
- gtk_box_pack_start (GTK_BOX (box), label, TRUE, TRUE, 0);
+ gtk_box_pack_start (GTK_BOX (box), label);
image = gtk_image_new_from_icon_name ("object-select-symbolic", GTK_ICON_SIZE_MENU);
- gtk_widget_set_no_show_all (image, TRUE);
gtk_widget_set_valign (image, GTK_ALIGN_CENTER);
gtk_widget_set_halign (image, GTK_ALIGN_END);
gtk_widget_set_margin_start (image, 20);
@@ -189,7 +188,7 @@ create_row (GsAppFolderDialog *dialog, const gchar *folder)
row = gtk_list_box_row_new ();
gtk_container_add (GTK_CONTAINER (row), box);
- gtk_widget_show_all (row);
+ gtk_widget_show (row);
g_object_set_data (G_OBJECT (row), "image", image);
g_object_set_data_full (G_OBJECT (row), "folder", g_strdup (folder), g_free);
@@ -333,7 +332,7 @@ create_folder_name_popover (GsAppFolderDialog *dialog)
g_signal_connect (dialog->new_folder_entry, "notify::text", G_CALLBACK (update_sensitive), button);
g_signal_connect (dialog->new_folder_entry, "activate", G_CALLBACK (activate_entry), button);
- gtk_widget_show_all (grid);
+ gtk_widget_show (grid);
}
static void
@@ -353,7 +352,7 @@ add_new_folder_row (GsAppFolderDialog *dialog)
g_signal_connect (dialog->app_folder_list, "row-activated",
G_CALLBACK (row_activated), dialog);
- gtk_widget_show_all (row);
+ gtk_widget_show (row);
create_folder_name_popover (dialog);
}
diff --git a/src/gs-app-folder-dialog.ui b/src/gs-app-folder-dialog.ui
index b1b31cd..9608e40 100644
--- a/src/gs-app-folder-dialog.ui
+++ b/src/gs-app-folder-dialog.ui
@@ -28,7 +28,6 @@
</child>
<child internal-child="vbox">
<object class="GtkBox">
- <property name="border-width">0</property>
<child>
<object class="GtkScrolledWindow" id="scrolledwindow">
<property name="visible">True</property>
@@ -55,9 +54,6 @@
</object>
</child>
</object>
- <packing>
- <property name="expand">True</property>
- </packing>
</child>
</object>
</child>
diff --git a/src/gs-app-row.ui b/src/gs-app-row.ui
index 5807d28..47aef0f 100644
--- a/src/gs-app-row.ui
+++ b/src/gs-app-row.ui
@@ -17,10 +17,6 @@
<property name="margin-start">12</property>
<property name="valign">center</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
<child>
<object class="GtkImage" id="image">
@@ -29,10 +25,6 @@
<property name="margin_start">24</property>
<property name="valign">center</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
<child>
<object class="GtkBox" id="name_box">
@@ -56,10 +48,6 @@
<attribute name="weight" value="bold"/>
</attributes>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkLabel" id="version_label">
@@ -68,20 +56,12 @@
<property name="yalign">0.5</property>
<property name="ellipsize">end</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
<child>
<object class="GsStarWidget" id="star">
<property name="visible">False</property>
<property name="halign">start</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
<child>
<object class="GtkLabel" id="folder_label">
@@ -95,15 +75,8 @@
<class name="folder-label"/>
</style>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
</object>
- <packing>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkBox" id="box_description">
@@ -126,8 +99,6 @@
<property name="xalign">0</property>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -136,7 +107,7 @@
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="spacing">4</property>
- <property name="margin_left">24</property>
+ <property name="margin_start">24</property>
<property name="orientation">vertical</property>
<child>
<object class="GtkLabel" id="label_warning">
@@ -150,8 +121,6 @@
</attributes>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">3</property>
</packing>
</child>
@@ -172,19 +141,14 @@
<class name="dim-label"/>
</style>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkBox" id="label_installed">
<property name="orientation">horizontal</property>
- <property name="no_show_all">True</property>
<property name="halign">end</property>
<property name="valign">end</property>
<property name="spacing">6</property>
- <property name="margin-right">24</property>
+ <property name="margin-end">24</property>
<child>
<object class="GtkImage" id="installed-icon">
<property name="visible">True</property>
@@ -198,10 +162,6 @@
<class name="app-row-installed-icon"/>
</style>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
<child>
<object class="GtkLabel" id="installed-label">
@@ -211,35 +171,17 @@
<class name="app-row-installed-label"/>
</style>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkBox" id="vertical_box">
@@ -247,7 +189,7 @@
<property name="orientation">vertical</property>
<property name="halign">center</property>
<property name="valign">center</property>
- <property name="margin-right">6</property>
+ <property name="margin-end">6</property>
<child>
<object class="GtkBox" id="button_box">
<property name="visible">True</property>
@@ -257,13 +199,11 @@
<child>
<object class="GsProgressButton" id="button">
<property name="width_request">100</property>
- <property name="margin-right">6</property>
+ <property name="margin-end">6</property>
<property name="halign">end</property>
</object>
<packing>
<property name="pack_type">end</property>
- <property name="expand">False</property>
- <property name="fill">False</property>
</packing>
</child>
<child>
@@ -274,8 +214,6 @@
</object>
<packing>
<property name="pack_type">end</property>
- <property name="expand">False</property>
- <property name="fill">False</property>
</packing>
</child>
<child>
@@ -286,15 +224,11 @@
</object>
<packing>
<property name="pack_type">end</property>
- <property name="expand">False</property>
- <property name="fill">False</property>
</packing>
</child>
</object>
<packing>
<property name="pack_type">start</property>
- <property name="expand">False</property>
- <property name="fill">False</property>
</packing>
</child>
<child>
@@ -311,8 +245,6 @@
</object>
<packing>
<property name="pack_type">end</property>
- <property name="expand">True</property>
- <property name="fill">True</property>
</packing>
</child>
</object>
diff --git a/src/gs-app-tile.ui b/src/gs-app-tile.ui
index 3e41e70..9b431fd 100644
--- a/src/gs-app-tile.ui
+++ b/src/gs-app-tile.ui
@@ -36,7 +36,6 @@
<property name="valign">fill</property>
<child type="overlay">
<object class="GtkEventBox" id="eventbox">
- <property name="no_show_all">True</property>
<property name="visible_window">True</property>
<property name="halign">start</property>
<property name="valign">start</property>
diff --git a/src/gs-application.c b/src/gs-application.c
index 264443e..2d9f309 100644
--- a/src/gs-application.c
+++ b/src/gs-application.c
@@ -216,7 +216,7 @@ theme_changed (GtkSettings *settings, GParamSpec *pspec, GsApplication *app)
} else {
file = g_file_new_for_uri ("resource:///org/gnome/Software/gtk-style.css");
}
- gtk_css_provider_load_from_file (app->provider, file, NULL);
+ gtk_css_provider_load_from_file (app->provider, file);
}
static void
diff --git a/src/gs-auth-dialog.ui b/src/gs-auth-dialog.ui
index 7cee9f5..41a0577 100644
--- a/src/gs-auth-dialog.ui
+++ b/src/gs-auth-dialog.ui
@@ -23,8 +23,6 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
@@ -32,7 +30,6 @@
<object class="GtkGrid">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="border_width">21</property>
<property name="row_spacing">9</property>
<property name="column_spacing">21</property>
<child>
@@ -282,8 +279,6 @@
<property name="icon_size">5</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -298,8 +293,6 @@
</attributes>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -311,8 +304,6 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
diff --git a/src/gs-category-page.ui b/src/gs-category-page.ui
index 318a12e..b1f06cb 100644
--- a/src/gs-category-page.ui
+++ b/src/gs-category-page.ui
@@ -61,7 +61,6 @@
<child>
<object class="GtkInfoBar" id="infobar_category_shell_extensions">
<property name="visible">False</property>
- <property name="app_paintable">True</property>
<property name="can_focus">False</property>
<property name="hexpand">True</property>
<property name="message_type">other</property>
@@ -84,15 +83,11 @@
<property name="receives_default">True</property>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
@@ -110,15 +105,11 @@
<property name="label" translatable="yes">Extensions are used at
your own risk. If you have any system problems, it is recommended to disable them.</property>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
diff --git a/src/gs-common.c b/src/gs-common.c
index 995d7fa..df8b7ce 100644
--- a/src/gs-common.c
+++ b/src/gs-common.c
@@ -357,7 +357,7 @@ gs_utils_widget_set_css_internal (GtkWidget *widget,
gtk_style_context_add_provider_for_screen (gdk_screen_get_default (),
GTK_STYLE_PROVIDER (provider),
GTK_STYLE_PROVIDER_PRIORITY_APPLICATION);
- gtk_css_provider_load_from_data (provider, css, -1, NULL);
+ gtk_css_provider_load_from_data (provider, css, -1);
g_object_set_data_full (G_OBJECT (widget),
"GnomeSoftware::provider",
g_object_ref (provider),
@@ -388,8 +388,8 @@ gs_utils_widget_set_css (GtkWidget *widget, const gchar *css)
static void
do_not_expand (GtkWidget *child, gpointer data)
{
- gtk_container_child_set (GTK_CONTAINER (gtk_widget_get_parent (child)),
- child, "expand", FALSE, "fill", FALSE, NULL);
+ /* TODO: This is useless now. */
+ /*gtk_container_child_set (GTK_CONTAINER (gtk_widget_get_parent (child)), NULL);*/
}
static gboolean
@@ -433,8 +433,7 @@ insert_details_widget (GtkMessageDialog *dialog, const gchar *details)
g_assert (GTK_IS_BOX (message_area));
/* make the hbox expand */
box = gtk_widget_get_parent (message_area);
- gtk_container_child_set (GTK_CONTAINER (gtk_widget_get_parent (box)), box,
- "expand", TRUE, "fill", TRUE, NULL);
+ gtk_widget_set_hexpand (box, TRUE);
/* make the labels not expand */
gtk_container_foreach (GTK_CONTAINER (message_area), do_not_expand, NULL);
@@ -448,7 +447,7 @@ insert_details_widget (GtkMessageDialog *dialog, const gchar *details)
label = gtk_label_new (_("Details"));
gtk_widget_set_halign (label, GTK_ALIGN_START);
gtk_widget_set_visible (label, TRUE);
- gtk_box_pack_start (GTK_BOX (message_area), label, FALSE, FALSE, 0);
+ gtk_box_pack_start (GTK_BOX (message_area), label);
sw = gtk_scrolled_window_new (NULL, NULL);
gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (sw),
@@ -469,7 +468,7 @@ insert_details_widget (GtkMessageDialog *dialog, const gchar *details)
gtk_widget_set_visible (tv, TRUE);
gtk_container_add (GTK_CONTAINER (sw), tv);
- gtk_box_pack_end (GTK_BOX (message_area), sw, TRUE, TRUE, 0);
+ gtk_box_pack_end (GTK_BOX (message_area), sw);
g_signal_connect (dialog, "map-event", G_CALLBACK (unset_focus), NULL);
}
diff --git a/src/gs-css.c b/src/gs-css.c
index b4d2777..6821f1b 100644
--- a/src/gs-css.c
+++ b/src/gs-css.c
@@ -214,7 +214,7 @@ gs_css_validate_part (GsCss *self, const gchar *markup, GError **error)
gtk_style_context_add_provider_for_screen (gdk_screen_get_default (),
GTK_STYLE_PROVIDER (provider),
GTK_STYLE_PROVIDER_PRIORITY_APPLICATION);
- gtk_css_provider_load_from_data (provider, str->str, -1, NULL);
+ gtk_css_provider_load_from_data (provider, str->str, -1);
if (error_parse != NULL) {
if (error != NULL)
*error = g_error_copy (error_parse);
diff --git a/src/gs-details-page.c b/src/gs-details-page.c
index 8b882eb..de7a4d8 100644
--- a/src/gs-details-page.c
+++ b/src/gs-details-page.c
@@ -567,7 +567,7 @@ gs_details_page_refresh_screenshots (GsDetailsPage *self)
"max-width-chars", 10,
"wrap", TRUE,
NULL);
- gtk_box_pack_start (GTK_BOX (self->box_details_screenshot_main), label, FALSE, FALSE,
0);
+ gtk_box_pack_start (GTK_BOX (self->box_details_screenshot_main), label);
gtk_widget_set_visible (label, TRUE);
/* set images */
@@ -578,7 +578,7 @@ gs_details_page_refresh_screenshots (GsDetailsPage *self)
48);
gs_screenshot_image_set_use_desktop_background (GS_SCREENSHOT_IMAGE (ssimg), FALSE);
gs_screenshot_image_load_async (GS_SCREENSHOT_IMAGE (ssimg), NULL);
- gtk_box_pack_start (GTK_BOX (self->box_details_screenshot_main), ssimg, FALSE, FALSE,
0);
+ gtk_box_pack_start (GTK_BOX (self->box_details_screenshot_main), ssimg);
gtk_widget_set_visible (ssimg, TRUE);
}
return;
@@ -628,7 +628,7 @@ gs_details_page_refresh_screenshots (GsDetailsPage *self)
AS_IMAGE_NORMAL_HEIGHT);
}
gs_screenshot_image_load_async (GS_SCREENSHOT_IMAGE (ssimg), NULL);
- gtk_box_pack_start (GTK_BOX (self->box_details_screenshot_main), ssimg, FALSE, FALSE, 0);
+ gtk_box_pack_start (GTK_BOX (self->box_details_screenshot_main), ssimg);
gtk_widget_set_visible (ssimg, TRUE);
/* set all the thumbnails */
@@ -639,7 +639,7 @@ gs_details_page_refresh_screenshots (GsDetailsPage *self)
list = gtk_list_box_new ();
gtk_style_context_add_class (gtk_widget_get_style_context (list), "image-list");
gtk_widget_show (list);
- gtk_box_pack_start (GTK_BOX (self->box_details_screenshot_thumbnails), list, FALSE, FALSE, 0);
+ gtk_box_pack_start (GTK_BOX (self->box_details_screenshot_thumbnails), list);
for (i = 0; i < screenshots->len; i++) {
ss = g_ptr_array_index (screenshots, i);
ssimg = gs_screenshot_image_new (self->session);
@@ -702,7 +702,7 @@ gs_details_page_set_description (GsDetailsPage *self, const gchar *tmp)
gtk_style_context_add_class (style_context,
"application-details-description");
- gtk_box_pack_start (GTK_BOX (self->box_details_description), para, FALSE, FALSE, 0);
+ gtk_box_pack_start (GTK_BOX (self->box_details_description), para);
}
/* show the webapp warning */
@@ -714,8 +714,7 @@ gs_details_page_set_description (GsDetailsPage *self, const gchar *tmp)
gtk_label_set_xalign (GTK_LABEL (label), 0.f);
gtk_style_context_add_class (gtk_widget_get_style_context (label),
"application-details-webapp-warning");
- gtk_box_pack_start (GTK_BOX (self->box_details_description),
- label, FALSE, FALSE, 0);
+ gtk_box_pack_start (GTK_BOX (self->box_details_description),label);
}
}
diff --git a/src/gs-details-page.ui b/src/gs-details-page.ui
index cacd1a0..4c49c53 100644
--- a/src/gs-details-page.ui
+++ b/src/gs-details-page.ui
@@ -63,7 +63,6 @@
<property name="valign">start</property>
<property name="margin_top">4</property>
<property name="margin_bottom">4</property>
- <property name="border_width">24</property>
<property name="spacing">18</property>
<property name="hexpand">False</property>
<child>
@@ -80,8 +79,6 @@
<property name="pixel_size">96</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
@@ -111,8 +108,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -133,15 +128,11 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -157,8 +148,6 @@
<property name="valign">center</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
@@ -173,23 +162,17 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">2</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
@@ -214,8 +197,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
@@ -231,8 +212,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">1</property>
</packing>
</child>
@@ -247,8 +226,6 @@
<property name="valign">start</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">2</property>
</packing>
</child>
@@ -257,8 +234,6 @@
<property name="can_focus">False</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">3</property>
</packing>
</child>
@@ -278,8 +253,6 @@
</style>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -294,10 +267,6 @@
<property name="can_focus">False</property>
<property name="label">Downloading</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
<child>
<object class="GtkLabel" id="label_progress_percentage">
@@ -305,22 +274,14 @@
<property name="can_focus">False</property>
<property name="label">50%</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">4</property>
</packing>
</child>
@@ -333,8 +294,6 @@
<property name="receives_default">True</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">5</property>
</packing>
</child>
@@ -344,8 +303,6 @@
<property name="label" translatable="yes">Pending</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">6</property>
</packing>
</child>
@@ -358,8 +315,6 @@
<property name="label" translatable="yes" comments="Translators: A label for
a button to add a shortcut to the selected application.">_Add shortcut</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">7</property>
<property name="pack-type">end</property>
</packing>
@@ -373,16 +328,12 @@
<property name="label" translatable="yes" comments="Translators: A label for
a button to remove a shortcut to the selected application.">Re_move shortcut</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">8</property>
<property name="pack-type">end</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -404,8 +355,6 @@
</child>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -420,15 +369,11 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
@@ -454,10 +399,6 @@
<property name="icon_size">6</property>
<property name="valign">end</property>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkLabel">
@@ -467,15 +408,9 @@
<property name="valign">start</property>
<property name="label" translatable="yes">No screenshot provided</property>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">3</property>
</packing>
</child>
@@ -491,8 +426,6 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">4</property>
</packing>
</child>
@@ -505,8 +438,6 @@
<property name="body" translatable="yes">This application includes a software
source which provides updates, as well as access to other software.</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">6</property>
</packing>
</child>
@@ -519,8 +450,6 @@
<property name="body" translatable="yes">This application does not include a
software source. It will not be updated with new versions.</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">7</property>
</packing>
</child>
@@ -533,8 +462,6 @@
<property name="title" translatable="yes">This software is already provided by
your distribution and should not be replaced.</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">8</property>
</packing>
</child>
@@ -548,8 +475,6 @@
<property name="warning" translatable="yes">Only use software sources that you
trust.</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">9</property>
</packing>
</child>
@@ -569,15 +494,11 @@
<property name="use_underline">True</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">10</property>
</packing>
</child>
@@ -595,8 +516,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">11</property>
</packing>
</child>
@@ -753,8 +672,6 @@
</child>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -1079,8 +996,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
@@ -1096,8 +1011,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">1</property>
</packing>
</child>
@@ -1113,8 +1026,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">2</property>
</packing>
</child>
@@ -1126,15 +1037,11 @@
</child>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">12</property>
</packing>
</child>
@@ -1196,8 +1103,6 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">13</property>
</packing>
</child>
@@ -1261,8 +1166,6 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">14</property>
</packing>
</child>
@@ -1318,7 +1221,6 @@
</child>
</template>
<object class="GtkSizeGroup" id="sizegroup_install_remove">
- <property name="ignore_hidden">True</property>
<widgets>
<widget name="button_install"/>
<widget name="button_remove"/>
@@ -1331,7 +1233,6 @@
</widgets>
</object>
<object class="GtkSizeGroup" id="sizegroup_details_title">
- <property name="ignore_hidden">True</property>
<widgets>
<widget name="label_details_version_title"/>
<widget name="label_details_updated_title"/>
@@ -1344,7 +1245,6 @@
</widgets>
</object>
<object class="GtkSizeGroup" id="sizegroup_details_value">
- <property name="ignore_hidden">True</property>
<widgets>
<widget name="label_details_version_value"/>
<widget name="label_details_updated_value"/>
@@ -1364,7 +1264,6 @@
</object>
<object class="GtkPopover" id="popover_license_free">
<property name="can_focus">False</property>
- <property name="border_width">21</property>
<property name="relative_to">button_details_license_free</property>
<child>
<object class="GtkBox">
@@ -1383,8 +1282,6 @@
</attributes>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
@@ -1399,8 +1296,6 @@
<property name="xalign">0</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">1</property>
</packing>
</child>
@@ -1414,8 +1309,6 @@
<property name="xalign">0</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">2</property>
</packing>
</child>
@@ -1430,8 +1323,6 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">3</property>
</packing>
</child>
@@ -1440,7 +1331,6 @@
</object>
<object class="GtkPopover" id="popover_license_nonfree">
<property name="can_focus">False</property>
- <property name="border_width">21</property>
<property name="relative_to">button_details_license_nonfree</property>
<child>
<object class="GtkBox">
@@ -1459,8 +1349,6 @@
</attributes>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
@@ -1475,8 +1363,6 @@
<property name="xalign">0</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">1</property>
</packing>
</child>
@@ -1491,8 +1377,6 @@
<property name="xalign">0</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">2</property>
</packing>
</child>
@@ -1502,7 +1386,6 @@
<object class="GtkPopover" id="popover_license_unknown">
<property name="name">popover_license_unknown</property>
<property name="can_focus">False</property>
- <property name="border_width">21</property>
<property name="relative_to">button_details_license_unknown</property>
<child>
<object class="GtkBox">
@@ -1521,8 +1404,6 @@
</attributes>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
@@ -1537,8 +1418,6 @@
<property name="xalign">0</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">1</property>
</packing>
</child>
@@ -1552,7 +1431,6 @@
<object class="GtkBox" id="box_content_rating">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="border_width">24</property>
<property name="orientation">vertical</property>
<property name="spacing">12</property>
<child>
@@ -1563,8 +1441,6 @@
<property name="xalign">0</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -1576,8 +1452,6 @@
<property name="xalign">0</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -1588,8 +1462,6 @@
<property name="label" translatable="yes">No details were available for this rating.</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
diff --git a/src/gs-editor.c b/src/gs-editor.c
index bcc5f7c..fe3a688 100644
--- a/src/gs-editor.c
+++ b/src/gs-editor.c
@@ -778,7 +778,7 @@ gs_editor_checkbutton_editors_pick_cb (GtkToggleButton *widget, GsEditor *self)
if (gtk_toggle_button_get_active (widget)) {
as_app_add_kudo (self->selected_item, "GnomeSoftware::popular");
} else {
- as_app_remove_kudo (self->selected_item, "GnomeSoftware::popular");
+ /*as_app_remove_kudo (self->selected_item, "GnomeSoftware::popular");*/
}
self->pending_changes = TRUE;
gs_editor_refresh_details (self);
@@ -794,9 +794,9 @@ gs_editor_checkbutton_category_featured_cb (GtkToggleButton *widget, GsEditor *s
return;
if (gtk_toggle_button_get_active (widget)) {
- as_app_add_category (self->selected_item, "Featured");
+ /*as_app_add_category (self->selected_item, "Featured");*/
} else {
- as_app_remove_category (self->selected_item, "Featured");
+ /*as_app_remove_category (self->selected_item, "Featured");*/
}
self->pending_changes = TRUE;
gs_editor_refresh_details (self);
@@ -923,7 +923,7 @@ gs_editor_button_new_feature_clicked_cb (GtkApplication *application, GsEditor *
(guint) g_random_int_range (0x0000, 0xffff));
as_app_set_id (item, id);
as_app_add_metadata (item, "GnomeSoftware::FeatureTile-css", css);
- as_app_add_kudo (item, "GnomeSoftware::popular");
+ /*as_app_add_kudo (item, "GnomeSoftware::popular");*/
as_app_add_category (item, "Featured");
as_store_add_app (self->store, item);
g_set_object (&self->selected_item, item);
@@ -1003,8 +1003,8 @@ gs_editor_startup_cb (GtkApplication *application, GsEditor *self)
self->featured_tile1 = gs_feature_tile_new (NULL);
self->upgrade_banner = gs_upgrade_banner_new ();
widget = GTK_WIDGET (gtk_builder_get_object (self->builder, "box_featured"));
- gtk_box_pack_start (GTK_BOX (widget), self->featured_tile1, FALSE, FALSE, 0);
- gtk_box_pack_start (GTK_BOX (widget), self->upgrade_banner, FALSE, FALSE, 0);
+ gtk_box_pack_start (GTK_BOX (widget), self->featured_tile1);
+ gtk_box_pack_start (GTK_BOX (widget), self->upgrade_banner);
widget = GTK_WIDGET (gtk_builder_get_object (self->builder, "textview_css"));
buffer = gtk_text_view_get_buffer (GTK_TEXT_VIEW (widget));
@@ -1161,7 +1161,7 @@ main (int argc, char *argv[])
bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
textdomain (GETTEXT_PACKAGE);
- gtk_init (&argc, &argv);
+ gtk_init ();
self = g_new0 (GsEditor, 1);
self->cancellable = g_cancellable_new ();
diff --git a/src/gs-editor.ui b/src/gs-editor.ui
index efcd738..347f94d 100644
--- a/src/gs-editor.ui
+++ b/src/gs-editor.ui
@@ -51,8 +51,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -66,8 +64,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -81,7 +77,6 @@
<object class="GtkScrolledWindow">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="border_width">24</property>
<property name="hscrollbar_policy">never</property>
<child>
<object class="GtkViewport">
@@ -127,7 +122,6 @@
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="vexpand">True</property>
- <property name="border_width">12</property>
<property name="orientation">vertical</property>
<property name="spacing">12</property>
<child>
@@ -145,8 +139,6 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="pack_type">end</property>
<property name="position">0</property>
</packing>
@@ -164,15 +156,11 @@
<property name="label" translatable="yes">Error message here</property>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -181,8 +169,6 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="pack_type">end</property>
<property name="position">0</property>
</packing>
@@ -206,16 +192,12 @@
</child>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="pack_type">end</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -224,8 +206,6 @@
</style>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -233,7 +213,6 @@
<object class="GtkBox">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="border_width">12</property>
<property name="orientation">vertical</property>
<property name="spacing">12</property>
<child>
@@ -257,8 +236,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -270,15 +247,11 @@
<property name="completion">entrycompletion_ids</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -303,8 +276,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -315,15 +286,11 @@
<property name="width_chars">25</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -348,8 +315,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -360,15 +325,11 @@
<property name="width_chars">25</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
@@ -388,8 +349,6 @@
<property name="draw_indicator">True</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -403,22 +362,16 @@
<property name="draw_indicator">True</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">3</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -458,8 +411,6 @@
<property name="max_width_chars">60</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -475,15 +426,11 @@
<property name="receives_default">True</property>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">1</property>
</packing>
</child>
@@ -505,8 +452,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
@@ -600,7 +545,6 @@
</object>
<object class="GtkPopover" id="popover_menu">
<property name="can_focus">False</property>
- <property name="border_width">6</property>
<property name="relative_to">button_menu</property>
<child>
<object class="GtkBox">
@@ -613,12 +557,9 @@
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
- <property name="border_width">6</property>
<property name="text" translatable="yes">Import from file</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -627,12 +568,9 @@
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
- <property name="border_width">6</property>
<property name="text" translatable="yes">Export to file</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -641,12 +579,9 @@
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
- <property name="border_width">6</property>
<property name="text" translatable="yes">Delete Design</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
@@ -655,7 +590,6 @@
</object>
<object class="GtkPopover" id="popover_new">
<property name="can_focus">False</property>
- <property name="border_width">6</property>
<property name="relative_to">button_new</property>
<child>
<object class="GtkBox">
@@ -668,12 +602,9 @@
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
- <property name="border_width">6</property>
<property name="text" translatable="yes">Featured App</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -682,12 +613,9 @@
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
- <property name="border_width">6</property>
<property name="text" translatable="yes">OS Upgrade</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
diff --git a/src/gs-feature-tile.ui b/src/gs-feature-tile.ui
index 1e41475..18c1285 100644
--- a/src/gs-feature-tile.ui
+++ b/src/gs-feature-tile.ui
@@ -49,9 +49,6 @@
<attribute name="weight" value="700"/>
</attributes>
</object>
- <packing>
- <property name="expand">True</property>
- </packing>
</child>
<child>
<object class="GtkLabel" id="subtitle">
diff --git a/src/gs-first-run-dialog.ui b/src/gs-first-run-dialog.ui
index 8e81c6c..5664c35 100644
--- a/src/gs-first-run-dialog.ui
+++ b/src/gs-first-run-dialog.ui
@@ -38,8 +38,6 @@
<property name="icon_name">org.gnome.Software</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -54,8 +52,6 @@
</attributes>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -68,15 +64,11 @@
<property name="max_width_chars">48</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -96,8 +88,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
diff --git a/src/gs-fixed-size-bin.c b/src/gs-fixed-size-bin.c
index 6cd3919..85dac60 100644
--- a/src/gs-fixed-size-bin.c
+++ b/src/gs-fixed-size-bin.c
@@ -40,125 +40,76 @@ enum {
};
static void
-gs_fixed_size_bin_size_allocate (GtkWidget *widget, GtkAllocation *allocation)
+gs_fixed_size_bin_size_allocate (GtkWidget *widget,
+ const GtkAllocation *allocation,
+ int baseline,
+ GtkAllocation *out_clip)
{
GsFixedSizeBin *bin = GS_FIXED_SIZE_BIN (widget);
+ /*
+ * TODO: I'm not exactly sure what this widget does.
+ */
+
+
+
if (bin->preferred_width >= 0 &&
bin->preferred_width >= bin->min_width &&
allocation->width > bin->preferred_width) {
/* Center the contents */
- allocation->x += (allocation->width - bin->preferred_width) / 2;
- allocation->width = bin->preferred_width;
+ /*allocation->x += (allocation->width - bin->preferred_width) / 2;*/
+ /*allocation->width = bin->preferred_width;*/
}
if (bin->preferred_height >= 0 &&
bin->preferred_height >= bin->min_height &&
allocation->height > bin->preferred_height) {
/* Align to the top */
- allocation->height = bin->preferred_height;
- }
-
- GTK_WIDGET_CLASS (gs_fixed_size_bin_parent_class)->size_allocate (widget, allocation);
-}
-
-static void
-gs_fixed_size_bin_get_preferred_width (GtkWidget *widget,
- gint *min, gint *nat)
-{
- GsFixedSizeBin *bin = GS_FIXED_SIZE_BIN (widget);
- gint m, n;
-
- GTK_WIDGET_CLASS (gs_fixed_size_bin_parent_class)->get_preferred_width (widget, &m, &n);
-
- bin->min_width = m;
- if (bin->preferred_width >= 0 && n > bin->preferred_width)
- n = MAX (m, bin->preferred_width);
- if (min)
- *min = m;
- if (nat)
- *nat = n;
-}
-
-static void
-gs_fixed_size_bin_get_preferred_height (GtkWidget *widget,
- gint *min, gint *nat)
-{
- GsFixedSizeBin *bin = GS_FIXED_SIZE_BIN (widget);
- gint m, n;
-
- GTK_WIDGET_CLASS (gs_fixed_size_bin_parent_class)->get_preferred_height (widget, &m, &n);
-
- bin->min_height = m;
- if (bin->preferred_height >= 0 && n > bin->preferred_height)
- n = MAX (m, bin->preferred_height);
- if (min)
- *min = m;
- if (nat)
- *nat = n;
-}
-
-static void
-gs_fixed_size_bin_get_preferred_width_for_height (GtkWidget *widget,
- gint for_height,
- gint *min, gint *nat)
-{
- GsFixedSizeBin *bin = GS_FIXED_SIZE_BIN (widget);
- gint m, n;
-
- if (gtk_widget_get_request_mode (widget) == GTK_SIZE_REQUEST_HEIGHT_FOR_WIDTH) {
- GTK_WIDGET_GET_CLASS (widget)->get_preferred_width (widget,
- min, nat);
- return;
- }
-
- if (bin->preferred_height >= 0 &&
- for_height > bin->preferred_height) {
- /* The height will be limited */
- for_height = MAX (bin->min_height, bin->preferred_height);
+ /*allocation->height = bin->preferred_height;*/
}
- GTK_WIDGET_CLASS (gs_fixed_size_bin_parent_class)->get_preferred_width_for_height (
- widget, for_height, &m, &n);
-
- bin->min_width = m;
- if (bin->preferred_width >= 0 && n > bin->preferred_width)
- n = MAX (m, bin->preferred_width);
- if (min)
- *min = m;
- if (nat)
- *nat = n;
+ GTK_WIDGET_CLASS (gs_fixed_size_bin_parent_class)->size_allocate (widget, allocation, baseline,
out_clip);
}
static void
-gs_fixed_size_bin_get_preferred_height_for_width (GtkWidget *widget,
- gint for_width,
- gint *min, gint *nat)
+gs_fixed_size_bin_measure (GtkWidget *widget,
+ GtkOrientation orientation,
+ int for_size,
+ int *minimum,
+ int *natural,
+ int *minimum_baseline,
+ int *natural_baseline)
{
GsFixedSizeBin *bin = GS_FIXED_SIZE_BIN (widget);
- gint m, n;
-
- if (gtk_widget_get_request_mode (widget) == GTK_SIZE_REQUEST_WIDTH_FOR_HEIGHT) {
- GTK_WIDGET_GET_CLASS (widget)->get_preferred_height (widget,
- min, nat);
- return;
+ int m, n;
+
+ if (orientation == GTK_ORIENTATION_HORIZONTAL &&
+ bin->preferred_height >= 0 &&
+ for_size > bin->preferred_height) {
+ for_size = MAX (bin->min_height, bin->preferred_height);
+ } else if (orientation == GTK_ORIENTATION_VERTICAL &&
+ bin->preferred_width >= 0 &&
+ for_size > bin->preferred_width) {
+ for_size = MAX (bin->min_width, bin->preferred_width);
}
- if (bin->preferred_width >= 0 &&
- for_width > bin->preferred_width) {
- /* The width will be limited */
- for_width = MAX (bin->min_width, bin->preferred_width);
+ GTK_WIDGET_CLASS (gs_fixed_size_bin_parent_class)->measure (widget,
+ orientation,
+ for_size,
+ &m, &n,
+ NULL, NULL);
+
+ if (orientation == GTK_ORIENTATION_HORIZONTAL) {
+ bin->min_width = m;
+ if (bin->preferred_width >= 0 && n > bin->preferred_width)
+ n = MAX (m, bin->preferred_width);
+ } else {
+ bin->min_height = m;
+ if (bin->preferred_height >= 0 && n > bin->preferred_height)
+ n = MAX (m, bin->preferred_height);
}
- GTK_WIDGET_CLASS (gs_fixed_size_bin_parent_class)->get_preferred_height_for_width (
- widget, for_width, &m, &n);
-
- bin->min_height = m;
- if (bin->preferred_height >= 0 && n > bin->preferred_height)
- n = MAX (m, bin->preferred_height);
- if (min)
- *min = m;
- if (nat)
- *nat = n;
+ *minimum = m;
+ *natural = n;
}
static void
@@ -223,10 +174,7 @@ gs_fixed_size_bin_class_init (GsFixedSizeBinClass *class)
object_class->set_property = gs_fixed_size_bin_set_property;
widget_class->size_allocate = gs_fixed_size_bin_size_allocate;
- widget_class->get_preferred_width = gs_fixed_size_bin_get_preferred_width;
- widget_class->get_preferred_height = gs_fixed_size_bin_get_preferred_height;
- widget_class->get_preferred_width_for_height = gs_fixed_size_bin_get_preferred_width_for_height;
- widget_class->get_preferred_height_for_width = gs_fixed_size_bin_get_preferred_height_for_width;
+ widget_class->measure = gs_fixed_size_bin_measure;
g_object_class_install_property (object_class, PROP_PREFERRED_WIDTH,
g_param_spec_int ("preferred-width",
diff --git a/src/gs-hiding-box.c b/src/gs-hiding-box.c
index 7e329b9..acc915e 100644
--- a/src/gs-hiding-box.c
+++ b/src/gs-hiding-box.c
@@ -128,7 +128,6 @@ gs_hiding_box_remove (GtkContainer *container, GtkWidget *widget)
static void
gs_hiding_box_forall (GtkContainer *container,
- gboolean include_internals,
GtkCallback callback,
gpointer callback_data)
{
@@ -145,7 +144,10 @@ gs_hiding_box_forall (GtkContainer *container,
}
static void
-gs_hiding_box_size_allocate (GtkWidget *widget, GtkAllocation *allocation)
+gs_hiding_box_size_allocate (GtkWidget *widget,
+ const GtkAllocation *allocation,
+ int baseline,
+ GtkAllocation *out_clip)
{
GsHidingBox *box = GS_HIDING_BOX (widget);
gint nvis_children = 0;
@@ -162,9 +164,7 @@ gs_hiding_box_size_allocate (GtkWidget *widget, GtkAllocation *allocation)
GtkWidget *child_widget;
gint spacing = box->spacing;
gint children_size;
- GtkAllocation clip, child_clip;
- gtk_widget_set_allocation (widget, allocation);
for (child = box->children; child != NULL; child = child->next) {
if (gtk_widget_get_visible (child->data))
@@ -187,10 +187,7 @@ gs_hiding_box_size_allocate (GtkWidget *widget, GtkAllocation *allocation)
if (!gtk_widget_get_visible (child_widget))
continue;
- gtk_widget_get_preferred_width_for_height (child_widget,
- allocation->height,
- &sizes[i].minimum_size,
- &sizes[i].natural_size);
+ gtk_widget_measure (child_widget,
GTK_ORIENTATION_HORIZONTAL,allocation->height,&sizes[i].minimum_size,&sizes[i].natural_size,NULL,NULL);
/* Assert the api is working properly */
if (sizes[i].minimum_size < 0)
@@ -227,6 +224,7 @@ gs_hiding_box_size_allocate (GtkWidget *widget, GtkAllocation *allocation)
x = allocation->x;
for (i = 0, child = box->children; child != NULL; child = child->next) {
+ GtkAllocation clip;
child_widget = GTK_WIDGET (child->data);
if (!gtk_widget_get_visible (child_widget))
@@ -255,95 +253,65 @@ gs_hiding_box_size_allocate (GtkWidget *widget, GtkAllocation *allocation)
/* Let this child be visible */
gtk_widget_set_child_visible (child_widget, TRUE);
- gtk_widget_size_allocate (child_widget, &child_allocation);
+ gtk_widget_size_allocate (child_widget, &child_allocation, -1, &clip);
+ gdk_rectangle_union (out_clip, &clip, out_clip);
x += child_allocation.width + spacing;
++i;
}
-
- /*
- * The code below is inspired by _gtk_widget_set_simple_clip.
- * Note: Here we ignore the "box-shadow" CSS property of the
- * hiding box because we don't use it.
- */
- clip = *allocation;
- if (gtk_widget_get_has_window (widget)) {
- clip.x = clip.y = 0;
- }
-
- for (child = box->children; child != NULL; child = child->next) {
- child_widget = GTK_WIDGET (child->data);
- if (gtk_widget_get_visible (child_widget) &&
- gtk_widget_get_child_visible (child_widget)) {
- gtk_widget_get_clip (child_widget, &child_clip);
- gdk_rectangle_union (&child_clip, &clip, &clip);
- }
- }
-
- if (gtk_widget_get_has_window (widget)) {
- clip.x += allocation->x;
- clip.y += allocation->y;
- }
- gtk_widget_set_clip (widget, &clip);
}
static void
-gs_hiding_box_get_preferred_width (GtkWidget *widget, gint *min, gint *nat)
+gs_hiding_box_measure (GtkWidget *widget,
+ GtkOrientation orientation,
+ int for_size,
+ int *minimum,
+ int *natural,
+ int *minimum_baseline,
+ int *natural_baseline)
{
GsHidingBox *box = GS_HIDING_BOX (widget);
- gint cm, cn;
- gint m, n;
GList *child;
- gint nvis_children;
- gboolean have_min = FALSE;
-
- m = n = nvis_children = 0;
- for (child = box->children; child != NULL; child = child->next) {
- if (!gtk_widget_is_visible (child->data))
- continue;
-
- ++nvis_children;
- gtk_widget_get_preferred_width (child->data, &cm, &cn);
- /* Minimum is a minimum of the first visible child */
- if (!have_min) {
- m = cm;
- have_min = TRUE;
- }
- /* Natural is a sum of all visible children */
- n += cn;
- }
+ int m, n;
+ int cm, cn;
- /* Natural must also include the spacing */
- if (box->spacing && nvis_children > 1)
- n += box->spacing * (nvis_children - 1);
+ m = n = 0;
- if (min)
- *min = m;
- if (nat)
- *nat = n;
-}
+ if (orientation == GTK_ORIENTATION_HORIZONTAL) {
+ gint nvis_children;
+ gboolean have_min = FALSE;
-static void
-gs_hiding_box_get_preferred_height (GtkWidget *widget, gint *min, gint *nat)
-{
- gint m, n;
- gint cm, cn;
- GList *child;
+ m = n = nvis_children = 0;
+ for (child = box->children; child != NULL; child = child->next) {
+ if (!gtk_widget_is_visible (child->data))
+ continue;
- GsHidingBox *box = GS_HIDING_BOX (widget);
- m = n = 0;
- for (child = box->children; child != NULL; child = child->next) {
- if (!gtk_widget_is_visible (child->data))
- continue;
+ ++nvis_children;
+ gtk_widget_measure (child->data, GTK_ORIENTATION_HORIZONTAL, -1, &cm, &cn,NULL,NULL);
+ /* Minimum is a minimum of the first visible child */
+ if (!have_min) {
+ m = cm;
+ have_min = TRUE;
+ }
+ /* Natural is a sum of all visible children */
+ n += cn;
+ }
- gtk_widget_get_preferred_height (child->data, &cm, &cn);
- m = MAX (m, cm);
- n = MAX (n, cn);
+ /* Natural must also include the spacing */
+ if (box->spacing && nvis_children > 1)
+ n += box->spacing * (nvis_children - 1);
+ } else { /* VERTICAL */
+ for (child = box->children; child != NULL; child = child->next) {
+ if (!gtk_widget_is_visible (child->data))
+ continue;
+
+ gtk_widget_measure (child->data, GTK_ORIENTATION_VERTICAL, -1, &cm, &cn,NULL,NULL);
+ m = MAX (m, cm);
+ n = MAX (n, cn);
+ }
}
- if (min)
- *min = m;
- if (nat)
- *nat = n;
+ *minimum = m;
+ *natural = n;
}
static void
@@ -365,9 +333,8 @@ gs_hiding_box_class_init (GsHidingBoxClass *class)
object_class->set_property = gs_hiding_box_set_property;
object_class->get_property = gs_hiding_box_get_property;
+ widget_class->measure = gs_hiding_box_measure;
widget_class->size_allocate = gs_hiding_box_size_allocate;
- widget_class->get_preferred_width = gs_hiding_box_get_preferred_width;
- widget_class->get_preferred_height = gs_hiding_box_get_preferred_height;
container_class->add = gs_hiding_box_add;
container_class->remove = gs_hiding_box_remove;
diff --git a/src/gs-history-dialog.c b/src/gs-history-dialog.c
index a57951a..2f45518 100644
--- a/src/gs-history-dialog.c
+++ b/src/gs-history-dialog.c
@@ -109,7 +109,7 @@ gs_history_dialog_set_app (GsHistoryDialog *dialog, GsApp *app)
"xalign", 0.0,
NULL);
gtk_size_group_add_widget (dialog->sizegroup_state, widget);
- gtk_box_pack_start (box, widget, TRUE, TRUE, 0);
+ gtk_box_pack_start (box, widget);
/* add the timestamp */
timestamp = gs_app_get_install_date (app);
@@ -128,7 +128,7 @@ gs_history_dialog_set_app (GsHistoryDialog *dialog, GsApp *app)
"xalign", 0.0,
NULL);
gtk_size_group_add_widget (dialog->sizegroup_timestamp, widget);
- gtk_box_pack_start (box, widget, TRUE, TRUE, 0);
+ gtk_box_pack_start (box, widget);
/* add the version */
widget = gtk_label_new (gs_app_get_version (app));
@@ -142,9 +142,9 @@ gs_history_dialog_set_app (GsHistoryDialog *dialog, GsApp *app)
"width-chars", 10,
NULL);
gtk_size_group_add_widget (dialog->sizegroup_version, widget);
- gtk_box_pack_start (box, widget, TRUE, TRUE, 0);
+ gtk_box_pack_start (box, widget);
- gtk_widget_show_all (GTK_WIDGET (box));
+ gtk_widget_show (GTK_WIDGET (box));
gtk_list_box_insert (GTK_LIST_BOX (dialog->list_box), GTK_WIDGET (box), -1);
row = gtk_widget_get_parent (GTK_WIDGET (box));
diff --git a/src/gs-history-dialog.ui b/src/gs-history-dialog.ui
index 2ea4e30..62913dc 100644
--- a/src/gs-history-dialog.ui
+++ b/src/gs-history-dialog.ui
@@ -13,7 +13,6 @@
<child internal-child="vbox">
<object class="GtkBox" id="dialog-vbox">
<property name="can_focus">False</property>
- <property name="border_width">0</property>
<property name="orientation">vertical</property>
<property name="spacing">9</property>
<child>
@@ -43,8 +42,6 @@
</child>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
diff --git a/src/gs-info-bar.ui b/src/gs-info-bar.ui
index 718c0a7..c69b29e 100644
--- a/src/gs-info-bar.ui
+++ b/src/gs-info-bar.ui
@@ -2,7 +2,6 @@
<interface>
<!-- interface-requires gtk+ 3.10 -->
<template class="GsInfoBar" parent="GtkInfoBar">
- <property name="app_paintable">True</property>
<property name="message_type">info</property>
<style>
<class name="application-details-infobar"/>
@@ -45,8 +44,6 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
diff --git a/src/gs-installed-page.c b/src/gs-installed-page.c
index 1c54be7..04721a5 100644
--- a/src/gs-installed-page.c
+++ b/src/gs-installed-page.c
@@ -605,7 +605,6 @@ set_selection_mode (GsInstalledPage *self, gboolean selection_mode)
if (self->selection_mode) {
gtk_header_bar_set_show_close_button (GTK_HEADER_BAR (header), FALSE);
gtk_style_context_add_class (context, "selection-mode");
- gtk_button_set_image (GTK_BUTTON (self->button_select), NULL);
gtk_button_set_label (GTK_BUTTON (self->button_select), _("_Cancel"));
gtk_button_set_use_underline (GTK_BUTTON (self->button_select), TRUE);
gtk_widget_show (self->button_select);
@@ -618,7 +617,6 @@ set_selection_mode (GsInstalledPage *self, gboolean selection_mode)
} else {
gtk_header_bar_set_show_close_button (GTK_HEADER_BAR (header), TRUE);
gtk_style_context_remove_class (context, "selection-mode");
- gtk_button_set_image (GTK_BUTTON (self->button_select), gtk_image_new_from_icon_name
("object-select-symbolic", GTK_ICON_SIZE_MENU));
gtk_button_set_label (GTK_BUTTON (self->button_select), NULL);
gtk_widget_show (self->button_select);
widget = GTK_WIDGET (gtk_builder_get_object (self->builder, "buttonbox_main"));
diff --git a/src/gs-installed-page.ui b/src/gs-installed-page.ui
index b0372b6..b1e2204 100644
--- a/src/gs-installed-page.ui
+++ b/src/gs-installed-page.ui
@@ -95,7 +95,6 @@
</child>
</template>
<object class="GtkSizeGroup" id="sizegroup_folder_buttons">
- <property name="ignore-hidden">False</property>
<property name="mode">vertical</property>
<widgets>
<widget name="button_folder_add"/>
diff --git a/src/gs-loading-page.ui b/src/gs-loading-page.ui
index fe6a6da..8a65f80 100644
--- a/src/gs-loading-page.ui
+++ b/src/gs-loading-page.ui
@@ -17,7 +17,7 @@
<style>
<class name="dim-label"/>
</style>
- <child type="center">
+ <child>
<object class="GtkBox" id="centerbox">
<property name="visible">True</property>
<property name="orientation">vertical</property>
@@ -41,10 +41,6 @@
<class name="upgrade-progressbar"/>
</style>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkLabel" id="label">
diff --git a/src/gs-moderate-page.ui b/src/gs-moderate-page.ui
index 03d9e78..03a588d 100644
--- a/src/gs-moderate-page.ui
+++ b/src/gs-moderate-page.ui
@@ -67,7 +67,7 @@
<style>
<class name="dim-label"/>
</style>
- <child type="center">
+ <child>
<object class="GtkBox" id="updates_uptodate_centerbox">
<property name="visible">True</property>
<property name="orientation">vertical</property>
diff --git a/src/gs-overview-page.ui b/src/gs-overview-page.ui
index 799c44f..cdbf37d 100644
--- a/src/gs-overview-page.ui
+++ b/src/gs-overview-page.ui
@@ -19,7 +19,6 @@
<child>
<object class="GtkInfoBar" id="infobar_proprietary">
<property name="visible">True</property>
- <property name="app_paintable">True</property>
<property name="can_focus">False</property>
<property name="show_close_button">True</property>
<child internal-child="action_area">
@@ -30,8 +29,6 @@
<child/>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
@@ -40,7 +37,6 @@
<property name="can_focus">False</property>
<property name="orientation">vertical</property>
<property name="spacing">6</property>
- <property name="border_width">12</property>
<child>
<object class="GtkLabel" id="label_proprietary_title">
<property name="visible">True</property>
@@ -52,8 +48,6 @@
</attributes>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -68,22 +62,16 @@
<property name="xalign">0</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -107,7 +95,6 @@
<property name="can_focus">False</property>
<property name="halign">center</property>
<property name="hexpand">False</property>
- <property name="border_width">12</property>
<property name="orientation">vertical</property>
<child>
<object class="GtkLabel" id="featured_heading">
@@ -125,19 +112,15 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
- <object class="GtkAlignment" id="bin_featured">
+ <object class="GtkFrame" id="bin_featured">
<property name="visible">True</property>
<property name="halign">fill</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -158,8 +141,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
@@ -178,8 +159,6 @@
</accessibility>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">3</property>
</packing>
</child>
@@ -204,8 +183,6 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">4</property>
</packing>
</child>
@@ -251,8 +228,6 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -278,8 +253,6 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
@@ -296,8 +269,6 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">5</property>
</packing>
</child>
@@ -318,8 +289,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">6</property>
</packing>
</child>
@@ -334,8 +303,6 @@
</accessibility>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">7</property>
</packing>
</child>
@@ -356,8 +323,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">8</property>
</packing>
</child>
@@ -372,8 +337,6 @@
</accessibility>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">9</property>
</packing>
</child>
diff --git a/src/gs-page.c b/src/gs-page.c
index 6102303..4ef2611 100644
--- a/src/gs-page.c
+++ b/src/gs-page.c
@@ -559,8 +559,8 @@ gs_page_needs_user_action (GsPageHelper *helper, AsScreenshot *ss)
helper->cancellable);
gtk_widget_set_margin_start (ssimg, 24);
gtk_widget_set_margin_end (ssimg, 24);
- content_area = gtk_dialog_get_content_area (GTK_DIALOG (dialog));
- gtk_box_pack_end (GTK_BOX (content_area), ssimg, FALSE, FALSE, 0);
+ content_area = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
+ gtk_box_pack_end (GTK_BOX (content_area), ssimg);
/* handle this async */
g_signal_connect (dialog, "response",
diff --git a/src/gs-popular-tile.ui b/src/gs-popular-tile.ui
index 2236467..ca68dfd 100644
--- a/src/gs-popular-tile.ui
+++ b/src/gs-popular-tile.ui
@@ -33,7 +33,6 @@
<property name="valign">fill</property>
<child type="overlay">
<object class="GtkEventBox" id="eventbox">
- <property name="no_show_all">True</property>
<property name="visible_window">True</property>
<property name="halign">end</property>
<property name="valign">start</property>
@@ -44,7 +43,7 @@
<property name="valign">center</property>
<property name="pixel-size">20</property>
<property name="margin-top">6</property>
- <property name="margin-right">6</property>
+ <property name="margin-end">6</property>
<property name="icon-name">software-installed-symbolic</property>
<style>
<class name="installed-icon"/>
@@ -73,10 +72,6 @@
<property name="visible">True</property>
<property name="valign">center</property>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkLabel" id="label">
@@ -87,10 +82,6 @@
<property name="width_chars">12</property>
<property name="max_width_chars">12</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GsStarWidget" id="stars">
@@ -100,10 +91,6 @@
<class name="onlyjustvisible"/>
</style>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- </packing>
</child>
</object>
</child>
diff --git a/src/gs-progress-button.c b/src/gs-progress-button.c
index ad55d6a..55620d9 100644
--- a/src/gs-progress-button.c
+++ b/src/gs-progress-button.c
@@ -44,7 +44,7 @@ gs_progress_button_set_progress (GsProgressButton *button, guint percentage)
else
css = g_strdup_printf (".install-progress { background-size: %u%%; }", percentage);
- gtk_css_provider_load_from_data (button->css_provider, css, -1, NULL);
+ gtk_css_provider_load_from_data (button->css_provider, css, -1);
}
void
diff --git a/src/gs-removal-dialog.c b/src/gs-removal-dialog.c
index 87a29fa..393fb6b 100644
--- a/src/gs-removal-dialog.c
+++ b/src/gs-removal-dialog.c
@@ -74,7 +74,7 @@ add_app (GtkListBox *listbox, GsApp *app)
widget = gtk_label_new (gs_app_get_name (app));
gtk_widget_set_halign (widget, GTK_ALIGN_START);
gtk_label_set_ellipsize (GTK_LABEL (widget), PANGO_ELLIPSIZE_END);
- gtk_box_pack_start (GTK_BOX (box), widget, FALSE, FALSE, 0);
+ gtk_box_pack_start (GTK_BOX (box), widget);
g_object_set_data_full (G_OBJECT (box),
"sort",
diff --git a/src/gs-review-bar.c b/src/gs-review-bar.c
index 1077040..6d9b5d4 100644
--- a/src/gs-review-bar.c
+++ b/src/gs-review-bar.c
@@ -45,12 +45,25 @@ gs_review_bar_init (GsReviewBar *bar)
{
}
-static gboolean
-gs_review_bar_draw (GtkWidget *widget, cairo_t *cr)
+static void
+gs_review_bar_snapshot (GtkWidget *widget, GtkSnapshot *snapshot)
{
+ GtkAllocation allocation;
GtkStyleContext *context;
gdouble y_offset, bar_height;
GdkRGBA color;
+ cairo_t *cr;
+
+ gtk_widget_get_allocation (widget, &allocation);
+
+ cr = gtk_snapshot_append_cairo (snapshot,
+ &GRAPHENE_RECT_INIT (
+ allocation.x,
+ allocation.y,
+ allocation.width,
+ allocation.height
+ ),
+ "review bar");
context = gtk_widget_get_style_context (widget);
@@ -67,18 +80,21 @@ gs_review_bar_draw (GtkWidget *widget, cairo_t *cr)
0, y_offset,
round (GS_REVIEW_BAR (widget)->fraction * gtk_widget_get_allocated_width (widget)),
bar_height);
- gtk_style_context_get_color (context, gtk_widget_get_state_flags (widget), &color);
+ gtk_style_context_get_color (context, &color);
cairo_set_source_rgba (cr, color.red, color.green, color.blue, color.alpha);
cairo_fill (cr);
- return GTK_WIDGET_CLASS (gs_review_bar_parent_class)->draw (widget, cr);
+ cairo_destroy (cr);
+
+ GTK_WIDGET_CLASS (gs_review_bar_parent_class)->snapshot (widget, snapshot);
}
static void
gs_review_bar_class_init (GsReviewBarClass *klass)
{
GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (klass);
- widget_class->draw = gs_review_bar_draw;
+
+ widget_class->snapshot = gs_review_bar_snapshot;
}
GtkWidget *
diff --git a/src/gs-review-dialog.ui b/src/gs-review-dialog.ui
index 575a118..4e3763b 100644
--- a/src/gs-review-dialog.ui
+++ b/src/gs-review-dialog.ui
@@ -61,8 +61,6 @@
<property name="can_focus">False</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
@@ -89,8 +87,6 @@
</attributes>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -100,8 +96,6 @@
<property name="halign">center</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
@@ -117,15 +111,11 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">3</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -146,8 +136,6 @@
</attributes>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -163,8 +151,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -174,15 +160,11 @@
<property name="can_focus">True</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">3</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -203,8 +185,6 @@
</attributes>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -220,8 +200,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -245,22 +223,16 @@
</child>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -268,7 +240,6 @@
</child>
</template>
<object class="GtkSizeGroup" id="sizegroup_folder_buttons">
- <property name="ignore-hidden">False</property>
<property name="mode">horizontal</property>
<widgets>
<widget name="cancel_button"/>
diff --git a/src/gs-review-histogram.ui b/src/gs-review-histogram.ui
index 1a365b6..a03880a 100644
--- a/src/gs-review-histogram.ui
+++ b/src/gs-review-histogram.ui
@@ -14,7 +14,7 @@
<property name="halign">end</property>
<property name="visible">True</property>
<property name="label">0</property>
- <property name="margin-left">5</property>
+ <property name="margin-start">5</property>
</object>
<packing>
<property name="left-attach">0</property>
@@ -26,7 +26,7 @@
<child>
<object class="GsReviewBar" id="bar5">
<property name="visible">True</property>
- <property name="margin-left">5</property>
+ <property name="margin-start">5</property>
<property name="width-request">120</property>
<style>
<class name="reviewbar"/>
@@ -111,7 +111,7 @@
<property name="halign">end</property>
<property name="visible">True</property>
<property name="label">0</property>
- <property name="margin-left">5</property>
+ <property name="margin-start">5</property>
</object>
<packing>
<property name="left-attach">0</property>
@@ -123,7 +123,7 @@
<child>
<object class="GsReviewBar" id="bar4">
<property name="visible">True</property>
- <property name="margin-left">5</property>
+ <property name="margin-start">5</property>
<style>
<class name="reviewbar"/>
</style>
@@ -197,7 +197,7 @@
<property name="halign">end</property>
<property name="visible">True</property>
<property name="label">0</property>
- <property name="margin-left">5</property>
+ <property name="margin-start">5</property>
</object>
<packing>
<property name="left-attach">0</property>
@@ -209,7 +209,7 @@
<child>
<object class="GsReviewBar" id="bar3">
<property name="visible">True</property>
- <property name="margin-left">5</property>
+ <property name="margin-start">5</property>
<style>
<class name="reviewbar"/>
</style>
@@ -273,7 +273,7 @@
<property name="halign">end</property>
<property name="visible">True</property>
<property name="label">0</property>
- <property name="margin-left">5</property>
+ <property name="margin-start">5</property>
</object>
<packing>
<property name="left-attach">0</property>
@@ -285,7 +285,7 @@
<child>
<object class="GsReviewBar" id="bar2">
<property name="visible">True</property>
- <property name="margin-left">5</property>
+ <property name="margin-start">5</property>
<style>
<class name="reviewbar"/>
</style>
@@ -339,7 +339,7 @@
<property name="halign">end</property>
<property name="visible">True</property>
<property name="label">0</property>
- <property name="margin-left">5</property>
+ <property name="margin-start">5</property>
</object>
<packing>
<property name="left-attach">0</property>
@@ -351,7 +351,7 @@
<child>
<object class="GsReviewBar" id="bar1">
<property name="visible">True</property>
- <property name="margin-left">5</property>
+ <property name="margin-start">5</property>
<style>
<class name="reviewbar"/>
</style>
@@ -394,7 +394,7 @@
<object class="GtkLabel" id="label_total">
<property name="visible">True</property>
<property name="label">0</property>
- <property name="margin-left">5</property>
+ <property name="margin-start">5</property>
<property name="margin-top">5</property>
</object>
<packing>
@@ -407,7 +407,7 @@
<child>
<object class="GtkLabel" id="label_1">
<property name="visible">True</property>
- <property name="margin-left">5</property>
+ <property name="margin-start">5</property>
<property name="halign">start</property>
<property name="margin-top">5</property>
<property name="label" translatable="yes" comments="Translators: A label for the total number of
reviews.">ratings in total</property>
diff --git a/src/gs-review-row.ui b/src/gs-review-row.ui
index 2f6fc59..54d4c4c 100644
--- a/src/gs-review-row.ui
+++ b/src/gs-review-row.ui
@@ -115,8 +115,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
@@ -138,8 +136,6 @@
<property name="relief">none</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
@@ -152,8 +148,6 @@
<property name="relief">none</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">1</property>
</packing>
</child>
@@ -166,15 +160,11 @@
<property name="relief">none</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">2</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">1</property>
</packing>
</child>
@@ -201,8 +191,6 @@
<property name="relief">none</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -216,8 +204,6 @@
<property name="relief">none</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
diff --git a/src/gs-screenshot-image.c b/src/gs-screenshot-image.c
index 744b495..a538bb6 100644
--- a/src/gs-screenshot-image.c
+++ b/src/gs-screenshot-image.c
@@ -619,31 +619,12 @@ gs_screenshot_image_init (GsScreenshotImage *ssimg)
}
}
-static gboolean
-gs_screenshot_image_draw (GtkWidget *widget, cairo_t *cr)
-{
- GtkStyleContext *context;
-
- context = gtk_widget_get_style_context (widget);
- gtk_render_background (context, cr,
- 0, 0,
- gtk_widget_get_allocated_width (widget),
- gtk_widget_get_allocated_height (widget));
- gtk_render_frame (context, cr,
- 0, 0,
- gtk_widget_get_allocated_width (widget),
- gtk_widget_get_allocated_height (widget));
-
- return GTK_WIDGET_CLASS (gs_screenshot_image_parent_class)->draw (widget, cr);
-}
-
static void
gs_screenshot_image_class_init (GsScreenshotImageClass *klass)
{
GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (klass);
widget_class->destroy = gs_screenshot_image_destroy;
- widget_class->draw = gs_screenshot_image_draw;
gtk_widget_class_set_template_from_resource (widget_class,
"/org/gnome/Software/gs-screenshot-image.ui");
diff --git a/src/gs-screenshot-image.ui b/src/gs-screenshot-image.ui
index 059a9ce..bd447a8 100644
--- a/src/gs-screenshot-image.ui
+++ b/src/gs-screenshot-image.ui
@@ -44,8 +44,6 @@
<property name="icon-name">dialog-error-symbolic</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -57,8 +55,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
diff --git a/src/gs-sources-dialog-row.ui b/src/gs-sources-dialog-row.ui
index 67ba900..711c43e 100644
--- a/src/gs-sources-dialog-row.ui
+++ b/src/gs-sources-dialog-row.ui
@@ -23,10 +23,6 @@
<property name="halign">start</property>
<property name="ellipsize">end</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
<child>
<object class="GtkLabel" id="comment_label">
@@ -35,10 +31,6 @@
<property name="xalign">0</property>
<property name="wrap">True</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
<child>
<object class="GtkLabel" id="description_label">
@@ -50,16 +42,8 @@
<class name="dim-label"/>
</style>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkSwitch" id="active_switch">
@@ -68,10 +52,6 @@
<property name="halign">end</property>
<property name="valign">start</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
</object>
</child>
diff --git a/src/gs-sources-dialog.c b/src/gs-sources-dialog.c
index 94a5d2c..483e3f2 100644
--- a/src/gs-sources-dialog.c
+++ b/src/gs-sources-dialog.c
@@ -416,7 +416,7 @@ add_app (GtkListBox *listbox, GsApp *app)
widget = gtk_label_new (gs_app_get_name (app));
gtk_widget_set_halign (widget, GTK_ALIGN_START);
gtk_label_set_ellipsize (GTK_LABEL (widget), PANGO_ELLIPSIZE_END);
- gtk_box_pack_start (GTK_BOX (box), widget, FALSE, FALSE, 0);
+ gtk_box_pack_start (GTK_BOX (box), widget);
g_object_set_data_full (G_OBJECT (box),
"sort",
diff --git a/src/gs-sources-dialog.ui b/src/gs-sources-dialog.ui
index a49b010..668da77 100644
--- a/src/gs-sources-dialog.ui
+++ b/src/gs-sources-dialog.ui
@@ -94,8 +94,6 @@
<property name="pixel-size">64</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -110,8 +108,6 @@
<property name="valign">center</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -162,10 +158,6 @@
<class name="dim-label"/>
</style>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkLabel" id="label3">
@@ -179,10 +171,6 @@
<class name="dim-label"/>
</style>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
<object class="GtkScrolledWindow" id="scrolledwindow">
@@ -208,10 +196,6 @@
</object>
</child>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
</child>
</object>
<packing>
@@ -274,8 +258,6 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -292,8 +274,6 @@
</attributes>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -321,8 +301,6 @@
</child>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -338,8 +316,6 @@
</attributes>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
@@ -477,8 +453,6 @@
</child>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">3</property>
</packing>
</child>
@@ -494,8 +468,6 @@
</style>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
<property name="position">4</property>
<property name="pack_type">end</property>
</packing>
@@ -507,8 +479,6 @@
</child>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
diff --git a/src/gs-summary-tile.c b/src/gs-summary-tile.c
index 00e71bb..ccdf199 100644
--- a/src/gs-summary-tile.c
+++ b/src/gs-summary-tile.c
@@ -227,24 +227,38 @@ gs_summary_tile_set_property (GObject *object,
}
static void
-gs_app_get_preferred_width (GtkWidget *widget,
- gint *min, gint *nat)
+gs_summary_tile_measure (GtkWidget *widget,
+ GtkOrientation orientation,
+ int for_size,
+ int *minimum,
+ int *natural,
+ int *minimum_baseline,
+ int *natural_baseline)
{
- gint m;
GsSummaryTile *app_tile = GS_SUMMARY_TILE (widget);
- if (app_tile->preferred_width < 0) {
- /* Just retrieve the default values */
- GTK_WIDGET_CLASS (gs_summary_tile_parent_class)->get_preferred_width (widget, min, nat);
- return;
- }
+ if (orientation == GTK_ORIENTATION_HORIZONTAL && for_size == -1 && app_tile->preferred_width >= 0) {
+ int m, n;
- GTK_WIDGET_CLASS (gs_summary_tile_parent_class)->get_preferred_width (widget, &m, NULL);
+ GTK_WIDGET_CLASS (gs_summary_tile_parent_class)->measure (widget,
+ orientation,
+ for_size,
+ &m,
+ &n,
+ NULL,
+ NULL);
- if (min != NULL)
- *min = m;
- if (nat != NULL)
- *nat = MAX (m, app_tile->preferred_width);
+ *minimum = m;
+ *natural = MAX (m, app_tile->preferred_width);
+ } else {
+ GTK_WIDGET_CLASS (gs_summary_tile_parent_class)->measure (widget,
+ orientation,
+ for_size,
+ minimum,
+ natural,
+ minimum_baseline,
+ natural_baseline);
+ }
}
static void
@@ -257,8 +271,8 @@ gs_summary_tile_class_init (GsSummaryTileClass *klass)
object_class->get_property = gs_summary_tile_get_property;
object_class->set_property = gs_summary_tile_set_property;
+ widget_class->measure = gs_summary_tile_measure;
widget_class->destroy = gs_summary_tile_destroy;
- widget_class->get_preferred_width = gs_app_get_preferred_width;
tile_class->set_app = gs_summary_tile_set_app;
tile_class->get_app = gs_summary_tile_get_app;
diff --git a/src/gs-summary-tile.ui b/src/gs-summary-tile.ui
index 0c704df..8ad772c 100644
--- a/src/gs-summary-tile.ui
+++ b/src/gs-summary-tile.ui
@@ -36,7 +36,6 @@
<property name="valign">fill</property>
<child type="overlay">
<object class="GtkEventBox" id="eventbox">
- <property name="no_show_all">True</property>
<property name="visible_window">True</property>
<property name="halign">end</property>
<property name="valign">start</property>
@@ -47,7 +46,7 @@
<property name="valign">center</property>
<property name="pixel-size">20</property>
<property name="margin-top">6</property>
- <property name="margin-right">6</property>
+ <property name="margin-end">6</property>
<property name="icon-name">software-installed-symbolic</property>
<style>
<class name="installed-icon"/>
diff --git a/src/gs-update-dialog.c b/src/gs-update-dialog.c
index c607a6a..4a79130 100644
--- a/src/gs-update-dialog.c
+++ b/src/gs-update-dialog.c
@@ -323,7 +323,7 @@ create_app_row (GsApp *app)
NULL);
gtk_widget_set_halign (label, GTK_ALIGN_START);
gtk_widget_set_valign (label, GTK_ALIGN_CENTER);
- gtk_box_pack_start (GTK_BOX (row), label, TRUE, TRUE, 0);
+ gtk_box_pack_start (GTK_BOX (row), label);
if (gs_app_get_state (app) == AS_APP_STATE_UPDATABLE ||
gs_app_get_state (app) == AS_APP_STATE_UPDATABLE_LIVE) {
g_autofree gchar *verstr = format_version_update (app);
@@ -341,8 +341,7 @@ create_app_row (GsApp *app)
NULL);
gtk_widget_set_halign (label, GTK_ALIGN_END);
gtk_widget_set_valign (label, GTK_ALIGN_CENTER);
- gtk_box_pack_start (GTK_BOX (row), label, FALSE, FALSE, 0);
- gtk_widget_show_all (row);
+ gtk_box_pack_start (GTK_BOX (row), label);
return row;
}
@@ -439,7 +438,7 @@ get_section_header (GsUpdateDialog *dialog, GsUpdateDialogSection section)
gtk_style_context_add_class (context, "app-listbox-header");
/* put label into the header */
- gtk_box_pack_start (GTK_BOX (header), label, TRUE, TRUE, 0);
+ gtk_box_pack_start (GTK_BOX (header), label);
gtk_widget_set_visible (label, TRUE);
gtk_widget_set_margin_start (label, 6);
gtk_label_set_xalign (GTK_LABEL (label), 0.0);
@@ -485,8 +484,7 @@ create_section (GsUpdateDialog *dialog, GsUpdateDialogSection section)
G_CALLBACK (row_activated_cb), dialog);
gtk_widget_set_visible (dialog->list_boxes[section], TRUE);
gtk_box_pack_start (GTK_BOX (dialog->os_update_box),
- dialog->list_boxes[section],
- TRUE, TRUE, 0);
+ dialog->list_boxes[section]);
gtk_widget_set_margin_top (dialog->list_boxes[section], 24);
/* reorder the children */
diff --git a/src/gs-update-dialog.ui b/src/gs-update-dialog.ui
index 8095086..a26ff5d 100644
--- a/src/gs-update-dialog.ui
+++ b/src/gs-update-dialog.ui
@@ -42,7 +42,6 @@
<child internal-child="vbox">
<object class="GtkBox" id="dialog-vbox1">
<property name="can_focus">False</property>
- <property name="border_width">0</property>
<property name="orientation">vertical</property>
<property name="spacing">2</property>
<child>
@@ -98,8 +97,6 @@
<property name="pixel-size">64</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -115,8 +112,6 @@
<property name="valign">center</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -133,7 +128,6 @@
<property name="margin_end">6</property>
<property name="margin_top">6</property>
<property name="margin_bottom">9</property>
- <property name="border_width">5</property>
<property name="orientation">vertical</property>
<property name="spacing">9</property>
<child>
@@ -150,8 +144,6 @@
<property name="icon_size">0</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -177,8 +169,6 @@
</attributes>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -194,22 +184,16 @@
<property name="width_chars">50</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -237,8 +221,6 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -300,8 +282,6 @@
</child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -309,7 +289,6 @@
</child>
</template>
<object class="GtkSizeGroup" id="sizegroup_update_details">
- <property name="ignore-hidden">False</property>
<property name="mode">horizontal</property>
<widgets>
<widget name="scrolledwindow"/>
diff --git a/src/gs-updates-page.c b/src/gs-updates-page.c
index 6e7374a..1404918 100644
--- a/src/gs-updates-page.c
+++ b/src/gs-updates-page.c
@@ -377,8 +377,7 @@ gs_updates_page_update_ui_state (GsUpdatesPage *self)
switch (self->state) {
case GS_UPDATES_PAGE_STATE_ACTION_REFRESH:
case GS_UPDATES_PAGE_STATE_ACTION_GET_UPDATES:
- gtk_image_set_from_icon_name (GTK_IMAGE (gtk_button_get_image (GTK_BUTTON
(self->button_refresh))),
- "media-playback-stop-symbolic", GTK_ICON_SIZE_MENU);
+ gtk_button_set_icon_name (GTK_BUTTON (self->button_refresh), "media-playback-stop-symbolic");
gtk_widget_show (self->button_refresh);
break;
case GS_UPDATES_PAGE_STATE_STARTUP:
@@ -386,8 +385,7 @@ gs_updates_page_update_ui_state (GsUpdatesPage *self)
gtk_widget_hide (self->button_refresh);
break;
default:
- gtk_image_set_from_icon_name (GTK_IMAGE (gtk_button_get_image (GTK_BUTTON
(self->button_refresh))),
- "view-refresh-symbolic", GTK_ICON_SIZE_MENU);
+ gtk_button_set_icon_name (GTK_BUTTON (self->button_refresh), "view-refresh-symbolic");
if (self->result_flags != GS_UPDATES_PAGE_FLAG_NONE) {
gtk_widget_show (self->button_refresh);
} else {
@@ -805,7 +803,7 @@ _get_section_header (GsUpdatesPage *self, GsUpdatePageSection section)
gtk_style_context_add_class (context, "app-listbox-header");
/* put label into the header */
- gtk_box_pack_start (GTK_BOX (header), label, TRUE, TRUE, 0);
+ gtk_box_pack_start (GTK_BOX (header), label);
gtk_widget_set_visible (label, TRUE);
gtk_widget_set_margin_start (label, 6);
gtk_label_set_xalign (GTK_LABEL (label), 0.0);
@@ -814,7 +812,7 @@ _get_section_header (GsUpdatesPage *self, GsUpdatePageSection section)
/* add button if one is specified */
if (button != NULL) {
- gtk_box_pack_end (GTK_BOX (header), button, FALSE, FALSE, 0);
+ gtk_box_pack_end (GTK_BOX (header), button);
gtk_widget_set_visible (button, TRUE);
gtk_widget_set_margin_end (button, 6);
gtk_size_group_add_widget (self->sizegroup_button, button);
@@ -881,9 +879,7 @@ _create_listbox_section (GsUpdatesPage *self, GsUpdatePageSection sect)
g_signal_connect (self->listboxes[sect], "row-activated",
G_CALLBACK (_app_row_activated_cb), self);
gtk_widget_set_visible (GTK_WIDGET (self->listboxes[sect]), TRUE);
- gtk_box_pack_start (GTK_BOX (self->updates_box),
- GTK_WIDGET (self->listboxes[sect]),
- TRUE, TRUE, 0);
+ gtk_box_pack_start (GTK_BOX (self->updates_box),GTK_WIDGET (self->listboxes[sect]));
gtk_widget_set_margin_top (GTK_WIDGET (self->listboxes[sect]), 24);
/* reorder the children */
@@ -1802,14 +1798,14 @@ gs_updates_page_setup (GsPage *page,
gs_page_set_header_start_widget (GS_PAGE (self), self->header_start_box);
self->header_spinner_start = gtk_spinner_new ();
- gtk_box_pack_end (GTK_BOX (self->header_start_box), self->header_spinner_start, FALSE, FALSE, 0);
+gtk_box_pack_end (GTK_BOX (self->header_start_box), self->header_spinner_start);
/* setup update details window */
self->button_refresh = gtk_button_new_from_icon_name ("view-refresh-symbolic", GTK_ICON_SIZE_MENU);
accessible = gtk_widget_get_accessible (self->button_refresh);
if (accessible != NULL)
atk_object_set_name (accessible, _("Check for updates"));
- gtk_box_pack_start (GTK_BOX (self->header_start_box), self->button_refresh, FALSE, FALSE, 0);
+gtk_box_pack_start (GTK_BOX (self->header_start_box), self->button_refresh);
g_signal_connect (self->button_refresh, "clicked",
G_CALLBACK (gs_updates_page_button_refresh_cb),
self);
diff --git a/src/gs-updates-page.ui b/src/gs-updates-page.ui
index dc6023f..16f0e5f 100644
--- a/src/gs-updates-page.ui
+++ b/src/gs-updates-page.ui
@@ -14,7 +14,6 @@
<child>
<object class="GtkBox" id="box_end_of_life">
<property name="can_focus">False</property>
- <property name="border_width">0</property>
<property name="orientation">horizontal</property>
<property name="spacing">18</property>
<style>
@@ -27,7 +26,7 @@
<property name="pixel_size">16</property>
<property name="icon_name">dialog-warning-symbolic</property>
<property name="margin_top">18</property>
- <property name="margin_left">18</property>
+ <property name="margin_start">18</property>
<property name="valign">start</property>
</object>
</child>
@@ -41,7 +40,7 @@
<object class="GtkLabel">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="margin_right">18</property>
+ <property name="margin_end">18</property>
<property name="margin_top">18</property>
<property name="label" translatable="yes">Operating System Updates Unavailable</property>
<property name="xalign">0</property>
@@ -49,28 +48,18 @@
<attribute name="weight" value="bold"/>
</attributes>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- <property name="position">0</property>
- </packing>
</child>
<child>
<object class="GtkLabel" id="label_end_of_life">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="margin_right">18</property>
+ <property name="margin_end">18</property>
<property name="margin_bottom">18</property>
<property name="label">Your OS is no longer supported. This means that it does not
receive security updates. It is recommended that you upgrade to a more recent version.</property>
<property name="wrap">True</property>
<property name="width_chars">80</property>
<property name="xalign">0</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- <property name="position">1</property>
- </packing>
</child>
</object>
</child>
@@ -171,7 +160,7 @@
<property name="vexpand">True</property>
</object>
</child>
- <child type="center">
+ <child>
<object class="GtkBox" id="updates_uptodate_centerbox">
<property name="visible">True</property>
<property name="orientation">vertical</property>
@@ -263,10 +252,6 @@
<property name="hexpand">False</property>
<property name="halign">center</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
</object>
<packing>
@@ -317,10 +302,6 @@
<property name="hexpand">False</property>
<property name="halign">center</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
</object>
<packing>
diff --git a/src/gs-upgrade-banner.ui b/src/gs-upgrade-banner.ui
index 83727f3..ebff9f9 100644
--- a/src/gs-upgrade-banner.ui
+++ b/src/gs-upgrade-banner.ui
@@ -57,10 +57,6 @@
<property name="use_underline">True</property>
<property name="relief">normal</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
<child>
@@ -85,10 +81,6 @@
<class name="upgrade-progressbar"/>
</style>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- </packing>
</child>
<child>
@@ -121,10 +113,6 @@
<property name="use_underline">True</property>
<property name="relief">normal</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
<child>
<object class="GtkButton" id="button_upgrades_cancel">
@@ -136,10 +124,6 @@
<property name="use_underline">True</property>
<property name="relief">normal</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
<child>
<object class="GtkButton" id="button_upgrades_install">
@@ -151,10 +135,6 @@
<property name="use_underline">True</property>
<property name="relief">normal</property>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
</child>
</object>
</child>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]