Closed
Bug 406202
Opened 17 years ago
Closed 14 years ago
Tabs cannot be extended anymore by Bug 387345
Categories
(Firefox :: Extension Compatibility, defect)
Firefox
Extension Compatibility
Tracking
()
RESOLVED
FIXED
People
(Reporter: yuki, Unassigned)
References
Details
(Whiteboard: [CLOSEME 2010-09-15])
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; ja; rv:1.8.1.10) Gecko/20071115 Firefox/2.0.0.10 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.9b2pre) Gecko/2007113005 Minefield/3.0b2pre Some tab-related extensions never work, because internal boxes of tabs and the stack for extra tab icon are lost by the patch of Bug 387345. In Firefox 2, we extension authors can extend tabs with no/less conflict, because there is internal anonymous box defined by XBL. Moreover, there is a place holder (image.tab-extra-status) which is not used by Firefox default, like: <xul:stack class="tab-icon"> <xul:image xbl:inherits="validate,src=image" class="tab-icon-image"/> <xul:image class="tab-extra-status"/> </xul:stack> But, by the patch of Bug 387345, they died. This change breaks Firefox's extendability seriously. Now, to insert extra items to each <tab>, now we extension authors MUST use custom binding for <tab>s. However, if multiple extensions provide different binding for <tab>s, they will conflict, so we users cannot combine favorite tab-related extensions anymore. If you recommend Firefox because it has powerful extendability, you shouldn't carelessly make changes like this. Reproducible: Always
Reporter | ||
Comment 1•17 years ago
|
||
Examples of extensions broken by the change: https://addons.mozilla.org/firefox/addon/4930 This cannot insert thumbnail to each tab anymore. https://addons.mozilla.org/firefox/addon/5890 This cannot twisty to each tab anymore.
Version: unspecified → Trunk
Reporter | ||
Comment 2•17 years ago
|
||
s/cannot twisty/cannot show twisty/
Reporter | ||
Comment 3•17 years ago
|
||
Firefox 2: <content chromedir="&locale.dir;" closetabtext="&closeTab.label;"> <xul:hbox class="tab-image-left" xbl:inherits="selected"/> <xul:hbox flex="1" class="tab-image-middle" align="center" xbl:inherits="selected"> <- We can insert elements into this box <xul:stack class="tab-icon"> <xul:image xbl:inherits="validate,src=image" class="tab-icon-image"/> <xul:image class="tab-extra-status"/> </xul:stack> <xul:label flex="1" xbl:inherits="value=label,crop,accesskey" crop="right" class="tab-text"/> <label value="(EXTRA LABEL)"/> <- like this. </xul:hbox> <xul:toolbarbutton anonid="close-button" class="tab-close-button" tabindex="-1"/> <xul:hbox class="tab-image-right" xbl:inherits="selected"/> </content> Because there is anonymous container, we can insert XUL elements by JavaScript, like: var container = document.getAnonymousElementByAttribute(tab, 'class', 'tab-image-middle'); var label = document.createElement('label'); label.setAttribute('value', '(EXTRA LABEL)'); container.appendChild(label); Firefox 3: <content chromedir="&locale.dir;" closetabtext="&closeTab.label;"> <xul:image xbl:inherits="validate,src=image" class="tab-icon-image"/> <xul:label flex="1" xbl:inherits="value=label,crop,accesskey" class="tab-text"/> <label value="(EXTRA LABEL)"/> <- We cannot insert elements into the tab like this <xul:toolbarbutton anonid="close-button" tabindex="-1" class="tab-close-button"/> </content> Because there is no container, there is no <xbl:children/> tag, we cannot insert elements. var closebox = document.getAnonymousElementByAttribute(tab, 'anonid', 'close-button'); var label = document.createElement('label'); label.setAttribute('value', '(EXTRA LABEL)'); tab.insertBefore(label, closebox); // <- this doesn't work, because "closebox" is an anonymous content and there is no <xbl:children/> place holder.
Reporter | ||
Comment 4•16 years ago
|
||
Does no one pay attention on this topic? I've made a library to take back placeholders in tabs to Firefox 3. This possibly helps you upgrading your extension for Firefox 3. It is compatible to Firefox 2. You only have to put those files into your extension and load the file "tabFx2Compatible.xul" by xul-overlay processing instruction. http://www.cozmixng.org/repos/piro/fx3-compatibility-lib/trunk/tabFx2Compatible.xul http://www.cozmixng.org/repos/piro/fx3-compatibility-lib/trunk/tabFx2Compatible.css http://www.cozmixng.org/repos/piro/fx3-compatibility-lib/trunk/tabFx2Compatible.xml
Comment 5•14 years ago
|
||
Reporter, are you still seeing this issue with Firefox 3.6.8 or later in safe mode? If not, please close. These links can help you in your testing. http://support.mozilla.com/kb/Safe+Mode http://support.mozilla.com/kb/Managing+profiles
Whiteboard: [CLOSEME 2010-09-15]
Reporter | ||
Comment 6•14 years ago
|
||
Almost fixed by the Bug 593967.
Status: UNCONFIRMED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•