Bug 91312 TITLE texts should follow the same BiDi directionality as the source object

patch by mozilla-bugzilla@future.shiny.co.il r=smontagu sr=roc a=asa
This commit is contained in:
timeless%mozdev.org 2006-09-14 06:09:39 +00:00
parent db5560056a
commit 9f1f7090d8

View File

@ -354,17 +354,20 @@ function FillInHTMLTooltip(tipElement)
var titleText = null;
var XLinkTitleText = null;
var direction = "inherit";
while (!titleText && !XLinkTitleText && tipElement) {
if (tipElement.nodeType == Node.ELEMENT_NODE) {
titleText = tipElement.getAttribute("title");
XLinkTitleText = tipElement.getAttributeNS(XLinkNS, "title");
direction = tipElement.ownerDocument.defaultView.getComputedStyle(tipElement, "").getPropertyValue("direction");
}
tipElement = tipElement.parentNode;
}
var texts = [titleText, XLinkTitleText];
var tipNode = document.getElementById("aHTMLTooltip");
tipNode.style.direction = direction;
for (var i = 0; i < texts.length; ++i) {
var t = texts[i];