Fix #7017 and hopefully #7001. WindowArea is not valid any more when splitting a group. Fix debug assert.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40058 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Clemens Zeidler 2011-01-02 00:19:36 +00:00
parent b03f6b7126
commit 1cbfd712a3
2 changed files with 2 additions and 6 deletions

View File

@ -994,12 +994,8 @@ SATGroup::_SplitGroupIfNecessary(WindowArea* removedArea)
bool ownGroupProcessed = false; bool ownGroupProcessed = false;
WindowAreaList newGroup; WindowAreaList newGroup;
while (_FindConnectedGroup(neighbourWindows, removedArea, newGroup)) { while (_FindConnectedGroup(neighbourWindows, removedArea, newGroup)) {
STRACE_SAT("Connected group found; %i windows:\n", STRACE_SAT("Connected group found; %i window(s)\n",
(int)newGroup.CountItems()); (int)newGroup.CountItems());
for (int i = 0; i < newGroup.CountItems(); i++) {
STRACE_SAT("\t%s\n", newGroup.ItemAt(i)->WindowList().ItemAt(0)
->GetWindow()->Title());
}
if (newGroup.CountItems() == 1 if (newGroup.CountItems() == 1
&& newGroup.ItemAt(0)->WindowList().CountItems() == 1) { && newGroup.ItemAt(0)->WindowList().CountItems() == 1) {

View File

@ -92,7 +92,7 @@ StackAndTile::WindowAdded(Window* window)
if (!satWindow) if (!satWindow)
return; return;
ASSERT(fSATWindowMap.find(window) == fSATWindowMap.end()); ASSERT(fSATWindowMap.find(window) != fSATWindowMap.end());
fSATWindowMap[window] = satWindow; fSATWindowMap[window] = satWindow;
} }