Bug 1004499 - Added code to check if the window should draw a focus ring. r=enndeakin

This commit is contained in:
Rik Cabanier 2014-05-01 11:29:00 +02:00
parent 539068b2ec
commit 036c7d680d

View File

@ -1862,7 +1862,10 @@ bool CanvasRenderingContext2D::DrawCustomFocusRing(mozilla::dom::Element& aEleme
nsCOMPtr<nsIDOMElement> focusedElement;
fm->GetFocusedElement(getter_AddRefs(focusedElement));
if (SameCOMIdentity(aElement.AsDOMNode(), focusedElement)) {
return true;
nsPIDOMWindow *window = aElement->OwnerDoc()->GetWindow();
if (window) {
return window->ShouldShowFocusRing();
}
}
}