Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: lib/appIntegration.js

Issue 8487012: Slightly improved notification for fennec (Closed)
Patch Set: Created Oct. 1, 2012, 4:15 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/appIntegration.js
===================================================================
--- a/lib/appIntegration.js
+++ b/lib/appIntegration.js
@@ -271,11 +271,19 @@
{
if ("BrowserApp" in window && "selectedTab" in window.BrowserApp)
{
- window.NativeWindow.doorhanger.show(message, id, buttons, window.BrowserApp.selectedTab.id,
+ let tabId = window.BrowserApp.selectedTab.id;
+ window.NativeWindow.doorhanger.show(message, id, buttons, tabId,
{
- persistence: persistence
+ // No navigation is happening after doorhanger is shown
+ // so persistence needs to be reduced by one
+ persistence: persistence-1
}
);
+ let surveyTimer = Cc["@mozilla.org/timer;1"].createInstance(Ci.nsITimer);
+ surveyTimer.initWithCallback(function()
+ {
+ window.NativeWindow.doorhanger.hide(id, tabId);
+ }, 5000, Ci.nsITimer.TYPE_ONE_SHOT);
Wladimir Palant 2012/10/01 20:36:33 https://developer.mozilla.org/en-US/docs/Extension
}
};
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld