with Tab Mix Plus, I cannot drop multiple tabs (fix for https://github.com/piroor/multipletab/issues/closed#issue/2 )
This commit is contained in:
parent
99dba23763
commit
64c7fb8b65
@ -1 +1 @@
|
|||||||
Subproject commit 7adc0c6e3866bb535ffd9f851afd8d0b7224eb9d
|
Subproject commit 6851e29a6e68c51bd6fc84e6e2a1208116d9fed5
|
@ -13,7 +13,7 @@
|
|||||||
http://github.com/piroor/fxaddonlibs/blob/master/tabsDragUtils.js
|
http://github.com/piroor/fxaddonlibs/blob/master/tabsDragUtils.js
|
||||||
*/
|
*/
|
||||||
(function() {
|
(function() {
|
||||||
const currentRevision = 4;
|
const currentRevision = 5;
|
||||||
|
|
||||||
if (!('piro.sakura.ne.jp' in window)) window['piro.sakura.ne.jp'] = {};
|
if (!('piro.sakura.ne.jp' in window)) window['piro.sakura.ne.jp'] = {};
|
||||||
|
|
||||||
@ -40,6 +40,9 @@
|
|||||||
},
|
},
|
||||||
_delayedInit : function TDU_delayedInit()
|
_delayedInit : function TDU_delayedInit()
|
||||||
{
|
{
|
||||||
|
window.removeEventListener('load', arguments.callee, false);
|
||||||
|
delete tabsDragUtils._delayedInit;
|
||||||
|
|
||||||
if (
|
if (
|
||||||
'PlacesControllerDragHelper' in window &&
|
'PlacesControllerDragHelper' in window &&
|
||||||
'onDrop' in PlacesControllerDragHelper &&
|
'onDrop' in PlacesControllerDragHelper &&
|
||||||
@ -64,7 +67,10 @@
|
|||||||
)
|
)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
delete tabsDragUtils._delayedInit;
|
|
||||||
|
// for Tab Mix Plus
|
||||||
|
if ('TabDNDObserver' in window)
|
||||||
|
tabsDragUtils.initTabDNDObserver(TabDNDObserver);
|
||||||
},
|
},
|
||||||
destroy : function TDU_destroy()
|
destroy : function TDU_destroy()
|
||||||
{
|
{
|
||||||
@ -77,19 +83,24 @@
|
|||||||
var tabDNDObserver = (aTabBrowser.tabContainer && aTabBrowser.tabContainer.tabbrowser == aTabBrowser) ?
|
var tabDNDObserver = (aTabBrowser.tabContainer && aTabBrowser.tabContainer.tabbrowser == aTabBrowser) ?
|
||||||
aTabBrowser.tabContainer : // Firefox 4.0 or later
|
aTabBrowser.tabContainer : // Firefox 4.0 or later
|
||||||
aTabBrowser ; // Firefox 3.5 - 3.6
|
aTabBrowser ; // Firefox 3.5 - 3.6
|
||||||
if ('_setEffectAllowedForDataTransfer' in tabDNDObserver &&
|
this.initTabDNDObserver(tabDNDObserver);
|
||||||
tabDNDObserver._setEffectAllowedForDataTransfer.toSource().indexOf('tabDragUtils') < 0) {
|
},
|
||||||
eval('tabDNDObserver._setEffectAllowedForDataTransfer = '+
|
destroyTabBrowser : function TDU_destroyTabBrowser(aTabBrowser)
|
||||||
tabDNDObserver._setEffectAllowedForDataTransfer.toSource().replace(
|
{
|
||||||
|
},
|
||||||
|
|
||||||
|
initTabDNDObserver : function TDU_initTabDNDObserver(aObserver)
|
||||||
|
{
|
||||||
|
if ('_setEffectAllowedForDataTransfer' in aObserver &&
|
||||||
|
aObserver._setEffectAllowedForDataTransfer.toSource().indexOf('tabDragUtils') < 0) {
|
||||||
|
eval('aObserver._setEffectAllowedForDataTransfer = '+
|
||||||
|
aObserver._setEffectAllowedForDataTransfer.toSource().replace(
|
||||||
'dt.mozItemCount > 1',
|
'dt.mozItemCount > 1',
|
||||||
'$& && !window["piro.sakura.ne.jp"].tabsDragUtils.isTabsDragging(arguments[0])'
|
'$& && !window["piro.sakura.ne.jp"].tabsDragUtils.isTabsDragging(arguments[0])'
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
destroyTabBrowser : function TDU_destroyTabBrowser(aTabBrowser)
|
|
||||||
{
|
|
||||||
},
|
|
||||||
|
|
||||||
startTabsDrag : function TDU_startTabsDrag(aEvent, aTabs)
|
startTabsDrag : function TDU_startTabsDrag(aEvent, aTabs)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user