Bug 190939 JS error and strict warning in sidebarOverlay.js r=shliang sr=alecf a=asa

This commit is contained in:
neil%parkwaycc.co.uk 2006-07-27 14:57:19 +00:00
Родитель b915e39cc4
Коммит abc3d2dee4
1 изменённых файлов: 9 добавлений и 9 удалений

Просмотреть файл

@ -801,8 +801,6 @@ function sidebar_open_default_panel(wait, tries) {
// which will aggregate it with the other datasources that describe // which will aggregate it with the other datasources that describe
// the individual panel's title, customize URL, and content URL. // the individual panel's title, customize URL, and content URL.
var panels = document.getElementById('sidebar-panels'); var panels = document.getElementById('sidebar-panels');
var ds = RDF.GetDataSource(sidebarObj.datasource_uri);
panels.database.AddDataSource(ds); panels.database.AddDataSource(ds);
debug("Adding observer to database."); debug("Adding observer to database.");
@ -1501,13 +1499,15 @@ function SidebarSetButtonOpen(aSidebarNowOpen)
{ {
// change state so toolbar icon can be updated // change state so toolbar icon can be updated
var pt = document.getElementById("PersonalToolbar"); var pt = document.getElementById("PersonalToolbar");
pt.setAttribute("prefixopen", aSidebarNowOpen); if (pt) {
pt.setAttribute("prefixopen", aSidebarNowOpen);
// set tooltip for toolbar icon
var header = document.getElementById("sidebar-title-box"); // set tooltip for toolbar icon
var tooltip = header.getAttribute(aSidebarNowOpen ? var header = document.getElementById("sidebar-title-box");
"tooltipclose" : "tooltipopen"); var tooltip = header.getAttribute(aSidebarNowOpen ?
pt.setAttribute("prefixtooltip", tooltip); "tooltipclose" : "tooltipopen");
pt.setAttribute("prefixtooltip", tooltip);
}
} }
function SidebarInitContextMenu(aMenu, aPopupNode) function SidebarInitContextMenu(aMenu, aPopupNode)