SetSelection(selNew);
InvalidateBestSize();
+ // GetListView()->InvalidateBestSize();
GetListView()->Arrange();
+
+ if (GetPageCount() == 1)
+ {
+ wxSizeEvent sz(GetSize(), GetId());
+ ProcessEvent(sz);
+ }
return true;
}
}
GetListView()->Arrange();
+ if (GetPageCount() == 0)
+ {
+ wxSizeEvent sz(GetSize(), GetId());
+ ProcessEvent(sz);
+ }
}
return win;
bool wxListbook::DeleteAllPages()
{
GetListView()->DeleteAllItems();
- return wxBookCtrlBase::DeleteAllPages();
+ if (!wxBookCtrlBase::DeleteAllPages())
+ return false;
+
+ m_selection = -1;
+
+ wxSizeEvent sz(GetSize(), GetId());
+ ProcessEvent(sz);
+
+ return true;
}
// ----------------------------------------------------------------------------