]> git.saurik.com Git - wxWidgets.git/commitdiff
Use wxControl instead of wxControlWithItems with wxRTTI macros.
authorVadim Zeitlin <vadim@wxwidgets.org>
Tue, 4 Jan 2011 14:13:29 +0000 (14:13 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Tue, 4 Jan 2011 14:13:29 +0000 (14:13 +0000)
wxControlWithItems is just a convenient combination of wxControl and
wxItemContainer mix-in and it is not useful to include it in wxRTTI classes
hierarchy. Also, using wxControlWithItems as the base class for wxChoice and
wxListBox but not for wxComboBox is inconsistent but wxControlWithItems can't
be used for the latter so resolve this by not using it at all.

Ideally we'd have a way of retrieving the list of supported interfaces (such
as wxItemContainer or wxTextEntry) via wxRTTI too.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66574 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/common/choiccmn.cpp
src/common/lboxcmn.cpp

index 5dd372a3188a1402dfb4ac116ce497bba4029319..dc925335a268a8e1c4fafc11e8bbe466b19c0679 100644 (file)
@@ -65,7 +65,7 @@ wxFLAGS_MEMBER(wxHSCROLL)
 
 wxEND_FLAGS( wxChoiceStyle )
 
 
 wxEND_FLAGS( wxChoiceStyle )
 
-wxIMPLEMENT_DYNAMIC_CLASS_XTI(wxChoice, wxControlWithItems, "wx/choice.h")
+wxIMPLEMENT_DYNAMIC_CLASS_XTI(wxChoice, wxControl, "wx/choice.h")
 
 wxBEGIN_PROPERTIES_TABLE(wxChoice)
 wxEVENT_PROPERTY( Select, wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEvent )
 
 wxBEGIN_PROPERTIES_TABLE(wxChoice)
 wxEVENT_PROPERTY( Select, wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEvent )
index 7e8b2be8e4d689d2e6411e44780997e8326ec9be..da8bc5f35de80b93cc32c5c59ed16f6f9cbef7a1 100644 (file)
@@ -86,7 +86,7 @@ wxFLAGS_MEMBER(wxLB_NEEDED_SB)
 wxFLAGS_MEMBER(wxLB_SORT)
 wxEND_FLAGS( wxListBoxStyle )
 
 wxFLAGS_MEMBER(wxLB_SORT)
 wxEND_FLAGS( wxListBoxStyle )
 
-wxIMPLEMENT_DYNAMIC_CLASS_XTI(wxListBox, wxControlWithItems, "wx/listbox.h")
+wxIMPLEMENT_DYNAMIC_CLASS_XTI(wxListBox, wxControl, "wx/listbox.h")
 
 wxBEGIN_PROPERTIES_TABLE(wxListBox)
 wxEVENT_PROPERTY( Select, wxEVT_COMMAND_LISTBOX_SELECTED, wxCommandEvent )
 
 wxBEGIN_PROPERTIES_TABLE(wxListBox)
 wxEVENT_PROPERTY( Select, wxEVT_COMMAND_LISTBOX_SELECTED, wxCommandEvent )