X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/f499ca450c3863cea52f7b7f77aa7eecc942b552..065fa73213c49c01489cf6c44f788c7486cf4f8d:/include/wx/sizer.h diff --git a/include/wx/sizer.h b/include/wx/sizer.h index 410b2c1e37..53dde1a4bf 100644 --- a/include/wx/sizer.h +++ b/include/wx/sizer.h @@ -54,14 +54,19 @@ public: wxSizerFlags& Align(int alignment) // combination of wxAlignment values { - m_flags &= wxALL; + m_flags &= ~wxALIGN_MASK; m_flags |= alignment; return *this; } + wxSizerFlags& Expand() + { + m_flags |= wxEXPAND; + return *this; + } + // some shortcuts for Align() - wxSizerFlags& Expand() { return Align(wxEXPAND); } wxSizerFlags& Centre() { return Align(wxCENTRE); } wxSizerFlags& Center() { return Centre(); } wxSizerFlags& Left() { return Align(wxALIGN_LEFT); } @@ -81,7 +86,14 @@ public: wxSizerFlags& Border(int direction = wxALL) { // FIXME: default border size shouldn't be hardcoded +#ifdef __SMARTPHONE__ + // no borders by default on limited size screen + wxUnusedVar(direction); + + return *this; +#else return Border(direction, 5); +#endif } @@ -243,6 +255,8 @@ public: void Show(bool show); bool IsShown() const; + void SetUserData(wxObject* userData) + { delete m_userData; m_userData = userData; } wxObject* GetUserData() const { return m_userData; } wxPoint GetPosition() const