Give error messages for invalid sizer flags in XRC wxSizer handler.

This allows to give the exact line number of the error, unlike asserts that
happen in wxSizer code which don't point exactly to the error location when
sizers are created via XRC.

It also has the advantage of allowing to detect wrong use of wxALIGN_LEFT and
wxALIGN_TOP, unlike the asserts which can't do it because the value of both of
these flags is 0.
This commit is contained in:
Vadim Zeitlin
2015-04-05 20:30:02 +02:00
parent 58114f22c3
commit 16c22794b7
3 changed files with 214 additions and 2 deletions

View File

@@ -57,6 +57,7 @@ private:
wxSizerItem* MakeSizerItem();
void SetSizerItemAttributes(wxSizerItem* sitem);
void AddSizerItem(wxSizerItem* sitem);
int GetSizerFlags();
};
#if wxUSE_BUTTON