dragging out of tree wrongly duplicated the dragged tree. now they should be duplicated if Ctrl or Command key is pressed. (but it doesn't work currently, because modifier keys are ignored on dragend event.)

This commit is contained in:
Piro / SHIMODA Hiroshi 2012-02-05 07:50:26 +09:00
parent 16f6cd7dd9
commit 5cbbd36fea
2 changed files with 8 additions and 1 deletions

View File

@ -760,6 +760,9 @@ catch(e) {
if (this.isDraggingAllCurrentTabs(draggedTab))
return;
if (aEvent.ctrlKey || aEvent.metaKey)
draggedTab.__treestyletab__toBeDuplicated = true;
b.replaceTabWithWindow(draggedTab);
},

View File

@ -1574,8 +1574,9 @@ TreeStyleTabWindow.prototype = {
}
else {
let actionInfo = {
action : this.kACTIONS_FOR_DESTINATION | this.kACTION_IMPORT
action : remoteTab.__treestyletab__toBeDuplicated ? this.kACTION_DUPLICATE : this.kACTION_IMPORT
};
let b = this.browser;
let blankTab;
this.Deferred
@ -1591,6 +1592,9 @@ TreeStyleTabWindow.prototype = {
remoteWindow = null
remoteService = null;
remoteMultipleTabService = null;
})
.error(function(e) {
Application.console.log(e+'\n'+e.stack)
});
}
return true;