зеркало из https://github.com/mozilla/pjs.git
fixes bug 166792 "move nsIIOService::GetURLSpecFromFile, etc. to
nsIFileProtocolHandler" r=dougt sr=alecf
This commit is contained in:
Родитель
56d915d263
Коммит
8280b6c4c3
|
@ -183,7 +183,8 @@
|
|||
fileLocator = fileLocator.QueryInterface(Components.interfaces.nsIProperties);
|
||||
var file = fileLocator.get(mimeTypes, Components.interfaces.nsIFile);
|
||||
var ioService = Components.classes["@mozilla.org/network/io-service;1"].getService(Components.interfaces.nsIIOService);
|
||||
gDS = gRDF.GetDataSource(ioService.getURLSpecFromFile(file));
|
||||
var fileHandler = ioService.getProtocolHandler("file").QueryInterface(Components.interfaces.nsIFileProtocolHandler);
|
||||
gDS = gRDF.GetDataSource(fileHandler.getURLSpecFromFile(file));
|
||||
}
|
||||
|
||||
function onAccept()
|
||||
|
|
|
@ -89,8 +89,9 @@ function Startup()
|
|||
var file = fileLocator.get(mimeTypes, Components.interfaces.nsIFile);
|
||||
|
||||
var ioService = Components.classes["@mozilla.org/network/io-service;1"].getService(Components.interfaces.nsIIOService);
|
||||
dump("spec is " + ioService.getURLSpecFromFile(file));
|
||||
gDS = gRDF.GetDataSource(ioService.getURLSpecFromFile(file));
|
||||
var fileHandler = ioService.getProtocolHandler("file").QueryInterface(Components.interfaces.nsIFileProtocolHandler);
|
||||
dump("spec is " + fileHandler.getURLSpecFromFile(file));
|
||||
gDS = gRDF.GetDataSource(fileHandler.getURLSpecFromFile(file));
|
||||
|
||||
// intialize the listbox
|
||||
gList.database.AddDataSource(gDS);
|
||||
|
|
Загрузка…
Ссылка в новой задаче