Bug 1073692 - Display each search suggestion row with the correct text direction on about:home/about:newtab. r=ehsan
--- a/browser/base/content/searchSuggestionUI.js
+++ b/browser/base/content/searchSuggestionUI.js
@@ -296,16 +296,17 @@ SearchSuggestionUIController.prototype =
_speculativeConnect: function () {
if (this.engineName) {
this._sendMsg("SpeculativeConnect", this.engineName);
}
},
_makeTableRow: function (type, suggestionStr, currentRow, searchWords) {
let row = document.createElementNS(HTML_NS, "tr");
+ row.dir = "auto";
row.classList.add("searchSuggestionRow");
row.classList.add(type);
row.setAttribute("role", "presentation");
row.addEventListener("mousemove", this);
row.addEventListener("mousedown", this);
let entry = document.createElementNS(HTML_NS, "td");
entry.classList.add("searchSuggestionEntry");
@@ -360,17 +361,16 @@ SearchSuggestionUIController.prototype =
}
return row.rowIndex;
},
_makeTable: function (id) {
this._table = document.createElementNS(HTML_NS, "table");
this._table.id = id;
this._table.hidden = true;
- this._table.dir = "auto";
this._table.classList.add("searchSuggestionTable");
this._table.setAttribute("role", "listbox");
return this._table;
},
_sendMsg: function (type, data=null) {
dispatchEvent(new CustomEvent("ContentSearchClient", {
detail: {