Index: TabBar.cpp =================================================================== --- TabBar.cpp (revision 2992) +++ TabBar.cpp (working copy) @@ -1885,14 +1885,25 @@ return; if(cross != -1) { + + //crude bugfix - if you have several tabs open, active is not last + // move mouse over cross of last tab and keep closing tabs without moving mouse + // if you do it fast enough (tenths of second, so no frantic clicking needed) + // the "cross" variable will contain still the old tab index, now beyond end of Vector + // -> crash + // sorry, no idea how to fix it properly, maybe cross should be recalculated every time from Point p? + if ( cross >= tabs.GetCount() ) cross = tabs.GetCount() - 1; + Value v = tabs[cross].key; Vectorvv; vv.Add(v); int ix = cross; if (!CancelClose(v) && !CancelCloseSome(Vector(vv, 0))) { - Close(ix); +// Close(ix); //bugfix PED, see below WhenClose(v); WhenCloseSome(vv); + Close(ix); //bugfix PED: Close should be called after callbacks + //according to "Executed before tab closing. Parameter: Key of closed tab" comment in TabBar.h } } else if(highlight >= 0) {