Bug 345257 - add tooltip to 'all tabs' menu button. patch from Michael Ventnor <ventnors_dogs234@yahoo.com.au>, r=me.

This commit is contained in:
mozilla.mano@sent.com 2007-08-21 22:01:40 -07:00
parent c2af5ae4af
commit 9ff84bd739
3 changed files with 15 additions and 2 deletions

View File

@ -2452,7 +2452,8 @@
</xul:arrowscrollbox>
<xul:hbox class="tabs-alltabs-box" align="center" pack="end"
anonid="alltabs-box">
<xul:toolbarbutton class="tabs-alltabs-button" type="menu">
<xul:toolbarbutton class="tabs-alltabs-button" type="menu" tooltip="_child">
<xul:tooltip anonid="alltabs-tooltip" label="&listAllTabs.label;"/>
<xul:menupopup class="tabs-alltabs-popup"
anonid="alltabs-popup"
position="after_end"/>
@ -2649,6 +2650,11 @@
"anonid", "alltabs-box");
</field>
<field name="mAllTabsTooltip">
document.getAnonymousElementByAttribute(this,
"anonid", "alltabs-tooltip");
</field>
<field name="mFlashTimer">null</field>
<field name="mFlashStage">0</field>
<field name="mFlashStart">6</field>
@ -2705,6 +2711,11 @@
</implementation>
<handlers>
<handler event="TabSelect" action="this._handleTabSelect();"/>
<handler event="popupshowing"><![CDATA[
if (event.originalTarget == this.mAllTabsTooltip &&
document.tooltipNode.parentNode == this.mAllTabsPopup)
event.preventDefault();
]]></handler>
</handlers>
</binding>

View File

@ -10,3 +10,4 @@
<!ENTITY reloadTab.label "Reload Tab">
<!ENTITY reloadTab.accesskey "r">
<!ENTITY newTabButton.tooltip "Open a new tab">
<!ENTITY listAllTabs.label "List all tabs">

View File

@ -64,7 +64,8 @@
</xul:arrowscrollbox>
<xul:hbox class="tabs-alltabs-box" pack="end" align="center"
anonid="alltabs-box">
<xul:toolbarbutton class="tabs-alltabs-button" type="menu">
<xul:toolbarbutton class="tabs-alltabs-button" type="menu" tooltip="_child">
<xul:tooltip anonid="alltabs-tooltip" label="&listAllTabs.label;"/>
<xul:menupopup class="tabs-alltabs-popup"
anonid="alltabs-popup" position="after_end"/>
</xul:toolbarbutton>