Patrick Williams | c0f7c04 | 2017-02-23 20:41:17 -0600 | [diff] [blame] | 1 | From f83a9179696b2d060ee4860733dafbf38bbd4b87 Mon Sep 17 00:00:00 2001 |
| 2 | From: Jussi Kukkonen <jussi.kukkonen@intel.com> |
| 3 | Date: Wed, 28 Sep 2016 15:05:41 +0300 |
| 4 | Subject: [PATCH] applets/systray: Allow icons to be smaller |
| 5 | |
| 6 | Don't expand/fill the systray items, align them in the center of the |
| 7 | systray panel. This makes sure the icons are drawn at the size they |
| 8 | expect. |
| 9 | |
| 10 | Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com> |
| 11 | Upstream-Status: Submitted |
| 12 | --- |
| 13 | applets/systray/systray.c | 5 +++-- |
| 14 | 1 file changed, 3 insertions(+), 2 deletions(-) |
| 15 | |
| 16 | diff --git a/applets/systray/systray.c b/applets/systray/systray.c |
| 17 | index 39698a8..94a5753 100644 |
| 18 | --- a/applets/systray/systray.c |
| 19 | +++ b/applets/systray/systray.c |
| 20 | @@ -29,8 +29,9 @@ on_realize (GtkWidget *widget, gpointer user_data) |
| 21 | tray = (GtkWidget *)na_tray_new_for_screen (screen, orientation); |
| 22 | |
| 23 | gtk_widget_show (tray); |
| 24 | - |
| 25 | - gtk_container_add (GTK_CONTAINER (widget), tray); |
| 26 | + gtk_widget_set_valign (tray, GTK_ALIGN_CENTER); |
| 27 | + gtk_widget_set_halign (tray, GTK_ALIGN_CENTER); |
| 28 | + gtk_box_pack_start (GTK_BOX (widget), tray, FALSE, FALSE, 0); |
| 29 | } |
| 30 | |
| 31 | G_MODULE_EXPORT GtkWidget * |
| 32 | -- |
| 33 | 2.1.4 |
| 34 | |