From 136a84136fe7c412008875485bd1a1371116dadb Mon Sep 17 00:00:00 2001 From: Ryo Nakano <26003928+ryonakano@users.noreply.github.com> Date: Fri, 7 Jun 2019 17:54:31 +0900 Subject: [PATCH 01/22] Use Granite.markup_accel_tooltip --- src/Widgets/Headerbar.vala | 4 ++-- src/Widgets/Search.vala | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Widgets/Headerbar.vala b/src/Widgets/Headerbar.vala index fa528f45..c081c373 100644 --- a/src/Widgets/Headerbar.vala +++ b/src/Widgets/Headerbar.vala @@ -23,13 +23,13 @@ namespace Monitor { end_process_button = new Gtk.Button.with_label (_("End Process")); end_process_button.margin_end = 10; end_process_button.clicked.connect (window.process_view.end_process); - end_process_button.tooltip_text = (_("Ctrl+E")); + end_process_button.tooltip_markup = Granite.markup_accel_tooltip ({"E"}, _("End selected process")); var end_process_button_context = end_process_button.get_style_context (); end_process_button_context.add_class (Gtk.STYLE_CLASS_SUGGESTED_ACTION); kill_process_button = new Gtk.Button.with_label (_("Kill Process")); kill_process_button.clicked.connect (window.process_view.kill_process); - kill_process_button.tooltip_text = (_("Ctrl+K")); + kill_process_button.tooltip_markup = Granite.markup_accel_tooltip ({"K"}, _("Kill selected process")); var kill_process_button_context = kill_process_button.get_style_context (); kill_process_button_context.add_class (Gtk.STYLE_CLASS_DESTRUCTIVE_ACTION); diff --git a/src/Widgets/Search.vala b/src/Widgets/Search.vala index 51f02219..cf54fcb8 100644 --- a/src/Widgets/Search.vala +++ b/src/Widgets/Search.vala @@ -12,7 +12,7 @@ namespace Monitor { construct { this.process_view = window.process_view; this.placeholder_text = _("Search Process"); - this.tooltip_text = _("Type Process Name or PID"); + this.tooltip_markup = Granite.markup_accel_tooltip ({"F"}, _("Type process name or PID to search")); filter_model = new Gtk.TreeModelFilter (window.generic_model, null); connect_signal (); From 09d1d736785fa571b7b34fe4ac0fcc9f8f344ed3 Mon Sep 17 00:00:00 2001 From: Ryo Nakano <26003928+ryonakano@users.noreply.github.com> Date: Fri, 7 Jun 2019 17:58:05 +0900 Subject: [PATCH 02/22] Update required granite version --- README.md | 2 +- debian/control | 2 +- meson.build | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 36785d69..d8c808b0 100644 --- a/README.md +++ b/README.md @@ -28,7 +28,7 @@ You'll need the following dependencies to build: * valac * libgtk-3-dev -* libgranite-dev +* libgranite-dev (>= 5.2.0) * libbamf3-dev * libwnck-3-dev * libgtop2-dev diff --git a/debian/control b/debian/control index 6322de32..ed40651f 100644 --- a/debian/control +++ b/debian/control @@ -8,7 +8,7 @@ Build-Depends: meson, libgtk-3-dev, libglib2.0-dev, valac (>= 0.26), - libgranite-dev, + libgranite-dev (>= 5.2.0), libbamf3-dev, libwnck-3-dev, libgtop2-dev, diff --git a/meson.build b/meson.build index ce2da1c3..84cce97b 100644 --- a/meson.build +++ b/meson.build @@ -7,7 +7,7 @@ i18n = import('i18n') # and these are project dependencies glib = dependency('glib-2.0') -granite = dependency('granite') +granite = dependency('granite', version: '>= 5.2.0') gtk = dependency('gtk+-3.0') gee = dependency('gee-0.8') gio = dependency('gio-2.0') From 93ceb45ae3b8bc5aa03a5c931d6134ffb37563f7 Mon Sep 17 00:00:00 2001 From: Mirko Brombin Date: Fri, 16 Aug 2019 14:06:53 +0200 Subject: [PATCH 03/22] Update Italian translation --- po/it.po | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/po/it.po b/po/it.po index 1c61db01..a6f6ff11 100644 --- a/po/it.po +++ b/po/it.po @@ -21,30 +21,30 @@ msgstr "" #: src/Indicator/Widgets/PopoverWidget.vala:12 msgid "Show Monitor" -msgstr "Apri il Monitore" +msgstr "Apri il Monitor" #: src/Indicator/Widgets/PopoverWidget.vala:13 msgid "Quit Monitor" -msgstr "Chidi il Monitore" +msgstr "Chiudi il Monitor" #. Some information about the indicator #. Unique name #: src/Indicator/Indicator.vala:44 msgid "Monitor Indicator" -msgstr "Icona del pannello" +msgstr "Icona nel pannello" #. Localised name #: src/Indicator/Indicator.vala:45 msgid "Show system resources" -msgstr "Mostra le risorse del sistema" +msgstr "Mostra risorse di sistema" #: src/Widgets/Headerbar.vala:13 msgid "Monitor" -msgstr "Monitore" +msgstr "Monitor" #: src/Widgets/Headerbar.vala:20 msgid "End process" -msgstr "Terminare il processo" +msgstr "Terminare processo" #: src/Widgets/Headerbar.vala:23 msgid "Ctrl+E" @@ -55,9 +55,8 @@ msgid "Settings" msgstr "Preferenze" #: src/Widgets/Headerbar.vala:46 -#, fuzzy msgid "Show an indicator:" -msgstr "Mostra l'icona del pannello" +msgstr "Mostra icona nel pannello" #: src/Widgets/Headerbar.vala:52 msgid "Start in background:" From ddb8a39675df6f0ce79b9725de8e47b5087aaacc Mon Sep 17 00:00:00 2001 From: Ryo Nakano <26003928+ryonakano@users.noreply.github.com> Date: Fri, 18 Oct 2019 00:19:13 +0900 Subject: [PATCH 04/22] Show swap usage in the status bar --- meson.build | 1 + src/Resources/Swap.vala | 22 ++++++++++++++++++++++ src/Services/Updater.vala | 7 ++++++- src/Utils.vala | 3 +++ src/Widgets/Statusbar/Statusbar.vala | 19 +++++++++++++++++-- 5 files changed, 49 insertions(+), 3 deletions(-) create mode 100644 src/Resources/Swap.vala diff --git a/meson.build b/meson.build index a338a7f6..ddacb11b 100644 --- a/meson.build +++ b/meson.build @@ -64,6 +64,7 @@ executable( 'src/Resources/CPU.vala', 'src/Resources/Core.vala', 'src/Resources/Memory.vala', + 'src/Resources/Swap.vala', c_args: c_args, dependencies: [ glib, diff --git a/src/Resources/Swap.vala b/src/Resources/Swap.vala new file mode 100644 index 00000000..ead3e417 --- /dev/null +++ b/src/Resources/Swap.vala @@ -0,0 +1,22 @@ +public class Monitor.Swap : Object { + public double total { get; private set; default = 0; } + public double used { get; private set; default = 0; } + + private GTop.Swap swap; + + public int percentage { + get { + update (); + return (int) (Math.round ((used / total) * 100)); + } + } + + public Swap () { + } + + private void update () { + GTop.get_swap (out swap); + total = (double) (swap.total / 1024 / 1024) / 1000; + used = (double) (swap.used / 1024 / 1024) / 1000; + } +} diff --git a/src/Services/Updater.vala b/src/Services/Updater.vala index 103ecb87..01fcde90 100644 --- a/src/Services/Updater.vala +++ b/src/Services/Updater.vala @@ -10,6 +10,7 @@ namespace Monitor { private CPU cpu; private Memory memory; + private Swap swap; private Utils.SystemResources sysres; public signal void update (Utils.SystemResources sysres); @@ -17,6 +18,7 @@ namespace Monitor { construct { memory = new Memory (); cpu = new CPU (); + swap = new Swap (); Timeout.add_seconds (interval, update_resources); } @@ -26,7 +28,10 @@ namespace Monitor { cpu_percentage = cpu.percentage, memory_percentage = memory.percentage, memory_used = memory.used, - memory_total = memory.total + memory_total = memory.total, + swap_percentage = swap.percentage, + swap_used = swap.used, + swap_total = swap.total }; update (sysres); return true; diff --git a/src/Utils.vala b/src/Utils.vala index 16e107cc..dbf1939b 100644 --- a/src/Utils.vala +++ b/src/Utils.vala @@ -4,5 +4,8 @@ namespace Monitor.Utils { public int memory_percentage; public double memory_used; public double memory_total; + public int swap_percentage; + public double swap_used; + public double swap_total; } } diff --git a/src/Widgets/Statusbar/Statusbar.vala b/src/Widgets/Statusbar/Statusbar.vala index ce9be7d2..ced47944 100644 --- a/src/Widgets/Statusbar/Statusbar.vala +++ b/src/Widgets/Statusbar/Statusbar.vala @@ -1,6 +1,7 @@ public class Monitor.Statusbar : Gtk.ActionBar { Gtk.Label cpu_usage_label; Gtk.Label memory_usage_label; + Gtk.Label swap_usage_label; construct { var cpu_icon = new Gtk.Image.from_icon_name ("cpu-symbolic", Gtk.IconSize.SMALL_TOOLBAR); @@ -9,6 +10,9 @@ public class Monitor.Statusbar : Gtk.ActionBar { var ram_icon = new Gtk.Image.from_icon_name ("ram-symbolic", Gtk.IconSize.SMALL_TOOLBAR); ram_icon.tooltip_text = _ ("Memory"); + var swap_icon = new Gtk.Image.from_icon_name ("ram-symbolic", Gtk.IconSize.SMALL_TOOLBAR); + swap_icon.tooltip_text = _ ("Swap"); + cpu_usage_label = new Gtk.Label (_("Calculating…")); pack_start (cpu_icon); pack_start (cpu_usage_label); @@ -17,6 +21,11 @@ public class Monitor.Statusbar : Gtk.ActionBar { ram_icon.margin_start = 6; pack_start (ram_icon); pack_start (memory_usage_label); + + swap_usage_label = new Gtk.Label (_("Calculating…")); + swap_icon.margin_start = 6; + pack_start (swap_icon); + pack_start (swap_usage_label); } public Statusbar () { @@ -25,8 +34,14 @@ public class Monitor.Statusbar : Gtk.ActionBar { public bool update (Utils.SystemResources sysres) { cpu_usage_label.set_text (("%d%%").printf (sysres.cpu_percentage)); memory_usage_label.set_text (("%d%%").printf (sysres.memory_percentage)); - string tooltip_text = ("%.1f %s / %.1f %s").printf (sysres.memory_used, _ ("GiB"), sysres.memory_total, _ ("GiB")); - memory_usage_label.tooltip_text = tooltip_text; + swap_usage_label.set_text (("%d%%").printf (sysres.swap_percentage)); + + string memory_tooltip_text = ("%.1f %s / %.1f %s").printf (sysres.memory_used, _ ("GiB"), sysres.memory_total, _ ("GiB")); + memory_usage_label.tooltip_text = memory_tooltip_text; + + string swap_tooltip_text = ("%.1f %s / %.1f %s").printf (sysres.swap_used, _ ("GiB"), sysres.swap_total, _ ("GiB")); + swap_usage_label.tooltip_text = swap_tooltip_text; + return true; } } From 2b4b2149e5f654e59f2281e0a348dd2567ea16a9 Mon Sep 17 00:00:00 2001 From: Ryo Nakano <26003928+ryonakano@users.noreply.github.com> Date: Fri, 18 Oct 2019 00:20:07 +0900 Subject: [PATCH 05/22] Replace Granite.Services.Settings with GLib.Settings --- meson.build | 2 -- src/Indicator/Indicator.vala | 6 +++--- src/MainWindow.vala | 18 ++++++++---------- src/Monitor.vala | 13 +++++++++---- src/Services/Settings.vala | 25 ------------------------- src/Widgets/Headerbar.vala | 8 ++++---- 6 files changed, 24 insertions(+), 48 deletions(-) delete mode 100644 src/Services/Settings.vala diff --git a/meson.build b/meson.build index a338a7f6..9d747159 100644 --- a/meson.build +++ b/meson.build @@ -56,7 +56,6 @@ executable( 'src/Managers/ProcessManager.vala', 'src/Managers/Process.vala', - 'src/Services/Settings.vala', 'src/Services/Shortcuts.vala', 'src/Services/DBusServer.vala', 'src/Services/Updater.vala', @@ -96,7 +95,6 @@ shared_module( 'src/Indicator/Widgets/MemoryWidget.vala', 'src/Indicator/Services/DBusClient.vala', - 'src/Services/Settings.vala', # 'src/Widgets/RevealerSwitch.vala', icons_gresource, c_args: c_args, diff --git a/src/Indicator/Indicator.vala b/src/Indicator/Indicator.vala index 9f587c21..f104a40d 100644 --- a/src/Indicator/Indicator.vala +++ b/src/Indicator/Indicator.vala @@ -3,12 +3,12 @@ public class Monitor.Indicator : Wingpanel.Indicator { private Widgets.DisplayWidget? display_widget = null; private Widgets.PopoverWidget? popover_widget = null; - public Settings saved_state; + private Settings settings; private DBusClient dbusclient; construct { Gtk.IconTheme.get_default().add_resource_path("/com/github/stsdc/monitor/icons"); - saved_state = Settings.get_default (); + settings = new Settings ("com.github.stsdc.monitor.settings"); this.visible = false; display_widget = new Widgets.DisplayWidget (); popover_widget = new Widgets.PopoverWidget (); @@ -16,7 +16,7 @@ public class Monitor.Indicator : Wingpanel.Indicator { dbusclient = DBusClient.get_default (); dbusclient.monitor_vanished.connect (() => this.visible = false); - dbusclient.monitor_appeared.connect (() => this.visible = saved_state.indicator_state); + dbusclient.monitor_appeared.connect (() => this.visible = settings.get_boolean ("indicator-state")); dbusclient.interface.indicator_state.connect((state) => this.visible = state); diff --git a/src/MainWindow.vala b/src/MainWindow.vala index 8d034e5a..b9fd0891 100644 --- a/src/MainWindow.vala +++ b/src/MainWindow.vala @@ -1,6 +1,5 @@ public class Monitor.MainWindow : Gtk.Window { // application reference - public Settings saved_state; private Shortcuts shortcuts; // Widgets @@ -23,10 +22,9 @@ // Constructs a main window public MainWindow (MonitorApp app) { this.set_application (app); - saved_state = Settings.get_default (); - this.set_default_size (saved_state.window_width, saved_state.window_height); + this.set_default_size (MonitorApp.settings.get_int ("window-width"), MonitorApp.settings.get_int ("window-height")); - if (saved_state.is_maximized) { this.maximize (); } + if (MonitorApp.settings.get_boolean ("is-maximized")) { this.maximize (); } this.window_position = Gtk.WindowPosition.CENTER; @@ -68,7 +66,7 @@ updater.update.connect ((sysres) => { statusbar.update (sysres); dbusserver.update (sysres); - dbusserver.indicator_state (saved_state.indicator_state); + dbusserver.indicator_state (MonitorApp.settings.get_boolean ("indicator-state")); }); dbusserver.quit.connect (() => app.quit()); @@ -86,11 +84,11 @@ int window_width; int window_height; get_size (out window_width, out window_height); - saved_state.window_width = window_width; - saved_state.window_height = window_height; - saved_state.is_maximized = this.is_maximized; + MonitorApp.settings.set_int ("window-width", window_width); + MonitorApp.settings.set_int ("window-height", window_height); + MonitorApp.settings.set_boolean ("is-maximized", this.is_maximized); - if (saved_state.indicator_state == true) { + if (MonitorApp.settings.get_boolean ("indicator-state")) { this.hide_on_delete (); } else { dbusserver.indicator_state (false); @@ -99,6 +97,6 @@ return true; }); - dbusserver.indicator_state (saved_state.indicator_state); + dbusserver.indicator_state (MonitorApp.settings.get_boolean ("indicator-state")); } } diff --git a/src/Monitor.vala b/src/Monitor.vala index 01318fa4..64f72390 100644 --- a/src/Monitor.vala +++ b/src/Monitor.vala @@ -1,6 +1,7 @@ namespace Monitor { public class MonitorApp : Gtk.Application { + public static Settings settings; private MainWindow window = null; public string[] args; @@ -22,6 +23,10 @@ namespace Monitor { status_background = status_indicator; } + static construct { + settings = new Settings ("com.github.stsdc.monitor.settings"); + } + public override void activate () { // only have one window if (get_windows () != null) { @@ -33,13 +38,13 @@ namespace Monitor { window = new MainWindow (this); // start in background with indicator - if (status_background || window.saved_state.background_state) { - if (!window.saved_state.indicator_state) { - window.saved_state.indicator_state = true; + if (status_background || MonitorApp.settings.get_boolean ("background-state")) { + if (!MonitorApp.settings.get_boolean ("indicator-state")) { + MonitorApp.settings.set_boolean ("indicator-state", true); } window.hide (); - window.saved_state.background_state = true; + MonitorApp.settings.set_boolean ("background-state", true); } else { window.show_all (); } diff --git a/src/Services/Settings.vala b/src/Services/Settings.vala deleted file mode 100644 index e4f01bf7..00000000 --- a/src/Services/Settings.vala +++ /dev/null @@ -1,25 +0,0 @@ -namespace Monitor { - public class Settings : Granite.Services.Settings { - private static GLib.Once instance; - public static unowned Settings get_default () { - return instance.once (() => { return new Settings (); }); - } - - public int window_width { get; set; } - public int window_height { get; set; } - public bool is_maximized { get; set; } - - public bool indicator_state { get; set; } - - public bool background_state { get; set; } - - construct { - // Controls the direction of the sort indicators - Gtk.Settings.get_default ().set ("gtk-alternative-sort-arrows", true, null); - } - - private Settings () { - base ("com.github.stsdc.monitor.settings"); - } - } -} diff --git a/src/Widgets/Headerbar.vala b/src/Widgets/Headerbar.vala index c081c373..9204bffa 100644 --- a/src/Widgets/Headerbar.vala +++ b/src/Widgets/Headerbar.vala @@ -57,13 +57,13 @@ namespace Monitor { indicator_label.halign = Gtk.Align.END; show_indicator_switch = new Gtk.Switch (); - show_indicator_switch.state = window.saved_state.indicator_state; + show_indicator_switch.state = MonitorApp.settings.get_boolean ("indicator-state"); var background_label = new Gtk.Label (_("Start in background:")); background_label.halign = Gtk.Align.END; background_switch = new Gtk.Switch (); - background_switch.state = window.saved_state.background_state; + background_switch.state = MonitorApp.settings.get_boolean ("background-state"); set_background_switch_state (); preferences_grid.attach (indicator_label, 0, 0, 1, 1); @@ -78,12 +78,12 @@ namespace Monitor { pack_end (search); show_indicator_switch.notify["active"].connect (() => { - window.saved_state.indicator_state = show_indicator_switch.state; + MonitorApp.settings.set_boolean ("indicator-state", show_indicator_switch.state); window.dbusserver.indicator_state (show_indicator_switch.state); set_background_switch_state (); }); background_switch.notify["active"].connect (() => { - window.saved_state.background_state = background_switch.state; + MonitorApp.settings.set_boolean ("background-state", background_switch.state); set_background_switch_state (); }); } From c8a0c987174031cd0fecd0b8a8d7ac5e295267b8 Mon Sep 17 00:00:00 2001 From: stsdc Date: Thu, 17 Oct 2019 21:29:01 +0200 Subject: [PATCH 06/22] update translations --- po/POTFILES | 1 - po/com.github.stsdc.monitor.pot | 30 +++++++++++++++---------- po/de.po | 39 +++++++++++++++++++++++---------- po/es.po | 39 +++++++++++++++++++++++---------- po/fr.po | 39 +++++++++++++++++++++++---------- po/it.po | 39 +++++++++++++++++++++++---------- po/ja.po | 39 +++++++++++++++++++++++---------- po/lt.po | 39 +++++++++++++++++++++++---------- po/nl.po | 39 +++++++++++++++++++++++---------- po/pl.po | 36 ++++++++++++++++++++---------- po/pt.po | 39 +++++++++++++++++++++++---------- po/ru.po | 39 +++++++++++++++++++++++---------- po/uk.po | 34 ++++++++++++++++++---------- 13 files changed, 309 insertions(+), 143 deletions(-) diff --git a/po/POTFILES b/po/POTFILES index 1ab87137..1790b433 100644 --- a/po/POTFILES +++ b/po/POTFILES @@ -10,5 +10,4 @@ src/Managers/AppManager.vala src/Managers/ProcessManager.vala src/Managers/Process.vala src/Models/GenericModel.vala -src/Services/Settings.vala src/Services/Shortcuts.vala diff --git a/po/com.github.stsdc.monitor.pot b/po/com.github.stsdc.monitor.pot index efecd79a..fea498be 100644 --- a/po/com.github.stsdc.monitor.pot +++ b/po/com.github.stsdc.monitor.pot @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: com.github.stsdc.monitor\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-04-12 18:26+0200\n" +"POT-Creation-Date: 2019-10-17 21:21+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -36,27 +36,35 @@ msgstr "" msgid "Show system resources" msgstr "" -#: src/Widgets/Headerbar.vala:13 +#: src/Widgets/Headerbar.vala:15 msgid "Monitor" msgstr "" -#: src/Widgets/Headerbar.vala:20 -msgid "End process" +#: src/Widgets/Headerbar.vala:23 +msgid "End Process" msgstr "" -#: src/Widgets/Headerbar.vala:23 -msgid "Ctrl+E" +#: src/Widgets/Headerbar.vala:26 +msgid "End selected process" +msgstr "" + +#: src/Widgets/Headerbar.vala:30 +msgid "Kill Process" msgstr "" #: src/Widgets/Headerbar.vala:32 +msgid "Kill selected process" +msgstr "" + +#: src/Widgets/Headerbar.vala:42 msgid "Settings" msgstr "" -#: src/Widgets/Headerbar.vala:46 +#: src/Widgets/Headerbar.vala:56 msgid "Show an indicator:" msgstr "" -#: src/Widgets/Headerbar.vala:52 +#: src/Widgets/Headerbar.vala:62 msgid "Start in background:" msgstr "" @@ -89,12 +97,12 @@ msgstr "" msgid "GiB" msgstr "" -#: src/Widgets/Search.vala:9 +#: src/Widgets/Search.vala:14 msgid "Search Process" msgstr "" -#: src/Widgets/Search.vala:10 -msgid "Type Process Name or PID" +#: src/Widgets/Search.vala:15 +msgid "Type process name or PID to search" msgstr "" #: src/Widgets/Statusbar/Statusbar.vala:12 diff --git a/po/de.po b/po/de.po index 2cfc9016..50ca1e75 100644 --- a/po/de.po +++ b/po/de.po @@ -1,7 +1,7 @@ msgid "" msgstr "" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-04-12 18:26+0200\n" +"POT-Creation-Date: 2019-10-17 21:21+0200\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -24,27 +24,38 @@ msgstr "Monitor Indikator" msgid "Show system resources" msgstr "Zeige Systemressourcen an" -#: src/Widgets/Headerbar.vala:13 +#: src/Widgets/Headerbar.vala:15 msgid "Monitor" msgstr "Monitor" -#: src/Widgets/Headerbar.vala:20 -msgid "End process" +#: src/Widgets/Headerbar.vala:23 +#, fuzzy +msgid "End Process" msgstr "Prozess beenden" -#: src/Widgets/Headerbar.vala:23 -msgid "Ctrl+E" -msgstr "Strg+E" +#: src/Widgets/Headerbar.vala:26 +#, fuzzy +msgid "End selected process" +msgstr "Prozess beenden" + +#: src/Widgets/Headerbar.vala:30 +#, fuzzy +msgid "Kill Process" +msgstr "" #: src/Widgets/Headerbar.vala:32 +msgid "Kill selected process" +msgstr "" + +#: src/Widgets/Headerbar.vala:42 msgid "Settings" msgstr "Einstellungen" -#: src/Widgets/Headerbar.vala:46 +#: src/Widgets/Headerbar.vala:56 msgid "Show an indicator:" msgstr "Zeige einen Indikator:" -#: src/Widgets/Headerbar.vala:52 +#: src/Widgets/Headerbar.vala:62 msgid "Start in background:" msgstr "Im Hintergrund ausführen:" @@ -77,12 +88,13 @@ msgstr "MiB" msgid "GiB" msgstr "GiB" -#: src/Widgets/Search.vala:9 +#: src/Widgets/Search.vala:14 msgid "Search Process" msgstr "Suche Prozess" -#: src/Widgets/Search.vala:10 -msgid "Type Process Name or PID" +#: src/Widgets/Search.vala:15 +#, fuzzy +msgid "Type process name or PID to search" msgstr "Geben Sie den Prozessnamen oder PID ein" #: src/Widgets/Statusbar/Statusbar.vala:12 @@ -94,6 +106,9 @@ msgstr "Berechne…" msgid "Background Applications" msgstr "Hintergrundanwendungen" +#~ msgid "Ctrl+E" +#~ msgstr "Strg+E" + #~ msgid "CPU:" #~ msgstr "CPU:" diff --git a/po/es.po b/po/es.po index 28d22393..24795026 100644 --- a/po/es.po +++ b/po/es.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-04-12 18:26+0200\n" +"POT-Creation-Date: 2019-10-17 21:21+0200\n" "PO-Revision-Date: 2019-06-03 23:25+0100\n" "Last-Translator: Mario Rodrigo\n" "Language-Team: \n" @@ -38,28 +38,39 @@ msgstr "Icono de monitorización" msgid "Show system resources" msgstr "Mostrar recursos del sistema" -#: src/Widgets/Headerbar.vala:13 +#: src/Widgets/Headerbar.vala:15 msgid "Monitor" msgstr "Monitor" -#: src/Widgets/Headerbar.vala:20 -msgid "End process" +#: src/Widgets/Headerbar.vala:23 +#, fuzzy +msgid "End Process" msgstr "Terminar proceso" -#: src/Widgets/Headerbar.vala:23 -msgid "Ctrl+E" -msgstr "Ctrl+E" +#: src/Widgets/Headerbar.vala:26 +#, fuzzy +msgid "End selected process" +msgstr "Terminar proceso" + +#: src/Widgets/Headerbar.vala:30 +#, fuzzy +msgid "Kill Process" +msgstr "" #: src/Widgets/Headerbar.vala:32 +msgid "Kill selected process" +msgstr "" + +#: src/Widgets/Headerbar.vala:42 msgid "Settings" msgstr "Preferencias" -#: src/Widgets/Headerbar.vala:46 +#: src/Widgets/Headerbar.vala:56 #, fuzzy msgid "Show an indicator:" msgstr "Mostrar icone de panel" -#: src/Widgets/Headerbar.vala:52 +#: src/Widgets/Headerbar.vala:62 msgid "Start in background:" msgstr "Arrancar en segundo plano" @@ -92,12 +103,13 @@ msgstr "MiB" msgid "GiB" msgstr "GiB" -#: src/Widgets/Search.vala:9 +#: src/Widgets/Search.vala:14 msgid "Search Process" msgstr "Buscar proceso" -#: src/Widgets/Search.vala:10 -msgid "Type Process Name or PID" +#: src/Widgets/Search.vala:15 +#, fuzzy +msgid "Type process name or PID to search" msgstr "Introduce el nombre del proceso o el PID" #: src/Widgets/Statusbar/Statusbar.vala:12 @@ -109,6 +121,9 @@ msgstr "Calculando…" msgid "Background Applications" msgstr "Aplicaciones en segundo plano" +#~ msgid "Ctrl+E" +#~ msgstr "Ctrl+E" + #~ msgid "CPU:" #~ msgstr "CPU :" diff --git a/po/fr.po b/po/fr.po index 79c56958..7f246f9e 100644 --- a/po/fr.po +++ b/po/fr.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-04-12 18:26+0200\n" +"POT-Creation-Date: 2019-10-17 21:21+0200\n" "PO-Revision-Date: 2019-03-31 10:30+0200\n" "Last-Translator: Raí B. Toffoletto \n" "Language-Team: \n" @@ -38,28 +38,39 @@ msgstr "Icône du panneau" msgid "Show system resources" msgstr "Montrer ressources du système" -#: src/Widgets/Headerbar.vala:13 +#: src/Widgets/Headerbar.vala:15 msgid "Monitor" msgstr "Monitor" -#: src/Widgets/Headerbar.vala:20 -msgid "End process" +#: src/Widgets/Headerbar.vala:23 +#, fuzzy +msgid "End Process" msgstr "Terminer le processus" -#: src/Widgets/Headerbar.vala:23 -msgid "Ctrl+E" -msgstr "Ctrl+E" +#: src/Widgets/Headerbar.vala:26 +#, fuzzy +msgid "End selected process" +msgstr "Terminer le processus" + +#: src/Widgets/Headerbar.vala:30 +#, fuzzy +msgid "Kill Process" +msgstr "" #: src/Widgets/Headerbar.vala:32 +msgid "Kill selected process" +msgstr "" + +#: src/Widgets/Headerbar.vala:42 msgid "Settings" msgstr "Préférences" -#: src/Widgets/Headerbar.vala:46 +#: src/Widgets/Headerbar.vala:56 #, fuzzy msgid "Show an indicator:" msgstr "Montrer icône du panneau" -#: src/Widgets/Headerbar.vala:52 +#: src/Widgets/Headerbar.vala:62 msgid "Start in background:" msgstr "" @@ -92,12 +103,13 @@ msgstr "Mio" msgid "GiB" msgstr "Gio" -#: src/Widgets/Search.vala:9 +#: src/Widgets/Search.vala:14 msgid "Search Process" msgstr "Rechercher un processus" -#: src/Widgets/Search.vala:10 -msgid "Type Process Name or PID" +#: src/Widgets/Search.vala:15 +#, fuzzy +msgid "Type process name or PID to search" msgstr "Entrez le nom d'un processus ou un PID" #: src/Widgets/Statusbar/Statusbar.vala:12 @@ -109,6 +121,9 @@ msgstr "" msgid "Background Applications" msgstr "Applications en arrière-plan" +#~ msgid "Ctrl+E" +#~ msgstr "Ctrl+E" + #~ msgid "CPU:" #~ msgstr "CPU :" diff --git a/po/it.po b/po/it.po index a6f6ff11..096c4696 100644 --- a/po/it.po +++ b/po/it.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-04-12 18:26+0200\n" +"POT-Creation-Date: 2019-10-17 21:21+0200\n" "PO-Revision-Date: 2019-03-31 10:59+0200\n" "Last-Translator: Raí B. Toffoletto \n" "Language-Team: \n" @@ -38,27 +38,38 @@ msgstr "Icona nel pannello" msgid "Show system resources" msgstr "Mostra risorse di sistema" -#: src/Widgets/Headerbar.vala:13 +#: src/Widgets/Headerbar.vala:15 msgid "Monitor" msgstr "Monitor" -#: src/Widgets/Headerbar.vala:20 -msgid "End process" +#: src/Widgets/Headerbar.vala:23 +#, fuzzy +msgid "End Process" msgstr "Terminare processo" -#: src/Widgets/Headerbar.vala:23 -msgid "Ctrl+E" -msgstr "Ctrl+E" +#: src/Widgets/Headerbar.vala:26 +#, fuzzy +msgid "End selected process" +msgstr "Terminare processo" + +#: src/Widgets/Headerbar.vala:30 +#, fuzzy +msgid "Kill Process" +msgstr "" #: src/Widgets/Headerbar.vala:32 +msgid "Kill selected process" +msgstr "" + +#: src/Widgets/Headerbar.vala:42 msgid "Settings" msgstr "Preferenze" -#: src/Widgets/Headerbar.vala:46 +#: src/Widgets/Headerbar.vala:56 msgid "Show an indicator:" msgstr "Mostra icona nel pannello" -#: src/Widgets/Headerbar.vala:52 +#: src/Widgets/Headerbar.vala:62 msgid "Start in background:" msgstr "" @@ -91,12 +102,13 @@ msgstr "MiB" msgid "GiB" msgstr "GiB" -#: src/Widgets/Search.vala:9 +#: src/Widgets/Search.vala:14 msgid "Search Process" msgstr "Cerca un processo" -#: src/Widgets/Search.vala:10 -msgid "Type Process Name or PID" +#: src/Widgets/Search.vala:15 +#, fuzzy +msgid "Type process name or PID to search" msgstr "Digita il nome del processo o il PID" #: src/Widgets/Statusbar/Statusbar.vala:12 @@ -108,6 +120,9 @@ msgstr "" msgid "Background Applications" msgstr "Applicazioni in background" +#~ msgid "Ctrl+E" +#~ msgstr "Ctrl+E" + #~ msgid "CPU:" #~ msgstr "CPU :" diff --git a/po/ja.po b/po/ja.po index b578671d..6d96ca2a 100644 --- a/po/ja.po +++ b/po/ja.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: com.github.stsdc.monitor\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-04-12 18:26+0200\n" +"POT-Creation-Date: 2019-10-17 21:21+0200\n" "PO-Revision-Date: 2019-02-20 11:53+0900\n" "Last-Translator: Ryo Nakano \n" "Language-Team: none\n" @@ -37,28 +37,39 @@ msgstr "モニターインジケーター" msgid "Show system resources" msgstr "システムリソースを表示" -#: src/Widgets/Headerbar.vala:13 +#: src/Widgets/Headerbar.vala:15 msgid "Monitor" msgstr "モニター" -#: src/Widgets/Headerbar.vala:20 -msgid "End process" +#: src/Widgets/Headerbar.vala:23 +#, fuzzy +msgid "End Process" msgstr "プロセスを終了" -#: src/Widgets/Headerbar.vala:23 -msgid "Ctrl+E" -msgstr "Ctrl+E" +#: src/Widgets/Headerbar.vala:26 +#, fuzzy +msgid "End selected process" +msgstr "プロセスを終了" + +#: src/Widgets/Headerbar.vala:30 +#, fuzzy +msgid "Kill Process" +msgstr "" #: src/Widgets/Headerbar.vala:32 +msgid "Kill selected process" +msgstr "" + +#: src/Widgets/Headerbar.vala:42 msgid "Settings" msgstr "設定" -#: src/Widgets/Headerbar.vala:46 +#: src/Widgets/Headerbar.vala:56 #, fuzzy msgid "Show an indicator:" msgstr "インジケーターを表示" -#: src/Widgets/Headerbar.vala:52 +#: src/Widgets/Headerbar.vala:62 msgid "Start in background:" msgstr "" @@ -91,12 +102,13 @@ msgstr "MiB" msgid "GiB" msgstr "GiB" -#: src/Widgets/Search.vala:9 +#: src/Widgets/Search.vala:14 msgid "Search Process" msgstr "プロセスを検索" -#: src/Widgets/Search.vala:10 -msgid "Type Process Name or PID" +#: src/Widgets/Search.vala:15 +#, fuzzy +msgid "Type process name or PID to search" msgstr "プロセス名か PID を入力してください" #: src/Widgets/Statusbar/Statusbar.vala:12 @@ -107,3 +119,6 @@ msgstr "計算しています…" #: src/Models/GenericModel.vala:274 msgid "Background Applications" msgstr "バックグランドアプリケーション" + +#~ msgid "Ctrl+E" +#~ msgstr "Ctrl+E" diff --git a/po/lt.po b/po/lt.po index 27aa95b5..6efae524 100644 --- a/po/lt.po +++ b/po/lt.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-04-12 18:26+0200\n" +"POT-Creation-Date: 2019-10-17 21:21+0200\n" "PO-Revision-Date: 2017-09-07 11:24+0300\n" "Last-Translator: Moo\n" "Language-Team: \n" @@ -40,28 +40,39 @@ msgstr "" msgid "Show system resources" msgstr "" -#: src/Widgets/Headerbar.vala:13 +#: src/Widgets/Headerbar.vala:15 msgid "Monitor" msgstr "Monitor" -#: src/Widgets/Headerbar.vala:20 -msgid "End process" +#: src/Widgets/Headerbar.vala:23 +#, fuzzy +msgid "End Process" msgstr "Užbaigti procesą" -#: src/Widgets/Headerbar.vala:23 -msgid "Ctrl+E" -msgstr "Ctrl(Vald)+E" +#: src/Widgets/Headerbar.vala:26 +#, fuzzy +msgid "End selected process" +msgstr "Užbaigti procesą" + +#: src/Widgets/Headerbar.vala:30 +#, fuzzy +msgid "Kill Process" +msgstr "Ieškoti proceso" #: src/Widgets/Headerbar.vala:32 +msgid "Kill selected process" +msgstr "" + +#: src/Widgets/Headerbar.vala:42 msgid "Settings" msgstr "" -#: src/Widgets/Headerbar.vala:46 +#: src/Widgets/Headerbar.vala:56 #, fuzzy msgid "Show an indicator:" msgstr "Monitor" -#: src/Widgets/Headerbar.vala:52 +#: src/Widgets/Headerbar.vala:62 msgid "Start in background:" msgstr "" @@ -94,12 +105,13 @@ msgstr "MiB" msgid "GiB" msgstr "GiB" -#: src/Widgets/Search.vala:9 +#: src/Widgets/Search.vala:14 msgid "Search Process" msgstr "Ieškoti proceso" -#: src/Widgets/Search.vala:10 -msgid "Type Process Name or PID" +#: src/Widgets/Search.vala:15 +#, fuzzy +msgid "Type process name or PID to search" msgstr "Įrašykite proceso pavadinimą ar PID" #: src/Widgets/Statusbar/Statusbar.vala:12 @@ -111,6 +123,9 @@ msgstr "" msgid "Background Applications" msgstr "Foninės programos" +#~ msgid "Ctrl+E" +#~ msgstr "Ctrl(Vald)+E" + #~ msgid "CPU:" #~ msgstr "CPU:" diff --git a/po/nl.po b/po/nl.po index d2f5f986..9c39cd34 100644 --- a/po/nl.po +++ b/po/nl.po @@ -2,7 +2,7 @@ msgid "" msgstr "" "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-04-12 18:26+0200\n" +"POT-Creation-Date: 2019-10-17 21:21+0200\n" "PO-Revision-Date: 2019-03-25 17:22+0100\n" "Last-Translator: Heimen Stoffels \n" "Language-Team: \n" @@ -31,28 +31,39 @@ msgstr "Monitor-indicator" msgid "Show system resources" msgstr "Systeembronnen tonen" -#: src/Widgets/Headerbar.vala:13 +#: src/Widgets/Headerbar.vala:15 msgid "Monitor" msgstr "Monitor" -#: src/Widgets/Headerbar.vala:20 -msgid "End process" +#: src/Widgets/Headerbar.vala:23 +#, fuzzy +msgid "End Process" msgstr "Proces beëindigen" -#: src/Widgets/Headerbar.vala:23 -msgid "Ctrl+E" -msgstr "Ctrl+E" +#: src/Widgets/Headerbar.vala:26 +#, fuzzy +msgid "End selected process" +msgstr "Proces beëindigen" + +#: src/Widgets/Headerbar.vala:30 +#, fuzzy +msgid "Kill Process" +msgstr "" #: src/Widgets/Headerbar.vala:32 +msgid "Kill selected process" +msgstr "" + +#: src/Widgets/Headerbar.vala:42 msgid "Settings" msgstr "Instellingen" -#: src/Widgets/Headerbar.vala:46 +#: src/Widgets/Headerbar.vala:56 #, fuzzy msgid "Show an indicator:" msgstr "Indicator tonen" -#: src/Widgets/Headerbar.vala:52 +#: src/Widgets/Headerbar.vala:62 msgid "Start in background:" msgstr "" @@ -85,12 +96,13 @@ msgstr "MiB" msgid "GiB" msgstr "GiB" -#: src/Widgets/Search.vala:9 +#: src/Widgets/Search.vala:14 msgid "Search Process" msgstr "Zoek een proces" -#: src/Widgets/Search.vala:10 -msgid "Type Process Name or PID" +#: src/Widgets/Search.vala:15 +#, fuzzy +msgid "Type process name or PID to search" msgstr "Voer de procesnaam of PID in" #: src/Widgets/Statusbar/Statusbar.vala:12 @@ -102,6 +114,9 @@ msgstr "" msgid "Background Applications" msgstr "Achtergrondtoepassingen" +#~ msgid "Ctrl+E" +#~ msgstr "Ctrl+E" + #~ msgid "CPU:" #~ msgstr "Processor:" diff --git a/po/pl.po b/po/pl.po index 1362fd30..199b26bf 100644 --- a/po/pl.po +++ b/po/pl.po @@ -1,7 +1,7 @@ msgid "" msgstr "" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-04-12 18:26+0200\n" +"POT-Creation-Date: 2019-10-17 21:21+0200\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -24,28 +24,39 @@ msgstr "" msgid "Show system resources" msgstr "Pokaż zasoby systemu" -#: src/Widgets/Headerbar.vala:13 +#: src/Widgets/Headerbar.vala:15 msgid "Monitor" msgstr "" -#: src/Widgets/Headerbar.vala:20 -msgid "End process" +#: src/Widgets/Headerbar.vala:23 +#, fuzzy +msgid "End Process" msgstr "Zakończ proces" -#: src/Widgets/Headerbar.vala:23 -msgid "Ctrl+E" -msgstr "" +#: src/Widgets/Headerbar.vala:26 +#, fuzzy +msgid "End selected process" +msgstr "Zakończ wybrany proces" + +#: src/Widgets/Headerbar.vala:30 +#, fuzzy +msgid "Kill Process" +msgstr "Zabij proces" #: src/Widgets/Headerbar.vala:32 +msgid "Kill selected process" +msgstr "Zabij wybrany proces" + +#: src/Widgets/Headerbar.vala:42 msgid "Settings" msgstr "Ustawienia" -#: src/Widgets/Headerbar.vala:46 +#: src/Widgets/Headerbar.vala:56 #, fuzzy msgid "Show an indicator:" msgstr "Pokaż indykator" -#: src/Widgets/Headerbar.vala:52 +#: src/Widgets/Headerbar.vala:62 msgid "Start in background:" msgstr "Uruchamiaj w tle" @@ -78,12 +89,13 @@ msgstr "" msgid "GiB" msgstr "" -#: src/Widgets/Search.vala:9 +#: src/Widgets/Search.vala:14 msgid "Search Process" msgstr "Wyszukaj proces" -#: src/Widgets/Search.vala:10 -msgid "Type Process Name or PID" +#: src/Widgets/Search.vala:15 +#, fuzzy +msgid "Type process name or PID to search" msgstr "Wpisz nazwę procesu lub PID" #: src/Widgets/Statusbar/Statusbar.vala:12 diff --git a/po/pt.po b/po/pt.po index 18c611dd..f0026f64 100644 --- a/po/pt.po +++ b/po/pt.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-04-12 18:26+0200\n" +"POT-Creation-Date: 2019-10-17 21:21+0200\n" "PO-Revision-Date: 2019-03-31 10:19+0200\n" "Last-Translator: Raí B. Toffoletto \n" "Language-Team: \n" @@ -38,28 +38,39 @@ msgstr "Ícone do painel" msgid "Show system resources" msgstr "Mostrar recursos do sistema" -#: src/Widgets/Headerbar.vala:13 +#: src/Widgets/Headerbar.vala:15 msgid "Monitor" msgstr "Monitor" -#: src/Widgets/Headerbar.vala:20 -msgid "End process" +#: src/Widgets/Headerbar.vala:23 +#, fuzzy +msgid "End Process" msgstr "Terminar processo" -#: src/Widgets/Headerbar.vala:23 -msgid "Ctrl+E" -msgstr "Ctrl+E" +#: src/Widgets/Headerbar.vala:26 +#, fuzzy +msgid "End selected process" +msgstr "Terminar processo" + +#: src/Widgets/Headerbar.vala:30 +#, fuzzy +msgid "Kill Process" +msgstr "" #: src/Widgets/Headerbar.vala:32 +msgid "Kill selected process" +msgstr "" + +#: src/Widgets/Headerbar.vala:42 msgid "Settings" msgstr "Preferências" -#: src/Widgets/Headerbar.vala:46 +#: src/Widgets/Headerbar.vala:56 #, fuzzy msgid "Show an indicator:" msgstr "Mostrar ícone do painel" -#: src/Widgets/Headerbar.vala:52 +#: src/Widgets/Headerbar.vala:62 msgid "Start in background:" msgstr "" @@ -92,12 +103,13 @@ msgstr "MiB" msgid "GiB" msgstr "GiB" -#: src/Widgets/Search.vala:9 +#: src/Widgets/Search.vala:14 msgid "Search Process" msgstr "Buscar por um processo" -#: src/Widgets/Search.vala:10 -msgid "Type Process Name or PID" +#: src/Widgets/Search.vala:15 +#, fuzzy +msgid "Type process name or PID to search" msgstr "Digite o nome de um processo ou um PID" #: src/Widgets/Statusbar/Statusbar.vala:12 @@ -109,6 +121,9 @@ msgstr "" msgid "Background Applications" msgstr "Aplicações ativas em background" +#~ msgid "Ctrl+E" +#~ msgstr "Ctrl+E" + #~ msgid "CPU:" #~ msgstr "CPU :" diff --git a/po/ru.po b/po/ru.po index 9419c96c..53fdb6ac 100644 --- a/po/ru.po +++ b/po/ru.po @@ -2,7 +2,7 @@ msgid "" msgstr "" "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-04-12 18:26+0200\n" +"POT-Creation-Date: 2019-10-17 21:21+0200\n" "PO-Revision-Date: \n" "Last-Translator: Andrey Kultyapov \n" "Language-Team: \n" @@ -31,27 +31,38 @@ msgstr "Индикатор монитора" msgid "Show system resources" msgstr "Показывать системные ресурсы" -#: src/Widgets/Headerbar.vala:13 +#: src/Widgets/Headerbar.vala:15 msgid "Monitor" msgstr "Monitor" -#: src/Widgets/Headerbar.vala:20 -msgid "End process" +#: src/Widgets/Headerbar.vala:23 +#, fuzzy +msgid "End Process" msgstr "Завершить процесс" -#: src/Widgets/Headerbar.vala:23 -msgid "Ctrl+E" -msgstr "Ctrl+E" +#: src/Widgets/Headerbar.vala:26 +#, fuzzy +msgid "End selected process" +msgstr "Завершить процесс" + +#: src/Widgets/Headerbar.vala:30 +#, fuzzy +msgid "Kill Process" +msgstr "" #: src/Widgets/Headerbar.vala:32 +msgid "Kill selected process" +msgstr "" + +#: src/Widgets/Headerbar.vala:42 msgid "Settings" msgstr "Параметры" -#: src/Widgets/Headerbar.vala:46 +#: src/Widgets/Headerbar.vala:56 msgid "Show an indicator:" msgstr "Показывать индикатор:" -#: src/Widgets/Headerbar.vala:52 +#: src/Widgets/Headerbar.vala:62 msgid "Start in background:" msgstr "Запустить в фоновом режиме:" @@ -84,12 +95,13 @@ msgstr "МиБ" msgid "GiB" msgstr "ГиБ" -#: src/Widgets/Search.vala:9 +#: src/Widgets/Search.vala:14 msgid "Search Process" msgstr "Найти процесс" -#: src/Widgets/Search.vala:10 -msgid "Type Process Name or PID" +#: src/Widgets/Search.vala:15 +#, fuzzy +msgid "Type process name or PID to search" msgstr "Введите имя или ИД процесса" #: src/Widgets/Statusbar/Statusbar.vala:12 @@ -101,6 +113,9 @@ msgstr "Вычисление…" msgid "Background Applications" msgstr "Фоновые приложения" +#~ msgid "Ctrl+E" +#~ msgstr "Ctrl+E" + #~ msgid "CPU:" #~ msgstr "ЦПУ:" diff --git a/po/uk.po b/po/uk.po index d01ff288..61c1becd 100644 --- a/po/uk.po +++ b/po/uk.po @@ -1,7 +1,7 @@ msgid "" msgstr "" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-04-12 18:26+0200\n" +"POT-Creation-Date: 2019-10-17 21:21+0200\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -24,27 +24,38 @@ msgstr "" msgid "Show system resources" msgstr "" -#: src/Widgets/Headerbar.vala:13 +#: src/Widgets/Headerbar.vala:15 msgid "Monitor" msgstr "" -#: src/Widgets/Headerbar.vala:20 -msgid "End process" +#: src/Widgets/Headerbar.vala:23 +#, fuzzy +msgid "End Process" msgstr "Закінчити процес" -#: src/Widgets/Headerbar.vala:23 -msgid "Ctrl+E" +#: src/Widgets/Headerbar.vala:26 +#, fuzzy +msgid "End selected process" +msgstr "Закінчити процес" + +#: src/Widgets/Headerbar.vala:30 +#, fuzzy +msgid "Kill Process" msgstr "" #: src/Widgets/Headerbar.vala:32 +msgid "Kill selected process" +msgstr "" + +#: src/Widgets/Headerbar.vala:42 msgid "Settings" msgstr "" -#: src/Widgets/Headerbar.vala:46 +#: src/Widgets/Headerbar.vala:56 msgid "Show an indicator:" msgstr "" -#: src/Widgets/Headerbar.vala:52 +#: src/Widgets/Headerbar.vala:62 msgid "Start in background:" msgstr "" @@ -77,12 +88,13 @@ msgstr "МіБ" msgid "GiB" msgstr "ГіБ" -#: src/Widgets/Search.vala:9 +#: src/Widgets/Search.vala:14 msgid "Search Process" msgstr "Пошук процесу" -#: src/Widgets/Search.vala:10 -msgid "Type Process Name or PID" +#: src/Widgets/Search.vala:15 +#, fuzzy +msgid "Type process name or PID to search" msgstr "Введіть назву процесу або PID" #: src/Widgets/Statusbar/Statusbar.vala:12 From 88161f7fdb51e0107f370974f2fc5288457c6b75 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stanis=C5=82aw?= Date: Thu, 17 Oct 2019 21:35:07 +0200 Subject: [PATCH 07/22] Update README.md --- README.md | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index d8c808b0..b0f231bf 100644 --- a/README.md +++ b/README.md @@ -22,9 +22,9 @@ ![Monitor Screenshot](https://github.com/stsdc/monitor/raw/master/data/com.github.stsdc.monitor.screenshot.png) -## Building and Installation +## Development -You'll need the following dependencies to build: +### Install dependencies * valac * libgtk-3-dev @@ -36,7 +36,7 @@ You'll need the following dependencies to build: * libxml2-utils * meson -## How To Build +### Clone, Build & Install git clone https://github.com/stsdc/monitor cd monitor @@ -47,7 +47,9 @@ You'll need the following dependencies to build: ### Debug `G_MESSAGES_DEBUG=all ./com.github.stsdc.monitor` -## Arch Linux +## Other OSes + +### Arch Linux Arch Linux users can find Monitor under the name [pantheon-system-monitor-git](https://aur.archlinux.org/packages/pantheon-system-monitor-git/) in the **AUR**: From eba7a4ce69548766abbc151468f0f1eb9064cd4d Mon Sep 17 00:00:00 2001 From: stsdc Date: Thu, 17 Oct 2019 21:40:48 +0200 Subject: [PATCH 08/22] update polish translation --- po/pl.po | 8 -------- 1 file changed, 8 deletions(-) diff --git a/po/pl.po b/po/pl.po index 199b26bf..12e7fce8 100644 --- a/po/pl.po +++ b/po/pl.po @@ -29,17 +29,14 @@ msgid "Monitor" msgstr "" #: src/Widgets/Headerbar.vala:23 -#, fuzzy msgid "End Process" msgstr "Zakończ proces" #: src/Widgets/Headerbar.vala:26 -#, fuzzy msgid "End selected process" msgstr "Zakończ wybrany proces" #: src/Widgets/Headerbar.vala:30 -#, fuzzy msgid "Kill Process" msgstr "Zabij proces" @@ -52,7 +49,6 @@ msgid "Settings" msgstr "Ustawienia" #: src/Widgets/Headerbar.vala:56 -#, fuzzy msgid "Show an indicator:" msgstr "Pokaż indykator" @@ -94,7 +90,6 @@ msgid "Search Process" msgstr "Wyszukaj proces" #: src/Widgets/Search.vala:15 -#, fuzzy msgid "Type process name or PID to search" msgstr "Wpisz nazwę procesu lub PID" @@ -106,6 +101,3 @@ msgstr "Obliczam…" #: src/Models/GenericModel.vala:274 msgid "Background Applications" msgstr "Aplikacje w tle" - -#~ msgid "Memory:" -#~ msgstr "Pamięć:" From 5d9778270a95465e1f4ace072a2627cc328bfab5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stanis=C5=82aw?= Date: Sun, 20 Oct 2019 10:21:41 +0200 Subject: [PATCH 09/22] add swap symbolic icon --- data/icons/icons.indicator.gresource.xml | 1 + data/icons/swap-symbolic.svg | 132 +++++++++++++++++++++++ 2 files changed, 133 insertions(+) create mode 100644 data/icons/swap-symbolic.svg diff --git a/data/icons/icons.indicator.gresource.xml b/data/icons/icons.indicator.gresource.xml index 4a701104..981a39a9 100644 --- a/data/icons/icons.indicator.gresource.xml +++ b/data/icons/icons.indicator.gresource.xml @@ -3,5 +3,6 @@ cpu-symbolic.svg ram-symbolic.svg + swap-symbolic.svg \ No newline at end of file diff --git a/data/icons/swap-symbolic.svg b/data/icons/swap-symbolic.svg new file mode 100644 index 00000000..b7aede53 --- /dev/null +++ b/data/icons/swap-symbolic.svg @@ -0,0 +1,132 @@ + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + From 81baf1c0b944e913a7992fb6c44eb076ce03350c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stanis=C5=82aw?= Date: Sun, 20 Oct 2019 10:28:13 +0200 Subject: [PATCH 10/22] fix swap icon --- data/icons/swap-symbolic.svg | 48 ++++++++---------------------------- 1 file changed, 10 insertions(+), 38 deletions(-) diff --git a/data/icons/swap-symbolic.svg b/data/icons/swap-symbolic.svg index b7aede53..3c852f95 100644 --- a/data/icons/swap-symbolic.svg +++ b/data/icons/swap-symbolic.svg @@ -26,13 +26,16 @@ inkscape:window-height="837" id="namedview16" showgrid="true" - inkscape:zoom="16" - inkscape:cx="9.8493685" - inkscape:cy="6.8582195" + inkscape:zoom="32" + inkscape:cx="11.692243" + inkscape:cy="10.10425" inkscape:window-x="0" inkscape:window-y="30" inkscape:window-maximized="1" - inkscape:current-layer="g4564"> + inkscape:current-layer="g4564" + inkscape:snap-bbox="false" + inkscape:bbox-paths="false" + inkscape:bbox-nodes="true"> @@ -56,40 +59,9 @@ id="g4564"> - - - - - - + d="M 7 4 L 7 5 L 15 5 L 15 10 L 1 10 L 1 9 L 1 7 L 0 7 L 0 11 L 1 11 L 1 13 L 6 13 L 8 13 L 15 13 L 15 11 L 16 11 L 16 4 L 7 4 z M 2 11 L 3 11 L 3 12 L 2 12 L 2 11 z M 4 11 L 5 11 L 5 12 L 4 12 L 4 11 z M 6 11 L 8 11 L 8 12 L 6 12 L 6 11 z M 9 11 L 10 11 L 10 12 L 9 12 L 9 11 z M 11 11 L 12 11 L 12 12 L 11 12 L 11 11 z M 13 11 L 14 11 L 14 12 L 13 12 L 13 11 z " + transform="translate(126.96989,1)" + id="path19" /> Date: Sun, 20 Oct 2019 19:41:53 +0900 Subject: [PATCH 11/22] Use the newly added swap-symbolic icon --- src/Widgets/Statusbar/Statusbar.vala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Widgets/Statusbar/Statusbar.vala b/src/Widgets/Statusbar/Statusbar.vala index ced47944..c14d0587 100644 --- a/src/Widgets/Statusbar/Statusbar.vala +++ b/src/Widgets/Statusbar/Statusbar.vala @@ -10,7 +10,7 @@ public class Monitor.Statusbar : Gtk.ActionBar { var ram_icon = new Gtk.Image.from_icon_name ("ram-symbolic", Gtk.IconSize.SMALL_TOOLBAR); ram_icon.tooltip_text = _ ("Memory"); - var swap_icon = new Gtk.Image.from_icon_name ("ram-symbolic", Gtk.IconSize.SMALL_TOOLBAR); + var swap_icon = new Gtk.Image.from_icon_name ("swap-symbolic", Gtk.IconSize.SMALL_TOOLBAR); swap_icon.tooltip_text = _ ("Swap"); cpu_usage_label = new Gtk.Label (_("Calculating…")); From 0fb1ef6d65811b90f2f73ace2c9b7f84e117bb9c Mon Sep 17 00:00:00 2001 From: camellan Date: Sun, 20 Oct 2019 22:34:50 +0400 Subject: [PATCH 12/22] Update Russian translation --- po/ru.po | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/po/ru.po b/po/ru.po index 53fdb6ac..91bdbc69 100644 --- a/po/ru.po +++ b/po/ru.po @@ -10,7 +10,7 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 2.0.6\n" +"X-Generator: Poedit 2.2.3\n" #: src/Indicator/Widgets/PopoverWidget.vala:12 msgid "Show Monitor" @@ -36,23 +36,20 @@ msgid "Monitor" msgstr "Monitor" #: src/Widgets/Headerbar.vala:23 -#, fuzzy msgid "End Process" msgstr "Завершить процесс" #: src/Widgets/Headerbar.vala:26 -#, fuzzy msgid "End selected process" -msgstr "Завершить процесс" +msgstr "Завершает выбранные процессы" #: src/Widgets/Headerbar.vala:30 -#, fuzzy msgid "Kill Process" -msgstr "" +msgstr "Убить процесс" #: src/Widgets/Headerbar.vala:32 msgid "Kill selected process" -msgstr "" +msgstr "Убивает выбранные процессы" #: src/Widgets/Headerbar.vala:42 msgid "Settings" @@ -100,9 +97,8 @@ msgid "Search Process" msgstr "Найти процесс" #: src/Widgets/Search.vala:15 -#, fuzzy msgid "Type process name or PID to search" -msgstr "Введите имя или ИД процесса" +msgstr "Для поиска введите имя или ИД процесса" #: src/Widgets/Statusbar/Statusbar.vala:12 #: src/Widgets/Statusbar/Statusbar.vala:16 From b55263f04f2901f0732e96f093019d14e0cc8de3 Mon Sep 17 00:00:00 2001 From: Ryo Nakano <26003928+ryonakano@users.noreply.github.com> Date: Mon, 21 Oct 2019 07:54:13 +0900 Subject: [PATCH 13/22] Save and restore the window position --- data/com.github.stsdc.monitor.gschema.xml | 10 ++++++ src/MainWindow.vala | 41 ++++++++++++++--------- 2 files changed, 35 insertions(+), 16 deletions(-) diff --git a/data/com.github.stsdc.monitor.gschema.xml b/data/com.github.stsdc.monitor.gschema.xml index efd2bda4..b7f8c63b 100644 --- a/data/com.github.stsdc.monitor.gschema.xml +++ b/data/com.github.stsdc.monitor.gschema.xml @@ -20,6 +20,16 @@ Window height Window height + + -1 + Window X position + Window X position + + + -1 + Window Y position + Window Y position + false To show Monitor Indicator or not diff --git a/src/MainWindow.vala b/src/MainWindow.vala index b9fd0891..e8fb78c2 100644 --- a/src/MainWindow.vala +++ b/src/MainWindow.vala @@ -26,7 +26,14 @@ if (MonitorApp.settings.get_boolean ("is-maximized")) { this.maximize (); } - this.window_position = Gtk.WindowPosition.CENTER; + int position_x = MonitorApp.settings.get_int ("position-x"); + int position_y = MonitorApp.settings.get_int ("position-y"); + if (position_x == -1 || position_y == -1) { + // -1 is default value of these keys, which means this is the first launch + this.window_position = Gtk.WindowPosition.CENTER; + } else { + move (position_x, position_y); + } get_style_context ().add_class ("rounded"); @@ -79,22 +86,24 @@ shortcuts = new Shortcuts (this); key_press_event.connect ((e) => shortcuts.handle (e)); - // Maybe move it from here to Settings this.delete_event.connect (() => { - int window_width; - int window_height; - get_size (out window_width, out window_height); - MonitorApp.settings.set_int ("window-width", window_width); - MonitorApp.settings.set_int ("window-height", window_height); - MonitorApp.settings.set_boolean ("is-maximized", this.is_maximized); - - if (MonitorApp.settings.get_boolean ("indicator-state")) { - this.hide_on_delete (); - } else { - dbusserver.indicator_state (false); - app.quit (); - } - return true; + int window_width, window_height, x, y; + get_size (out window_width, out window_height); + get_position (out x, out y); + MonitorApp.settings.set_int ("window-width", window_width); + MonitorApp.settings.set_int ("window-height", window_height); + MonitorApp.settings.set_int ("position-x", x); + MonitorApp.settings.set_int ("position-y", y); + MonitorApp.settings.set_boolean ("is-maximized", this.is_maximized); + + if (MonitorApp.settings.get_boolean ("indicator-state")) { + this.hide_on_delete (); + } else { + dbusserver.indicator_state (false); + app.quit (); + } + + return true; }); dbusserver.indicator_state (MonitorApp.settings.get_boolean ("indicator-state")); From 5272c40a0617f7586dff61e43ab869b080cf7fea Mon Sep 17 00:00:00 2001 From: Ryo Nakano <26003928+ryonakano@users.noreply.github.com> Date: Mon, 21 Oct 2019 08:13:53 +0900 Subject: [PATCH 14/22] Fix the window positions is not restored when showing the window from the indicator menu --- src/MainWindow.vala | 28 +++++++++++++++++----------- 1 file changed, 17 insertions(+), 11 deletions(-) diff --git a/src/MainWindow.vala b/src/MainWindow.vala index e8fb78c2..63de931b 100644 --- a/src/MainWindow.vala +++ b/src/MainWindow.vala @@ -22,18 +22,8 @@ // Constructs a main window public MainWindow (MonitorApp app) { this.set_application (app); - this.set_default_size (MonitorApp.settings.get_int ("window-width"), MonitorApp.settings.get_int ("window-height")); - if (MonitorApp.settings.get_boolean ("is-maximized")) { this.maximize (); } - - int position_x = MonitorApp.settings.get_int ("position-x"); - int position_y = MonitorApp.settings.get_int ("position-y"); - if (position_x == -1 || position_y == -1) { - // -1 is default value of these keys, which means this is the first launch - this.window_position = Gtk.WindowPosition.CENTER; - } else { - move (position_x, position_y); - } + setup_window_state (); get_style_context ().add_class ("rounded"); @@ -80,6 +70,7 @@ dbusserver.show.connect (() => { this.deiconify(); this.present(); + setup_window_state (); this.show_all (); }); @@ -108,4 +99,19 @@ dbusserver.indicator_state (MonitorApp.settings.get_boolean ("indicator-state")); } + + private void setup_window_state () { + this.set_default_size (MonitorApp.settings.get_int ("window-width"), MonitorApp.settings.get_int ("window-height")); + + if (MonitorApp.settings.get_boolean ("is-maximized")) { this.maximize (); } + + int position_x = MonitorApp.settings.get_int ("position-x"); + int position_y = MonitorApp.settings.get_int ("position-y"); + if (position_x == -1 || position_y == -1) { + // -1 is default value of these keys, which means this is the first launch + this.window_position = Gtk.WindowPosition.CENTER; + } else { + move (position_x, position_y); + } + } } From 08e0b8abc28e8b1275c98674799509568d13baf6 Mon Sep 17 00:00:00 2001 From: Ryo Nakano <26003928+ryonakano@users.noreply.github.com> Date: Mon, 21 Oct 2019 08:16:39 +0900 Subject: [PATCH 15/22] Fix long line, no need to avoid variable name conflicts --- src/MainWindow.vala | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/MainWindow.vala b/src/MainWindow.vala index 63de931b..624f6c2b 100644 --- a/src/MainWindow.vala +++ b/src/MainWindow.vala @@ -78,13 +78,13 @@ key_press_event.connect ((e) => shortcuts.handle (e)); this.delete_event.connect (() => { - int window_width, window_height, x, y; + int window_width, window_height, position_x, position_y; get_size (out window_width, out window_height); - get_position (out x, out y); + get_position (out position_x, out position_y); MonitorApp.settings.set_int ("window-width", window_width); MonitorApp.settings.set_int ("window-height", window_height); - MonitorApp.settings.set_int ("position-x", x); - MonitorApp.settings.set_int ("position-y", y); + MonitorApp.settings.set_int ("position-x", position_x); + MonitorApp.settings.set_int ("position-y", position_y); MonitorApp.settings.set_boolean ("is-maximized", this.is_maximized); if (MonitorApp.settings.get_boolean ("indicator-state")) { @@ -101,7 +101,9 @@ } private void setup_window_state () { - this.set_default_size (MonitorApp.settings.get_int ("window-width"), MonitorApp.settings.get_int ("window-height")); + int window_width = MonitorApp.settings.get_int ("window-width"); + int window_height = MonitorApp.settings.get_int ("window-height"); + this.set_default_size (window_width, window_height); if (MonitorApp.settings.get_boolean ("is-maximized")) { this.maximize (); } From 43bf6b1683f3140362bc4b424e0a318e4ae3568c Mon Sep 17 00:00:00 2001 From: Ryo Nakano <26003928+ryonakano@users.noreply.github.com> Date: Tue, 22 Oct 2019 00:10:22 +0900 Subject: [PATCH 16/22] Update Japanese translation --- po/ja.po | 37 +++++++++++++++++++------------------ 1 file changed, 19 insertions(+), 18 deletions(-) diff --git a/po/ja.po b/po/ja.po index 6d96ca2a..2e66913a 100644 --- a/po/ja.po +++ b/po/ja.po @@ -7,8 +7,8 @@ msgid "" msgstr "" "Project-Id-Version: com.github.stsdc.monitor\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-10-17 21:21+0200\n" -"PO-Revision-Date: 2019-02-20 11:53+0900\n" +"POT-Creation-Date: 2019-10-22 00:03+0900\n" +"PO-Revision-Date: 2019-10-22 00:09+0900\n" "Last-Translator: Ryo Nakano \n" "Language-Team: none\n" "Language: ja\n" @@ -16,7 +16,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=1; plural=0;\n" -"X-Generator: Poedit 2.2.1\n" +"X-Generator: Poedit 2.2.4\n" #: src/Indicator/Widgets/PopoverWidget.vala:12 msgid "Show Monitor" @@ -42,47 +42,43 @@ msgid "Monitor" msgstr "モニター" #: src/Widgets/Headerbar.vala:23 -#, fuzzy msgid "End Process" msgstr "プロセスを終了" #: src/Widgets/Headerbar.vala:26 -#, fuzzy msgid "End selected process" -msgstr "プロセスを終了" +msgstr "選択したプロセスを終了します" #: src/Widgets/Headerbar.vala:30 -#, fuzzy msgid "Kill Process" -msgstr "" +msgstr "プロセスを強制終了" #: src/Widgets/Headerbar.vala:32 msgid "Kill selected process" -msgstr "" +msgstr "選択したプロセスを強制終了します" #: src/Widgets/Headerbar.vala:42 msgid "Settings" msgstr "設定" #: src/Widgets/Headerbar.vala:56 -#, fuzzy msgid "Show an indicator:" -msgstr "インジケーターを表示" +msgstr "インジケーターを表示:" #: src/Widgets/Headerbar.vala:62 msgid "Start in background:" -msgstr "" +msgstr "バックグラウンドで起動:" #. setup name column #: src/Widgets/OverallView.vala:21 msgid "Process Name" msgstr "プロセス名" -#: src/Widgets/OverallView.vala:42 src/Widgets/Statusbar/Statusbar.vala:7 +#: src/Widgets/OverallView.vala:42 src/Widgets/Statusbar/Statusbar.vala:8 msgid "CPU" msgstr "CPU" -#: src/Widgets/OverallView.vala:53 src/Widgets/Statusbar/Statusbar.vala:10 +#: src/Widgets/OverallView.vala:53 src/Widgets/Statusbar/Statusbar.vala:11 msgid "Memory" msgstr "メモリー" @@ -98,7 +94,8 @@ msgstr "KiB" msgid "MiB" msgstr "MiB" -#: src/Widgets/OverallView.vala:118 src/Widgets/Statusbar/Statusbar.vala:28 +#: src/Widgets/OverallView.vala:118 src/Widgets/Statusbar/Statusbar.vala:39 +#: src/Widgets/Statusbar/Statusbar.vala:42 msgid "GiB" msgstr "GiB" @@ -107,12 +104,16 @@ msgid "Search Process" msgstr "プロセスを検索" #: src/Widgets/Search.vala:15 -#, fuzzy msgid "Type process name or PID to search" -msgstr "プロセス名か PID を入力してください" +msgstr "検索するにはプロセス名か PID を入力してください" + +#: src/Widgets/Statusbar/Statusbar.vala:14 +msgid "Swap" +msgstr "スワップ" -#: src/Widgets/Statusbar/Statusbar.vala:12 #: src/Widgets/Statusbar/Statusbar.vala:16 +#: src/Widgets/Statusbar/Statusbar.vala:20 +#: src/Widgets/Statusbar/Statusbar.vala:25 msgid "Calculating…" msgstr "計算しています…" From fe88b084696bc0364ae82d6891252939cef3ec37 Mon Sep 17 00:00:00 2001 From: Ryo Nakano <26003928+ryonakano@users.noreply.github.com> Date: Tue, 22 Oct 2019 00:19:44 +0900 Subject: [PATCH 17/22] Fix warnings --- src/Indicator/Indicator.vala | 31 +++++++++--------------- src/Indicator/Services/DBusClient.vala | 4 +-- src/Indicator/Widgets/DisplayWidget.vala | 4 --- src/Indicator/Widgets/PopoverWidget.vala | 10 +++++--- src/Widgets/OverallView.vala | 9 +++++-- 5 files changed, 27 insertions(+), 31 deletions(-) diff --git a/src/Indicator/Indicator.vala b/src/Indicator/Indicator.vala index f104a40d..2af66860 100644 --- a/src/Indicator/Indicator.vala +++ b/src/Indicator/Indicator.vala @@ -26,13 +26,21 @@ public class Monitor.Indicator : Wingpanel.Indicator { }); popover_widget.quit_monitor.connect (() => { - dbusclient.interface.quit_monitor (); - this.visible = false; + try { + dbusclient.interface.quit_monitor (); + this.visible = false; + } catch (Error e) { + warning (e.message); + } }); popover_widget.show_monitor.connect (() => { - close (); - dbusclient.interface.show_monitor (); + try { + close (); + dbusclient.interface.show_monitor (); + } catch (Error e) { + warning (e.message); + } }); } @@ -64,15 +72,6 @@ public class Monitor.Indicator : Wingpanel.Indicator { public override void closed () { } - /* Method to connect the signals */ - private void connect_signals () { - /* Connect to the click signal of the hide button */ - // hide_button.clicked.connect (hide_me); - - /* Connect to the switch signal of the compositing switch */ - // compositing_switch.switched.connect (update_compositing); - } - /* Method to hide the indicator for a short time */ // private void hide_me () { // /* Hide the indicator */ @@ -87,12 +86,6 @@ public class Monitor.Indicator : Wingpanel.Indicator { // return false; // }); // } - - /* Method to check the status of the compositing switch and update the indicator */ - private void update_compositing () { - /* If the switch is enabled set the icon name of the icon that should be drawn on top of the other one, if not hide the top icon. */ - // display_widget.set_overlay_icon_name (compositing_switch.get_active () ? "nm-vpn-active-lock" : ""); - } } /* diff --git a/src/Indicator/Services/DBusClient.vala b/src/Indicator/Services/DBusClient.vala index f87528c1..dd5f6c7d 100644 --- a/src/Indicator/Services/DBusClient.vala +++ b/src/Indicator/Services/DBusClient.vala @@ -1,7 +1,7 @@ [DBus (name = "com.github.stsdc.monitor")] public interface Monitor.DBusClientInterface : Object { - public abstract void quit_monitor () throws IOError; - public abstract void show_monitor () throws IOError; + public abstract void quit_monitor () throws Error; + public abstract void show_monitor () throws Error; public signal void update (Utils.SystemResources data); public signal void indicator_state (bool state); } diff --git a/src/Indicator/Widgets/DisplayWidget.vala b/src/Indicator/Widgets/DisplayWidget.vala index e4fa3539..c4cdac67 100644 --- a/src/Indicator/Widgets/DisplayWidget.vala +++ b/src/Indicator/Widgets/DisplayWidget.vala @@ -1,7 +1,4 @@ public class Monitor.Widgets.DisplayWidget : Gtk.Grid { - private Gtk.Revealer percent_revealer; - private bool allow_percent = false; - public CPUWidget cpu_widget; public MemoryWidget memory_widget; @@ -14,6 +11,5 @@ public class Monitor.Widgets.DisplayWidget : Gtk.Grid { add (cpu_widget); add (memory_widget); - } } diff --git a/src/Indicator/Widgets/PopoverWidget.vala b/src/Indicator/Widgets/PopoverWidget.vala index 2d8399e2..96133ac8 100644 --- a/src/Indicator/Widgets/PopoverWidget.vala +++ b/src/Indicator/Widgets/PopoverWidget.vala @@ -1,7 +1,7 @@ public class Monitor.Widgets.PopoverWidget : Gtk.Grid { /* Button to hide the indicator */ - private Wingpanel.Widgets.Button show_monitor_button; - private Wingpanel.Widgets.Button quit_monitor_button; + private Gtk.ModelButton show_monitor_button; + private Gtk.ModelButton quit_monitor_button; public signal void quit_monitor (); public signal void show_monitor (); @@ -9,8 +9,10 @@ public class Monitor.Widgets.PopoverWidget : Gtk.Grid { construct { orientation = Gtk.Orientation.VERTICAL; - show_monitor_button = new Wingpanel.Widgets.Button (_("Show Monitor")); - quit_monitor_button = new Wingpanel.Widgets.Button (_("Quit Monitor")); + show_monitor_button = new Gtk.ModelButton (); + show_monitor_button.text = _("Show Monitor"); + quit_monitor_button = new Gtk.ModelButton (); + quit_monitor_button.text = _("Quit Monitor"); show_monitor_button.clicked.connect (() => show_monitor ()); quit_monitor_button.clicked.connect (() => quit_monitor ()); diff --git a/src/Widgets/OverallView.vala b/src/Widgets/OverallView.vala index 6e8f60f2..75ced365 100644 --- a/src/Widgets/OverallView.vala +++ b/src/Widgets/OverallView.vala @@ -79,8 +79,13 @@ namespace Monitor { model.get_value (iter, Column.ICON, out icon_name); if (regex.match ((string) icon_name)) { string path = ((string) icon_name); - Gdk.Pixbuf icon = new Gdk.Pixbuf.from_file_at_size (path, 16, -1); - (icon_cell as Gtk.CellRendererPixbuf).pixbuf = icon; + + try { + Gdk.Pixbuf icon = new Gdk.Pixbuf.from_file_at_size (path, 16, -1); + (icon_cell as Gtk.CellRendererPixbuf).pixbuf = icon; + } catch (Error e) { + warning (e.message); + } } else { (icon_cell as Gtk.CellRendererPixbuf).icon_name = (string) icon_name; } From 8b35d7fd2f0e9caffaa98840381758ca32b25337 Mon Sep 17 00:00:00 2001 From: Ryo Nakano <26003928+ryonakano@users.noreply.github.com> Date: Thu, 24 Oct 2019 23:04:50 +0900 Subject: [PATCH 18/22] Fix margins of Indicator popover --- src/Indicator/Widgets/PopoverWidget.vala | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Indicator/Widgets/PopoverWidget.vala b/src/Indicator/Widgets/PopoverWidget.vala index 96133ac8..79ad10e8 100644 --- a/src/Indicator/Widgets/PopoverWidget.vala +++ b/src/Indicator/Widgets/PopoverWidget.vala @@ -11,8 +11,10 @@ public class Monitor.Widgets.PopoverWidget : Gtk.Grid { show_monitor_button = new Gtk.ModelButton (); show_monitor_button.text = _("Show Monitor"); + show_monitor_button.hexpand = true; quit_monitor_button = new Gtk.ModelButton (); quit_monitor_button.text = _("Quit Monitor"); + quit_monitor_button.hexpand = true; show_monitor_button.clicked.connect (() => show_monitor ()); quit_monitor_button.clicked.connect (() => quit_monitor ()); From 8853d6108c8e014350fb99775309c72f97fa6f67 Mon Sep 17 00:00:00 2001 From: Ryo Nakano <26003928+ryonakano@users.noreply.github.com> Date: Thu, 24 Oct 2019 23:14:49 +0900 Subject: [PATCH 19/22] Update coding style of Indicator widgets --- src/Indicator/Widgets/CPUWidget.vala | 16 ++++++---------- src/Indicator/Widgets/MemoryWidget.vala | 23 ++++++----------------- 2 files changed, 12 insertions(+), 27 deletions(-) diff --git a/src/Indicator/Widgets/CPUWidget.vala b/src/Indicator/Widgets/CPUWidget.vala index 30daf7ad..ef8ee105 100644 --- a/src/Indicator/Widgets/CPUWidget.vala +++ b/src/Indicator/Widgets/CPUWidget.vala @@ -1,25 +1,21 @@ public class Monitor.Widgets.CPUWidget : Gtk.Box { private Gtk.Label percentage_label; - private Gtk.Label cpu_indicator_text; - string cpu_text; + public int percentage { - set { percentage_label.set_label ("%i%%".printf (value)); } + set { percentage_label.label = "%i%%".printf (value); } + } + + public CPUWidget () { + Object (orientation: Gtk.Orientation.HORIZONTAL); } construct { var icon = new Gtk.Image.from_icon_name ("cpu-symbolic", Gtk.IconSize.SMALL_TOOLBAR); - cpu_text = _("cpu"); - cpu_indicator_text = new Gtk.Label (cpu_text); percentage_label = new Gtk.Label ("N/A"); percentage_label.margin = 1; pack_start (icon); - // pack_start (cpu_indicator_text); pack_start (percentage_label); } - - public CPUWidget () { - orientation = Gtk.Orientation.HORIZONTAL; - } } diff --git a/src/Indicator/Widgets/MemoryWidget.vala b/src/Indicator/Widgets/MemoryWidget.vala index 9c953caa..dfe48359 100644 --- a/src/Indicator/Widgets/MemoryWidget.vala +++ b/src/Indicator/Widgets/MemoryWidget.vala @@ -1,32 +1,21 @@ public class Monitor.Widgets.MemoryWidget : Gtk.Box { private Gtk.Label percentage_label; - private Gtk.Label mem_indicator_text; - private string mem_text; public int percentage { - set { percentage_label.set_label ("%i%%".printf (value)); } + set { percentage_label.label = "%i%%".printf (value); } } - construct { - // image = new Gtk.Image (); - // image.icon_name = "phone-symbolic"; - // image.pixel_size = 16; - var icon = new Gtk.Image.from_icon_name ("ram-symbolic", Gtk.IconSize.SMALL_TOOLBAR); + public MemoryWidget () { + Object (orientation: Gtk.Orientation.HORIZONTAL); + } - mem_text = _("mem"); - mem_indicator_text = new Gtk.Label (mem_text); + construct { + var icon = new Gtk.Image.from_icon_name ("ram-symbolic", Gtk.IconSize.SMALL_TOOLBAR); percentage_label = new Gtk.Label ("N/A"); percentage_label.margin = 2; pack_start (icon); - // pack_start (mem_indicator_text); pack_start (percentage_label); - } - - public MemoryWidget () { - orientation = Gtk.Orientation.HORIZONTAL; - } - } From 76055fc4a391c7330139f725a2345c2930008247 Mon Sep 17 00:00:00 2001 From: Ryo Nakano <26003928+ryonakano@users.noreply.github.com> Date: Thu, 24 Oct 2019 23:19:24 +0900 Subject: [PATCH 20/22] Unify CPUWidget.vala and MemoryWidget.vala --- meson.build | 3 +-- src/Indicator/Widgets/CPUWidget.vala | 21 ------------------ src/Indicator/Widgets/DisplayWidget.vala | 8 +++---- src/Indicator/Widgets/IndicatorWidget.vala | 25 ++++++++++++++++++++++ src/Indicator/Widgets/MemoryWidget.vala | 21 ------------------ 5 files changed, 30 insertions(+), 48 deletions(-) delete mode 100644 src/Indicator/Widgets/CPUWidget.vala create mode 100644 src/Indicator/Widgets/IndicatorWidget.vala delete mode 100644 src/Indicator/Widgets/MemoryWidget.vala diff --git a/meson.build b/meson.build index f5e68a8c..c8d85f7c 100644 --- a/meson.build +++ b/meson.build @@ -92,8 +92,7 @@ shared_module( 'src/Indicator/Widgets/DisplayWidget.vala', 'src/Indicator/Widgets/PopoverWidget.vala', - 'src/Indicator/Widgets/CPUWidget.vala', - 'src/Indicator/Widgets/MemoryWidget.vala', + 'src/Indicator/Widgets/IndicatorWidget.vala', 'src/Indicator/Services/DBusClient.vala', # 'src/Widgets/RevealerSwitch.vala', diff --git a/src/Indicator/Widgets/CPUWidget.vala b/src/Indicator/Widgets/CPUWidget.vala deleted file mode 100644 index ef8ee105..00000000 --- a/src/Indicator/Widgets/CPUWidget.vala +++ /dev/null @@ -1,21 +0,0 @@ -public class Monitor.Widgets.CPUWidget : Gtk.Box { - private Gtk.Label percentage_label; - - public int percentage { - set { percentage_label.label = "%i%%".printf (value); } - } - - public CPUWidget () { - Object (orientation: Gtk.Orientation.HORIZONTAL); - } - - construct { - var icon = new Gtk.Image.from_icon_name ("cpu-symbolic", Gtk.IconSize.SMALL_TOOLBAR); - - percentage_label = new Gtk.Label ("N/A"); - percentage_label.margin = 1; - - pack_start (icon); - pack_start (percentage_label); - } -} diff --git a/src/Indicator/Widgets/DisplayWidget.vala b/src/Indicator/Widgets/DisplayWidget.vala index c4cdac67..d43351b0 100644 --- a/src/Indicator/Widgets/DisplayWidget.vala +++ b/src/Indicator/Widgets/DisplayWidget.vala @@ -1,13 +1,13 @@ public class Monitor.Widgets.DisplayWidget : Gtk.Grid { - public CPUWidget cpu_widget; - public MemoryWidget memory_widget; + public IndicatorWidget cpu_widget; + public IndicatorWidget memory_widget; construct { valign = Gtk.Align.CENTER; - cpu_widget = new CPUWidget (); + cpu_widget = new IndicatorWidget ("cpu-symbolic"); - memory_widget = new MemoryWidget (); + memory_widget = new IndicatorWidget ("ram-symbolic"); add (cpu_widget); add (memory_widget); diff --git a/src/Indicator/Widgets/IndicatorWidget.vala b/src/Indicator/Widgets/IndicatorWidget.vala new file mode 100644 index 00000000..d6cb1ceb --- /dev/null +++ b/src/Indicator/Widgets/IndicatorWidget.vala @@ -0,0 +1,25 @@ +public class Monitor.Widgets.IndicatorWidget : Gtk.Box { + private Gtk.Label percentage_label; + + public string icon_name { get; construct; } + public int percentage { + set { percentage_label.label = "%i%%".printf (value); } + } + + public IndicatorWidget (string icon_name) { + Object ( + orientation: Gtk.Orientation.HORIZONTAL, + icon_name: icon_name + ); + } + + construct { + var icon = new Gtk.Image.from_icon_name (icon_name, Gtk.IconSize.SMALL_TOOLBAR); + + percentage_label = new Gtk.Label ("N/A"); + percentage_label.margin = 2; + + pack_start (icon); + pack_start (percentage_label); + } +} diff --git a/src/Indicator/Widgets/MemoryWidget.vala b/src/Indicator/Widgets/MemoryWidget.vala deleted file mode 100644 index dfe48359..00000000 --- a/src/Indicator/Widgets/MemoryWidget.vala +++ /dev/null @@ -1,21 +0,0 @@ -public class Monitor.Widgets.MemoryWidget : Gtk.Box { - private Gtk.Label percentage_label; - - public int percentage { - set { percentage_label.label = "%i%%".printf (value); } - } - - public MemoryWidget () { - Object (orientation: Gtk.Orientation.HORIZONTAL); - } - - construct { - var icon = new Gtk.Image.from_icon_name ("ram-symbolic", Gtk.IconSize.SMALL_TOOLBAR); - - percentage_label = new Gtk.Label ("N/A"); - percentage_label.margin = 2; - - pack_start (icon); - pack_start (percentage_label); - } -} From 80b6355a72188ec035ad6366a7d61dafbe60062e Mon Sep 17 00:00:00 2001 From: Christopher Crouse Date: Sat, 26 Oct 2019 19:45:29 +0200 Subject: [PATCH 21/22] Meson Build Fix --- meson.build | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/meson.build b/meson.build index c8d85f7c..cd3dc3b4 100644 --- a/meson.build +++ b/meson.build @@ -106,8 +106,8 @@ shared_module( wingpanel ], install: true, - # install_dir : wingpanel.get_pkgconfig_variable('indicatorsdir'), <- installs to /usr/local/ - install_dir : '/usr/lib/x86_64-linux-gnu/wingpanel/' + install_dir : wingpanel.get_pkgconfig_variable('indicatorsdir'), + # install_dir : '/usr/lib/x86_64-linux-gnu/wingpanel/' ) From a1e7689782142413cbdbe690abf819648482d5bd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stanis=C5=82aw?= Date: Tue, 29 Oct 2019 17:51:30 +0100 Subject: [PATCH 22/22] bump version & add update changelog --- data/com.github.stsdc.monitor.appdata.xml.in | 16 ++++++---------- debian/changelog | 10 ++++++++++ meson.build | 2 +- 3 files changed, 17 insertions(+), 11 deletions(-) diff --git a/data/com.github.stsdc.monitor.appdata.xml.in b/data/com.github.stsdc.monitor.appdata.xml.in index 8f7b5d18..7bc584d6 100644 --- a/data/com.github.stsdc.monitor.appdata.xml.in +++ b/data/com.github.stsdc.monitor.appdata.xml.in @@ -25,18 +25,14 @@ https://github.com/stsdc/monitor/issues - +
    -
  • Fix contents of the window are not shown (Ryo Nakano)
  • -
  • Fix no row is still selected when indicator options are enabled (Ryo Nakano)
  • -
  • Fix the app crashes by clicking the "End/Kill Process" buttons when no process is selected (Ryo Nakano)
  • -
  • Added buttons to either "kill" or "end" a process. (Evan Buss)
  • -
  • Change screenshot to English (Christopher Crouse)
  • -
  • Update Russian translation (camellan)
  • -
  • Check if the default display is a X11 display (Hannes Schulze)
  • -
  • Update German translation (J0Ar)
  • -
  • Update Spanish translation (Mario Rodrigo)
  • +
  • Update Italian translation (Mirko Brombin)
  • +
  • Show swap usage (Ryo Nakano)
  • +
  • Update Russian translation (camellan)
  • +
  • Code refactoring (Ryo Nakano)
  • +
  • Update Japanese translation (Ryo Nakano)
diff --git a/debian/changelog b/debian/changelog index 7263de09..4dbc6996 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,13 @@ +com.github.stsdc.monitor (0.6.0) bionic; urgency=low + + * Update Italian translation (Mirko Brombin) + * Show swap usage (Ryo Nakano) + * Update Russian translation (camellan) + * Code refactoring (Ryo Nakano) + * Update Japanese translation (Ryo Nakano) + +-- Stanisław Dac Tue, 29 Oct 2019 17:48:02 +0100 + com.github.stsdc.monitor (0.5.0) bionic; urgency=low * Fix contents of the window are not shown (Ryo Nakano) diff --git a/meson.build b/meson.build index cd3dc3b4..744d73bf 100644 --- a/meson.build +++ b/meson.build @@ -1,5 +1,5 @@ -project('com.github.stsdc.monitor', 'vala', 'c', version: '0.5.0') +project('com.github.stsdc.monitor', 'vala', 'c', version: '0.6.0') # these are Meson modules gnome = import('gnome')