summaryrefslogtreecommitdiffstats
path: root/chrome/common/extensions/docs/js
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/common/extensions/docs/js')
-rwxr-xr-xchrome/common/extensions/docs/js/api_page_generator.js8
1 files changed, 6 insertions, 2 deletions
diff --git a/chrome/common/extensions/docs/js/api_page_generator.js b/chrome/common/extensions/docs/js/api_page_generator.js
index a89a83a..e9173bc 100755
--- a/chrome/common/extensions/docs/js/api_page_generator.js
+++ b/chrome/common/extensions/docs/js/api_page_generator.js
@@ -227,9 +227,13 @@ function selectCurrentPageOnLeftNav() {
evalXPathFromId(".//li/a", "leftNav").select(function(node) {
if (pageBase == finalPathPart(node.href)) {
var parent = node.parentNode;
- parent.className = "leftNavSelected";
+ if (node.firstChild.nodeName == 'DIV') {
+ node.firstChild.className = "leftNavSelected";
+ } else {
+ parent.className = "leftNavSelected";
+ }
parent.removeChild(node);
- parent.appendChild(node.firstChild);
+ parent.insertBefore(node.firstChild, parent.firstChild);
return true;
}
});