зеркало из https://github.com/mozilla/gecko-dev.git
Bug 825527 - Part 1: Look through an Xray wrapper at our images in tests so that we always see the QueryInterface method on them; r=bzbarsky
This commit is contained in:
Родитель
e2bc56a552
Коммит
87bbd55993
|
@ -36,7 +36,7 @@ function getImageStatus(id)
|
|||
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
|
||||
|
||||
// Get the image
|
||||
var img = document.getElementById(id);
|
||||
var img = SpecialPowers.wrap(document.getElementById(id));
|
||||
|
||||
// QI the image to nsImageLoadingContent
|
||||
img.QueryInterface(SpecialPowers.Ci.nsIImageLoadingContent);
|
||||
|
|
|
@ -22,7 +22,7 @@ SimpleTest.waitForExplicitFinish();
|
|||
|
||||
window.onload = function() {
|
||||
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
|
||||
var img = document.getElementsByTagName("img")[0];
|
||||
var img = SpecialPowers.wrap(document.getElementsByTagName("img")[0]);
|
||||
var container = img
|
||||
.QueryInterface(Components.interfaces.nsIImageLoadingContent)
|
||||
.getRequest(Components.interfaces.nsIImageLoadingContent.CURRENT_REQUEST)
|
||||
|
|
Загрузка…
Ссылка в новой задаче