зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1564449, ensure the right body element is used throughout the method call, r=mccr8
This commit is contained in:
Родитель
8307db6f25
Коммит
2c99c9a038
|
@ -657,7 +657,7 @@ nsresult ImageDocument::CreateSyntheticDocument() {
|
||||||
NS_ENSURE_SUCCESS(rv, rv);
|
NS_ENSURE_SUCCESS(rv, rv);
|
||||||
|
|
||||||
// Add the image element
|
// Add the image element
|
||||||
Element* body = GetBodyElement();
|
RefPtr<Element> body = GetBodyElement();
|
||||||
if (!body) {
|
if (!body) {
|
||||||
NS_WARNING("no body on image document!");
|
NS_WARNING("no body on image document!");
|
||||||
return NS_ERROR_FAILURE;
|
return NS_ERROR_FAILURE;
|
||||||
|
|
|
@ -190,7 +190,7 @@ nsresult PluginDocument::CreateSyntheticPluginDocument() {
|
||||||
NS_ENSURE_SUCCESS(rv, rv);
|
NS_ENSURE_SUCCESS(rv, rv);
|
||||||
// then attach our plugin
|
// then attach our plugin
|
||||||
|
|
||||||
Element* body = GetBodyElement();
|
RefPtr<Element> body = GetBodyElement();
|
||||||
if (!body) {
|
if (!body) {
|
||||||
NS_WARNING("no body on plugin document!");
|
NS_WARNING("no body on plugin document!");
|
||||||
return NS_ERROR_FAILURE;
|
return NS_ERROR_FAILURE;
|
||||||
|
|
|
@ -102,7 +102,7 @@ void VideoDocument::SetScriptGlobalObject(
|
||||||
}
|
}
|
||||||
|
|
||||||
nsresult VideoDocument::CreateVideoElement() {
|
nsresult VideoDocument::CreateVideoElement() {
|
||||||
Element* body = GetBodyElement();
|
RefPtr<Element> body = GetBodyElement();
|
||||||
if (!body) {
|
if (!body) {
|
||||||
NS_WARNING("no body on video document!");
|
NS_WARNING("no body on video document!");
|
||||||
return NS_ERROR_FAILURE;
|
return NS_ERROR_FAILURE;
|
||||||
|
|
Загрузка…
Ссылка в новой задаче