[gnome-boxes] app: Suspend machines on your own
- From: Zeeshan Ali Khattak <zeeshanak src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-boxes] app: Suspend machines on your own
- Date: Mon, 24 Feb 2014 19:39:45 +0000 (UTC)
commit 2386af907548e21d1accdbc43277626ff46a3fbe
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date: Mon Feb 24 19:38:32 2014 +0000
app: Suspend machines on your own
No need for another module to have to explicitly ask App to suspend
machines, it should do so in its _shutdown implementation.
src/app.vala | 3 ++-
src/main.vala | 2 --
2 files changed, 2 insertions(+), 3 deletions(-)
---
diff --git a/src/app.vala b/src/app.vala
index 156202a..9e20d73 100644
--- a/src/app.vala
+++ b/src/app.vala
@@ -319,6 +319,7 @@ private class Boxes.App: Gtk.Application, Boxes.UI {
notificationbar.cancel ();
wizard.cleanup ();
+ suspend_machines ();
}
public void open_name (string name) {
@@ -652,7 +653,7 @@ private class Boxes.App: Gtk.Application, Boxes.UI {
current_item.set_state (ui_state);
}
- public void suspend_machines () {
+ private void suspend_machines () {
// if we are not the main Boxes instance, 'collection' won't
// be set as it's created in GtkApplication::startup()
if (collection == null)
diff --git a/src/main.vala b/src/main.vala
index 66a4ec0..5c5d242 100644
--- a/src/main.vala
+++ b/src/main.vala
@@ -83,7 +83,5 @@ public int main (string[] args) {
var exit_status = app.run (args);
- app.suspend_machines ();
-
return exit_status;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]