commit
b6ec11c81e
@ -33,10 +33,8 @@
|
||||
*
|
||||
* ***** END LICENSE BLOCK ******/
|
||||
|
||||
const IOService = Components.classes['@mozilla.org/network/io-service;1']
|
||||
.getService(Components.interfaces.nsIIOService);
|
||||
|
||||
Components.utils.import('resource://gre/modules/XPCOMUtils.jsm');
|
||||
Components.utils.import('resource://gre/modules/Services.jsm');
|
||||
|
||||
function AboutGroup()
|
||||
{
|
||||
@ -49,7 +47,7 @@ AboutGroup.prototype = {
|
||||
|
||||
newChannel : function(aURI)
|
||||
{
|
||||
return IOService.newChannel('chrome://treestyletab/content/group.xul', null, null);
|
||||
return Services.io.newChannel('chrome://treestyletab/content/group.xul', null, null);
|
||||
},
|
||||
|
||||
getURIFlags : function(aURI)
|
||||
|
@ -48,7 +48,6 @@ const SSS = Cc['@mozilla.org/content/style-sheet-service;1']
|
||||
.getService(Ci.nsIStyleSheetService);
|
||||
const SecMan = Cc['@mozilla.org/scriptsecuritymanager;1']
|
||||
.getService(Ci.nsIScriptSecurityManager);
|
||||
const IOService = Services.io;
|
||||
|
||||
function TabbarDNDObserver(aTabBrowser)
|
||||
{
|
||||
@ -1151,7 +1150,7 @@ catch(e) {
|
||||
.split('\n')[0]];
|
||||
|
||||
case 'application/x-moz-file':
|
||||
let fileHandler = IOService.getProtocolHandler('file')
|
||||
let fileHandler = Services.io.getProtocolHandler('file')
|
||||
.QueryInterface(Ci.nsIFileProtocolHandler);
|
||||
return [fileHandler.getURLSpecFromFile(aData)];
|
||||
}
|
||||
|
@ -276,14 +276,6 @@ var TreeStyleTabUtils = {
|
||||
},
|
||||
_SessionStore : null,
|
||||
|
||||
get IOService() {
|
||||
if (!this._IOService) {
|
||||
this._IOService = Services.io;
|
||||
}
|
||||
return this._IOService;
|
||||
},
|
||||
_IOService : null,
|
||||
|
||||
get WindowMediator() {
|
||||
if (!this._WindowMediator) {
|
||||
this._WindowMediator = Services.wm;
|
||||
@ -1141,13 +1133,13 @@ var TreeStyleTabUtils = {
|
||||
var newURI;
|
||||
aURI = aURI || '';
|
||||
if (aURI && String(aURI).indexOf('file:') == 0) {
|
||||
var fileHandler = this.IOService.getProtocolHandler('file').QueryInterface(Ci.nsIFileProtocolHandler);
|
||||
var fileHandler = Services.io.getProtocolHandler('file').QueryInterface(Ci.nsIFileProtocolHandler);
|
||||
var tempLocalFile = fileHandler.getFileFromURLSpec(aURI);
|
||||
newURI = this.IOService.newFileURI(tempLocalFile);
|
||||
newURI = Services.io.newFileURI(tempLocalFile);
|
||||
}
|
||||
else {
|
||||
if (!/^\w+\:/.test(aURI)) aURI = 'http://'+aURI;
|
||||
newURI = this.IOService.newURI(aURI, null, null);
|
||||
newURI = Services.io.newURI(aURI, null, null);
|
||||
}
|
||||
return newURI;
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user