b=251062, livemark popup displayed even when page has no feeds, r=shaver

git-svn-id: svn://10.0.0.236/branches/AVIARY_1_0_20040515_BRANCH@159383 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
vladimir%pobox.com
2004-07-17 03:20:13 +00:00
parent 4eca9f19e8
commit a641daf14b
4 changed files with 11 additions and 4 deletions

View File

@@ -5467,8 +5467,10 @@ function updatePageLivemarks()
var livemarkLinks = gBrowser.mCurrentBrowser.livemarkLinks;
if (!livemarkLinks || livemarkLinks.length == 0) {
gLivemarksButton.removeAttribute("livemarks");
gLivemarksButton.setAttribute("tooltiptext", gNavigatorBundle.getString("livemarkNoLivemarksTooltip"));
} else {
gLivemarksButton.setAttribute("livemarks", "true");
gLivemarksButton.setAttribute("tooltiptext", gNavigatorBundle.getString("livemarkHasLivemarksTooltip"));
}
}
@@ -5476,7 +5478,7 @@ function livemarkFillPopup(menuPopup)
{
var livemarkLinks = gBrowser.mCurrentBrowser.livemarkLinks;
if (livemarkLinks == null) {
return;
return false;
}
while (menuPopup.firstChild) {
@@ -5492,6 +5494,8 @@ function livemarkFillPopup(menuPopup)
menuItem.setAttribute("tooltiptext", markinfo.href);
menuPopup.appendChild(menuItem);
}
return true;
}
function livemarkAddMark(wincontent, data) {

View File

@@ -456,8 +456,8 @@
<menuseparator/>
</menupopup>
</statusbarpanel>
<statusbarpanel id="livemark-button" type="menu" class="statusbarpanel-menu-iconic" tooltiptext="&livemarkIcon.tooltip;">
<menupopup onpopupshowing="livemarkFillPopup(this);"
<statusbarpanel id="livemark-button" type="menu" class="statusbarpanel-menu-iconic">
<menupopup onpopupshowing="return livemarkFillPopup(this);"
oncommand="livemarkAddMark(window._content, event.target.getAttribute('data'));" />
</statusbarpanel>
<statusbarpanel id="statusbar-updates"/>

View File

@@ -329,7 +329,6 @@
<!ENTITY pageThemeIcon.tooltip "Switch to an alternate stylesheet">
<!ENTITY pageReportIcon.tooltip "Change popup blocking settings for this website">
<!ENTITY livemarkIcon.tooltip "Create Livemark for this page">
<!ENTITY find.label "Find:">
<!ENTITY findNext.label "Find Next">

View File

@@ -73,3 +73,7 @@ popupBlock=Block popups for %S
popupWarningDontShowFromMessage=Don't show this message when popups are blocked
popupWarningDontShowFromStatusbar=Don't show info message when popups are blocked
popupShowPopupPrefix=Show '%S'
livemarkHasLivemarksTooltip=Add Livemark for this page's feed
livemarkNoLivemarksTooltip=Page has no feeds for Livemark