Bug 492250 - URLs in Page Info Media tab should be LTR; r-gavin

This commit is contained in:
Ehsan Akhgari 2010-05-23 22:16:50 -04:00
parent c2804730fc
commit 6f913f6a1f

View File

@ -168,13 +168,19 @@ const COPYCOL_IMAGE = COL_IMAGE_ADDRESS;
var gMetaView = new pageInfoTreeView(COPYCOL_META_CONTENT);
var gImageView = new pageInfoTreeView(COPYCOL_IMAGE);
gImageView.getCellProperties = function(row, col, props) {
var aserv = Components.classes[ATOM_CONTRACTID]
.getService(Components.interfaces.nsIAtomService);
var atomSvc = Components.classes["@mozilla.org/atom-service;1"]
.getService(Components.interfaces.nsIAtomService);
gImageView._ltrAtom = atomSvc.getAtom("ltr");
gImageView._brokenAtom = atomSvc.getAtom("broken");
gImageView.getCellProperties = function(row, col, props) {
if (gImageView.data[row][COL_IMAGE_SIZE] == gStrings.unknown &&
!/^https:/.test(gImageView.data[row][COL_IMAGE_ADDRESS]))
props.AppendElement(aserv.getAtom("broken"));
props.AppendElement(this._brokenAtom);
if (col.element.id == "image-address")
props.AppendElement(this._ltrAtom);
};
var gImageHash = { };