ドロップ時のアタッチ先タブの判定を間違えていたのを修正

git-svn-id: http://www.cozmixng.org/repos/piro/treestyletab/trunk@1250 599a83e7-65a4-db11-8015-0010dcdd6dc2
This commit is contained in:
piro 2007-10-20 13:41:40 +00:00
parent 5af75957f9
commit 0555a9c94d

View File

@ -1318,11 +1318,8 @@ catch(e) {
else { else {
var prevNest = Number(prevTab.getAttribute(this.kNEST)); var prevNest = Number(prevTab.getAttribute(this.kNEST));
var targetNest = Number(tab.getAttribute(this.kNEST)); var targetNest = Number(tab.getAttribute(this.kNEST));
info.action = this.kACTION_MOVE | this.kACTION_ATTACH; info.parent = (prevNest < targetNest) ? prevTab : this.getParentTab(tab) ;
info.parent = ( info.action = this.kACTION_MOVE | (info.parent ? this.kACTION_ATTACH : this.kACTION_PART );
(prevNest < targetNest) ? prevTab :
this.getParentTab(tab)
) || tab ;
info.insertBefore = tab; info.insertBefore = tab;
} }
break; break;
@ -1348,11 +1345,8 @@ catch(e) {
else { else {
var targetNest = Number(tab.getAttribute(this.kNEST)); var targetNest = Number(tab.getAttribute(this.kNEST));
var nextNest = Number(nextTab.getAttribute(this.kNEST)); var nextNest = Number(nextTab.getAttribute(this.kNEST));
info.action = this.kACTION_MOVE | this.kACTION_ATTACH; info.parent = (targetNest < nextNest) ? tab : this.getParentTab(tab) ;
info.parent = ( info.action = this.kACTION_MOVE | (info.parent ? this.kACTION_ATTACH : this.kACTION_PART );
(targetNest < nextNest) ? tab :
this.getParentTab(tab)
) || tab ;
info.insertBefore = nextTab; info.insertBefore = nextTab;
} }
break; break;