[Pkg-mozext-commits] [firegestures] 04/13: fix #118: 'Restart Firefox' command dosen't work on Nightly47.0a1
David Prévot
taffit at moszumanska.debian.org
Thu Feb 4 02:06:13 UTC 2016
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository firegestures.
commit e0d963fd9cb1de0b5c8d08ae0d9ce20856835499
Author: Gomita <gomita at xuldev.org>
Date: Sun Jan 31 18:46:14 2016 +0900
fix #118: 'Restart Firefox' command dosen't work on Nightly47.0a1
---
chrome/content/firegestures/browser.js | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/chrome/content/firegestures/browser.js b/chrome/content/firegestures/browser.js
index bb4416b..a92ab9e 100644
--- a/chrome/content/firegestures/browser.js
+++ b/chrome/content/firegestures/browser.js
@@ -504,7 +504,14 @@ var FireGestures = {
gFindBar.hidden ? gFindBar.onFindCommand() : gFindBar.close();
break;
case "FireGestures:RestartApp":
- Application.restart();
+ let cancelQuit = Cc["@mozilla.org/supports-PRBool;1"].
+ createInstance(Ci.nsISupportsPRBool);
+ Services.obs.notifyObservers(cancelQuit, "quit-application-requested", "restart");
+ if (cancelQuit.data)
+ return;
+ let appStartup = Cc["@mozilla.org/toolkit/app-startup;1"].
+ getService(Ci.nsIAppStartup);
+ appStartup.quit(Ci.nsIAppStartup.eAttemptQuit | Ci.nsIAppStartup.eRestart);
break;
case "FireGestures:Preferences":
this._gestureMapping.configure();
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/firegestures.git
More information about the Pkg-mozext-commits
mailing list