Bug 1356569 - Remove some more newURI null trailing parameters, rs=Fallen.
This commit is contained in:
Родитель
ed8679f38d
Коммит
26250d7902
|
@ -18,7 +18,7 @@
|
|||
var ios = Cc["@mozilla.org/network/io-service;1"].getService(Ci.nsIIOService);
|
||||
Components.classes["@mozilla.org/uriloader/external-protocol-service;1"]
|
||||
.getService(Ci.nsIExternalProtocolService)
|
||||
.loadURI(ios.newURI(url, null, null), window);
|
||||
.loadURI(ios.newURI(url), window);
|
||||
}
|
||||
]]></script>
|
||||
</window>
|
||||
|
|
|
@ -166,7 +166,7 @@
|
|||
getService(Components.interfaces.nsIIOService);
|
||||
Components.classes["@mozilla.org/uriloader/external-protocol-service;1"]
|
||||
.getService(Components.interfaces.nsIExternalProtocolService)
|
||||
.loadURI(ioService.newURI(aEvent.target.href, null, null));
|
||||
.loadURI(ioService.newURI(aEvent.target.href));
|
||||
}
|
||||
|
||||
]]>
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
function onAccept() {
|
||||
// If it's a file, convert to a data URL.
|
||||
if (gBackgroundImage && /^file:/i.test(gBackgroundImage)) {
|
||||
let nsFile = Services.io.newURI(gBackgroundImage, null, null)
|
||||
let nsFile = Services.io.newURI(gBackgroundImage)
|
||||
.QueryInterface(Components.interfaces.nsIFileURL).file;
|
||||
if (nsFile.exists()) {
|
||||
let reader = new FileReader();
|
||||
|
|
|
@ -38,7 +38,7 @@ function isAccel (event) { return isOSX && event.metaKey || event.ctrlKey; }
|
|||
function getLocalStorage(page) {
|
||||
var url = "chrome://content/messenger/accountProvisionerStorage/" + page;
|
||||
|
||||
var uri = Services.io.newURI(url, "");
|
||||
var uri = Services.io.newURI(url);
|
||||
var principal = Services.scriptSecurityManager.createCodebasePrincipal(uri, {});
|
||||
return Services.domStorageManager.createStorage(null, principal, url);
|
||||
}
|
||||
|
|
|
@ -1206,7 +1206,7 @@ function test_search_button_disabled_if_no_query_on_init() {
|
|||
let url = "chrome://content/messenger/accountProvisionerStorage/accountProvisioner";
|
||||
let dsm = Services.domStorageManager;
|
||||
|
||||
let uri = Services.io.newURI(url, "");
|
||||
let uri = Services.io.newURI(url);
|
||||
let principal = Services.scriptSecurityManager.createCodebasePrincipal(uri, {});
|
||||
let storage = dsm.createStorage(null, principal, url);
|
||||
|
||||
|
|
|
@ -118,7 +118,7 @@
|
|||
}
|
||||
|
||||
function GenerateDataURL(url) {
|
||||
var file = Services.io.newURI(url, null, null)
|
||||
var file = Services.io.newURI(url)
|
||||
.QueryInterface(Components.interfaces.nsIFileURL).file;
|
||||
var contentType = Components.classes["@mozilla.org/mime;1"]
|
||||
.getService(Components.interfaces.nsIMIMEService)
|
||||
|
|
|
@ -37,7 +37,7 @@ function run_test() {
|
|||
do_check_eq(pH.allowPort(i, ""), (i == protocols[part].defaultPort));
|
||||
|
||||
// Check we get a URI when we ask for one
|
||||
var uri = pH.newURI(protocols[part].urlSpec, "");
|
||||
var uri = pH.newURI(protocols[part].urlSpec);
|
||||
|
||||
uri.QueryInterface(Ci.nsISmtpUrl);
|
||||
|
||||
|
|
|
@ -45,7 +45,7 @@ function run_test() {
|
|||
do_check_true(pH.allowPort(i, ""));
|
||||
|
||||
// Check we get a URI when we ask for one
|
||||
var uri = pH.newURI(protocols[part].urlSpec, "");
|
||||
var uri = pH.newURI(protocols[part].urlSpec);
|
||||
|
||||
uri.QueryInterface(Ci.nsIImapUrl);
|
||||
|
||||
|
|
|
@ -36,7 +36,7 @@ function run_test()
|
|||
do_check_eq(pH.allowPort(i, ""), false);
|
||||
|
||||
// Check we get a URI when we ask for one
|
||||
var uri = pH.newURI(protocols[part].urlSpec, "");
|
||||
var uri = pH.newURI(protocols[part].urlSpec);
|
||||
|
||||
uri.QueryInterface(Ci.nsIMailboxUrl);
|
||||
|
||||
|
|
|
@ -41,7 +41,7 @@ function run_test() {
|
|||
do_check_true(pH.allowPort(i, ""));
|
||||
|
||||
// Check we get a URI when we ask for one
|
||||
var uri = pH.newURI(protocols[part].urlSpec, "");
|
||||
var uri = pH.newURI(protocols[part].urlSpec);
|
||||
|
||||
uri.QueryInterface(Ci.nsINntpUrl);
|
||||
|
||||
|
|
|
@ -56,7 +56,7 @@ function progressAsyncStartup(aList) {
|
|||
var fSource = document.getElementById("fileSource");
|
||||
fName.label = gDownload.displayName;
|
||||
fName.tooltipText = gDownload.target.path;
|
||||
var uri = Services.io.newURI(gDownload.source.url, null, null);
|
||||
var uri = Services.io.newURI(gDownload.source.url);
|
||||
var fromString;
|
||||
try {
|
||||
fromString = uri.host;
|
||||
|
|
|
@ -180,7 +180,7 @@ function test()
|
|||
var ios = Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsIIOService);
|
||||
return (aObj instanceof Components.interfaces.nsIFile) ? ios.newFileURI(aObj) :
|
||||
ios.newURI(aObj, null, null);
|
||||
ios.newURI(aObj);
|
||||
}
|
||||
|
||||
const nsIWBP = Components.interfaces.nsIWebBrowserPersist;
|
||||
|
|
|
@ -203,7 +203,7 @@ function test_properDownloadData(aWin)
|
|||
is(view.getCellText(i, colState), stateString,
|
||||
"Download states match up");
|
||||
|
||||
var filePath = ioSvc.newURI(DownloadData[i].target, null, null)
|
||||
var filePath = ioSvc.newURI(DownloadData[i].target)
|
||||
.QueryInterface(Components.interfaces.nsIFileURL)
|
||||
.file.clone()
|
||||
.QueryInterface(Components.interfaces.nsIFile)
|
||||
|
|
|
@ -127,7 +127,7 @@ function test()
|
|||
var ios = Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsIIOService);
|
||||
return (aObj instanceof Components.interfaces.nsIFile) ? ios.newFileURI(aObj) :
|
||||
ios.newURI(aObj, null, null);
|
||||
ios.newURI(aObj);
|
||||
}
|
||||
|
||||
const nsIWBP = Components.interfaces.nsIWebBrowserPersist;
|
||||
|
|
|
@ -147,7 +147,7 @@ function test()
|
|||
var ios = Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsIIOService);
|
||||
return (aObj instanceof Components.interfaces.nsIFile) ? ios.newFileURI(aObj) :
|
||||
ios.newURI(aObj, null, null);
|
||||
ios.newURI(aObj);
|
||||
}
|
||||
|
||||
const nsIWBP = Components.interfaces.nsIWebBrowserPersist;
|
||||
|
|
|
@ -147,7 +147,7 @@ function test()
|
|||
var ios = Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsIIOService);
|
||||
return (aObj instanceof Components.interfaces.nsIFile) ? ios.newFileURI(aObj) :
|
||||
ios.newURI(aObj, null, null);
|
||||
ios.newURI(aObj);
|
||||
}
|
||||
|
||||
const nsIWBP = Components.interfaces.nsIWebBrowserPersist;
|
||||
|
|
|
@ -125,7 +125,7 @@ function test()
|
|||
var ios = Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsIIOService);
|
||||
return (aObj instanceof Components.interfaces.nsIFile) ? ios.newFileURI(aObj) :
|
||||
ios.newURI(aObj, null, null);
|
||||
ios.newURI(aObj);
|
||||
}
|
||||
|
||||
const nsIWBP = Components.interfaces.nsIWebBrowserPersist;
|
||||
|
|
|
@ -52,7 +52,7 @@
|
|||
var ios = Cc["@mozilla.org/network/io-service;1"].
|
||||
getService(Ci.nsIIOService);
|
||||
function uri(spec) {
|
||||
return ios.newURI(spec, null, null);
|
||||
return ios.newURI(spec);
|
||||
}
|
||||
|
||||
// Add a bookmark.
|
||||
|
|
|
@ -49,7 +49,7 @@
|
|||
var ios = Cc["@mozilla.org/network/io-service;1"].
|
||||
getService(Ci.nsIIOService);
|
||||
function uri(spec) {
|
||||
return ios.newURI(spec, null, null);
|
||||
return ios.newURI(spec);
|
||||
}
|
||||
|
||||
var testURI = uri("http://www.mozilla.org/");
|
||||
|
|
|
@ -59,11 +59,11 @@
|
|||
let vtime = Date.now() * 1000;
|
||||
const ttype = PlacesUtils.history.TRANSITION_TYPED;
|
||||
let places =
|
||||
[{ uri: Services.io.newURI("http://example.tld/", null, null),
|
||||
[{ uri: Services.io.newURI("http://example.tld/"),
|
||||
visitDate: ++vtime, transition: ttype },
|
||||
{ uri: Services.io.newURI("http://example2.tld/", null, null),
|
||||
{ uri: Services.io.newURI("http://example2.tld/"),
|
||||
visitDate: ++vtime, transition: ttype },
|
||||
{ uri: Services.io.newURI("http://example3.tld/", null, null),
|
||||
{ uri: Services.io.newURI("http://example3.tld/"),
|
||||
visitDate: ++vtime, transition: ttype }];
|
||||
|
||||
addVisits(places, function() {
|
||||
|
|
|
@ -58,7 +58,7 @@
|
|||
|
||||
function continue_test() {
|
||||
addVisits(
|
||||
{uri: Services.io.newURI("http://example.tld/", null, null),
|
||||
{uri: Services.io.newURI("http://example.tld/"),
|
||||
visitDate: Date.now() * 1000,
|
||||
transition: PlacesUtils.history.TRANSITION_TYPED},
|
||||
function() {
|
||||
|
|
|
@ -73,7 +73,7 @@
|
|||
var iosvc = Cc["@mozilla.org/network/io-service;1"].
|
||||
getService(Ci.nsIIOService);
|
||||
function uri(spec) {
|
||||
return iosvc.newURI(spec, null, null);
|
||||
return iosvc.newURI(spec);
|
||||
}
|
||||
|
||||
var midnight = new Date();
|
||||
|
|
Загрузка…
Ссылка в новой задаче