Stuff navigator.platform into Scholar.platform
This commit is contained in:
parent
6ad69b3a13
commit
50a50a67ac
1 changed files with 6 additions and 0 deletions
|
@ -38,6 +38,7 @@ var Scholar = new function(){
|
||||||
|
|
||||||
// Public properties
|
// Public properties
|
||||||
this.version;
|
this.version;
|
||||||
|
this.platform;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Initialize the extension
|
* Initialize the extension
|
||||||
|
@ -68,6 +69,11 @@ var Scholar = new function(){
|
||||||
this.version
|
this.version
|
||||||
= gExtensionManager.getItemForID(SCHOLAR_CONFIG['GUID']).version;
|
= gExtensionManager.getItemForID(SCHOLAR_CONFIG['GUID']).version;
|
||||||
|
|
||||||
|
// OS platform
|
||||||
|
var win = Components.classes["@mozilla.org/appshell/appShellService;1"]
|
||||||
|
.getService(Components.interfaces.nsIAppShellService)
|
||||||
|
.hiddenDOMWindow;
|
||||||
|
this.platform = win.navigator.platform;
|
||||||
|
|
||||||
// Load in the localization stringbundle for use by getString(name)
|
// Load in the localization stringbundle for use by getString(name)
|
||||||
var src = 'chrome://scholar/locale/scholar.properties';
|
var src = 'chrome://scholar/locale/scholar.properties';
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue