Bug 462289, don't focus the selected tab when clicking it with the mouse, r=gavin

This commit is contained in:
Neil Deakin 2009-03-09 13:43:44 -04:00
parent b8aeaa6484
commit 84e17c3406
2 changed files with 17 additions and 1 deletions

View File

@ -3371,12 +3371,27 @@
if (anonid == "close-button")
this.mOverCloseButton = false;
</handler>
<handler event="dragstart" phase="capturing">
this.style.MozUserFocus = '';
</handler>
<handler event="mousedown" button="0" phase="capturing">
<![CDATA[
if (this.mOverCloseButton)
if (this.mOverCloseButton) {
event.stopPropagation();
}
else {
this.style.MozUserFocus = 'ignore';
this.clientTop; // just using this to flush style updates
}
]]>
</handler>
<handler event="mousedown" button="2">
this.style.MozUserFocus = 'ignore';
this.clientTop;
</handler>
<handler event="mouseup">
this.style.MozUserFocus = '';
</handler>
</handlers>
</binding>

View File

@ -99,6 +99,7 @@ _BROWSER_FILES = browser_sanitize-timespans.js \
browser_sanitize-passwordDisabledHosts.js \
browser_bug479408.js \
browser_bug479408_sample.html \
browser_bug462289.js \
$(NULL)
ifneq (,$(filter mac cocoa,$(MOZ_WIDGET_TOOLKIT)))