Tree can be broken when the last child tab is moved to the upper level by drag and drop #297

This commit is contained in:
Piro / SHIMODA Hiroshi 2012-08-04 02:35:44 +09:00
parent 42d84c9633
commit ce6b3b95db

View File

@ -402,7 +402,7 @@ catch(e) {
if (aSourceTab == nextTab) {
info.action = sv.kACTION_MOVE | sv.kACTION_ATTACH;
info.parent = sv.getParentTab(tab);
info.insertBefore = sv.getNextSiblingTab(tab);
info.insertBefore = sv.getNextSiblingTab(tab) || sv.getNextTab(nextTab);
}
}
if (DEBUG && info.insertBefore) dump(' insertBefore = '+info.insertBefore._tPos+'\n');