INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_DIR = @INSTALL_DIR@
-ICC_PCH_USE_SWITCH = @ICC_PCH_USE_SWITCH@
BK_DEPS = @BK_DEPS@
BK_MAKE_PCH = @BK_MAKE_PCH@
srcdir = @srcdir@
-Wl,--out-implib=$(LIBDIRNAME)/$(LIBPREFIX)wx_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)-$(WX_RELEASE)$(HOST_SUFFIX).$(DLLIMP_SUFFIX)
@COND_WINDOWS_IMPLIB_1@__monodll___importlib = $(COND_WINDOWS_IMPLIB_1___monodll___importlib)
@COND_GCC_PCH_1@__monodll_PCH_INC = -I./.pch/wxprec_monodll
-@COND_ICC_PCH_1@__monodll_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__monodll_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_monodll/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_monodll_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_monodll/wx/wxprec.h.gch
monodll_rgncmn.o \
monodll_settcmn.o \
monodll_sizer.o \
+ monodll_spinbuttcmn.o \
+ monodll_spinctrlcmn.o \
monodll_srchcmn.o \
monodll_statbar.o \
monodll_stattextcmn.o \
monodll_rgncmn.o \
monodll_settcmn.o \
monodll_sizer.o \
+ monodll_spinbuttcmn.o \
+ monodll_spinctrlcmn.o \
monodll_srchcmn.o \
monodll_statbar.o \
monodll_stattextcmn.o \
@COND_MONOLITHIC_1_SHARED_0@__uninstall_monolib___depname \
@COND_MONOLITHIC_1_SHARED_0@ = uninstall_monolib
@COND_GCC_PCH_1@__monolib_PCH_INC = -I./.pch/wxprec_monolib
-@COND_ICC_PCH_1@__monolib_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__monolib_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_monolib/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_monolib_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_monolib/wx/wxprec.h.gch
monolib_rgncmn.o \
monolib_settcmn.o \
monolib_sizer.o \
+ monolib_spinbuttcmn.o \
+ monolib_spinctrlcmn.o \
monolib_srchcmn.o \
monolib_statbar.o \
monolib_stattextcmn.o \
monolib_rgncmn.o \
monolib_settcmn.o \
monolib_sizer.o \
+ monolib_spinbuttcmn.o \
+ monolib_spinctrlcmn.o \
monolib_srchcmn.o \
monolib_statbar.o \
monolib_stattextcmn.o \
-Wl,--out-implib=$(LIBDIRNAME)/$(LIBPREFIX)wx_base$(WXBASEPORT)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)-$(WX_RELEASE)$(HOST_SUFFIX).$(DLLIMP_SUFFIX)
@COND_WINDOWS_IMPLIB_1@__basedll___importlib = $(COND_WINDOWS_IMPLIB_1___basedll___importlib)
@COND_GCC_PCH_1@__basedll_PCH_INC = -I./.pch/wxprec_basedll
-@COND_ICC_PCH_1@__basedll_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__basedll_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_basedll/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_basedll_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_basedll/wx/wxprec.h.gch
@COND_MONOLITHIC_0_SHARED_0@__uninstall_baselib___depname \
@COND_MONOLITHIC_0_SHARED_0@ = uninstall_baselib
@COND_GCC_PCH_1@__baselib_PCH_INC = -I./.pch/wxprec_baselib
-@COND_ICC_PCH_1@__baselib_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__baselib_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_baselib/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_baselib_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_baselib/wx/wxprec.h.gch
-Wl,--out-implib=$(LIBDIRNAME)/$(LIBPREFIX)wx_base$(WXBASEPORT)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_net-$(WX_RELEASE)$(HOST_SUFFIX).$(DLLIMP_SUFFIX)
@COND_WINDOWS_IMPLIB_1@__netdll___importlib = $(COND_WINDOWS_IMPLIB_1___netdll___importlib)
@COND_GCC_PCH_1@__netdll_PCH_INC = -I./.pch/wxprec_netdll
-@COND_ICC_PCH_1@__netdll_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__netdll_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_netdll/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_netdll_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_netdll/wx/wxprec.h.gch
@COND_MONOLITHIC_0_SHARED_0@__install_netlib___depname = install_netlib
@COND_MONOLITHIC_0_SHARED_0@__uninstall_netlib___depname = uninstall_netlib
@COND_GCC_PCH_1@__netlib_PCH_INC = -I./.pch/wxprec_netlib
-@COND_ICC_PCH_1@__netlib_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__netlib_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_netlib/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_netlib_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_netlib/wx/wxprec.h.gch
-Wl,--out-implib=$(LIBDIRNAME)/$(LIBPREFIX)wx_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_core-$(WX_RELEASE)$(HOST_SUFFIX).$(DLLIMP_SUFFIX)
@COND_WINDOWS_IMPLIB_1@__coredll___importlib = $(COND_WINDOWS_IMPLIB_1___coredll___importlib)
@COND_GCC_PCH_1@__coredll_PCH_INC = -I./.pch/wxprec_coredll
-@COND_ICC_PCH_1@__coredll_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__coredll_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_coredll/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_coredll_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_coredll/wx/wxprec.h.gch
coredll_rgncmn.o \
coredll_settcmn.o \
coredll_sizer.o \
+ coredll_spinbuttcmn.o \
+ coredll_spinctrlcmn.o \
coredll_srchcmn.o \
coredll_statbar.o \
coredll_stattextcmn.o \
coredll_rgncmn.o \
coredll_settcmn.o \
coredll_sizer.o \
+ coredll_spinbuttcmn.o \
+ coredll_spinctrlcmn.o \
coredll_srchcmn.o \
coredll_statbar.o \
coredll_stattextcmn.o \
@COND_MONOLITHIC_0_SHARED_0_USE_GUI_1@__uninstall_corelib___depname \
@COND_MONOLITHIC_0_SHARED_0_USE_GUI_1@ = uninstall_corelib
@COND_GCC_PCH_1@__corelib_PCH_INC = -I./.pch/wxprec_corelib
-@COND_ICC_PCH_1@__corelib_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__corelib_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_corelib/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_corelib_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_corelib/wx/wxprec.h.gch
corelib_rgncmn.o \
corelib_settcmn.o \
corelib_sizer.o \
+ corelib_spinbuttcmn.o \
+ corelib_spinctrlcmn.o \
corelib_srchcmn.o \
corelib_statbar.o \
corelib_stattextcmn.o \
corelib_rgncmn.o \
corelib_settcmn.o \
corelib_sizer.o \
+ corelib_spinbuttcmn.o \
+ corelib_spinctrlcmn.o \
corelib_srchcmn.o \
corelib_statbar.o \
corelib_stattextcmn.o \
-Wl,--out-implib=$(LIBDIRNAME)/$(LIBPREFIX)wx_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_adv-$(WX_RELEASE)$(HOST_SUFFIX).$(DLLIMP_SUFFIX)
@COND_WINDOWS_IMPLIB_1@__advdll___importlib = $(COND_WINDOWS_IMPLIB_1___advdll___importlib)
@COND_GCC_PCH_1@__advdll_PCH_INC = -I./.pch/wxprec_advdll
-@COND_ICC_PCH_1@__advdll_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__advdll_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_advdll/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_advdll_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_advdll/wx/wxprec.h.gch
@COND_MONOLITHIC_0_SHARED_0_USE_GUI_1@__uninstall_advlib___depname \
@COND_MONOLITHIC_0_SHARED_0_USE_GUI_1@ = uninstall_advlib
@COND_GCC_PCH_1@__advlib_PCH_INC = -I./.pch/wxprec_advlib
-@COND_ICC_PCH_1@__advlib_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__advlib_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_advlib/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_advlib_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_advlib/wx/wxprec.h.gch
-Wl,--out-implib=$(LIBDIRNAME)/$(LIBPREFIX)wx_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_media-$(WX_RELEASE)$(HOST_SUFFIX).$(DLLIMP_SUFFIX)
@COND_WINDOWS_IMPLIB_1@__mediadll___importlib = $(COND_WINDOWS_IMPLIB_1___mediadll___importlib)
@COND_GCC_PCH_1@__mediadll_PCH_INC = -I./.pch/wxprec_mediadll
-@COND_ICC_PCH_1@__mediadll_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__mediadll_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_mediadll/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_mediadll_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_mediadll/wx/wxprec.h.gch
@COND_MONOLITHIC_0_SHARED_0_USE_GUI_1_USE_MEDIA_1@__uninstall_medialib___depname \
@COND_MONOLITHIC_0_SHARED_0_USE_GUI_1_USE_MEDIA_1@ = uninstall_medialib
@COND_GCC_PCH_1@__medialib_PCH_INC = -I./.pch/wxprec_medialib
-@COND_ICC_PCH_1@__medialib_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__medialib_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_medialib/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_medialib_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_medialib/wx/wxprec.h.gch
-Wl,--out-implib=$(LIBDIRNAME)/$(LIBPREFIX)wx_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_html-$(WX_RELEASE)$(HOST_SUFFIX).$(DLLIMP_SUFFIX)
@COND_WINDOWS_IMPLIB_1@__htmldll___importlib = $(COND_WINDOWS_IMPLIB_1___htmldll___importlib)
@COND_GCC_PCH_1@__htmldll_PCH_INC = -I./.pch/wxprec_htmldll
-@COND_ICC_PCH_1@__htmldll_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__htmldll_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_htmldll/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_htmldll_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_htmldll/wx/wxprec.h.gch
@COND_MONOLITHIC_0_SHARED_0_USE_GUI_1_USE_HTML_1@__uninstall_htmllib___depname \
@COND_MONOLITHIC_0_SHARED_0_USE_GUI_1_USE_HTML_1@ = uninstall_htmllib
@COND_GCC_PCH_1@__htmllib_PCH_INC = -I./.pch/wxprec_htmllib
-@COND_ICC_PCH_1@__htmllib_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__htmllib_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_htmllib/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_htmllib_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_htmllib/wx/wxprec.h.gch
-Wl,--out-implib=$(LIBDIRNAME)/$(LIBPREFIX)wx_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_qa-$(WX_RELEASE)$(HOST_SUFFIX).$(DLLIMP_SUFFIX)
@COND_WINDOWS_IMPLIB_1@__qadll___importlib = $(COND_WINDOWS_IMPLIB_1___qadll___importlib)
@COND_GCC_PCH_1@__qadll_PCH_INC = -I./.pch/wxprec_qadll
-@COND_ICC_PCH_1@__qadll_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__qadll_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_qadll/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_qadll_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_qadll/wx/wxprec.h.gch
@COND_MONOLITHIC_0_SHARED_0_USE_GUI_1_USE_QA_1@__uninstall_qalib___depname \
@COND_MONOLITHIC_0_SHARED_0_USE_GUI_1_USE_QA_1@ = uninstall_qalib
@COND_GCC_PCH_1@__qalib_PCH_INC = -I./.pch/wxprec_qalib
-@COND_ICC_PCH_1@__qalib_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__qalib_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_qalib/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_qalib_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_qalib/wx/wxprec.h.gch
-Wl,--out-implib=$(LIBDIRNAME)/$(LIBPREFIX)wx_base$(WXBASEPORT)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_xml-$(WX_RELEASE)$(HOST_SUFFIX).$(DLLIMP_SUFFIX)
@COND_WINDOWS_IMPLIB_1@__xmldll___importlib = $(COND_WINDOWS_IMPLIB_1___xmldll___importlib)
@COND_GCC_PCH_1@__xmldll_PCH_INC = -I./.pch/wxprec_xmldll
-@COND_ICC_PCH_1@__xmldll_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__xmldll_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_xmldll/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_xmldll_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_xmldll/wx/wxprec.h.gch
@COND_MONOLITHIC_0_SHARED_0@__install_xmllib___depname = install_xmllib
@COND_MONOLITHIC_0_SHARED_0@__uninstall_xmllib___depname = uninstall_xmllib
@COND_GCC_PCH_1@__xmllib_PCH_INC = -I./.pch/wxprec_xmllib
-@COND_ICC_PCH_1@__xmllib_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__xmllib_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_xmllib/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_xmllib_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_xmllib/wx/wxprec.h.gch
-Wl,--out-implib=$(LIBDIRNAME)/$(LIBPREFIX)wx_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_xrc-$(WX_RELEASE)$(HOST_SUFFIX).$(DLLIMP_SUFFIX)
@COND_WINDOWS_IMPLIB_1@__xrcdll___importlib = $(COND_WINDOWS_IMPLIB_1___xrcdll___importlib)
@COND_GCC_PCH_1@__xrcdll_PCH_INC = -I./.pch/wxprec_xrcdll
-@COND_ICC_PCH_1@__xrcdll_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__xrcdll_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_xrcdll/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_xrcdll_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_xrcdll/wx/wxprec.h.gch
@COND_MONOLITHIC_0_SHARED_0_USE_XRC_1@__uninstall_xrclib___depname \
@COND_MONOLITHIC_0_SHARED_0_USE_XRC_1@ = uninstall_xrclib
@COND_GCC_PCH_1@__xrclib_PCH_INC = -I./.pch/wxprec_xrclib
-@COND_ICC_PCH_1@__xrclib_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__xrclib_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_xrclib/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_xrclib_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_xrclib/wx/wxprec.h.gch
-Wl,--out-implib=$(LIBDIRNAME)/$(LIBPREFIX)wx_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_aui-$(WX_RELEASE)$(HOST_SUFFIX).$(DLLIMP_SUFFIX)
@COND_WINDOWS_IMPLIB_1@__auidll___importlib = $(COND_WINDOWS_IMPLIB_1___auidll___importlib)
@COND_GCC_PCH_1@__auidll_PCH_INC = -I./.pch/wxprec_auidll
-@COND_ICC_PCH_1@__auidll_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__auidll_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_auidll/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_auidll_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_auidll/wx/wxprec.h.gch
@COND_MONOLITHIC_0_SHARED_0_USE_AUI_1@__uninstall_auilib___depname \
@COND_MONOLITHIC_0_SHARED_0_USE_AUI_1@ = uninstall_auilib
@COND_GCC_PCH_1@__auilib_PCH_INC = -I./.pch/wxprec_auilib
-@COND_ICC_PCH_1@__auilib_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__auilib_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_auilib/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_auilib_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_auilib/wx/wxprec.h.gch
-Wl,--out-implib=$(LIBDIRNAME)/$(LIBPREFIX)wx_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_propgrid-$(WX_RELEASE)$(HOST_SUFFIX).$(DLLIMP_SUFFIX)
@COND_WINDOWS_IMPLIB_1@__propgriddll___importlib = $(COND_WINDOWS_IMPLIB_1___propgriddll___importlib)
@COND_GCC_PCH_1@__propgriddll_PCH_INC = -I./.pch/wxprec_propgriddll
-@COND_ICC_PCH_1@__propgriddll_PCH_INC = \
-@COND_ICC_PCH_1@ $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__propgriddll_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_propgriddll/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_propgriddll_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_propgriddll/wx/wxprec.h.gch
@COND_MONOLITHIC_0_SHARED_0_USE_PROPGRID_1@__uninstall_propgridlib___depname \
@COND_MONOLITHIC_0_SHARED_0_USE_PROPGRID_1@ = uninstall_propgridlib
@COND_GCC_PCH_1@__propgridlib_PCH_INC = -I./.pch/wxprec_propgridlib
-@COND_ICC_PCH_1@__propgridlib_PCH_INC = \
-@COND_ICC_PCH_1@ $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__propgridlib_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_propgridlib/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_propgridlib_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_propgridlib/wx/wxprec.h.gch
-Wl,--out-implib=$(LIBDIRNAME)/$(LIBPREFIX)wx_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_richtext-$(WX_RELEASE)$(HOST_SUFFIX).$(DLLIMP_SUFFIX)
@COND_WINDOWS_IMPLIB_1@__richtextdll___importlib = $(COND_WINDOWS_IMPLIB_1___richtextdll___importlib)
@COND_GCC_PCH_1@__richtextdll_PCH_INC = -I./.pch/wxprec_richtextdll
-@COND_ICC_PCH_1@__richtextdll_PCH_INC = \
-@COND_ICC_PCH_1@ $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__richtextdll_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_richtextdll/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_richtextdll_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_richtextdll/wx/wxprec.h.gch
@COND_MONOLITHIC_0_SHARED_0_USE_RICHTEXT_1@__uninstall_richtextlib___depname \
@COND_MONOLITHIC_0_SHARED_0_USE_RICHTEXT_1@ = uninstall_richtextlib
@COND_GCC_PCH_1@__richtextlib_PCH_INC = -I./.pch/wxprec_richtextlib
-@COND_ICC_PCH_1@__richtextlib_PCH_INC = \
-@COND_ICC_PCH_1@ $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__richtextlib_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_richtextlib/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_richtextlib_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_richtextlib/wx/wxprec.h.gch
-Wl,--out-implib=$(LIBDIRNAME)/$(LIBPREFIX)wx_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_stc-$(WX_RELEASE)$(HOST_SUFFIX).$(DLLIMP_SUFFIX)
@COND_WINDOWS_IMPLIB_1@__stcdll___importlib = $(COND_WINDOWS_IMPLIB_1___stcdll___importlib)
@COND_GCC_PCH_1@__stcdll_PCH_INC = -I./.pch/wxprec_stcdll
-@COND_ICC_PCH_1@__stcdll_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__stcdll_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_stcdll/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_stcdll_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_stcdll/wx/wxprec.h.gch
@COND_MONOLITHIC_0_SHARED_0_USE_STC_1@__uninstall_stclib___depname \
@COND_MONOLITHIC_0_SHARED_0_USE_STC_1@ = uninstall_stclib
@COND_GCC_PCH_1@__stclib_PCH_INC = -I./.pch/wxprec_stclib
-@COND_ICC_PCH_1@__stclib_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__stclib_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_stclib/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_stclib_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_stclib/wx/wxprec.h.gch
-Wl,--out-implib=$(LIBDIRNAME)/$(LIBPREFIX)wx_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_gl-$(WX_RELEASE)$(HOST_SUFFIX).$(DLLIMP_SUFFIX)
@COND_WINDOWS_IMPLIB_1@__gldll___importlib = $(COND_WINDOWS_IMPLIB_1___gldll___importlib)
@COND_GCC_PCH_1@__gldll_PCH_INC = -I./.pch/wxprec_gldll
-@COND_ICC_PCH_1@__gldll_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__gldll_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_gldll/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_gldll_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_gldll/wx/wxprec.h.gch
@COND_SHARED_0_USE_GUI_1_USE_OPENGL_1@__uninstall_gllib___depname \
@COND_SHARED_0_USE_GUI_1_USE_OPENGL_1@ = uninstall_gllib
@COND_GCC_PCH_1@__gllib_PCH_INC = -I./.pch/wxprec_gllib
-@COND_ICC_PCH_1@__gllib_PCH_INC = $(ICC_PCH_USE_SWITCH) \
+@COND_ICC_PCH_1@__gllib_PCH_INC = -use_pch \
@COND_ICC_PCH_1@ ./.pch/wxprec_gllib/wx/wxprec.h.gch
@COND_USE_PCH_1@_____pch_wxprec_gllib_wx_wxprec_h_gch___depname \
@COND_USE_PCH_1@ = ./.pch/wxprec_gllib/wx/wxprec.h.gch
@COND_USE_GUI_1@monodll_sizer.o: $(srcdir)/src/common/sizer.cpp $(MONODLL_ODEP)
@COND_USE_GUI_1@ $(CXXC) -c -o $@ $(MONODLL_CXXFLAGS) $(srcdir)/src/common/sizer.cpp
+@COND_USE_GUI_1@monodll_spinbuttcmn.o: $(srcdir)/src/common/spinbuttcmn.cpp $(MONODLL_ODEP)
+@COND_USE_GUI_1@ $(CXXC) -c -o $@ $(MONODLL_CXXFLAGS) $(srcdir)/src/common/spinbuttcmn.cpp
+
+@COND_USE_GUI_1@monodll_spinctrlcmn.o: $(srcdir)/src/common/spinctrlcmn.cpp $(MONODLL_ODEP)
+@COND_USE_GUI_1@ $(CXXC) -c -o $@ $(MONODLL_CXXFLAGS) $(srcdir)/src/common/spinctrlcmn.cpp
+
@COND_USE_GUI_1@monodll_srchcmn.o: $(srcdir)/src/common/srchcmn.cpp $(MONODLL_ODEP)
@COND_USE_GUI_1@ $(CXXC) -c -o $@ $(MONODLL_CXXFLAGS) $(srcdir)/src/common/srchcmn.cpp
@COND_USE_GUI_1@monolib_sizer.o: $(srcdir)/src/common/sizer.cpp $(MONOLIB_ODEP)
@COND_USE_GUI_1@ $(CXXC) -c -o $@ $(MONOLIB_CXXFLAGS) $(srcdir)/src/common/sizer.cpp
+@COND_USE_GUI_1@monolib_spinbuttcmn.o: $(srcdir)/src/common/spinbuttcmn.cpp $(MONOLIB_ODEP)
+@COND_USE_GUI_1@ $(CXXC) -c -o $@ $(MONOLIB_CXXFLAGS) $(srcdir)/src/common/spinbuttcmn.cpp
+
+@COND_USE_GUI_1@monolib_spinctrlcmn.o: $(srcdir)/src/common/spinctrlcmn.cpp $(MONOLIB_ODEP)
+@COND_USE_GUI_1@ $(CXXC) -c -o $@ $(MONOLIB_CXXFLAGS) $(srcdir)/src/common/spinctrlcmn.cpp
+
@COND_USE_GUI_1@monolib_srchcmn.o: $(srcdir)/src/common/srchcmn.cpp $(MONOLIB_ODEP)
@COND_USE_GUI_1@ $(CXXC) -c -o $@ $(MONOLIB_CXXFLAGS) $(srcdir)/src/common/srchcmn.cpp
@COND_USE_GUI_1@coredll_sizer.o: $(srcdir)/src/common/sizer.cpp $(COREDLL_ODEP)
@COND_USE_GUI_1@ $(CXXC) -c -o $@ $(COREDLL_CXXFLAGS) $(srcdir)/src/common/sizer.cpp
+@COND_USE_GUI_1@coredll_spinbuttcmn.o: $(srcdir)/src/common/spinbuttcmn.cpp $(COREDLL_ODEP)
+@COND_USE_GUI_1@ $(CXXC) -c -o $@ $(COREDLL_CXXFLAGS) $(srcdir)/src/common/spinbuttcmn.cpp
+
+@COND_USE_GUI_1@coredll_spinctrlcmn.o: $(srcdir)/src/common/spinctrlcmn.cpp $(COREDLL_ODEP)
+@COND_USE_GUI_1@ $(CXXC) -c -o $@ $(COREDLL_CXXFLAGS) $(srcdir)/src/common/spinctrlcmn.cpp
+
@COND_USE_GUI_1@coredll_srchcmn.o: $(srcdir)/src/common/srchcmn.cpp $(COREDLL_ODEP)
@COND_USE_GUI_1@ $(CXXC) -c -o $@ $(COREDLL_CXXFLAGS) $(srcdir)/src/common/srchcmn.cpp
@COND_USE_GUI_1@corelib_sizer.o: $(srcdir)/src/common/sizer.cpp $(CORELIB_ODEP)
@COND_USE_GUI_1@ $(CXXC) -c -o $@ $(CORELIB_CXXFLAGS) $(srcdir)/src/common/sizer.cpp
+@COND_USE_GUI_1@corelib_spinbuttcmn.o: $(srcdir)/src/common/spinbuttcmn.cpp $(CORELIB_ODEP)
+@COND_USE_GUI_1@ $(CXXC) -c -o $@ $(CORELIB_CXXFLAGS) $(srcdir)/src/common/spinbuttcmn.cpp
+
+@COND_USE_GUI_1@corelib_spinctrlcmn.o: $(srcdir)/src/common/spinctrlcmn.cpp $(CORELIB_ODEP)
+@COND_USE_GUI_1@ $(CXXC) -c -o $@ $(CORELIB_CXXFLAGS) $(srcdir)/src/common/spinctrlcmn.cpp
+
@COND_USE_GUI_1@corelib_srchcmn.o: $(srcdir)/src/common/srchcmn.cpp $(CORELIB_ODEP)
@COND_USE_GUI_1@ $(CXXC) -c -o $@ $(CORELIB_CXXFLAGS) $(srcdir)/src/common/srchcmn.cpp
src/common/rgncmn.cpp
src/common/settcmn.cpp
src/common/sizer.cpp
+ src/common/spinbuttcmn.cpp
+ src/common/spinctrlcmn.cpp
src/common/srchcmn.cpp
src/common/statbar.cpp
src/common/stattextcmn.cpp
$(OBJS)\monodll_rgncmn.obj \
$(OBJS)\monodll_settcmn.obj \
$(OBJS)\monodll_sizer.obj \
+ $(OBJS)\monodll_spinbuttcmn.obj \
+ $(OBJS)\monodll_spinctrlcmn.obj \
$(OBJS)\monodll_srchcmn.obj \
$(OBJS)\monodll_statbar.obj \
$(OBJS)\monodll_stattextcmn.obj \
$(OBJS)\monodll_rgncmn.obj \
$(OBJS)\monodll_settcmn.obj \
$(OBJS)\monodll_sizer.obj \
+ $(OBJS)\monodll_spinbuttcmn.obj \
+ $(OBJS)\monodll_spinctrlcmn.obj \
$(OBJS)\monodll_srchcmn.obj \
$(OBJS)\monodll_statbar.obj \
$(OBJS)\monodll_stattextcmn.obj \
$(OBJS)\monolib_rgncmn.obj \
$(OBJS)\monolib_settcmn.obj \
$(OBJS)\monolib_sizer.obj \
+ $(OBJS)\monolib_spinbuttcmn.obj \
+ $(OBJS)\monolib_spinctrlcmn.obj \
$(OBJS)\monolib_srchcmn.obj \
$(OBJS)\monolib_statbar.obj \
$(OBJS)\monolib_stattextcmn.obj \
$(OBJS)\monolib_rgncmn.obj \
$(OBJS)\monolib_settcmn.obj \
$(OBJS)\monolib_sizer.obj \
+ $(OBJS)\monolib_spinbuttcmn.obj \
+ $(OBJS)\monolib_spinctrlcmn.obj \
$(OBJS)\monolib_srchcmn.obj \
$(OBJS)\monolib_statbar.obj \
$(OBJS)\monolib_stattextcmn.obj \
$(OBJS)\coredll_rgncmn.obj \
$(OBJS)\coredll_settcmn.obj \
$(OBJS)\coredll_sizer.obj \
+ $(OBJS)\coredll_spinbuttcmn.obj \
+ $(OBJS)\coredll_spinctrlcmn.obj \
$(OBJS)\coredll_srchcmn.obj \
$(OBJS)\coredll_statbar.obj \
$(OBJS)\coredll_stattextcmn.obj \
$(OBJS)\coredll_rgncmn.obj \
$(OBJS)\coredll_settcmn.obj \
$(OBJS)\coredll_sizer.obj \
+ $(OBJS)\coredll_spinbuttcmn.obj \
+ $(OBJS)\coredll_spinctrlcmn.obj \
$(OBJS)\coredll_srchcmn.obj \
$(OBJS)\coredll_statbar.obj \
$(OBJS)\coredll_stattextcmn.obj \
$(OBJS)\corelib_rgncmn.obj \
$(OBJS)\corelib_settcmn.obj \
$(OBJS)\corelib_sizer.obj \
+ $(OBJS)\corelib_spinbuttcmn.obj \
+ $(OBJS)\corelib_spinctrlcmn.obj \
$(OBJS)\corelib_srchcmn.obj \
$(OBJS)\corelib_statbar.obj \
$(OBJS)\corelib_stattextcmn.obj \
$(OBJS)\corelib_rgncmn.obj \
$(OBJS)\corelib_settcmn.obj \
$(OBJS)\corelib_sizer.obj \
+ $(OBJS)\corelib_spinbuttcmn.obj \
+ $(OBJS)\corelib_spinctrlcmn.obj \
$(OBJS)\corelib_srchcmn.obj \
$(OBJS)\corelib_statbar.obj \
$(OBJS)\corelib_stattextcmn.obj \
$(CXX) -q -c -P -o$@ $(MONODLL_CXXFLAGS) ..\..\src\common\sizer.cpp
!endif
+!if "$(USE_GUI)" == "1"
+$(OBJS)\monodll_spinbuttcmn.obj: ..\..\src\common\spinbuttcmn.cpp
+ $(CXX) -q -c -P -o$@ $(MONODLL_CXXFLAGS) ..\..\src\common\spinbuttcmn.cpp
+!endif
+
+!if "$(USE_GUI)" == "1"
+$(OBJS)\monodll_spinctrlcmn.obj: ..\..\src\common\spinctrlcmn.cpp
+ $(CXX) -q -c -P -o$@ $(MONODLL_CXXFLAGS) ..\..\src\common\spinctrlcmn.cpp
+!endif
+
!if "$(USE_GUI)" == "1"
$(OBJS)\monodll_srchcmn.obj: ..\..\src\common\srchcmn.cpp
$(CXX) -q -c -P -o$@ $(MONODLL_CXXFLAGS) ..\..\src\common\srchcmn.cpp
$(CXX) -q -c -P -o$@ $(MONOLIB_CXXFLAGS) ..\..\src\common\sizer.cpp
!endif
+!if "$(USE_GUI)" == "1"
+$(OBJS)\monolib_spinbuttcmn.obj: ..\..\src\common\spinbuttcmn.cpp
+ $(CXX) -q -c -P -o$@ $(MONOLIB_CXXFLAGS) ..\..\src\common\spinbuttcmn.cpp
+!endif
+
+!if "$(USE_GUI)" == "1"
+$(OBJS)\monolib_spinctrlcmn.obj: ..\..\src\common\spinctrlcmn.cpp
+ $(CXX) -q -c -P -o$@ $(MONOLIB_CXXFLAGS) ..\..\src\common\spinctrlcmn.cpp
+!endif
+
!if "$(USE_GUI)" == "1"
$(OBJS)\monolib_srchcmn.obj: ..\..\src\common\srchcmn.cpp
$(CXX) -q -c -P -o$@ $(MONOLIB_CXXFLAGS) ..\..\src\common\srchcmn.cpp
$(CXX) -q -c -P -o$@ $(COREDLL_CXXFLAGS) ..\..\src\common\sizer.cpp
!endif
+!if "$(USE_GUI)" == "1"
+$(OBJS)\coredll_spinbuttcmn.obj: ..\..\src\common\spinbuttcmn.cpp
+ $(CXX) -q -c -P -o$@ $(COREDLL_CXXFLAGS) ..\..\src\common\spinbuttcmn.cpp
+!endif
+
+!if "$(USE_GUI)" == "1"
+$(OBJS)\coredll_spinctrlcmn.obj: ..\..\src\common\spinctrlcmn.cpp
+ $(CXX) -q -c -P -o$@ $(COREDLL_CXXFLAGS) ..\..\src\common\spinctrlcmn.cpp
+!endif
+
!if "$(USE_GUI)" == "1"
$(OBJS)\coredll_srchcmn.obj: ..\..\src\common\srchcmn.cpp
$(CXX) -q -c -P -o$@ $(COREDLL_CXXFLAGS) ..\..\src\common\srchcmn.cpp
$(CXX) -q -c -P -o$@ $(CORELIB_CXXFLAGS) ..\..\src\common\sizer.cpp
!endif
+!if "$(USE_GUI)" == "1"
+$(OBJS)\corelib_spinbuttcmn.obj: ..\..\src\common\spinbuttcmn.cpp
+ $(CXX) -q -c -P -o$@ $(CORELIB_CXXFLAGS) ..\..\src\common\spinbuttcmn.cpp
+!endif
+
+!if "$(USE_GUI)" == "1"
+$(OBJS)\corelib_spinctrlcmn.obj: ..\..\src\common\spinctrlcmn.cpp
+ $(CXX) -q -c -P -o$@ $(CORELIB_CXXFLAGS) ..\..\src\common\spinctrlcmn.cpp
+!endif
+
!if "$(USE_GUI)" == "1"
$(OBJS)\corelib_srchcmn.obj: ..\..\src\common\srchcmn.cpp
$(CXX) -q -c -P -o$@ $(CORELIB_CXXFLAGS) ..\..\src\common\srchcmn.cpp
$(OBJS)\monodll_rgncmn.o \
$(OBJS)\monodll_settcmn.o \
$(OBJS)\monodll_sizer.o \
+ $(OBJS)\monodll_spinbuttcmn.o \
+ $(OBJS)\monodll_spinctrlcmn.o \
$(OBJS)\monodll_srchcmn.o \
$(OBJS)\monodll_statbar.o \
$(OBJS)\monodll_stattextcmn.o \
$(OBJS)\monodll_rgncmn.o \
$(OBJS)\monodll_settcmn.o \
$(OBJS)\monodll_sizer.o \
+ $(OBJS)\monodll_spinbuttcmn.o \
+ $(OBJS)\monodll_spinctrlcmn.o \
$(OBJS)\monodll_srchcmn.o \
$(OBJS)\monodll_statbar.o \
$(OBJS)\monodll_stattextcmn.o \
$(OBJS)\monolib_rgncmn.o \
$(OBJS)\monolib_settcmn.o \
$(OBJS)\monolib_sizer.o \
+ $(OBJS)\monolib_spinbuttcmn.o \
+ $(OBJS)\monolib_spinctrlcmn.o \
$(OBJS)\monolib_srchcmn.o \
$(OBJS)\monolib_statbar.o \
$(OBJS)\monolib_stattextcmn.o \
$(OBJS)\monolib_rgncmn.o \
$(OBJS)\monolib_settcmn.o \
$(OBJS)\monolib_sizer.o \
+ $(OBJS)\monolib_spinbuttcmn.o \
+ $(OBJS)\monolib_spinctrlcmn.o \
$(OBJS)\monolib_srchcmn.o \
$(OBJS)\monolib_statbar.o \
$(OBJS)\monolib_stattextcmn.o \
$(OBJS)\coredll_rgncmn.o \
$(OBJS)\coredll_settcmn.o \
$(OBJS)\coredll_sizer.o \
+ $(OBJS)\coredll_spinbuttcmn.o \
+ $(OBJS)\coredll_spinctrlcmn.o \
$(OBJS)\coredll_srchcmn.o \
$(OBJS)\coredll_statbar.o \
$(OBJS)\coredll_stattextcmn.o \
$(OBJS)\coredll_rgncmn.o \
$(OBJS)\coredll_settcmn.o \
$(OBJS)\coredll_sizer.o \
+ $(OBJS)\coredll_spinbuttcmn.o \
+ $(OBJS)\coredll_spinctrlcmn.o \
$(OBJS)\coredll_srchcmn.o \
$(OBJS)\coredll_statbar.o \
$(OBJS)\coredll_stattextcmn.o \
$(OBJS)\corelib_rgncmn.o \
$(OBJS)\corelib_settcmn.o \
$(OBJS)\corelib_sizer.o \
+ $(OBJS)\corelib_spinbuttcmn.o \
+ $(OBJS)\corelib_spinctrlcmn.o \
$(OBJS)\corelib_srchcmn.o \
$(OBJS)\corelib_statbar.o \
$(OBJS)\corelib_stattextcmn.o \
$(OBJS)\corelib_rgncmn.o \
$(OBJS)\corelib_settcmn.o \
$(OBJS)\corelib_sizer.o \
+ $(OBJS)\corelib_spinbuttcmn.o \
+ $(OBJS)\corelib_spinctrlcmn.o \
$(OBJS)\corelib_srchcmn.o \
$(OBJS)\corelib_statbar.o \
$(OBJS)\corelib_stattextcmn.o \
$(CXX) -c -o $@ $(MONODLL_CXXFLAGS) $(CPPDEPS) $<
endif
+ifeq ($(USE_GUI),1)
+$(OBJS)\monodll_spinbuttcmn.o: ../../src/common/spinbuttcmn.cpp
+ $(CXX) -c -o $@ $(MONODLL_CXXFLAGS) $(CPPDEPS) $<
+endif
+
+ifeq ($(USE_GUI),1)
+$(OBJS)\monodll_spinctrlcmn.o: ../../src/common/spinctrlcmn.cpp
+ $(CXX) -c -o $@ $(MONODLL_CXXFLAGS) $(CPPDEPS) $<
+endif
+
ifeq ($(USE_GUI),1)
$(OBJS)\monodll_srchcmn.o: ../../src/common/srchcmn.cpp
$(CXX) -c -o $@ $(MONODLL_CXXFLAGS) $(CPPDEPS) $<
$(CXX) -c -o $@ $(MONOLIB_CXXFLAGS) $(CPPDEPS) $<
endif
+ifeq ($(USE_GUI),1)
+$(OBJS)\monolib_spinbuttcmn.o: ../../src/common/spinbuttcmn.cpp
+ $(CXX) -c -o $@ $(MONOLIB_CXXFLAGS) $(CPPDEPS) $<
+endif
+
+ifeq ($(USE_GUI),1)
+$(OBJS)\monolib_spinctrlcmn.o: ../../src/common/spinctrlcmn.cpp
+ $(CXX) -c -o $@ $(MONOLIB_CXXFLAGS) $(CPPDEPS) $<
+endif
+
ifeq ($(USE_GUI),1)
$(OBJS)\monolib_srchcmn.o: ../../src/common/srchcmn.cpp
$(CXX) -c -o $@ $(MONOLIB_CXXFLAGS) $(CPPDEPS) $<
$(CXX) -c -o $@ $(COREDLL_CXXFLAGS) $(CPPDEPS) $<
endif
+ifeq ($(USE_GUI),1)
+$(OBJS)\coredll_spinbuttcmn.o: ../../src/common/spinbuttcmn.cpp
+ $(CXX) -c -o $@ $(COREDLL_CXXFLAGS) $(CPPDEPS) $<
+endif
+
+ifeq ($(USE_GUI),1)
+$(OBJS)\coredll_spinctrlcmn.o: ../../src/common/spinctrlcmn.cpp
+ $(CXX) -c -o $@ $(COREDLL_CXXFLAGS) $(CPPDEPS) $<
+endif
+
ifeq ($(USE_GUI),1)
$(OBJS)\coredll_srchcmn.o: ../../src/common/srchcmn.cpp
$(CXX) -c -o $@ $(COREDLL_CXXFLAGS) $(CPPDEPS) $<
$(CXX) -c -o $@ $(CORELIB_CXXFLAGS) $(CPPDEPS) $<
endif
+ifeq ($(USE_GUI),1)
+$(OBJS)\corelib_spinbuttcmn.o: ../../src/common/spinbuttcmn.cpp
+ $(CXX) -c -o $@ $(CORELIB_CXXFLAGS) $(CPPDEPS) $<
+endif
+
+ifeq ($(USE_GUI),1)
+$(OBJS)\corelib_spinctrlcmn.o: ../../src/common/spinctrlcmn.cpp
+ $(CXX) -c -o $@ $(CORELIB_CXXFLAGS) $(CPPDEPS) $<
+endif
+
ifeq ($(USE_GUI),1)
$(OBJS)\corelib_srchcmn.o: ../../src/common/srchcmn.cpp
$(CXX) -c -o $@ $(CORELIB_CXXFLAGS) $(CPPDEPS) $<
$(OBJS)\monodll_rgncmn.obj \
$(OBJS)\monodll_settcmn.obj \
$(OBJS)\monodll_sizer.obj \
+ $(OBJS)\monodll_spinbuttcmn.obj \
+ $(OBJS)\monodll_spinctrlcmn.obj \
$(OBJS)\monodll_srchcmn.obj \
$(OBJS)\monodll_statbar.obj \
$(OBJS)\monodll_stattextcmn.obj \
$(OBJS)\monodll_rgncmn.obj \
$(OBJS)\monodll_settcmn.obj \
$(OBJS)\monodll_sizer.obj \
+ $(OBJS)\monodll_spinbuttcmn.obj \
+ $(OBJS)\monodll_spinctrlcmn.obj \
$(OBJS)\monodll_srchcmn.obj \
$(OBJS)\monodll_statbar.obj \
$(OBJS)\monodll_stattextcmn.obj \
$(OBJS)\monolib_rgncmn.obj \
$(OBJS)\monolib_settcmn.obj \
$(OBJS)\monolib_sizer.obj \
+ $(OBJS)\monolib_spinbuttcmn.obj \
+ $(OBJS)\monolib_spinctrlcmn.obj \
$(OBJS)\monolib_srchcmn.obj \
$(OBJS)\monolib_statbar.obj \
$(OBJS)\monolib_stattextcmn.obj \
$(OBJS)\monolib_rgncmn.obj \
$(OBJS)\monolib_settcmn.obj \
$(OBJS)\monolib_sizer.obj \
+ $(OBJS)\monolib_spinbuttcmn.obj \
+ $(OBJS)\monolib_spinctrlcmn.obj \
$(OBJS)\monolib_srchcmn.obj \
$(OBJS)\monolib_statbar.obj \
$(OBJS)\monolib_stattextcmn.obj \
$(OBJS)\coredll_rgncmn.obj \
$(OBJS)\coredll_settcmn.obj \
$(OBJS)\coredll_sizer.obj \
+ $(OBJS)\coredll_spinbuttcmn.obj \
+ $(OBJS)\coredll_spinctrlcmn.obj \
$(OBJS)\coredll_srchcmn.obj \
$(OBJS)\coredll_statbar.obj \
$(OBJS)\coredll_stattextcmn.obj \
$(OBJS)\coredll_rgncmn.obj \
$(OBJS)\coredll_settcmn.obj \
$(OBJS)\coredll_sizer.obj \
+ $(OBJS)\coredll_spinbuttcmn.obj \
+ $(OBJS)\coredll_spinctrlcmn.obj \
$(OBJS)\coredll_srchcmn.obj \
$(OBJS)\coredll_statbar.obj \
$(OBJS)\coredll_stattextcmn.obj \
$(OBJS)\corelib_rgncmn.obj \
$(OBJS)\corelib_settcmn.obj \
$(OBJS)\corelib_sizer.obj \
+ $(OBJS)\corelib_spinbuttcmn.obj \
+ $(OBJS)\corelib_spinctrlcmn.obj \
$(OBJS)\corelib_srchcmn.obj \
$(OBJS)\corelib_statbar.obj \
$(OBJS)\corelib_stattextcmn.obj \
$(OBJS)\corelib_rgncmn.obj \
$(OBJS)\corelib_settcmn.obj \
$(OBJS)\corelib_sizer.obj \
+ $(OBJS)\corelib_spinbuttcmn.obj \
+ $(OBJS)\corelib_spinctrlcmn.obj \
$(OBJS)\corelib_srchcmn.obj \
$(OBJS)\corelib_statbar.obj \
$(OBJS)\corelib_stattextcmn.obj \
$(CXX) /c /nologo /TP /Fo$@ $(MONODLL_CXXFLAGS) ..\..\src\common\sizer.cpp
!endif
+!if "$(USE_GUI)" == "1"
+$(OBJS)\monodll_spinbuttcmn.obj: ..\..\src\common\spinbuttcmn.cpp
+ $(CXX) /c /nologo /TP /Fo$@ $(MONODLL_CXXFLAGS) ..\..\src\common\spinbuttcmn.cpp
+!endif
+
+!if "$(USE_GUI)" == "1"
+$(OBJS)\monodll_spinctrlcmn.obj: ..\..\src\common\spinctrlcmn.cpp
+ $(CXX) /c /nologo /TP /Fo$@ $(MONODLL_CXXFLAGS) ..\..\src\common\spinctrlcmn.cpp
+!endif
+
!if "$(USE_GUI)" == "1"
$(OBJS)\monodll_srchcmn.obj: ..\..\src\common\srchcmn.cpp
$(CXX) /c /nologo /TP /Fo$@ $(MONODLL_CXXFLAGS) ..\..\src\common\srchcmn.cpp
$(CXX) /c /nologo /TP /Fo$@ $(MONOLIB_CXXFLAGS) ..\..\src\common\sizer.cpp
!endif
+!if "$(USE_GUI)" == "1"
+$(OBJS)\monolib_spinbuttcmn.obj: ..\..\src\common\spinbuttcmn.cpp
+ $(CXX) /c /nologo /TP /Fo$@ $(MONOLIB_CXXFLAGS) ..\..\src\common\spinbuttcmn.cpp
+!endif
+
+!if "$(USE_GUI)" == "1"
+$(OBJS)\monolib_spinctrlcmn.obj: ..\..\src\common\spinctrlcmn.cpp
+ $(CXX) /c /nologo /TP /Fo$@ $(MONOLIB_CXXFLAGS) ..\..\src\common\spinctrlcmn.cpp
+!endif
+
!if "$(USE_GUI)" == "1"
$(OBJS)\monolib_srchcmn.obj: ..\..\src\common\srchcmn.cpp
$(CXX) /c /nologo /TP /Fo$@ $(MONOLIB_CXXFLAGS) ..\..\src\common\srchcmn.cpp
$(CXX) /c /nologo /TP /Fo$@ $(COREDLL_CXXFLAGS) ..\..\src\common\sizer.cpp
!endif
+!if "$(USE_GUI)" == "1"
+$(OBJS)\coredll_spinbuttcmn.obj: ..\..\src\common\spinbuttcmn.cpp
+ $(CXX) /c /nologo /TP /Fo$@ $(COREDLL_CXXFLAGS) ..\..\src\common\spinbuttcmn.cpp
+!endif
+
+!if "$(USE_GUI)" == "1"
+$(OBJS)\coredll_spinctrlcmn.obj: ..\..\src\common\spinctrlcmn.cpp
+ $(CXX) /c /nologo /TP /Fo$@ $(COREDLL_CXXFLAGS) ..\..\src\common\spinctrlcmn.cpp
+!endif
+
!if "$(USE_GUI)" == "1"
$(OBJS)\coredll_srchcmn.obj: ..\..\src\common\srchcmn.cpp
$(CXX) /c /nologo /TP /Fo$@ $(COREDLL_CXXFLAGS) ..\..\src\common\srchcmn.cpp
$(CXX) /c /nologo /TP /Fo$@ $(CORELIB_CXXFLAGS) ..\..\src\common\sizer.cpp
!endif
+!if "$(USE_GUI)" == "1"
+$(OBJS)\corelib_spinbuttcmn.obj: ..\..\src\common\spinbuttcmn.cpp
+ $(CXX) /c /nologo /TP /Fo$@ $(CORELIB_CXXFLAGS) ..\..\src\common\spinbuttcmn.cpp
+!endif
+
+!if "$(USE_GUI)" == "1"
+$(OBJS)\corelib_spinctrlcmn.obj: ..\..\src\common\spinctrlcmn.cpp
+ $(CXX) /c /nologo /TP /Fo$@ $(CORELIB_CXXFLAGS) ..\..\src\common\spinctrlcmn.cpp
+!endif
+
!if "$(USE_GUI)" == "1"
$(OBJS)\corelib_srchcmn.obj: ..\..\src\common\srchcmn.cpp
$(CXX) /c /nologo /TP /Fo$@ $(CORELIB_CXXFLAGS) ..\..\src\common\srchcmn.cpp
$(OBJS)\monodll_rgncmn.obj &
$(OBJS)\monodll_settcmn.obj &
$(OBJS)\monodll_sizer.obj &
+ $(OBJS)\monodll_spinbuttcmn.obj &
+ $(OBJS)\monodll_spinctrlcmn.obj &
$(OBJS)\monodll_srchcmn.obj &
$(OBJS)\monodll_statbar.obj &
$(OBJS)\monodll_stattextcmn.obj &
$(OBJS)\monodll_rgncmn.obj &
$(OBJS)\monodll_settcmn.obj &
$(OBJS)\monodll_sizer.obj &
+ $(OBJS)\monodll_spinbuttcmn.obj &
+ $(OBJS)\monodll_spinctrlcmn.obj &
$(OBJS)\monodll_srchcmn.obj &
$(OBJS)\monodll_statbar.obj &
$(OBJS)\monodll_stattextcmn.obj &
$(OBJS)\monolib_rgncmn.obj &
$(OBJS)\monolib_settcmn.obj &
$(OBJS)\monolib_sizer.obj &
+ $(OBJS)\monolib_spinbuttcmn.obj &
+ $(OBJS)\monolib_spinctrlcmn.obj &
$(OBJS)\monolib_srchcmn.obj &
$(OBJS)\monolib_statbar.obj &
$(OBJS)\monolib_stattextcmn.obj &
$(OBJS)\monolib_rgncmn.obj &
$(OBJS)\monolib_settcmn.obj &
$(OBJS)\monolib_sizer.obj &
+ $(OBJS)\monolib_spinbuttcmn.obj &
+ $(OBJS)\monolib_spinctrlcmn.obj &
$(OBJS)\monolib_srchcmn.obj &
$(OBJS)\monolib_statbar.obj &
$(OBJS)\monolib_stattextcmn.obj &
$(OBJS)\coredll_rgncmn.obj &
$(OBJS)\coredll_settcmn.obj &
$(OBJS)\coredll_sizer.obj &
+ $(OBJS)\coredll_spinbuttcmn.obj &
+ $(OBJS)\coredll_spinctrlcmn.obj &
$(OBJS)\coredll_srchcmn.obj &
$(OBJS)\coredll_statbar.obj &
$(OBJS)\coredll_stattextcmn.obj &
$(OBJS)\coredll_rgncmn.obj &
$(OBJS)\coredll_settcmn.obj &
$(OBJS)\coredll_sizer.obj &
+ $(OBJS)\coredll_spinbuttcmn.obj &
+ $(OBJS)\coredll_spinctrlcmn.obj &
$(OBJS)\coredll_srchcmn.obj &
$(OBJS)\coredll_statbar.obj &
$(OBJS)\coredll_stattextcmn.obj &
$(OBJS)\corelib_rgncmn.obj &
$(OBJS)\corelib_settcmn.obj &
$(OBJS)\corelib_sizer.obj &
+ $(OBJS)\corelib_spinbuttcmn.obj &
+ $(OBJS)\corelib_spinctrlcmn.obj &
$(OBJS)\corelib_srchcmn.obj &
$(OBJS)\corelib_statbar.obj &
$(OBJS)\corelib_stattextcmn.obj &
$(OBJS)\corelib_rgncmn.obj &
$(OBJS)\corelib_settcmn.obj &
$(OBJS)\corelib_sizer.obj &
+ $(OBJS)\corelib_spinbuttcmn.obj &
+ $(OBJS)\corelib_spinctrlcmn.obj &
$(OBJS)\corelib_srchcmn.obj &
$(OBJS)\corelib_statbar.obj &
$(OBJS)\corelib_stattextcmn.obj &
$(CXX) -bt=nt -zq -fo=$^@ $(MONODLL_CXXFLAGS) $<
!endif
+!ifeq USE_GUI 1
+$(OBJS)\monodll_spinbuttcmn.obj : .AUTODEPEND ..\..\src\common\spinbuttcmn.cpp
+ $(CXX) -bt=nt -zq -fo=$^@ $(MONODLL_CXXFLAGS) $<
+!endif
+
+!ifeq USE_GUI 1
+$(OBJS)\monodll_spinctrlcmn.obj : .AUTODEPEND ..\..\src\common\spinctrlcmn.cpp
+ $(CXX) -bt=nt -zq -fo=$^@ $(MONODLL_CXXFLAGS) $<
+!endif
+
!ifeq USE_GUI 1
$(OBJS)\monodll_srchcmn.obj : .AUTODEPEND ..\..\src\common\srchcmn.cpp
$(CXX) -bt=nt -zq -fo=$^@ $(MONODLL_CXXFLAGS) $<
$(CXX) -bt=nt -zq -fo=$^@ $(MONOLIB_CXXFLAGS) $<
!endif
+!ifeq USE_GUI 1
+$(OBJS)\monolib_spinbuttcmn.obj : .AUTODEPEND ..\..\src\common\spinbuttcmn.cpp
+ $(CXX) -bt=nt -zq -fo=$^@ $(MONOLIB_CXXFLAGS) $<
+!endif
+
+!ifeq USE_GUI 1
+$(OBJS)\monolib_spinctrlcmn.obj : .AUTODEPEND ..\..\src\common\spinctrlcmn.cpp
+ $(CXX) -bt=nt -zq -fo=$^@ $(MONOLIB_CXXFLAGS) $<
+!endif
+
!ifeq USE_GUI 1
$(OBJS)\monolib_srchcmn.obj : .AUTODEPEND ..\..\src\common\srchcmn.cpp
$(CXX) -bt=nt -zq -fo=$^@ $(MONOLIB_CXXFLAGS) $<
$(CXX) -bt=nt -zq -fo=$^@ $(COREDLL_CXXFLAGS) $<
!endif
+!ifeq USE_GUI 1
+$(OBJS)\coredll_spinbuttcmn.obj : .AUTODEPEND ..\..\src\common\spinbuttcmn.cpp
+ $(CXX) -bt=nt -zq -fo=$^@ $(COREDLL_CXXFLAGS) $<
+!endif
+
+!ifeq USE_GUI 1
+$(OBJS)\coredll_spinctrlcmn.obj : .AUTODEPEND ..\..\src\common\spinctrlcmn.cpp
+ $(CXX) -bt=nt -zq -fo=$^@ $(COREDLL_CXXFLAGS) $<
+!endif
+
!ifeq USE_GUI 1
$(OBJS)\coredll_srchcmn.obj : .AUTODEPEND ..\..\src\common\srchcmn.cpp
$(CXX) -bt=nt -zq -fo=$^@ $(COREDLL_CXXFLAGS) $<
$(CXX) -bt=nt -zq -fo=$^@ $(CORELIB_CXXFLAGS) $<
!endif
+!ifeq USE_GUI 1
+$(OBJS)\corelib_spinbuttcmn.obj : .AUTODEPEND ..\..\src\common\spinbuttcmn.cpp
+ $(CXX) -bt=nt -zq -fo=$^@ $(CORELIB_CXXFLAGS) $<
+!endif
+
+!ifeq USE_GUI 1
+$(OBJS)\corelib_spinctrlcmn.obj : .AUTODEPEND ..\..\src\common\spinctrlcmn.cpp
+ $(CXX) -bt=nt -zq -fo=$^@ $(CORELIB_CXXFLAGS) $<
+!endif
+
!ifeq USE_GUI 1
$(OBJS)\corelib_srchcmn.obj : .AUTODEPEND ..\..\src\common\srchcmn.cpp
$(CXX) -bt=nt -zq -fo=$^@ $(CORELIB_CXXFLAGS) $<
# End Source File\r
# Begin Source File\r
\r
+SOURCE=..\..\src\common\spinbuttcmn.cpp\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=..\..\src\common\spinctrlcmn.cpp\r
+# End Source File\r
+# Begin Source File\r
+\r
SOURCE=..\..\src\common\srchcmn.cpp\r
# End Source File\r
# Begin Source File\r
<File\r
RelativePath="..\..\src\common\sizer.cpp">\r
</File>\r
+ <File\r
+ RelativePath="..\..\src\common\spinbuttcmn.cpp">\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\common\spinctrlcmn.cpp">\r
+ </File>\r
<File\r
RelativePath="..\..\src\common\srchcmn.cpp">\r
</File>\r
RelativePath="..\..\src\common\sizer.cpp"\r
>\r
</File>\r
+ <File\r
+ RelativePath="..\..\src\common\spinbuttcmn.cpp"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\common\spinctrlcmn.cpp"\r
+ >\r
+ </File>\r
<File\r
RelativePath="..\..\src\common\srchcmn.cpp"\r
>\r
RelativePath="..\..\src\common\sizer.cpp"\r
>\r
</File>\r
+ <File\r
+ RelativePath="..\..\src\common\spinbuttcmn.cpp"\r
+ >\r
+ </File>\r
+ <File\r
+ RelativePath="..\..\src\common\spinctrlcmn.cpp"\r
+ >\r
+ </File>\r
<File\r
RelativePath="..\..\src\common\srchcmn.cpp"\r
>\r
#! /bin/sh
-# From configure.in Id: configure.in 58007 2009-01-11 00:46:55Z VZ .
+# From configure.in Id: configure.in 58009 2009-01-11 00:57:08Z VZ .
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.61 for wxWidgets 2.9.0.
#
echo "${ECHO_T}$result" >&6; }
+cat >>confdefs.h <<\_ACEOF
+#define wxEVENTS_COMPATIBILITY_2_8 0
+_ACEOF
+
+
enablestring=disable
defaultval=
WX_ARG_ENABLE(compat26, [ --enable-compat26 enable wxWidgets 2.6 compatibility], WXWIN_COMPATIBILITY_2_6)
WX_ARG_DISABLE(compat28, [ --disable-compat28 disable wxWidgets 2.8 compatibility], WXWIN_COMPATIBILITY_2_8)
+dnl currently we don't provide a switch for disabling it as it shouldn't be
+dnl necessary to do it unless the compiler doesn't support the new events and
+dnl this should be tested for by configure itself (but also isn't done yet
+dnl because there are no known examples of such compilers among the currently
+dnl supported ones)
+AC_DEFINE(wxEVENTS_COMPATIBILITY_2_8, 0)
+
WX_ARG_DISABLE(rpath, [ --disable-rpath disable use of rpath for uninstalled builds], wxUSE_RPATH)
WX_ARG_ENABLE(objc_uniquifying,[ --enable-objc_uniquifying enable Objective-C class name uniquifying], wxUSE_OBJC_UNIQUIFYING)
- Event loops, timers and sockets can now be used in wxBase, without GUI.
+- Events can now be connected to any functor, not necessarily a method of
+ wxEvtHandler-derived class. The compile-time safety was also improved.
+
- Documentation for wxWidgets has been converted from LaTex to C++ headers
with Doxygen comments and significantly improved in the process (screenshots
of various controls were added, more identifiers are now linked to their
virtual int FilterEvent(wxEvent& event);
#if wxUSE_EXCEPTIONS
+ // execute the functor to handle the given event
+ //
+ // this is a generalization of HandleEvent() below and the base class
+ // implementation of CallEventHandler() still calls HandleEvent() for
+ // compatibility for functors which are just wxEventFunctions (i.e. methods
+ // of wxEvtHandler)
+ virtual void CallEventHandler(wxEvtHandler *handler,
+ wxEventFunctor& functor,
+ wxEvent& event) const;
+
// call the specified handler on the given object with the given event
//
// this method only exists to allow catching the exceptions thrown by any
#ifndef SWIG
-BEGIN_DECLARE_EVENT_TYPES()
- DECLARE_EXPORTED_EVENT_TYPE(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUITOOLBAR_TOOL_DROPDOWN, 0)
- DECLARE_EXPORTED_EVENT_TYPE(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUITOOLBAR_OVERFLOW_CLICK, 0)
- DECLARE_EXPORTED_EVENT_TYPE(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUITOOLBAR_RIGHT_CLICK, 0)
- DECLARE_EXPORTED_EVENT_TYPE(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUITOOLBAR_MIDDLE_CLICK, 0)
- DECLARE_EXPORTED_EVENT_TYPE(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUITOOLBAR_BEGIN_DRAG, 0)
-END_DECLARE_EVENT_TYPES()
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUITOOLBAR_TOOL_DROPDOWN, wxAuiToolBarEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUITOOLBAR_OVERFLOW_CLICK, wxAuiToolBarEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUITOOLBAR_RIGHT_CLICK, wxAuiToolBarEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUITOOLBAR_MIDDLE_CLICK, wxAuiToolBarEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUITOOLBAR_BEGIN_DRAG, wxAuiToolBarEvent )
typedef void (wxEvtHandler::*wxAuiToolBarEventFunction)(wxAuiToolBarEvent&);
#define wxAuiToolBarEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxAuiToolBarEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxAuiToolBarEventFunction, func)
#define EVT_AUITOOLBAR_TOOL_DROPDOWN(winid, fn) \
wx__DECLARE_EVT1(wxEVT_COMMAND_AUITOOLBAR_TOOL_DROPDOWN, winid, wxAuiToolBarEventHandler(fn))
void OnChildFocusNotebook(wxChildFocusEvent& evt);
void OnRender(wxAuiManagerEvent& evt);
void OnSize(wxSizeEvent& evt);
- void OnTabClicked(wxCommandEvent& evt);
- void OnTabBeginDrag(wxCommandEvent& evt);
- void OnTabDragMotion(wxCommandEvent& evt);
- void OnTabEndDrag(wxCommandEvent& evt);
- void OnTabButton(wxCommandEvent& evt);
- void OnTabMiddleDown(wxCommandEvent& evt);
- void OnTabMiddleUp(wxCommandEvent& evt);
- void OnTabRightDown(wxCommandEvent& evt);
- void OnTabRightUp(wxCommandEvent& evt);
- void OnTabBgDClick(wxCommandEvent& evt);
+ void OnTabClicked(wxAuiNotebookEvent& evt);
+ void OnTabBeginDrag(wxAuiNotebookEvent& evt);
+ void OnTabDragMotion(wxAuiNotebookEvent& evt);
+ void OnTabEndDrag(wxAuiNotebookEvent& evt);
+ void OnTabButton(wxAuiNotebookEvent& evt);
+ void OnTabMiddleDown(wxAuiNotebookEvent& evt);
+ void OnTabMiddleUp(wxAuiNotebookEvent& evt);
+ void OnTabRightDown(wxAuiNotebookEvent& evt);
+ void OnTabRightUp(wxAuiNotebookEvent& evt);
+ void OnTabBgDClick(wxAuiNotebookEvent& evt);
void OnNavigationKeyNotebook(wxNavigationKeyEvent& event);
// set selection to the given window (which must be non-NULL and be one of
#ifndef SWIG
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSE;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_COMMAND_AUINOTEBOOK_PAGE_CHANGED;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_COMMAND_AUINOTEBOOK_PAGE_CHANGING;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSED;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_COMMAND_AUINOTEBOOK_BUTTON;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_COMMAND_AUINOTEBOOK_BEGIN_DRAG;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_COMMAND_AUINOTEBOOK_END_DRAG;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_COMMAND_AUINOTEBOOK_DRAG_MOTION;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_COMMAND_AUINOTEBOOK_ALLOW_DND;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_COMMAND_AUINOTEBOOK_TAB_MIDDLE_DOWN;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_COMMAND_AUINOTEBOOK_TAB_MIDDLE_UP;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_COMMAND_AUINOTEBOOK_TAB_RIGHT_DOWN;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_COMMAND_AUINOTEBOOK_TAB_RIGHT_UP;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_COMMAND_AUINOTEBOOK_DRAG_DONE;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_COMMAND_AUINOTEBOOK_BG_DCLICK;
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSE, wxAuiNotebookEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUINOTEBOOK_PAGE_CHANGED, wxAuiNotebookEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUINOTEBOOK_PAGE_CHANGING, wxAuiNotebookEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSED, wxAuiNotebookEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUINOTEBOOK_BUTTON, wxAuiNotebookEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUINOTEBOOK_BEGIN_DRAG, wxAuiNotebookEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUINOTEBOOK_END_DRAG, wxAuiNotebookEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUINOTEBOOK_DRAG_MOTION, wxAuiNotebookEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUINOTEBOOK_ALLOW_DND, wxAuiNotebookEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUINOTEBOOK_TAB_MIDDLE_DOWN, wxAuiNotebookEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUINOTEBOOK_TAB_MIDDLE_UP, wxAuiNotebookEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUINOTEBOOK_TAB_RIGHT_DOWN, wxAuiNotebookEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUINOTEBOOK_TAB_RIGHT_UP, wxAuiNotebookEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUINOTEBOOK_DRAG_DONE, wxAuiNotebookEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_AUI, wxEVT_COMMAND_AUINOTEBOOK_BG_DCLICK, wxAuiNotebookEvent)
typedef void (wxEvtHandler::*wxAuiNotebookEventFunction)(wxAuiNotebookEvent&);
#define wxAuiNotebookEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxAuiNotebookEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxAuiNotebookEventFunction, func)
#define EVT_AUINOTEBOOK_PAGE_CLOSE(winid, fn) \
wx__DECLARE_EVT1(wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSE, winid, wxAuiNotebookEventHandler(fn))
#ifndef SWIG
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_AUI_PANE_BUTTON;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_AUI_PANE_CLOSE;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_AUI_PANE_MAXIMIZE;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_AUI_PANE_RESTORE;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_AUI_RENDER;
-extern WXDLLIMPEXP_AUI const wxEventType wxEVT_AUI_FIND_MANAGER;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_AUI, wxEVT_AUI_PANE_BUTTON, wxAuiManagerEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_AUI, wxEVT_AUI_PANE_CLOSE, wxAuiManagerEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_AUI, wxEVT_AUI_PANE_MAXIMIZE, wxAuiManagerEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_AUI, wxEVT_AUI_PANE_RESTORE, wxAuiManagerEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_AUI, wxEVT_AUI_RENDER, wxAuiManagerEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_AUI, wxEVT_AUI_FIND_MANAGER, wxAuiManagerEvent )
typedef void (wxEvtHandler::*wxAuiManagerEventFunction)(wxAuiManagerEvent&);
#define wxAuiManagerEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxAuiManagerEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxAuiManagerEventFunction, func)
#define EVT_AUI_PANE_BUTTON(func) \
wx__DECLARE_EVT0(wxEVT_AUI_PANE_BUTTON, wxAuiManagerEventHandler(func))
typedef void (wxEvtHandler::*wxBookCtrlEventFunction)(wxBookCtrlEvent&);
#define wxBookCtrlEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxBookCtrlEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxBookCtrlEventFunction, func)
// obsolete name, defined for compatibility only
#define wxBookCtrlBaseEvent wxBookCtrlEvent
// calendar event types and macros for handling them
// ----------------------------------------------------------------------------
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_CALENDAR_SEL_CHANGED;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_CALENDAR_PAGE_CHANGED;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_CALENDAR_DOUBLECLICKED;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_CALENDAR_WEEKDAY_CLICKED;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_CALENDAR_SEL_CHANGED, wxCalendarEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_CALENDAR_PAGE_CHANGED, wxCalendarEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_CALENDAR_DOUBLECLICKED, wxCalendarEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_CALENDAR_WEEKDAY_CLICKED, wxCalendarEvent )
// deprecated events
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_CALENDAR_DAY_CHANGED;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_CALENDAR_MONTH_CHANGED;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_CALENDAR_YEAR_CHANGED;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_CALENDAR_DAY_CHANGED, wxCalendarEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_CALENDAR_MONTH_CHANGED, wxCalendarEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_CALENDAR_YEAR_CHANGED, wxCalendarEvent )
typedef void (wxEvtHandler::*wxCalendarEventFunction)(wxCalendarEvent&);
#define wxCalendarEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxCalendarEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxCalendarEventFunction, func)
#define wx__DECLARE_CALEVT(evt, id, fn) \
wx__DECLARE_EVT1(wxEVT_CALENDAR_ ## evt, id, wxCalendarEventHandler(fn))
class WXDLLIMPEXP_FWD_CORE wxChoice;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGING;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGED, wxBookCtrlEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGING, wxBookCtrlEvent )
// wxChoicebook flags
#define wxCHB_DEFAULT wxBK_DEFAULT
DECLARE_DYNAMIC_CLASS_NO_ASSIGN(wxClipboardEvent)
};
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_CLIPBOARD_CHANGED;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_CLIPBOARD_CHANGED, wxClipboardEvent )
typedef void (wxEvtHandler::*wxClipboardEventFunction)(wxClipboardEvent&);
#define wxClipboardEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxClipboardEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxClipboardEventFunction, func)
#define EVT_CLIPBOARD_CHANGED(func) wx__DECLARE_EVT0(wxEVT_CLIPBOARD_CHANGED, wxClipboardEventHandler(func))
// wxColourPickerEvent: used by wxColourPickerCtrl only
// ----------------------------------------------------------------------------
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_COLOURPICKER_CHANGED;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_COLOURPICKER_CHANGED, wxColourPickerEvent )
class WXDLLIMPEXP_CORE wxColourPickerEvent : public wxCommandEvent
{
typedef void (wxEvtHandler::*wxColourPickerEventFunction)(wxColourPickerEvent&);
#define wxColourPickerEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxColourPickerEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxColourPickerEventFunction, func)
#define EVT_COLOURPICKER_CHANGED(id, fn) \
wx__DECLARE_EVT1(wxEVT_COMMAND_COLOURPICKER_CHANGED, id, wxColourPickerEventHandler(fn))
// event types and macros
// ----------------------------------------------------------------------------
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_COLLPANE_CHANGED;
+class WXDLLIMPEXP_FWD_CORE wxCollapsiblePaneEvent;
+
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_COLLPANE_CHANGED, wxCollapsiblePaneEvent )
class WXDLLIMPEXP_CORE wxCollapsiblePaneEvent : public wxCommandEvent
{
typedef void (wxEvtHandler::*wxCollapsiblePaneEventFunction)(wxCollapsiblePaneEvent&);
#define wxCollapsiblePaneEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxCollapsiblePaneEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxCollapsiblePaneEventFunction, func)
#define EVT_COLLAPSIBLEPANE_CHANGED(id, fn) \
wx__DECLARE_EVT1(wxEVT_COMMAND_COLLPANE_CHANGED, id, wxCollapsiblePaneEventHandler(fn))
DECLARE_DYNAMIC_CLASS_NO_ASSIGN(wxDataViewEvent)
};
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_COMMAND_DATAVIEW_SELECTION_CHANGED;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_COMMAND_DATAVIEW_SELECTION_CHANGED, wxDataViewEvent )
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_COMMAND_DATAVIEW_ITEM_ACTIVATED;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_COMMAND_DATAVIEW_ITEM_COLLAPSED;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_COMMAND_DATAVIEW_ITEM_EXPANDED;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_COMMAND_DATAVIEW_ITEM_COLLAPSING;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_COMMAND_DATAVIEW_ITEM_EXPANDING;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_COMMAND_DATAVIEW_ITEM_EDITING_STARTED;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_COMMAND_DATAVIEW_ITEM_EDITING_DONE;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_COMMAND_DATAVIEW_ITEM_VALUE_CHANGED;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_COMMAND_DATAVIEW_ITEM_ACTIVATED, wxDataViewEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_COMMAND_DATAVIEW_ITEM_COLLAPSED, wxDataViewEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_COMMAND_DATAVIEW_ITEM_EXPANDED, wxDataViewEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_COMMAND_DATAVIEW_ITEM_COLLAPSING, wxDataViewEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_COMMAND_DATAVIEW_ITEM_EXPANDING, wxDataViewEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_COMMAND_DATAVIEW_ITEM_EDITING_STARTED, wxDataViewEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_COMMAND_DATAVIEW_ITEM_EDITING_DONE, wxDataViewEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_COMMAND_DATAVIEW_ITEM_VALUE_CHANGED, wxDataViewEvent )
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_COMMAND_DATAVIEW_ITEM_CONTEXT_MENU;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_COMMAND_DATAVIEW_ITEM_CONTEXT_MENU, wxDataViewEvent )
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_COMMAND_DATAVIEW_COLUMN_HEADER_CLICK;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_COMMAND_DATAVIEW_COLUMN_HEADER_RIGHT_CLICK;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_COMMAND_DATAVIEW_COLUMN_SORTED;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_COMMAND_DATAVIEW_COLUMN_REORDERED;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_COMMAND_DATAVIEW_COLUMN_HEADER_CLICK, wxDataViewEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_COMMAND_DATAVIEW_COLUMN_HEADER_RIGHT_CLICK, wxDataViewEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_COMMAND_DATAVIEW_COLUMN_SORTED, wxDataViewEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_COMMAND_DATAVIEW_COLUMN_REORDERED, wxDataViewEvent )
typedef void (wxEvtHandler::*wxDataViewEventFunction)(wxDataViewEvent&);
#define wxDataViewEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxDataViewEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxDataViewEventFunction, func)
#define wx__DECLARE_DATAVIEWEVT(evt, id, fn) \
wx__DECLARE_EVT1(wxEVT_COMMAND_DATAVIEW_ ## evt, id, wxDataViewEventHandler(fn))
// event types and macros for handling them
// ----------------------------------------------------------------------------
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_DATE_CHANGED;
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_ADV, wxEVT_DATE_CHANGED, wxDateEvent)
typedef void (wxEvtHandler::*wxDateEventFunction)(wxDateEvent&);
#define wxDateEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxDateEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxDateEventFunction, func)
#define EVT_DATE_CHANGED(id, fn) \
wx__DECLARE_EVT1(wxEVT_DATE_CHANGED, id, wxDateEventHandler(fn))
// wxDialUpManager events
// ----------------------------------------------------------------------------
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_DIALUP_CONNECTED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_DIALUP_DISCONNECTED;
+class WXDLLIMPEXP_FWD_CORE wxDialUpEvent;
+
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_DIALUP_CONNECTED, wxDialUpEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_DIALUP_DISCONNECTED, wxDialUpEvent )
// the event class for the dialup events
class WXDLLIMPEXP_CORE wxDialUpEvent : public wxEvent
typedef void (wxEvtHandler::*wxDialUpEventFunction)(wxDialUpEvent&);
#define wxDialUpEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxDialUpEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxDialUpEventFunction, func)
// macros to catch dialup events
#define EVT_DIALUP_CONNECTED(func) \
// ----------------------------------------------------------------------------
class WXDLLIMPEXP_FWD_BASE wxList;
+class WXDLLIMPEXP_FWD_BASE wxEvent;
#if wxUSE_GUI
class WXDLLIMPEXP_FWD_CORE wxDC;
class WXDLLIMPEXP_FWD_CORE wxMenu;
#define wxStaticCastEvent(type, val) static_cast<type>(val)
#define DECLARE_EVENT_TABLE_ENTRY(type, winid, idLast, fn, obj) \
- wxEventTableEntry(type, winid, idLast, fn, obj)
+ wxEventTableEntry(type, winid, idLast, wxNewEventFunctor(type, fn), obj)
+
+#define DECLARE_EVENT_TABLE_TERMINATOR() \
+ wxEventTableEntry(wxEVT_NULL, 0, 0, 0, 0)
// obsolete event declaration/definition macros, we don't need them any longer
// but we keep them for compatibility as it doesn't cost us anything anyhow
// generate a new unique event type
extern WXDLLIMPEXP_BASE wxEventType wxNewEventType();
+// macros to create an event type depending on whether type safe events are
+// enabled.
+
+#if wxEVENTS_COMPATIBILITY_2_8
+ #define wxDEFINE_EVENT( name, type ) \
+ const wxEventType name( wxNewEventType() );
+
+ #define wxDECLARE_EXPORTED_EVENT( expdecl, name, type ) \
+ extern const expdecl wxEventType name;
+
+ #define wxDEFINE_EVENT_REFERENCE( name, type, value ) \
+ const wxEventType &name( value );
+
+ #define wxDECLARE_EXPORTED_EVENT_REFERENCE( expdecl, name, type ) \
+ extern const expdecl wxEventType &name;
+
+ #define wxDECLARE_LOCAL_EVENT( name, type ) \
+ wxDECLARE_EXPORTED_EVENT( wxEMPTY_PARAMETER_VALUE, name, type )
+
+ #define wxEVENT_HANDLER_CAST( functype, func ) \
+ ( wxObjectEventFunction )( wxEventFunction )wxStaticCastEvent( functype, &func )
+#else
+ #define wxDEFINE_EVENT( name, type ) \
+ const wxTypedEventType< type > name( wxNewEventType() );
+
+ #define wxDECLARE_EXPORTED_EVENT( expdecl, name, type ) \
+ extern const expdecl wxTypedEventType< type > name;
+
+ #define wxDEFINE_EVENT_REFERENCE( name, type, value ) \
+ const wxTypedEventTypeReference< type > name( value );
+
+ #define wxDECLARE_EXPORTED_EVENT_REFERENCE( expdecl, name, type ) \
+ extern const expdecl wxTypedEventTypeReference< type > name;
+
+ #define wxDECLARE_LOCAL_EVENT( name, type ) \
+ wxDECLARE_EXPORTED_EVENT( wxEMPTY_PARAMETER_VALUE, name, type )
+
+ #define wxEVENT_HANDLER_CAST( functype, func ) \
+ ( &func )
+#endif
+
+// template which associates the correct event object with the event type
+
+#if !wxEVENTS_COMPATIBILITY_2_8
+
+template <typename Event>
+class WXDLLIMPEXP_BASE wxTypedEventType
+{
+public:
+ typedef Event CorrespondingEvent;
+
+ wxTypedEventType(wxEventType type) { m_type = type; }
+
+ // used for static event tables
+ operator const wxEventType&() const { return m_type; }
+
+private:
+ wxEventType m_type;
+};
+
+// Due to a bug in older wx versions wxSpinEvents were being sent with type of
+// wxEVT_SCROLL_LINEUP, wxEVT_SCROLL_LINEDOWN and wxEVT_SCROLL_THUMBTRACK. But
+// with the type-safe events in place, these event types are associated with
+// wxScrollEvent. To allow handling of spin events, new event types have been
+// defined in spinbutt.h/spinnbuttcmn.cpp. To maintain backward compatibility
+// the spin event types are being initialized with the scroll event types. But
+// this presents as with the same static initialization order problem we also
+// have for the static event tables. So we use the same solution and the
+// template definition below holds a reference to a wxEventType.
+template <typename Event>
+class WXDLLIMPEXP_BASE wxTypedEventTypeReference
+{
+public:
+ typedef Event CorrespondingEvent;
+
+ wxTypedEventTypeReference(const wxEventType& type) : m_type(type) { }
+
+ // used for static event tables
+ operator const wxEventType&() const { return m_type; }
+
+private:
+ const wxEventType &m_type;
+};
+
+#endif // !wxEVENTS_COMPATIBILITY_2_8
+
+// These are needed for the functor definitions
+typedef void (wxEvtHandler::*wxEventFunction)(wxEvent&);
+
+// We had some trouble (specifically with eVC for ARM WinCE build) with using
+// wxEventFunction in the past so we had introduced wxObjectEventFunction which
+// used to be a typedef for a member of wxObject and not wxEvtHandler to work
+// around this but as eVC is not really supported any longer we now only keep
+// this for backwards compatibility and, despite its name, this is a typedef
+// for wxEvtHandler member now -- but if we have the same problem with another
+// compiler we can restore its old definition for it.
+typedef wxEventFunction wxObjectEventFunction;
+
+
+// the functors which will be stored in the static/dynamic tables
+class WXDLLIMPEXP_BASE wxEventFunctor
+{
+public:
+ virtual ~wxEventFunctor();
+
+ virtual void operator()(wxEvtHandler *, wxEvent &) = 0;
+
+ virtual bool operator==(const wxEventFunctor& other) const = 0;
+
+ virtual wxEvtHandler *GetHandler() const { return NULL; }
+
+ virtual wxObjectEventFunction GetMethod() const { return NULL; }
+};
+
+// A plain method functor
+class WXDLLIMPEXP_BASE wxObjectEventFunctor : public wxEventFunctor
+{
+public:
+ wxObjectEventFunctor(wxObjectEventFunction method, wxEvtHandler *handler)
+ {
+ m_handler = handler;
+ m_method = method;
+ }
+
+ virtual void operator()(wxEvtHandler *handler, wxEvent& event)
+ {
+ wxEvtHandler * const realHandler = m_handler ? m_handler : handler;
+
+ (realHandler->*m_method)(event);
+ }
+
+ virtual bool operator==(const wxEventFunctor& other) const
+ {
+ wxEvtHandler * const handler = other.GetHandler();
+ const wxObjectEventFunction method = other.GetMethod();
+
+ return (m_handler == handler || !handler) &&
+ (m_method == method || !method);
+ }
+
+ virtual wxEvtHandler *GetHandler() const { return m_handler; }
+ virtual wxObjectEventFunction GetMethod() const { return m_method; }
+
+private:
+ wxEvtHandler *m_handler;
+ wxObjectEventFunction m_method;
+};
+
+#if !wxEVENTS_COMPATIBILITY_2_8
+
+template <typename EventType>
+class WXDLLIMPEXP_BASE wxEventFunctorFunction : public wxEventFunctor
+{
+public:
+ wxEventFunctorFunction(void (*handler)(typename EventType::CorrespondingEvent &))
+ {
+ m_handler = handler;
+ }
+
+ virtual void operator()(wxEvtHandler *WXUNUSED(handler), wxEvent& event)
+ {
+ // Protect against wrong event i.e. wxMouseEvent evt(wxEVT_PAINT):
+ wxASSERT( dynamic_cast< typename EventType::CorrespondingEvent * >( &event ) != NULL );
+
+ // Will throw a std::bad_cast exception in release build:
+ ( *m_handler )( dynamic_cast< typename EventType::CorrespondingEvent & >( event ));
+ }
+
+ virtual bool operator == ( const wxEventFunctor &right ) const
+ {
+ wxEventFunctorFunction const &other = dynamic_cast< wxEventFunctorFunction const & >( right );
+
+ return m_handler == other.m_handler || other.m_handler == NULL;
+ }
+
+private:
+ void ( *m_handler )( typename EventType::CorrespondingEvent & );
+};
+
+
+template <typename EventType, typename Class, typename Derived>
+class WXDLLIMPEXP_BASE wxEventFunctorMethod : public wxEventFunctor
+{
+public:
+ wxEventFunctorMethod( void ( Class::*method )( typename EventType::CorrespondingEvent & ),
+ Derived *handler )
+ {
+ m_handler = handler;
+ m_method = method;
+ }
+
+ virtual void operator () ( wxEvtHandler *handler, wxEvent &event )
+ {
+ // Compile-time type check 1: This requires Derived to derive from or
+ // be of the same type as Class
+ Class *realHandler = m_handler;
+
+ if( m_handler == NULL )
+ {
+ // Verify that the handler does indeed derive from the class
+ // containing the handler method
+ wxASSERT( dynamic_cast< Class * >( handler) != NULL );
+
+ realHandler = dynamic_cast< Class * >( handler );
+ }
+
+ // Protect against wrong event i.e. wxMouseEvent evt(wxEVT_PAINT):
+ wxASSERT( dynamic_cast< typename EventType::CorrespondingEvent * >( &event ) != NULL );
+
+ // Will throw a std::bad_cast exception in release build:
+ ( realHandler->*m_method )( dynamic_cast< typename EventType::CorrespondingEvent & >( event ));
+ }
+
+ virtual bool operator == ( const wxEventFunctor &right ) const
+ {
+ wxEventFunctorMethod const &other = dynamic_cast< wxEventFunctorMethod const & >( right );
+
+ return (( m_handler == other.m_handler || other.m_handler == NULL ) &&
+ ( m_method == other.m_method || other.m_method == NULL ));
+ }
+
+ virtual wxEvtHandler *GetHandler() const
+ {
+ // This makes sure Derived derives from wxEvtHandler (it is still
+ // possible and even ok if Class does not derive from wxEvtHandler. In
+ // this case Derived would end up using multiple inheritance: class
+ // Derived : public wxEvtHandler, public Class { } where Class contains
+ // the method to call, but wxEvtHandler contains the wxTrackable and
+ // code for weak ref support
+ return m_handler;
+ }
+
+ virtual wxObjectEventFunction GetMethod() const
+ {
+ return reinterpret_cast<wxObjectEventFunction>(m_method);
+ }
+
+private:
+ Derived *m_handler;
+ void (Class::*m_method)(typename EventType::CorrespondingEvent&);
+};
+
+
+template <typename EventType, typename Functor>
+class WXDLLIMPEXP_BASE wxEventFunctorAdapter : public wxEventFunctor
+{
+public:
+ wxEventFunctorAdapter( Functor &functor )
+ {
+ m_functor = functor;
+ }
+
+ virtual void operator () ( wxEvtHandler *WXUNUSED( handler ), wxEvent &event )
+ {
+ // Protect against wrong event i.e. wxMouseEvent evt(wxEVT_PAINT):
+ wxASSERT( dynamic_cast< typename EventType::CorrespondingEvent * >( &event ) != NULL );
+
+ // Will throw a std::bad_cast exception in release build:
+ m_functor( dynamic_cast< typename EventType::CorrespondingEvent & >( event ));
+ }
+
+ virtual bool operator == ( const wxEventFunctor &right ) const
+ {
+ wxEventFunctorAdapter const &other = dynamic_cast< wxEventFunctorAdapter const & >( right );
+
+ return m_functor == other.m_functor;
+ }
+
+private:
+ Functor m_functor;
+};
+
+#endif // wxEVENTS_COMPATIBILITY_2_8
+
+// Create a functor for the legacy events:
+
+inline wxObjectEventFunctor *
+wxNewEventFunctor(wxEventType WXUNUSED(evtType),
+ wxObjectEventFunction method,
+ wxEvtHandler *handler = NULL)
+{
+ return new wxObjectEventFunctor(method, handler);
+}
+
+inline wxObjectEventFunctor
+wxConstructEventFunctor(wxEventType WXUNUSED(evtType),
+ wxObjectEventFunction method,
+ wxEvtHandler *handler = NULL)
+{
+ return wxObjectEventFunctor(method, handler);
+}
+
+#if !wxEVENTS_COMPATIBILITY_2_8
+
+//
+// Create functors for the templatized events (needed in wxEvtHandler::Connect):
+//
+
+// Create a functor for functions:
+
+template <typename EventType>
+inline wxEventFunctorFunction<EventType> *
+wxNewEventFunctor(const EventType &,
+ void (*function)(typename EventType::CorrespondingEvent&))
+{
+ return new wxEventFunctorFunction<EventType>(function);
+}
+
+// Create a functor for methods:
+
+template <typename EventType, typename Class>
+inline wxEventFunctorMethod<EventType, Class, Class> *
+wxNewEventFunctor(const EventType &,
+ void (Class::*method)(typename EventType::CorrespondingEvent&))
+{
+ return new wxEventFunctorMethod<EventType, Class, Class>(method, NULL);
+}
+
+template <typename EventType, typename Class, typename Derived>
+inline wxEventFunctorMethod<EventType, Class, Derived> *
+wxNewEventFunctor(const EventType &,
+ void (Class::*method)(typename EventType::CorrespondingEvent &),
+ Derived *handler )
+{
+ return new wxEventFunctorMethod<EventType, Class, Derived>(method, handler);
+}
+
+// Create a functor for arbitrary functors (like boost::function):
+template <typename EventType, typename Functor>
+inline wxEventFunctorAdapter<EventType, Functor> *
+wxNewEventFunctor(const EventType &,
+ Functor& functor )
+{
+ return new wxEventFunctorAdapter<EventType, Functor>(functor);
+}
+
+//
+// Construct functors for the templatized events (needed in wxEvtHandler::Disconnect):
+//
+
+// Construct a functor for functions:
+
+template <typename EventType>
+inline wxEventFunctorFunction<EventType>
+wxConstructEventFunctor(const EventType &,
+ void (*function)(typename EventType::CorrespondingEvent&))
+{
+ return wxEventFunctorFunction<EventType>(function);
+}
+
+// Construct a functor for methods:
+
+template <typename EventType, typename Class>
+inline wxEventFunctorMethod<EventType, Class, Class>
+wxConstructEventFunctor(const EventType &,
+ void (Class::*method)(typename EventType::CorrespondingEvent&))
+{
+ return wxEventFunctorMethod<EventType, Class, Class>(method, NULL);
+}
+
+template <typename EventType, typename Class, typename Derived>
+inline wxEventFunctorMethod<EventType, Class, Derived>
+wxConstructEventFunctor(const EventType &,
+ void (Class::*method)(typename EventType::CorrespondingEvent&),
+ Derived *handler)
+{
+ return wxEventFunctorMethod<EventType, Class, Derived>(method, handler);
+}
+
+// Construct a functor for arbitrary functors (like boost:function):
+
+template <typename EventType, typename Functor>
+inline wxEventFunctorAdapter<EventType, Functor>
+wxConstructEventFunctor(const EventType &,
+ Functor& functor)
+{
+ return wxEventFunctorAdapter<EventType, Functor>(functor);
+}
+
+#endif // !wxEVENTS_COMPATIBILITY_2_8
+
// many, but not all, standard event types
// some generic events
extern WXDLLIMPEXP_BASE const wxEventType wxEVT_FIRST;
extern WXDLLIMPEXP_BASE const wxEventType wxEVT_USER_FIRST;
+ // Need events declared to do this
+class WXDLLIMPEXP_FWD_CORE wxCommandEvent;
+class WXDLLIMPEXP_FWD_CORE wxMouseEvent;
+class WXDLLIMPEXP_FWD_CORE wxFocusEvent;
+class WXDLLIMPEXP_FWD_CORE wxChildFocusEvent;
+class WXDLLIMPEXP_FWD_CORE wxKeyEvent;
+class WXDLLIMPEXP_FWD_CORE wxNavigationKeyEvent;
+class WXDLLIMPEXP_FWD_CORE wxSetCursorEvent;
+class WXDLLIMPEXP_FWD_CORE wxScrollEvent;
+class WXDLLIMPEXP_FWD_CORE wxScrollWinEvent;
+class WXDLLIMPEXP_FWD_CORE wxSizeEvent;
+class WXDLLIMPEXP_FWD_CORE wxMoveEvent;
+class WXDLLIMPEXP_FWD_CORE wxCloseEvent;
+class WXDLLIMPEXP_FWD_CORE wxActivateEvent;
+class WXDLLIMPEXP_FWD_CORE wxWindowCreateEvent;
+class WXDLLIMPEXP_FWD_CORE wxWindowDestroyEvent;
+class WXDLLIMPEXP_FWD_CORE wxShowEvent;
+class WXDLLIMPEXP_FWD_CORE wxIconizeEvent;
+class WXDLLIMPEXP_FWD_CORE wxMaximizeEvent;
+class WXDLLIMPEXP_FWD_CORE wxMouseCaptureChangedEvent;
+class WXDLLIMPEXP_FWD_CORE wxMouseCaptureLostEvent;
+class WXDLLIMPEXP_FWD_CORE wxPaintEvent;
+class WXDLLIMPEXP_FWD_CORE wxEraseEvent;
+class WXDLLIMPEXP_FWD_CORE wxNcPaintEvent;
+class WXDLLIMPEXP_FWD_CORE wxMenuEvent;
+class WXDLLIMPEXP_FWD_CORE wxContextMenuEvent;
+class WXDLLIMPEXP_FWD_CORE wxSysColourChangedEvent;
+class WXDLLIMPEXP_FWD_CORE wxDisplayChangedEvent;
+class WXDLLIMPEXP_FWD_CORE wxQueryNewPaletteEvent;
+class WXDLLIMPEXP_FWD_CORE wxPaletteChangedEvent;
+class WXDLLIMPEXP_FWD_CORE wxJoystickEvent;
+class WXDLLIMPEXP_FWD_CORE wxDropFilesEvent;
+class WXDLLIMPEXP_FWD_CORE wxInitDialogEvent;
+class WXDLLIMPEXP_FWD_CORE wxIdleEvent;
+class WXDLLIMPEXP_FWD_CORE wxUpdateUIEvent;
+class WXDLLIMPEXP_FWD_CORE wxClipboardTextEvent;
+class WXDLLIMPEXP_FWD_CORE wxHelpEvent;
+
+
// Command events
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_BUTTON_CLICKED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_CHECKBOX_CLICKED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_CHOICE_SELECTED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LISTBOX_SELECTED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LISTBOX_DOUBLECLICKED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_CHECKLISTBOX_TOGGLED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_MENU_SELECTED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_SLIDER_UPDATED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_RADIOBOX_SELECTED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_RADIOBUTTON_SELECTED;
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_LISTBOX_SELECTED, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_LISTBOX_DOUBLECLICKED, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_CHECKLISTBOX_TOGGLED, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_MENU_SELECTED, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_SLIDER_UPDATED, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_RADIOBOX_SELECTED, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_RADIOBUTTON_SELECTED, wxCommandEvent)
// wxEVT_COMMAND_SCROLLBAR_UPDATED is deprecated, use wxEVT_SCROLL... events
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_SCROLLBAR_UPDATED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_VLBOX_SELECTED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_COMBOBOX_SELECTED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TOOL_RCLICKED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TOOL_DROPDOWN_CLICKED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TOOL_ENTER;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_SPINCTRL_UPDATED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_SPINCTRLDOUBLE_UPDATED;
-
- // Sockets and timers send events, too
-extern WXDLLIMPEXP_BASE const wxEventType wxEVT_SOCKET;
-extern WXDLLIMPEXP_BASE const wxEventType wxEVT_TIMER;
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_SCROLLBAR_UPDATED, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_VLBOX_SELECTED, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_COMBOBOX_SELECTED, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_TOOL_RCLICKED, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_TOOL_DROPDOWN_CLICKED, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_TOOL_ENTER, wxCommandEvent)
// Mouse event types
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_LEFT_DOWN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_LEFT_UP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_MIDDLE_DOWN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_MIDDLE_UP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_RIGHT_DOWN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_RIGHT_UP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_MOTION;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_ENTER_WINDOW;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_LEAVE_WINDOW;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_LEFT_DCLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_MIDDLE_DCLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_RIGHT_DCLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SET_FOCUS;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_KILL_FOCUS;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_CHILD_FOCUS;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_MOUSEWHEEL;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_AUX1_DOWN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_AUX1_UP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_AUX1_DCLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_AUX2_DOWN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_AUX2_UP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_AUX2_DCLICK;
-
- // Non-client mouse events
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_NC_LEFT_DOWN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_NC_LEFT_UP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_NC_MIDDLE_DOWN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_NC_MIDDLE_UP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_NC_RIGHT_DOWN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_NC_RIGHT_UP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_NC_MOTION;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_NC_ENTER_WINDOW;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_NC_LEAVE_WINDOW;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_NC_LEFT_DCLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_NC_MIDDLE_DCLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_NC_RIGHT_DCLICK;
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_LEFT_DOWN, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_LEFT_UP, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_MIDDLE_DOWN, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_MIDDLE_UP, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_RIGHT_DOWN, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_RIGHT_UP, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_MOTION, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_ENTER_WINDOW, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_LEAVE_WINDOW, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_LEFT_DCLICK, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_MIDDLE_DCLICK, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_RIGHT_DCLICK, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SET_FOCUS, wxFocusEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_KILL_FOCUS, wxFocusEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_CHILD_FOCUS, wxChildFocusEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_MOUSEWHEEL, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_AUX1_DOWN, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_AUX1_UP, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_AUX1_DCLICK, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_AUX2_DOWN, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_AUX2_UP, wxMouseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_AUX2_DCLICK, wxMouseEvent)
// Character input event type
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_CHAR;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_CHAR_HOOK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_NAVIGATION_KEY;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_KEY_DOWN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_KEY_UP;
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_CHAR, wxKeyEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_CHAR_HOOK, wxKeyEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_NAVIGATION_KEY, wxNavigationKeyEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_KEY_DOWN, wxKeyEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_KEY_UP, wxKeyEvent)
#if wxUSE_HOTKEY
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_HOTKEY;
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_HOTKEY, wxKeyEvent)
#endif
// Set cursor event
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SET_CURSOR;
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SET_CURSOR, wxSetCursorEvent)
// wxScrollBar and wxSlider event identifiers
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SCROLL_TOP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SCROLL_BOTTOM;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SCROLL_LINEUP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SCROLL_LINEDOWN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SCROLL_PAGEUP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SCROLL_PAGEDOWN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SCROLL_THUMBTRACK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SCROLL_THUMBRELEASE;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SCROLL_CHANGED;
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SCROLL_TOP, wxScrollEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SCROLL_BOTTOM, wxScrollEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SCROLL_LINEUP, wxScrollEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SCROLL_LINEDOWN, wxScrollEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SCROLL_PAGEUP, wxScrollEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SCROLL_PAGEDOWN, wxScrollEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SCROLL_THUMBTRACK, wxScrollEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SCROLL_THUMBRELEASE, wxScrollEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SCROLL_CHANGED, wxScrollEvent)
// Scroll events from wxWindow
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SCROLLWIN_TOP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SCROLLWIN_BOTTOM;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SCROLLWIN_LINEUP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SCROLLWIN_LINEDOWN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SCROLLWIN_PAGEUP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SCROLLWIN_PAGEDOWN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SCROLLWIN_THUMBTRACK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SCROLLWIN_THUMBRELEASE;
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SCROLLWIN_TOP, wxScrollWinEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SCROLLWIN_BOTTOM, wxScrollWinEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SCROLLWIN_LINEUP, wxScrollWinEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SCROLLWIN_LINEDOWN, wxScrollWinEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SCROLLWIN_PAGEUP, wxScrollWinEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SCROLLWIN_PAGEDOWN, wxScrollWinEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SCROLLWIN_THUMBTRACK, wxScrollWinEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SCROLLWIN_THUMBRELEASE, wxScrollWinEvent)
// System events
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SIZE;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_MOVE;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_CLOSE_WINDOW;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_END_SESSION;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_QUERY_END_SESSION;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_ACTIVATE_APP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_ACTIVATE;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_CREATE;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_DESTROY;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SHOW;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_ICONIZE;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_MAXIMIZE;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_MOUSE_CAPTURE_CHANGED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_MOUSE_CAPTURE_LOST;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_PAINT;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_ERASE_BACKGROUND;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_NC_PAINT;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_PAINT_ICON;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_MENU_OPEN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_MENU_CLOSE;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_MENU_HIGHLIGHT;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_CONTEXT_MENU;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SYS_COLOUR_CHANGED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_DISPLAY_CHANGED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SETTING_CHANGED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_QUERY_NEW_PALETTE;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_PALETTE_CHANGED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_JOY_BUTTON_DOWN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_JOY_BUTTON_UP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_JOY_MOVE;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_JOY_ZMOVE;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_DROP_FILES;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_DRAW_ITEM;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_MEASURE_ITEM;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMPARE_ITEM;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_INIT_DIALOG;
-extern WXDLLIMPEXP_BASE const wxEventType wxEVT_IDLE;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_UPDATE_UI;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_SIZING;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_MOVING;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_MOVE_START;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_MOVE_END;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_HIBERNATE;
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SIZE, wxSizeEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_MOVE, wxMoveEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_CLOSE_WINDOW, wxCloseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_END_SESSION, wxCloseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_QUERY_END_SESSION, wxCloseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_ACTIVATE_APP, wxActivateEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_ACTIVATE, wxActivateEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_CREATE, wxWindowCreateEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_DESTROY, wxWindowDestroyEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SHOW, wxShowEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_ICONIZE, wxIconizeEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_MAXIMIZE, wxMaximizeEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_MOUSE_CAPTURE_CHANGED, wxMouseCaptureChangedEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_MOUSE_CAPTURE_LOST, wxMouseCaptureLostEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_PAINT, wxPaintEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_ERASE_BACKGROUND, wxEraseEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_NC_PAINT, wxNcPaintEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_MENU_OPEN, wxMenuEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_MENU_CLOSE, wxMenuEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_MENU_HIGHLIGHT, wxMenuEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_CONTEXT_MENU, wxContextMenuEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SYS_COLOUR_CHANGED, wxSysColourChangedEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_DISPLAY_CHANGED, wxDisplayChangedEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_QUERY_NEW_PALETTE, wxQueryNewPaletteEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_PALETTE_CHANGED, wxPaletteChangedEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_JOY_BUTTON_DOWN, wxJoystickEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_JOY_BUTTON_UP, wxJoystickEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_JOY_MOVE, wxJoystickEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_JOY_ZMOVE, wxJoystickEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_DROP_FILES, wxDropFilesEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_INIT_DIALOG, wxInitDialogEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_BASE, wxEVT_IDLE, wxIdleEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_UPDATE_UI, wxUpdateUIEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_SIZING, wxSizeEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_MOVING, wxMoveEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_MOVE_START, wxMoveEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_MOVE_END, wxMoveEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_HIBERNATE, wxActivateEvent)
// Clipboard events
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TEXT_COPY;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TEXT_CUT;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TEXT_PASTE;
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_TEXT_COPY, wxClipboardTextEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_TEXT_CUT, wxClipboardTextEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_TEXT_PASTE, wxClipboardTextEvent)
// Generic command events
// Note: a click is a higher-level event than button down/up
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LEFT_CLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LEFT_DCLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_RIGHT_CLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_RIGHT_DCLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_SET_FOCUS;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_KILL_FOCUS;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_ENTER;
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_LEFT_CLICK, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_LEFT_DCLICK, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_RIGHT_CLICK, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_RIGHT_DCLICK, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_SET_FOCUS, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_KILL_FOCUS, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_ENTER, wxCommandEvent)
// Help events
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_HELP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_DETAILED_HELP;
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_HELP, wxHelpEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_DETAILED_HELP, wxHelpEvent)
// these 2 events are the same
#define wxEVT_COMMAND_TOOL_CLICKED wxEVT_COMMAND_MENU_SELECTED
// wx/textctrl.h in all ports [yet], so declare it here as well
//
// still, any new code using it should include wx/textctrl.h explicitly
-extern const wxEventType WXDLLIMPEXP_CORE wxEVT_COMMAND_TEXT_UPDATED;
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_TEXT_UPDATED, wxCommandEvent)
// the predefined constants for the number of times we propagate event
// upwards window child-parent chain
// event handler and related classes
// ============================================================================
-typedef void (wxEvtHandler::*wxEventFunction)(wxEvent&);
-
-// We had some trouble (specifically with eVC for ARM WinCE build) with using
-// wxEventFunction in the past so we had introduced wxObjectEventFunction which
-// used to be a typedef for a member of wxObject and not wxEvtHandler to work
-// around this but as eVC is not really supported any longer we now only keep
-// this for backwards compatibility and, despite its name, this is a typedef
-// for wxEvtHandler member now -- but if we have the same problem with another
-// compiler we can restore its old definition for it.
-typedef wxEventFunction wxObjectEventFunction;
// struct containing the members common to static and dynamic event tables
// entries
struct WXDLLIMPEXP_BASE wxEventTableEntryBase
{
-private:
- wxEventTableEntryBase& operator=(const wxEventTableEntryBase& event);
-
-public:
wxEventTableEntryBase(int winid, int idLast,
- wxObjectEventFunction fn, wxObject *data)
+ wxEventFunctor* fn, wxObject *data)
: m_id(winid),
m_lastId(idLast),
m_fn(fn),
m_callbackUserData(data)
{ }
- wxEventTableEntryBase(const wxEventTableEntryBase& event)
- : m_id(event.m_id),
- m_lastId(event.m_lastId),
- m_fn(event.m_fn),
- m_callbackUserData(event.m_callbackUserData)
- { }
+ wxEventTableEntryBase( const wxEventTableEntryBase &entry )
+ : m_id( entry.m_id ),
+ m_lastId( entry.m_lastId ),
+ m_fn( entry.m_fn ),
+ m_callbackUserData( entry.m_callbackUserData )
+ {
+ // This is a 'hack' to ensure that only one instance tries to delete
+ // the functor pointer. It is safe as long as the only place where the
+ // copy constructor is being called is when the static event tables are
+ // being initialized (a temporary instance is created and then this
+ // constructor is called).
+
+ const_cast< wxEventTableEntryBase & >( entry ).m_fn = NULL;
+ }
+
+ ~wxEventTableEntryBase()
+ {
+ wxDELETE( m_fn );
+ }
// the range of ids for this entry: if m_lastId == wxID_ANY, the range
// consists only of m_id, otherwise it is m_id..m_lastId inclusive
int m_id,
m_lastId;
- // function to call: not wxEventFunction, because of dependency problems
- wxObjectEventFunction m_fn;
+ // function/method/functor to call
+ wxEventFunctor* m_fn;
- // arbitrary user data asosciated with the callback
+ // arbitrary user data associated with the callback
wxObject* m_callbackUserData;
+
+private:
+ wxEventTableEntryBase &operator = ( const wxEventTableEntryBase & );
};
// an entry from a static event table
struct WXDLLIMPEXP_BASE wxEventTableEntry : public wxEventTableEntryBase
{
wxEventTableEntry(const int& evType, int winid, int idLast,
- wxObjectEventFunction fn, wxObject *data)
+ wxEventFunctor* fn, wxObject *data)
: wxEventTableEntryBase(winid, idLast, fn, data),
m_eventType(evType)
{ }
const int& m_eventType;
private:
- wxEventTableEntry& operator=(const wxEventTableEntry&);
+ wxEventTableEntry &operator = ( const wxEventTableEntry & );
};
// an entry used in dynamic event table managed by wxEvtHandler::Connect()
struct WXDLLIMPEXP_BASE wxDynamicEventTableEntry : public wxEventTableEntryBase
{
wxDynamicEventTableEntry(int evType, int winid, int idLast,
- wxObjectEventFunction fn, wxObject *data, wxEvtHandler* eventSink)
+ wxEventFunctor* fn, wxObject *data)
: wxEventTableEntryBase(winid, idLast, fn, data),
- m_eventType(evType),
- m_eventSink(eventSink)
+ m_eventType(evType)
{ }
// not a reference here as we can't keep a reference to a temporary int
// do we need it
int m_eventType;
- // Pointer to object whose function is fn - so we don't assume the
- // EventFunction is always a member of the EventHandler receiving the
- // message
- wxEvtHandler* m_eventSink;
-
- DECLARE_NO_COPY_CLASS(wxDynamicEventTableEntry)
+private:
+ wxDynamicEventTableEntry &operator = ( const wxDynamicEventTableEntry & );
};
// ----------------------------------------------------------------------------
wxEventType eventType,
wxObjectEventFunction func,
wxObject *userData = (wxObject *) NULL,
- wxEvtHandler *eventSink = (wxEvtHandler *) NULL);
+ wxEvtHandler *eventSink = (wxEvtHandler *) NULL)
+ {
+ wxObjectEventFunctor *functor = wxNewEventFunctor( eventType, func, eventSink );
+
+ Subscribe( winid, lastId, eventType, functor, userData );
+ }
// Convenience function: take just one id
void Connect(int winid,
wxEventType eventType,
wxObjectEventFunction func = NULL,
wxObject *userData = (wxObject *) NULL,
- wxEvtHandler *eventSink = (wxEvtHandler *) NULL);
+ wxEvtHandler *eventSink = (wxEvtHandler *) NULL)
+ {
+ wxObjectEventFunctor functor = wxConstructEventFunctor( eventType, func, eventSink );
+
+ return Unsubscribe( winid, lastId, eventType, functor, userData );
+ }
bool Disconnect(int winid = wxID_ANY,
wxEventType eventType = wxEVT_NULL,
wxEvtHandler *eventSink = (wxEvtHandler *) NULL)
{ return Disconnect(wxID_ANY, eventType, func, userData, eventSink); }
+
+#if !wxEVENTS_COMPATIBILITY_2_8
+ //
+ // Connect a function to an event:
+ //
+ template <typename EventType>
+ void Connect(int winid,
+ int lastId,
+ const EventType &eventType,
+ void (*func)(typename EventType::CorrespondingEvent&),
+ wxObject* userData = NULL)
+ {
+ wxEventFunctorFunction< EventType > *functor = wxNewEventFunctor( eventType, func );
+
+ Subscribe( winid, lastId, eventType, functor, userData );
+ }
+
+ template <typename EventType>
+ void Connect( int winid,
+ const EventType &eventType,
+ void ( *func )( typename EventType::CorrespondingEvent & ),
+ wxObject* userData = NULL )
+ { Connect( winid, wxID_ANY, eventType, func, userData ); }
+
+ template <typename EventType>
+ void Connect( const EventType &eventType,
+ void ( *func )( typename EventType::CorrespondingEvent & ),
+ wxObject* userData = NULL )
+ { Connect( wxID_ANY, wxID_ANY, eventType, func, userData ); }
+
+ //
+ // Connect a method to an event:
+ //
+
+ template <typename EventType, typename Class>
+ void Connect( int winid,
+ int lastId,
+ const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL )
+ {
+ wxEventFunctorMethod< EventType, Class, Class > *functor =
+ wxNewEventFunctor( eventType, func, static_cast< Class * const >( this ));
+
+ Subscribe( winid, lastId, eventType, functor, userData );
+ }
+
+ template <typename EventType, typename Class>
+ void Connect( int winid,
+ const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL )
+ { Connect( winid, wxID_ANY, eventType, func, userData ); }
+
+ template <typename EventType, typename Class>
+ void Connect( const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL )
+ { Connect( wxID_ANY, wxID_ANY, eventType, func, userData ); }
+
+ template <typename EventType, typename Class, typename Derived>
+ void Connect( int winid,
+ int lastId,
+ const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL,
+ Derived *eventSink = NULL )
+ {
+ wxEventFunctorMethod< EventType, Class, Derived > *functor =
+ wxNewEventFunctor( eventType, func, eventSink );
+
+ Subscribe( winid, lastId, eventType, functor, userData );
+ }
+
+ template <typename EventType, typename Class, typename Derived>
+ void Connect( int winid,
+ const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL,
+ Derived *eventSink = NULL )
+ { Connect( winid, wxID_ANY, eventType, func, userData, eventSink ); }
+
+ template <typename EventType, typename Class, typename Derived>
+ void Connect( const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL,
+ Derived *eventSink = NULL )
+ { Connect( wxID_ANY, wxID_ANY, eventType, func, userData, eventSink ); }
+
+ template <typename Sender, typename EventType, typename Class, typename Derived>
+ static void Connect( Sender *sender,
+ int winid,
+ int lastId,
+ const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL,
+ Derived *eventSink = NULL )
+ {
+ wxEventFunctorMethod< EventType, Class, Derived > *functor =
+ wxNewEventFunctor( eventType, func, eventSink );
+
+ sender->Subscribe( winid, lastId, eventType, functor, userData );
+ }
+
+ template <typename Sender, typename EventType, typename Class, typename Derived>
+ static void Connect( Sender *sender,
+ int winid,
+ const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL,
+ Derived *eventSink = NULL )
+ { Connect( sender, winid, wxID_ANY, eventType, func, userData, eventSink ); }
+
+ template <typename Sender, typename EventType, typename Class, typename Derived>
+ static void Connect( Sender *sender,
+ const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL,
+ Derived *eventSink = NULL )
+ { Connect( sender, wxID_ANY, wxID_ANY, eventType, func, userData, eventSink ); }
+
+ //
+ // Connect an arbitrary functor to an event:
+ //
+
+ template <typename EventType, typename Functor>
+ void Connect( int winid,
+ int lastId,
+ const EventType &eventType,
+ Functor &functor,
+ wxObject* userData = NULL)
+ {
+ wxEventFunctorAdapter< EventType, Functor > *adapter =
+ wxNewEventFunctor( eventType, functor );
+
+ Subscribe( winid, lastId, eventType, adapter, userData );
+ }
+ template <typename EventType, typename Functor>
+ void Connect( int winid,
+ const EventType &eventType,
+ Functor &functor,
+ wxObject* userData = NULL)
+ { Connect( winid, wxID_ANY, eventType, functor, userData ); }
+
+ template <typename EventType, typename Functor>
+ void Connect( const EventType &eventType,
+ Functor &functor,
+ wxObject* userData = NULL)
+ { Connect( wxID_ANY, wxID_ANY, eventType, functor, userData ); }
+
+ //
+ // Disconnect a function from an event:
+ //
+
+ template <typename EventType>
+ bool Disconnect( int winid,
+ int lastId,
+ const EventType &eventType,
+ void ( *func )( typename EventType::CorrespondingEvent & ),
+ wxObject* userData = NULL )
+ {
+ wxEventFunctorFunction< EventType > functor = wxConstructEventFunctor( eventType, func );
+
+ return Unsubscribe( winid, lastId, eventType, functor, userData );
+ }
+
+ template <typename EventType>
+ bool Disconnect( int winid,
+ const EventType &eventType,
+ void ( *func )( typename EventType::CorrespondingEvent & ),
+ wxObject* userData = NULL )
+ { return Disconnect( winid, wxID_ANY, eventType, func, userData ); }
+
+ template <typename EventType>
+ bool Disconnect( const EventType &eventType,
+ void ( *func )( typename EventType::CorrespondingEvent & ),
+ wxObject* userData = NULL )
+ { return Disconnect( wxID_ANY, wxID_ANY, eventType, func, userData ); }
+
+ //
+ // Disconnect a method from an event:
+ //
+
+ template <typename EventType, typename Class>
+ bool Disconnect( int winid,
+ int lastId,
+ const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL )
+ {
+ wxEventFunctorMethod< EventType, Class, Class > functor =
+ wxConstructEventFunctor( eventType, func, static_cast< Class * const >( this ));
+
+ return Unsubscribe( winid, lastId, eventType, functor, userData );
+ }
+
+ template <typename EventType, typename Class>
+ bool Disconnect( int winid,
+ const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL )
+ { return Disconnect( winid, wxID_ANY, eventType, func, userData ); }
+
+ template <typename EventType, typename Class>
+ bool Disconnect( const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL )
+ { return Disconnect( wxID_ANY, wxID_ANY, eventType, func, userData ); }
+
+ template <typename EventType, typename Class, typename Derived>
+ bool Disconnect( int winid,
+ int lastId,
+ const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL,
+ Derived *eventSink = NULL )
+ {
+ wxEventFunctorMethod< EventType, Class, Derived > functor =
+ wxConstructEventFunctor( eventType, func, eventSink );
+
+ return Unsubscribe( winid, lastId, eventType, functor, userData );
+ }
+
+ template <typename EventType, typename Class, typename Derived>
+ bool Disconnect( int winid,
+ const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL,
+ Derived *eventSink = NULL )
+ { return Disconnect( winid, wxID_ANY, eventType, func, userData, eventSink ); }
+
+ template <typename EventType, typename Class, typename Derived>
+ bool Disconnect( const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL,
+ Derived *eventSink = NULL )
+ { return Disconnect( wxID_ANY, wxID_ANY, eventType, func, userData, eventSink ); }
+
+ template <typename Sender, typename EventType, typename Class, typename Derived>
+ static bool Disconnect( Sender *sender,
+ int winid,
+ int lastId,
+ const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL,
+ Derived *eventSink = NULL )
+ {
+ wxEventFunctorMethod< EventType, Class, Derived > functor =
+ wxConstructEventFunctor( eventType, func, eventSink );
+
+ return sender->Unsubscribe( winid, lastId, eventType, functor, userData );
+ }
+
+ template <typename Sender, typename EventType, typename Class, typename Derived>
+ static bool Disconnect( Sender *sender,
+ int winid,
+ const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL,
+ Derived *eventSink = NULL )
+ { return Disconnect( sender, winid, wxID_ANY, eventType, func, userData, eventSink ); }
+
+ template <typename Sender, typename EventType, typename Class, typename Derived>
+ static bool Disconnect( Sender *sender,
+ const EventType &eventType,
+ void ( Class::*func )( typename EventType::CorrespondingEvent & ),
+ wxObject *userData = NULL,
+ Derived *eventSink = NULL )
+ { return Disconnect( sender, wxID_ANY, wxID_ANY, eventType, func, userData, eventSink ); }
+
+ //
+ // Disconnect an arbitrary functor from an event:
+ //
+
+ template <typename EventType, typename Functor>
+ bool Disconnect( int winid,
+ int lastId,
+ const EventType &eventType,
+ Functor &functor,
+ wxObject* userData = NULL)
+ {
+ wxEventFunctorAdapter< EventType, Functor > adapter =
+ wxConstructEventFunctor( eventType, functor );
+
+ return Unsubscribe( winid, lastId, eventType, adapter, userData );
+ }
+
+ template <typename EventType, typename Functor>
+ bool Disconnect( int winid,
+ const EventType &eventType,
+ Functor &functor,
+ wxObject* userData = NULL)
+ { return Disconnect( winid, wxID_ANY, eventType, functor, userData ); }
+
+ template <typename EventType, typename Functor>
+ bool Disconnect( const EventType &eventType,
+ Functor &functor,
+ wxObject* userData = NULL)
+ { return Disconnect( wxID_ANY, wxID_ANY, eventType, functor, userData ); }
+
+#endif // !wxEVENTS_COMPATIBILITY_2_8
+
+
wxList* GetDynamicEventTable() const { return m_dynamicEvents ; }
// User data can be associated with each wxEvtHandler
private:
+ void Subscribe(int winid,
+ int lastId,
+ wxEventType eventType,
+ wxEventFunctor *func,
+ wxObject* userData);
+
+ bool Unsubscribe(int winid,
+ int lastId,
+ wxEventType eventType,
+ const wxEventFunctor &func,
+ wxObject *userData);
+
static const wxEventTableEntry sm_eventTableEntries[];
protected:
typedef void (wxEvtHandler::*wxIdleEventFunction)(wxIdleEvent&);
#define wxEventHandler(func) \
- (wxObjectEventFunction)wxStaticCastEvent(wxEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxEventFunction, func)
#define wxIdleEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxIdleEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxIdleEventFunction, func)
#if wxUSE_GUI
#define wxCommandEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxCommandEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxCommandEventFunction, func)
#define wxScrollEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxScrollEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxScrollEventFunction, func)
#define wxScrollWinEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxScrollWinEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxScrollWinEventFunction, func)
#define wxSizeEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxSizeEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxSizeEventFunction, func)
#define wxMoveEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxMoveEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxMoveEventFunction, func)
#define wxPaintEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxPaintEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxPaintEventFunction, func)
#define wxNcPaintEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxNcPaintEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxNcPaintEventFunction, func)
#define wxEraseEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxEraseEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxEraseEventFunction, func)
#define wxMouseEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxMouseEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxMouseEventFunction, func)
#define wxCharEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxCharEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxCharEventFunction, func)
#define wxKeyEventHandler(func) wxCharEventHandler(func)
#define wxFocusEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxFocusEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxFocusEventFunction, func)
#define wxChildFocusEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxChildFocusEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxChildFocusEventFunction, func)
#define wxActivateEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxActivateEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxActivateEventFunction, func)
#define wxMenuEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxMenuEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxMenuEventFunction, func)
#define wxJoystickEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxJoystickEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxJoystickEventFunction, func)
#define wxDropFilesEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxDropFilesEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxDropFilesEventFunction, func)
#define wxInitDialogEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxInitDialogEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxInitDialogEventFunction, func)
#define wxSysColourChangedEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxSysColourChangedEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxSysColourChangedEventFunction, func)
#define wxDisplayChangedEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxDisplayChangedEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxDisplayChangedEventFunction, func)
#define wxUpdateUIEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxUpdateUIEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxUpdateUIEventFunction, func)
#define wxCloseEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxCloseEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxCloseEventFunction, func)
#define wxShowEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxShowEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxShowEventFunction, func)
#define wxIconizeEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxIconizeEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxIconizeEventFunction, func)
#define wxMaximizeEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxMaximizeEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxMaximizeEventFunction, func)
#define wxNavigationKeyEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxNavigationKeyEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxNavigationKeyEventFunction, func)
#define wxPaletteChangedEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxPaletteChangedEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxPaletteChangedEventFunction, func)
#define wxQueryNewPaletteEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxQueryNewPaletteEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxQueryNewPaletteEventFunction, func)
#define wxWindowCreateEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxWindowCreateEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxWindowCreateEventFunction, func)
#define wxWindowDestroyEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxWindowDestroyEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxWindowDestroyEventFunction, func)
#define wxSetCursorEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxSetCursorEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxSetCursorEventFunction, func)
#define wxNotifyEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxNotifyEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxNotifyEventFunction, func)
#define wxHelpEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxHelpEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxHelpEventFunction, func)
#define wxContextMenuEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxContextMenuEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxContextMenuEventFunction, func)
#define wxMouseCaptureChangedEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxMouseCaptureChangedEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxMouseCaptureChangedEventFunction, func)
#define wxMouseCaptureLostEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxMouseCaptureLostEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxMouseCaptureLostEventFunction, func)
#define wxClipboardTextEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxClipboardTextEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxClipboardTextEventFunction, func)
#endif // wxUSE_GUI
template<typename T1, typename T2, typename T3, typename T4, typename T5, typename T6, typename T7, typename T8> \
const wxEventTableEntry theClass<T1, T2, T3, T4, T5, T6, T7, T8>::sm_eventTableEntries[] = { \
-#define END_EVENT_TABLE() DECLARE_EVENT_TABLE_ENTRY( wxEVT_NULL, 0, 0, 0, 0 ) };
+#define END_EVENT_TABLE() DECLARE_EVENT_TABLE_TERMINATOR() };
/*
* Event table macros
// EVT_COMMAND
#define EVT_COMMAND(winid, event, func) \
wx__DECLARE_EVT1(event, winid, wxCommandEventHandler(func))
+
#define EVT_COMMAND_RANGE(id1, id2, event, func) \
wx__DECLARE_EVT2(event, id1, id2, wxCommandEventHandler(func))
#define EVT_NOTIFY(event, winid, func) \
wx__DECLARE_EVT1(event, winid, wxNotifyEventHandler(func))
+
#define EVT_NOTIFY_RANGE(event, id1, id2, func) \
wx__DECLARE_EVT2(event, id1, id2, wxNotifyEventHandler(func))
DECLARE_DYNAMIC_CLASS_NO_ASSIGN(wxFindDialogEvent)
};
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_FIND;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_FIND_NEXT;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_FIND_REPLACE;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_FIND_REPLACE_ALL;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_FIND_CLOSE;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_FIND, wxFindDialogEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_FIND_NEXT, wxFindDialogEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_FIND_REPLACE, wxFindDialogEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_FIND_REPLACE_ALL, wxFindDialogEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_FIND_CLOSE, wxFindDialogEvent )
typedef void (wxEvtHandler::*wxFindDialogEventFunction)(wxFindDialogEvent&);
#define wxFindDialogEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxFindDialogEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxFindDialogEventFunction, func)
#define EVT_FIND(id, fn) \
wx__DECLARE_EVT1(wxEVT_COMMAND_FIND, id, wxFindDialogEventHandler(fn))
#define wxFC_DEFAULT_STYLE wxFC_OPEN
extern WXDLLIMPEXP_DATA_CORE(const char) wxFileCtrlNameStr[]; // in filectrlcmn.cpp
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_FILECTRL_SELECTIONCHANGED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_FILECTRL_FILEACTIVATED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_FILECTRL_FOLDERCHANGED;
-
class WXDLLIMPEXP_CORE wxFileCtrlBase
{
public:
typedef void ( wxEvtHandler::*wxFileCtrlEventFunction )( wxFileCtrlEvent& );
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_FILECTRL_SELECTIONCHANGED, wxFileCtrlEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_FILECTRL_FILEACTIVATED, wxFileCtrlEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_FILECTRL_FOLDERCHANGED, wxFileCtrlEvent )
+
#define wxFileCtrlEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxFileCtrlEventFunction, &func)
+ wxEVENT_HANDLER_CAST( wxFileCtrlEventFunction, func )
#define EVT_FILECTRL_FILEACTIVATED(id, fn) \
wx__DECLARE_EVT1(wxEVT_FILECTRL_FILEACTIVATED, id, wxFileCtrlEventHandler(fn))
extern WXDLLIMPEXP_DATA_CORE(const char) wxDirPickerCtrlNameStr[];
extern WXDLLIMPEXP_DATA_CORE(const char) wxDirSelectorPromptStr[];
+// ----------------------------------------------------------------------------
+// wxFileDirPickerEvent: used by wxFilePickerCtrl and wxDirPickerCtrl only
+// ----------------------------------------------------------------------------
+
+class WXDLLIMPEXP_CORE wxFileDirPickerEvent : public wxCommandEvent
+{
+public:
+ wxFileDirPickerEvent() {}
+ wxFileDirPickerEvent(wxEventType type, wxObject *generator, int id, const wxString &path)
+ : wxCommandEvent(type, id),
+ m_path(path)
+ {
+ SetEventObject(generator);
+ }
+
+ wxString GetPath() const { return m_path; }
+ void SetPath(const wxString &p) { m_path = p; }
+
+ // default copy ctor, assignment operator and dtor are ok
+ virtual wxEvent *Clone() const { return new wxFileDirPickerEvent(*this); }
+
+private:
+ wxString m_path;
+
+ DECLARE_DYNAMIC_CLASS_NO_ASSIGN(wxFileDirPickerEvent)
+};
+
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_FILEPICKER_CHANGED, wxFileDirPickerEvent );
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_DIRPICKER_CHANGED, wxFileDirPickerEvent );
+
+// ----------------------------------------------------------------------------
+// event types and macros
+// ----------------------------------------------------------------------------
+
+typedef void (wxEvtHandler::*wxFileDirPickerEventFunction)(wxFileDirPickerEvent&);
+
+#define wxFileDirPickerEventHandler(func) \
+ wxEVENT_HANDLER_CAST(wxFileDirPickerEventFunction, func)
+
+#define EVT_FILEPICKER_CHANGED(id, fn) \
+ wx__DECLARE_EVT1(wxEVT_COMMAND_FILEPICKER_CHANGED, id, wxFileDirPickerEventHandler(fn))
+#define EVT_DIRPICKER_CHANGED(id, fn) \
+ wx__DECLARE_EVT1(wxEVT_COMMAND_DIRPICKER_CHANGED, id, wxFileDirPickerEventHandler(fn))
// ----------------------------------------------------------------------------
// wxFileDirPickerWidgetBase: a generic abstract interface which must be
// Returns the event type sent by this picker
virtual wxEventType GetEventType() const = 0;
+ virtual void DoConnect( wxControl *sender, wxFileDirPickerCtrlBase *eventSink ) = 0;
+
// Returns the filtered value currently placed in the text control (if present).
virtual wxString GetTextCtrlValue() const = 0;
wxEventType GetEventType() const
{ return wxEVT_COMMAND_FILEPICKER_CHANGED; }
+ virtual void DoConnect( wxControl *sender, wxFileDirPickerCtrlBase *eventSink )
+ {
+ sender->Connect( wxEVT_COMMAND_FILEPICKER_CHANGED,
+ wxFileDirPickerEventHandler( wxFileDirPickerCtrlBase::OnFileDirChange ),
+ NULL, eventSink );
+ }
+
+
protected:
virtual
wxFileDirPickerWidgetBase *CreatePicker(wxWindow *parent,
wxEventType GetEventType() const
{ return wxEVT_COMMAND_DIRPICKER_CHANGED; }
+ virtual void DoConnect( wxControl *sender, wxFileDirPickerCtrlBase *eventSink )
+ {
+ sender->Connect( wxEVT_COMMAND_DIRPICKER_CHANGED,
+ wxFileDirPickerEventHandler( wxFileDirPickerCtrlBase::OnFileDirChange ),
+ NULL, eventSink );
+ }
+
+
protected:
virtual
wxFileDirPickerWidgetBase *CreatePicker(wxWindow *parent,
#endif // wxUSE_DIRPICKERCTRL
-
-#if wxUSE_FILEPICKERCTRL || wxUSE_DIRPICKERCTRL
-
-// ----------------------------------------------------------------------------
-// wxFileDirPickerEvent: used by wxFilePickerCtrl and wxDirPickerCtrl only
-// ----------------------------------------------------------------------------
-
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_FILEPICKER_CHANGED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_DIRPICKER_CHANGED;
-
-class WXDLLIMPEXP_CORE wxFileDirPickerEvent : public wxCommandEvent
-{
-public:
- wxFileDirPickerEvent() {}
- wxFileDirPickerEvent(wxEventType type, wxObject *generator, int id, const wxString &path)
- : wxCommandEvent(type, id),
- m_path(path)
- {
- SetEventObject(generator);
- }
-
- wxString GetPath() const { return m_path; }
- void SetPath(const wxString &p) { m_path = p; }
-
- // default copy ctor, assignment operator and dtor are ok
- virtual wxEvent *Clone() const { return new wxFileDirPickerEvent(*this); }
-
-private:
- wxString m_path;
-
- DECLARE_DYNAMIC_CLASS_NO_ASSIGN(wxFileDirPickerEvent)
-};
-
-// ----------------------------------------------------------------------------
-// event types and macros
-// ----------------------------------------------------------------------------
-
-typedef void (wxEvtHandler::*wxFileDirPickerEventFunction)(wxFileDirPickerEvent&);
-
-#define wxFileDirPickerEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxFileDirPickerEventFunction, &func)
-
-#define EVT_FILEPICKER_CHANGED(id, fn) \
- wx__DECLARE_EVT1(wxEVT_COMMAND_FILEPICKER_CHANGED, id, wxFileDirPickerEventHandler(fn))
-#define EVT_DIRPICKER_CHANGED(id, fn) \
- wx__DECLARE_EVT1(wxEVT_COMMAND_DIRPICKER_CHANGED, id, wxFileDirPickerEventHandler(fn))
-
-
-#endif // wxUSE_FILEPICKERCTRL || wxUSE_DIRPICKERCTRL
-
#endif // _WX_FILEDIRPICKER_H_BASE_
// wxFontPickerEvent: used by wxFontPickerCtrl only
// ----------------------------------------------------------------------------
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_FONTPICKER_CHANGED;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_FONTPICKER_CHANGED, wxFontPickerEvent )
class WXDLLIMPEXP_CORE wxFontPickerEvent : public wxCommandEvent
{
typedef void (wxEvtHandler::*wxFontPickerEventFunction)(wxFontPickerEvent&);
#define wxFontPickerEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxFontPickerEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxFontPickerEventFunction, func)
#define EVT_FONTPICKER_CHANGED(id, fn) \
wx__DECLARE_EVT1(wxEVT_COMMAND_FONTPICKER_CHANGED, id, wxFontPickerEventHandler(fn))
class WXDLLIMPEXP_FWD_CORE wxComboBox;
class WXDLLIMPEXP_FWD_CORE wxStaticText;
class WXDLLIMPEXP_FWD_CORE wxSpinCtrl;
+class WXDLLIMPEXP_FWD_CORE wxSpinEvent;
// ----------------------------------------------------------------------------
// wxGenericCalendarCtrl
void OnDClick(wxMouseEvent& event);
void OnChar(wxKeyEvent& event);
void OnMonthChange(wxCommandEvent& event);
- void OnYearChange(wxCommandEvent& event);
+
+ void HandleYearChange(wxCommandEvent& event);
+ void OnYearChange(wxSpinEvent& event);
void OnYearTextChange(wxCommandEvent& event);
// (re)calc m_widthCol and m_heightRow
#include "wx/dirdlg.h"
-extern WXDLLIMPEXP_DATA_CORE(const wxEventType) wxEVT_COMMAND_DIRPICKER_CHANGED;
-extern WXDLLIMPEXP_DATA_CORE(const wxEventType) wxEVT_COMMAND_FILEPICKER_CHANGED;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_DIRPICKER_CHANGED, wxFileDirPickerEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_FILEPICKER_CHANGED, wxFileDirPickerEvent )
//-----------------------------------------------------------------------------
};
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_CELL_LEFT_CLICK;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_CELL_RIGHT_CLICK;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_CELL_LEFT_DCLICK;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_CELL_RIGHT_DCLICK;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_LABEL_LEFT_CLICK;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_LABEL_RIGHT_CLICK;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_LABEL_LEFT_DCLICK;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_LABEL_RIGHT_DCLICK;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_ROW_SIZE;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_COL_SIZE;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_RANGE_SELECT;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_CELL_CHANGING;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_CELL_CHANGED;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_SELECT_CELL;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_EDITOR_SHOWN;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_EDITOR_HIDDEN;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_EDITOR_CREATED;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_CELL_BEGIN_DRAG;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_COL_MOVE;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_GRID_COL_SORT;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_CELL_LEFT_CLICK, wxGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_CELL_RIGHT_CLICK, wxGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_CELL_LEFT_DCLICK, wxGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_CELL_RIGHT_DCLICK, wxGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_LABEL_LEFT_CLICK, wxGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_LABEL_RIGHT_CLICK, wxGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_LABEL_LEFT_DCLICK, wxGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_LABEL_RIGHT_DCLICK, wxGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_ROW_SIZE, wxGridSizeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_COL_SIZE, wxGridSizeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_RANGE_SELECT, wxGridRangeSelectEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_CELL_CHANGING, wxGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_CELL_CHANGED, wxGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_SELECT_CELL, wxGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_EDITOR_SHOWN, wxGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_EDITOR_HIDDEN, wxGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_EDITOR_CREATED, wxGridEditorCreatedEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_CELL_BEGIN_DRAG, wxGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_COL_MOVE, wxGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_GRID_COL_SORT, wxGridEvent )
typedef void (wxEvtHandler::*wxGridEventFunction)(wxGridEvent&);
typedef void (wxEvtHandler::*wxGridSizeEventFunction)(wxGridSizeEvent&);
typedef void (wxEvtHandler::*wxGridEditorCreatedEventFunction)(wxGridEditorCreatedEvent&);
#define wxGridEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxGridEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxGridEventFunction, func)
#define wxGridSizeEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxGridSizeEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxGridSizeEventFunction, func)
#define wxGridRangeSelectEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxGridRangeSelectEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxGridRangeSelectEventFunction, func)
#define wxGridEditorCreatedEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxGridEditorCreatedEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxGridEditorCreatedEventFunction, func)
#define wx__DECLARE_GRIDEVT(evt, id, fn) \
wx__DECLARE_EVT1(wxEVT_GRID_ ## evt, id, wxGridEventHandler(fn))
#include "wx/event.h"
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_QUERY_LAYOUT_INFO;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_CALCULATE_LAYOUT;
+class WXDLLIMPEXP_FWD_ADV wxQueryLayoutInfoEvent;
+class WXDLLIMPEXP_FWD_ADV wxCalculateLayoutEvent;
+
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_QUERY_LAYOUT_INFO, wxQueryLayoutInfoEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_CALCULATE_LAYOUT, wxCalculateLayoutEvent )
enum wxLayoutOrientation
{
typedef void (wxEvtHandler::*wxQueryLayoutInfoEventFunction)(wxQueryLayoutInfoEvent&);
+#define wxQueryLayoutInfoEventHandler( func ) \
+ wxEVENT_HANDLER_CAST( wxQueryLayoutInfoEventFunction, func )
+
#define EVT_QUERY_LAYOUT_INFO(func) \
- DECLARE_EVENT_TABLE_ENTRY( wxEVT_QUERY_LAYOUT_INFO, wxID_ANY, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxQueryLayoutInfoEventFunction, & func ), NULL ),
+ DECLARE_EVENT_TABLE_ENTRY( wxEVT_QUERY_LAYOUT_INFO, wxID_ANY, wxID_ANY, wxQueryLayoutInfoEventHandler( func ), NULL ),
/*
* This event is used to take a bite out of the available client area.
typedef void (wxEvtHandler::*wxCalculateLayoutEventFunction)(wxCalculateLayoutEvent&);
+#define wxCalculateLayoutEventHandler( func ) wxEVENT_HANDLER_CAST(wxCalculateLayoutEventFunction, func)
+
#define EVT_CALCULATE_LAYOUT(func) \
- DECLARE_EVENT_TABLE_ENTRY( wxEVT_CALCULATE_LAYOUT, wxID_ANY, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxCalculateLayoutEventFunction, & func ), NULL ),
+ DECLARE_EVENT_TABLE_ENTRY( wxEVT_CALCULATE_LAYOUT, wxID_ANY, wxID_ANY, wxCalculateLayoutEventHandler( func ), NULL ),
#if wxUSE_SASH
DECLARE_NO_COPY_CLASS(wxSashWindow)
};
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_SASH_DRAGGED;
+class WXDLLIMPEXP_FWD_ADV wxSashEvent;
+
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_SASH_DRAGGED, wxSashEvent )
enum wxSashDragStatus
{
typedef void (wxEvtHandler::*wxSashEventFunction)(wxSashEvent&);
#define wxSashEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxSashEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxSashEventFunction, func)
#define EVT_SASH_DRAGGED(id, fn) \
wx__DECLARE_EVT1(wxEVT_SASH_DRAGGED, id, wxSashEventHandler(fn))
typedef void (wxEvtHandler::*wxSplitterEventFunction)(wxSplitterEvent&);
#define wxSplitterEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxSplitterEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxSplitterEventFunction, func)
#define wx__DECLARE_SPLITTEREVT(evt, id, fn) \
wx__DECLARE_EVT1(wxEVT_COMMAND_SPLITTER_ ## evt, id, wxSplitterEventHandler(fn))
};
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_HEADER_CLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_HEADER_RIGHT_CLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_HEADER_MIDDLE_CLICK;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_HEADER_CLICK, wxHeaderCtrlEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_HEADER_RIGHT_CLICK, wxHeaderCtrlEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_HEADER_MIDDLE_CLICK, wxHeaderCtrlEvent )
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_HEADER_DCLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_HEADER_RIGHT_DCLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_HEADER_MIDDLE_DCLICK;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_HEADER_DCLICK, wxHeaderCtrlEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_HEADER_RIGHT_DCLICK, wxHeaderCtrlEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_HEADER_MIDDLE_DCLICK, wxHeaderCtrlEvent )
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_HEADER_SEPARATOR_DCLICK;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_HEADER_SEPARATOR_DCLICK, wxHeaderCtrlEvent )
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_HEADER_BEGIN_RESIZE;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_HEADER_RESIZING;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_HEADER_END_RESIZE;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_HEADER_BEGIN_RESIZE, wxHeaderCtrlEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_HEADER_RESIZING, wxHeaderCtrlEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_HEADER_END_RESIZE, wxHeaderCtrlEvent )
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_HEADER_BEGIN_REORDER;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_HEADER_END_REORDER;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_HEADER_BEGIN_REORDER, wxHeaderCtrlEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_HEADER_END_REORDER, wxHeaderCtrlEvent )
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_HEADER_DRAGGING_CANCELLED;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_HEADER_DRAGGING_CANCELLED, wxHeaderCtrlEvent )
typedef void (wxEvtHandler::*wxHeaderCtrlEventFunction)(wxHeaderCtrlEvent&);
#define wxHeaderCtrlEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent( \
- wxHeaderCtrlEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxHeaderCtrlEventFunction, func)
#define wx__DECLARE_HEADER_EVT(evt, id, fn) \
wx__DECLARE_EVT1(wxEVT_COMMAND_HEADER_ ## evt, id, wxHeaderCtrlEventHandler(fn))
DECLARE_NO_COPY_CLASS(wxHtmlWindow)
};
+class WXDLLIMPEXP_FWD_HTML wxHtmlCellEvent;
-extern WXDLLIMPEXP_HTML const wxEventType wxEVT_COMMAND_HTML_CELL_CLICKED;
-extern WXDLLIMPEXP_HTML const wxEventType wxEVT_COMMAND_HTML_CELL_HOVER;
-extern WXDLLIMPEXP_HTML const wxEventType wxEVT_COMMAND_HTML_LINK_CLICKED;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_HTML, wxEVT_COMMAND_HTML_CELL_CLICKED, wxHtmlCellEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_HTML, wxEVT_COMMAND_HTML_CELL_HOVER, wxHtmlCellEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_HTML, wxEVT_COMMAND_HTML_LINK_CLICKED, wxHtmlLinkEvent )
/*!
typedef void (wxEvtHandler::*wxHtmlLinkEventFunction)(wxHtmlLinkEvent&);
#define wxHtmlCellEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxHtmlCellEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxHtmlCellEventFunction, func)
#define wxHtmlLinkEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxHtmlLinkEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxHtmlLinkEventFunction, func)
#define EVT_HTML_CELL_CLICKED(id, fn) \
wx__DECLARE_EVT1(wxEVT_COMMAND_HTML_CELL_CLICKED, id, wxHtmlCellEventHandler(fn))
typedef void (wxEvtHandler::*wxWebKitBeforeLoadEventFunction)(wxWebKitBeforeLoadEvent&);
typedef void (wxEvtHandler::*wxWebKitNewWindowEventFunction)(wxWebKitNewWindowEvent&);
-extern const wxEventType wxEVT_WEBKIT_BEFORE_LOAD;
-extern const wxEventType wxEVT_WEBKIT_STATE_CHANGED;
-extern const wxEventType wxEVT_WEBKIT_NEW_WINDOW;
+#define wxWebKitStateChangedEventHandler( func ) \
+ wxEVENT_HANDLER_CAST( wxWebKitStateChangedEventFunction, func )
+
+#define wxWebKitBeforeLoadEventHandler( func ) \
+ wxEVENT_HANDLER_CAST( wxWebKitBeforeLoadEventFunction, func )
+
+#define wxWebKitNewWindowEventHandler( func ) \
+ wxEVENT_HANDLER_CAST( wxWebKitNewWindowEventFunction, func )
+
+wxDECLARE_EVENT( wxEVT_WEBKIT_STATE_CHANGED, wxWebKitStateChangedEvent )
+wxDECLARE_EVENT( wxEVT_WEBKIT_BEFORE_LOAD, wxWebKitBeforeLoadEvent )
+wxDECLARE_EVENT( wxEVT_WEBKIT_NEW_WINDOW, wxWebKitNewWindowEvent )
#define EVT_WEBKIT_STATE_CHANGED(func) \
DECLARE_EVENT_TABLE_ENTRY( wxEVT_WEBKIT_STATE_CHANGED, \
wxID_ANY, \
wxID_ANY, \
- (wxObjectEventFunction) \
- (wxWebKitStateChangedEventFunction) & func, \
+ wxWebKitStateChangedEventHandler( func ), \
(wxObject *) NULL ),
#define EVT_WEBKIT_BEFORE_LOAD(func) \
DECLARE_EVENT_TABLE_ENTRY( wxEVT_WEBKIT_BEFORE_LOAD, \
wxID_ANY, \
wxID_ANY, \
- (wxObjectEventFunction) \
- (wxWebKitBeforeLoadEventFunction) & func, \
+ wxWebKitBeforeLoadEventHandler( func ), \
(wxObject *) NULL ),
#define EVT_WEBKIT_NEW_WINDOW(func) \
DECLARE_EVENT_TABLE_ENTRY( wxEVT_WEBKIT_NEW_WINDOW, \
wxID_ANY, \
wxID_ANY, \
- (wxObjectEventFunction) \
- (wxWebKitNewWindowEventFunction) & func, \
+ wxWebKitNewWindowEventFunction( func ), \
(wxObject *) NULL ),
#endif // wxUSE_WEBKIT
// wxHyperlinkEvent
// ----------------------------------------------------------------------------
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_COMMAND_HYPERLINK;
+class WXDLLIMPEXP_FWD_ADV wxHyperlinkEvent;
+
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_COMMAND_HYPERLINK, wxHyperlinkEvent )
//
// An event fired when the user clicks on the label in a hyperlink control.
typedef void (wxEvtHandler::*wxHyperlinkEventFunction)(wxHyperlinkEvent&);
#define wxHyperlinkEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxHyperlinkEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxHyperlinkEventFunction, func)
#define EVT_HYPERLINK(id, fn) \
wx__DECLARE_EVT1(wxEVT_COMMAND_HYPERLINK, id, wxHyperlinkEventHandler(fn))
// wxListCtrl event macros
// ----------------------------------------------------------------------------
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_BEGIN_DRAG;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_BEGIN_RDRAG;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_END_LABEL_EDIT;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_DELETE_ITEM;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS;
-
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_ITEM_SELECTED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_ITEM_DESELECTED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_KEY_DOWN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_INSERT_ITEM;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_COL_CLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_ITEM_ACTIVATED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_CACHE_HINT;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_COL_RIGHT_CLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_COL_BEGIN_DRAG;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_COL_DRAGGING;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_COL_END_DRAG;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LIST_ITEM_FOCUSED;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_BEGIN_DRAG, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_BEGIN_RDRAG, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_END_LABEL_EDIT, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_DELETE_ITEM, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS, wxListEvent )
+
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_ITEM_SELECTED, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_ITEM_DESELECTED, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_KEY_DOWN, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_INSERT_ITEM, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_COL_CLICK, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_ITEM_ACTIVATED, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_CACHE_HINT, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_COL_RIGHT_CLICK, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_COL_BEGIN_DRAG, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_COL_DRAGGING, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_COL_END_DRAG, wxListEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LIST_ITEM_FOCUSED, wxListEvent )
typedef void (wxEvtHandler::*wxListEventFunction)(wxListEvent&);
#define wxListEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxListEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxListEventFunction, func)
#define wx__DECLARE_LISTEVT(evt, id, fn) \
wx__DECLARE_EVT1(wxEVT_COMMAND_LIST_ ## evt, id, wxListEventHandler(fn))
class WXDLLIMPEXP_FWD_CORE wxListView;
class WXDLLIMPEXP_FWD_CORE wxListEvent;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LISTBOOK_PAGE_CHANGED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_LISTBOOK_PAGE_CHANGING;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LISTBOOK_PAGE_CHANGED, wxBookCtrlEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_LISTBOOK_PAGE_CHANGING, wxBookCtrlEvent )
// wxListbook flags
#define wxLB_DEFAULT wxBK_DEFAULT
//Our events
-extern WXDLLIMPEXP_MEDIA const wxEventType wxEVT_MEDIA_FINISHED;
-extern WXDLLIMPEXP_MEDIA const wxEventType wxEVT_MEDIA_STOP;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_MEDIA, wxEVT_MEDIA_FINISHED, wxMediaEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_MEDIA, wxEVT_MEDIA_STOP, wxMediaEvent )
//Function type(s) our events need
typedef void (wxEvtHandler::*wxMediaEventFunction)(wxMediaEvent&);
#define wxMediaEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxMediaEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxMediaEventFunction, func)
//Macro for usage with message maps
#define EVT_MEDIA_FINISHED(winid, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_MEDIA_FINISHED, winid, wxID_ANY, wxMediaEventHandler(fn), (wxObject *) NULL ),
#define EVT_MEDIA_STOP(winid, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_MEDIA_STOP, winid, wxID_ANY, wxMediaEventHandler(fn), (wxObject *) NULL ),
-extern WXDLLIMPEXP_MEDIA const wxEventType wxEVT_MEDIA_LOADED;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_MEDIA, wxEVT_MEDIA_LOADED, wxMediaEvent )
#define EVT_MEDIA_LOADED(winid, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_MEDIA_LOADED, winid, wxID_ANY, wxMediaEventHandler(fn), (wxObject *) NULL ),
-extern WXDLLIMPEXP_MEDIA const wxEventType wxEVT_MEDIA_STATECHANGED;
-extern WXDLLIMPEXP_MEDIA const wxEventType wxEVT_MEDIA_PLAY;
-extern WXDLLIMPEXP_MEDIA const wxEventType wxEVT_MEDIA_PAUSE;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_MEDIA, wxEVT_MEDIA_STATECHANGED, wxMediaEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_MEDIA, wxEVT_MEDIA_PLAY, wxMediaEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_MEDIA, wxEVT_MEDIA_PAUSE, wxMediaEvent )
#define EVT_MEDIA_STATECHANGED(winid, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_MEDIA_STATECHANGED, winid, wxID_ANY, wxMediaEventHandler(fn), (wxObject *) NULL ),
#define EVT_MEDIA_PLAY(winid, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_MEDIA_PLAY, winid, wxID_ANY, wxMediaEventHandler(fn), (wxObject *) NULL ),
#define EVT_MEDIA_PAUSE(winid, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_MEDIA_PAUSE, winid, wxID_ANY, wxMediaEventHandler(fn), (wxObject *) NULL ),
// Recommended setting: 0 (please update your code)
#define WXWIN_COMPATIBILITY_2_8 1
+// Use the 2.8-compatible events and Connect(): this is set to 0 by default as
+// the new events bring significant benefits in compile-time safety and
+// flexibility but can be disabled to somewhat reduce the compilation time and,
+// especially, to still allow building if the compiler template support is too
+// bad to compile the new code.
+//
+// Default is 0 for all compilers except VC6 currently.
+//
+// Recommended setting: 0 (please upgrade your compiler instead of changing it)
+#define wxEVENTS_COMPATIBILITY_2_8 0
+
// MSW-only: Set to 0 for accurate dialog units, else 1 for old behaviour when
// default system font is used for wxWindow::GetCharWidth/Height() instead of
// the current font.
# define wxUSE_POSTSCRIPT 1
#endif
+/* VC6 can't handle the templates for the 'type safe events': */
+#if !wxEVENTS_COMPATIBILITY_2_8
+# ifdef __VISUALC6__
+# undef wxEVENTS_COMPATIBILITY_2_8
+# define wxEVENTS_COMPATIBILITY_2_8 1
+# endif
+#endif
+
#endif /* _WX_MSW_CHKCONF_H_ */
{ return m_dispid; }
};
-#define wxACTIVEX_ID 14001
-DECLARE_EXPORTED_EVENT_TYPE(WXDLLIMPEXP_MEDIA, wxEVT_ACTIVEX, wxACTIVEX_ID)
+// #define wxACTIVEX_ID 14001
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_MEDIA, wxEVT_ACTIVEX, wxActiveXEvent )
+
typedef void (wxEvtHandler::*wxActiveXEventFunction)(wxActiveXEvent&);
-#define EVT_ACTIVEX(id, fn) DECLARE_EVENT_TABLE_ENTRY(wxEVT_ACTIVEX, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxActiveXEventFunction) & fn, (wxObject *) NULL ),
+
#define wxActiveXEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxActiveXEventFunction, &func)
+ wxEVENT_HANDLER_CAST( wxActiveXEventFunction, func )
+
+#define EVT_ACTIVEX(id, fn) DECLARE_EVENT_TABLE_ENTRY(wxEVT_ACTIVEX, id, -1, wxActiveXEventHandler( fn ), (wxObject *) NULL ),
#endif // wxUSE_ACTIVEX
// Recommended setting: 0 (please update your code)
#define WXWIN_COMPATIBILITY_2_8 1
+// Use the 2.8-compatible events and Connect(): this is set to 0 by default as
+// the new events bring significant benefits in compile-time safety and
+// flexibility but can be disabled to somewhat reduce the compilation time and,
+// especially, to still allow building if the compiler template support is too
+// bad to compile the new code.
+//
+// Default is 0 for all compilers except VC6 currently.
+//
+// Recommended setting: 0 (please upgrade your compiler instead of changing it)
+#define wxEVENTS_COMPATIBILITY_2_8 0
+
// MSW-only: Set to 0 for accurate dialog units, else 1 for old behaviour when
// default system font is used for wxWindow::GetCharWidth/Height() instead of
// the current font.
// Recommended setting: 0 (please update your code)
#define WXWIN_COMPATIBILITY_2_8 1
+// Use the 2.8-compatible events and Connect(): this is set to 0 by default as
+// the new events bring significant benefits in compile-time safety and
+// flexibility but can be disabled to somewhat reduce the compilation time and,
+// especially, to still allow building if the compiler template support is too
+// bad to compile the new code.
+//
+// Default is 0 for all compilers except VC6 currently.
+//
+// Recommended setting: 0 (please upgrade your compiler instead of changing it)
+#define wxEVENTS_COMPATIBILITY_2_8 0
+
// MSW-only: Set to 0 for accurate dialog units, else 1 for old behaviour when
// default system font is used for wxWindow::GetCharWidth/Height() instead of
// the current font.
typedef wxBookCtrlEventFunction wxNotebookEventFunction;
#define wxNotebookEventHandler(func) wxBookCtrlEventHandler(func)
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED, wxBookCtrlEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING, wxBookCtrlEvent )
#define EVT_NOTEBOOK_PAGE_CHANGED(winid, fn) \
wx__DECLARE_EVT1(wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED, winid, wxBookCtrlEventHandler(fn))
// Recommended setting: 0 (please update your code)
#define WXWIN_COMPATIBILITY_2_8 1
+// Use the 2.8-compatible events and Connect(): this is set to 0 by default as
+// the new events bring significant benefits in compile-time safety and
+// flexibility but can be disabled to somewhat reduce the compilation time and,
+// especially, to still allow building if the compiler template support is too
+// bad to compile the new code.
+//
+// Default is 0 for all compilers except VC6 currently.
+//
+// Recommended setting: 0 (please upgrade your compiler instead of changing it)
+#define wxEVENTS_COMPATIBILITY_2_8 0
+
// MSW-only: Set to 0 for accurate dialog units, else 1 for old behaviour when
// default system font is used for wxWindow::GetCharWidth/Height() instead of
// the current font.
// Recommended setting: 0 (please update your code)
#define WXWIN_COMPATIBILITY_2_8 1
+// Use the 2.8-compatible events and Connect(): this is set to 0 by default as
+// the new events bring significant benefits in compile-time safety and
+// flexibility but can be disabled to somewhat reduce the compilation time and,
+// especially, to still allow building if the compiler template support is too
+// bad to compile the new code.
+//
+// Default is 0 for all compilers except VC6 currently.
+//
+// Recommended setting: 0 (please upgrade your compiler instead of changing it)
+#define wxEVENTS_COMPATIBILITY_2_8 0
+
// MSW-only: Set to 0 for accurate dialog units, else 1 for old behaviour when
// default system font is used for wxWindow::GetCharWidth/Height() instead of
// the current font.
// Recommended setting: 0 (please update your code)
#define WXWIN_COMPATIBILITY_2_8 1
+// Use the 2.8-compatible events and Connect(): this is set to 0 by default as
+// the new events bring significant benefits in compile-time safety and
+// flexibility but can be disabled to somewhat reduce the compilation time and,
+// especially, to still allow building if the compiler template support is too
+// bad to compile the new code.
+//
+// Default is 0 for all compilers except VC6 currently.
+//
+// Recommended setting: 0 (please upgrade your compiler instead of changing it)
+#define wxEVENTS_COMPATIBILITY_2_8 0
+
// MSW-only: Set to 0 for accurate dialog units, else 1 for old behaviour when
// default system font is used for wxWindow::GetCharWidth/Height() instead of
// the current font.
DECLARE_DYNAMIC_CLASS_NO_ASSIGN(wxPowerEvent)
};
-extern WXDLLIMPEXP_BASE const wxEventType wxEVT_POWER_SUSPENDING;
-extern WXDLLIMPEXP_BASE const wxEventType wxEVT_POWER_SUSPENDED;
-extern WXDLLIMPEXP_BASE const wxEventType wxEVT_POWER_SUSPEND_CANCEL;
-extern WXDLLIMPEXP_BASE const wxEventType wxEVT_POWER_RESUME;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_BASE, wxEVT_POWER_SUSPENDING, wxPowerEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_BASE, wxEVT_POWER_SUSPENDED, wxPowerEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_BASE, wxEVT_POWER_SUSPEND_CANCEL, wxPowerEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_BASE, wxEVT_POWER_RESUME, wxPowerEvent )
typedef void (wxEvtHandler::*wxPowerEventFunction)(wxPowerEvent&);
#define wxPowerEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction) \
- wxStaticCastEvent(wxPowerEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxPowerEventFunction, func)
#define EVT_POWER_SUSPENDING(func) \
wx__DECLARE_EVT0(wxEVT_POWER_SUSPENDING, wxPowerEventHandler(func))
// wxProcess events
// ----------------------------------------------------------------------------
-extern WXDLLIMPEXP_BASE const wxEventType wxEVT_END_PROCESS;
+class WXDLLIMPEXP_FWD_BASE wxProcessEvent;
+
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_BASE, wxEVT_END_PROCESS, wxProcessEvent )
class WXDLLIMPEXP_BASE wxProcessEvent : public wxEvent
{
typedef void (wxEvtHandler::*wxProcessEventFunction)(wxProcessEvent&);
#define wxProcessEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxProcessEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxProcessEventFunction, func)
#define EVT_END_PROCESS(id, func) \
wx__DECLARE_EVT1(wxEVT_END_PROCESS, id, wxProcessEventHandler(func))
#ifndef SWIG
-extern WXDLLIMPEXP_PROPGRID const wxEventType wxEVT_PG_SELECTED;
-extern WXDLLIMPEXP_PROPGRID const wxEventType wxEVT_PG_CHANGING;
-extern WXDLLIMPEXP_PROPGRID const wxEventType wxEVT_PG_CHANGED;
-extern WXDLLIMPEXP_PROPGRID const wxEventType wxEVT_PG_HIGHLIGHTED;
-extern WXDLLIMPEXP_PROPGRID const wxEventType wxEVT_PG_RIGHT_CLICK;
-extern WXDLLIMPEXP_PROPGRID const wxEventType wxEVT_PG_PAGE_CHANGED;
-extern WXDLLIMPEXP_PROPGRID const wxEventType wxEVT_PG_ITEM_COLLAPSED;
-extern WXDLLIMPEXP_PROPGRID const wxEventType wxEVT_PG_ITEM_EXPANDED;
-extern WXDLLIMPEXP_PROPGRID const wxEventType wxEVT_PG_DOUBLE_CLICK;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_PROPGRID, wxEVT_PG_SELECTED, wxPropertyGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_PROPGRID, wxEVT_PG_CHANGING, wxPropertyGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_PROPGRID, wxEVT_PG_CHANGED, wxPropertyGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_PROPGRID, wxEVT_PG_HIGHLIGHTED, wxPropertyGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_PROPGRID, wxEVT_PG_RIGHT_CLICK, wxPropertyGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_PROPGRID, wxEVT_PG_PAGE_CHANGED, wxPropertyGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_PROPGRID, wxEVT_PG_ITEM_COLLAPSED, wxPropertyGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_PROPGRID, wxEVT_PG_ITEM_EXPANDED, wxPropertyGridEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_PROPGRID, wxEVT_PG_DOUBLE_CLICK, wxPropertyGridEvent )
#else
enum {
#ifndef SWIG
typedef void (wxEvtHandler::*wxPropertyGridEventFunction)(wxPropertyGridEvent&);
-#define EVT_PG_SELECTED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_SELECTED, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxPropertyGridEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_PG_CHANGING(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_CHANGING, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxPropertyGridEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_PG_CHANGED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_CHANGED, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxPropertyGridEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_PG_HIGHLIGHTED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_HIGHLIGHTED, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxPropertyGridEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_PG_RIGHT_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_RIGHT_CLICK, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxPropertyGridEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_PG_DOUBLE_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_DOUBLE_CLICK, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxPropertyGridEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_PG_PAGE_CHANGED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_PAGE_CHANGED, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxPropertyGridEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_PG_ITEM_COLLAPSED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_ITEM_COLLAPSED, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxPropertyGridEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_PG_ITEM_EXPANDED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_ITEM_EXPANDED, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxPropertyGridEventFunction, & fn ), (wxObject *) NULL ),
-
-#define wxPropertyGridEventHandler(A) \
- ((wxObjectEventFunction)(wxEventFunction)(wxPropertyGridEventFunction)&A)
+#define EVT_PG_SELECTED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_SELECTED, id, -1, wxEVENT_HANDLER_CAST( wxPropertyGridEventFunction, fn ), (wxObject *) NULL ),
+#define EVT_PG_CHANGING(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_CHANGING, id, -1, wxEVENT_HANDLER_CAST( wxPropertyGridEventFunction, fn ), (wxObject *) NULL ),
+#define EVT_PG_CHANGED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_CHANGED, id, -1, wxEVENT_HANDLER_CAST( wxPropertyGridEventFunction, fn ), (wxObject *) NULL ),
+#define EVT_PG_HIGHLIGHTED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_HIGHLIGHTED, id, -1, wxEVENT_HANDLER_CAST( wxPropertyGridEventFunction, fn ), (wxObject *) NULL ),
+#define EVT_PG_RIGHT_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_RIGHT_CLICK, id, -1, wxEVENT_HANDLER_CAST( wxPropertyGridEventFunction, fn ), (wxObject *) NULL ),
+#define EVT_PG_DOUBLE_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_DOUBLE_CLICK, id, -1, wxEVENT_HANDLER_CAST( wxPropertyGridEventFunction, fn ), (wxObject *) NULL ),
+#define EVT_PG_PAGE_CHANGED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_PAGE_CHANGED, id, -1, wxEVENT_HANDLER_CAST( wxPropertyGridEventFunction, fn ), (wxObject *) NULL ),
+#define EVT_PG_ITEM_COLLAPSED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_ITEM_COLLAPSED, id, -1, wxEVENT_HANDLER_CAST( wxPropertyGridEventFunction, fn ), (wxObject *) NULL ),
+#define EVT_PG_ITEM_EXPANDED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_PG_ITEM_EXPANDED, id, -1, wxEVENT_HANDLER_CAST( wxPropertyGridEventFunction, fn ), (wxObject *) NULL ),
+
+#define wxPropertyGridEventHandler(fn) \
+ wxEVENT_HANDLER_CAST( wxPropertyGridEventFunction, fn )
#endif
/*!
* wxRichTextCtrl events
*/
-extern WXDLLIMPEXP_RICHTEXT const wxEventType wxEVT_COMMAND_RICHTEXT_LEFT_CLICK;
-extern WXDLLIMPEXP_RICHTEXT const wxEventType wxEVT_COMMAND_RICHTEXT_RIGHT_CLICK;
-extern WXDLLIMPEXP_RICHTEXT const wxEventType wxEVT_COMMAND_RICHTEXT_MIDDLE_CLICK;
-extern WXDLLIMPEXP_RICHTEXT const wxEventType wxEVT_COMMAND_RICHTEXT_LEFT_DCLICK;
-extern WXDLLIMPEXP_RICHTEXT const wxEventType wxEVT_COMMAND_RICHTEXT_RETURN;
-extern WXDLLIMPEXP_RICHTEXT const wxEventType wxEVT_COMMAND_RICHTEXT_CHARACTER;
-extern WXDLLIMPEXP_RICHTEXT const wxEventType wxEVT_COMMAND_RICHTEXT_DELETE;
-
-extern WXDLLIMPEXP_RICHTEXT const wxEventType wxEVT_COMMAND_RICHTEXT_STYLESHEET_CHANGING;
-extern WXDLLIMPEXP_RICHTEXT const wxEventType wxEVT_COMMAND_RICHTEXT_STYLESHEET_CHANGED;
-extern WXDLLIMPEXP_RICHTEXT const wxEventType wxEVT_COMMAND_RICHTEXT_STYLESHEET_REPLACING;
-extern WXDLLIMPEXP_RICHTEXT const wxEventType wxEVT_COMMAND_RICHTEXT_STYLESHEET_REPLACED;
-
-extern WXDLLIMPEXP_RICHTEXT const wxEventType wxEVT_COMMAND_RICHTEXT_CONTENT_INSERTED;
-extern WXDLLIMPEXP_RICHTEXT const wxEventType wxEVT_COMMAND_RICHTEXT_CONTENT_DELETED;
-extern WXDLLIMPEXP_RICHTEXT const wxEventType wxEVT_COMMAND_RICHTEXT_STYLE_CHANGED;
-extern WXDLLIMPEXP_RICHTEXT const wxEventType wxEVT_COMMAND_RICHTEXT_SELECTION_CHANGED;
-extern WXDLLIMPEXP_RICHTEXT const wxEventType wxEVT_COMMAND_RICHTEXT_BUFFER_RESET;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_RICHTEXT, wxEVT_COMMAND_RICHTEXT_LEFT_CLICK, wxRichTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_RICHTEXT, wxEVT_COMMAND_RICHTEXT_RIGHT_CLICK, wxRichTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_RICHTEXT, wxEVT_COMMAND_RICHTEXT_MIDDLE_CLICK, wxRichTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_RICHTEXT, wxEVT_COMMAND_RICHTEXT_LEFT_DCLICK, wxRichTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_RICHTEXT, wxEVT_COMMAND_RICHTEXT_RETURN, wxRichTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_RICHTEXT, wxEVT_COMMAND_RICHTEXT_CHARACTER, wxRichTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_RICHTEXT, wxEVT_COMMAND_RICHTEXT_DELETE, wxRichTextEvent )
+
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_RICHTEXT, wxEVT_COMMAND_RICHTEXT_STYLESHEET_CHANGING, wxRichTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_RICHTEXT, wxEVT_COMMAND_RICHTEXT_STYLESHEET_CHANGED, wxRichTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_RICHTEXT, wxEVT_COMMAND_RICHTEXT_STYLESHEET_REPLACING, wxRichTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_RICHTEXT, wxEVT_COMMAND_RICHTEXT_STYLESHEET_REPLACED, wxRichTextEvent )
+
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_RICHTEXT, wxEVT_COMMAND_RICHTEXT_CONTENT_INSERTED, wxRichTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_RICHTEXT, wxEVT_COMMAND_RICHTEXT_CONTENT_DELETED, wxRichTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_RICHTEXT, wxEVT_COMMAND_RICHTEXT_STYLE_CHANGED, wxRichTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_RICHTEXT, wxEVT_COMMAND_RICHTEXT_SELECTION_CHANGED, wxRichTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_RICHTEXT, wxEVT_COMMAND_RICHTEXT_BUFFER_RESET, wxRichTextEvent )
typedef void (wxEvtHandler::*wxRichTextEventFunction)(wxRichTextEvent&);
#define wxRichTextEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxRichTextEventFunction, &func)
-
-#define EVT_RICHTEXT_LEFT_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_LEFT_CLICK, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxRichTextEventFunction, & fn ), NULL ),
-#define EVT_RICHTEXT_RIGHT_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_RIGHT_CLICK, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxRichTextEventFunction, & fn ), NULL ),
-#define EVT_RICHTEXT_MIDDLE_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_MIDDLE_CLICK, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxRichTextEventFunction, & fn ), NULL ),
-#define EVT_RICHTEXT_LEFT_DCLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_LEFT_DCLICK, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxRichTextEventFunction, & fn ), NULL ),
-#define EVT_RICHTEXT_RETURN(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_RETURN, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxRichTextEventFunction, & fn ), NULL ),
-#define EVT_RICHTEXT_CHARACTER(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_CHARACTER, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxRichTextEventFunction, & fn ), NULL ),
-#define EVT_RICHTEXT_DELETE(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_DELETE, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxRichTextEventFunction, & fn ), NULL ),
-
-#define EVT_RICHTEXT_STYLESHEET_CHANGING(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_STYLESHEET_CHANGING, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxRichTextEventFunction, & fn ), NULL ),
-#define EVT_RICHTEXT_STYLESHEET_CHANGED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_STYLESHEET_CHANGED, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxRichTextEventFunction, & fn ), NULL ),
-#define EVT_RICHTEXT_STYLESHEET_REPLACING(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_STYLESHEET_REPLACING, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxRichTextEventFunction, & fn ), NULL ),
-#define EVT_RICHTEXT_STYLESHEET_REPLACED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_STYLESHEET_REPLACED, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxRichTextEventFunction, & fn ), NULL ),
-
-#define EVT_RICHTEXT_CONTENT_INSERTED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_CONTENT_INSERTED, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxRichTextEventFunction, & fn ), NULL ),
-#define EVT_RICHTEXT_CONTENT_DELETED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_CONTENT_DELETED, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxRichTextEventFunction, & fn ), NULL ),
-#define EVT_RICHTEXT_STYLE_CHANGED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_STYLE_CHANGED, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxRichTextEventFunction, & fn ), NULL ),
-#define EVT_RICHTEXT_SELECTION_CHANGED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_SELECTION_CHANGED, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxRichTextEventFunction, & fn ), NULL ),
-#define EVT_RICHTEXT_BUFFER_RESET(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_BUFFER_RESET, id, -1, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxRichTextEventFunction, & fn ), NULL ),
+ wxEVENT_HANDLER_CAST(wxRichTextEventFunction, func)
+
+#define EVT_RICHTEXT_LEFT_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_LEFT_CLICK, id, -1, wxRichTextEventHandler( fn ), NULL ),
+#define EVT_RICHTEXT_RIGHT_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_RIGHT_CLICK, id, -1, wxRichTextEventHandler( fn ), NULL ),
+#define EVT_RICHTEXT_MIDDLE_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_MIDDLE_CLICK, id, -1, wxRichTextEventHandler( fn ), NULL ),
+#define EVT_RICHTEXT_LEFT_DCLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_LEFT_DCLICK, id, -1, wxRichTextEventHandler( fn ), NULL ),
+#define EVT_RICHTEXT_RETURN(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_RETURN, id, -1, wxRichTextEventHandler( fn ), NULL ),
+#define EVT_RICHTEXT_CHARACTER(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_CHARACTER, id, -1, wxRichTextEventHandler( fn ), NULL ),
+#define EVT_RICHTEXT_DELETE(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_DELETE, id, -1, wxRichTextEventHandler( fn ), NULL ),
+
+#define EVT_RICHTEXT_STYLESHEET_CHANGING(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_STYLESHEET_CHANGING, id, -1, wxRichTextEventHandler( fn ), NULL ),
+#define EVT_RICHTEXT_STYLESHEET_CHANGED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_STYLESHEET_CHANGED, id, -1, wxRichTextEventHandler( fn ), NULL ),
+#define EVT_RICHTEXT_STYLESHEET_REPLACING(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_STYLESHEET_REPLACING, id, -1, wxRichTextEventHandler( fn ), NULL ),
+#define EVT_RICHTEXT_STYLESHEET_REPLACED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_STYLESHEET_REPLACED, id, -1, wxRichTextEventHandler( fn ), NULL ),
+
+#define EVT_RICHTEXT_CONTENT_INSERTED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_CONTENT_INSERTED, id, -1, wxRichTextEventHandler( fn ), NULL ),
+#define EVT_RICHTEXT_CONTENT_DELETED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_CONTENT_DELETED, id, -1, wxRichTextEventHandler( fn ), NULL ),
+#define EVT_RICHTEXT_STYLE_CHANGED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_STYLE_CHANGED, id, -1, wxRichTextEventHandler( fn ), NULL ),
+#define EVT_RICHTEXT_SELECTION_CHANGED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_SELECTION_CHANGED, id, -1, wxRichTextEventHandler( fn ), NULL ),
+#define EVT_RICHTEXT_BUFFER_RESET(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_RICHTEXT_BUFFER_RESET, id, -1, wxRichTextEventHandler( fn ), NULL ),
#endif
// wxUSE_RICHTEXT
// Recommended setting: 0 (please update your code)
#define WXWIN_COMPATIBILITY_2_8 1
+// Use the 2.8-compatible events and Connect(): this is set to 0 by default as
+// the new events bring significant benefits in compile-time safety and
+// flexibility but can be disabled to somewhat reduce the compilation time and,
+// especially, to still allow building if the compiler template support is too
+// bad to compile the new code.
+//
+// Default is 0 for all compilers except VC6 currently.
+//
+// Recommended setting: 0 (please upgrade your compiler instead of changing it)
+#define wxEVENTS_COMPATIBILITY_2_8 0
+
// MSW-only: Set to 0 for accurate dialog units, else 1 for old behaviour when
// default system font is used for wxWindow::GetCharWidth/Height() instead of
// the current font.
};
+// event
+class WXDLLIMPEXP_FWD_NET wxSocketEvent;
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_NET, wxEVT_SOCKET, wxSocketEvent)
// --------------------------------------------------------------------------
// wxSocketBase
typedef void (wxEvtHandler::*wxSocketEventFunction)(wxSocketEvent&);
#define wxSocketEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxSocketEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxSocketEventFunction, func)
#define EVT_SOCKET(id, func) \
wx__DECLARE_EVT1(wxEVT_SOCKET, id, wxSocketEventHandler(func))
#define wxSPIN_BUTTON_NAME _T("wxSpinButton")
+class WXDLLIMPEXP_FWD_CORE wxSpinEvent;
+wxDECLARE_EXPORTED_EVENT_REFERENCE( WXDLLIMPEXP_CORE, wxEVT_SPIN_UP, wxSpinEvent )
+wxDECLARE_EXPORTED_EVENT_REFERENCE( WXDLLIMPEXP_CORE, wxEVT_SPIN_DOWN, wxSpinEvent )
+wxDECLARE_EXPORTED_EVENT_REFERENCE( WXDLLIMPEXP_CORE, wxEVT_SPIN, wxSpinEvent )
+
// ----------------------------------------------------------------------------
// The wxSpinButton is like a small scrollbar than is often placed next
// to a text control.
typedef void (wxEvtHandler::*wxSpinEventFunction)(wxSpinEvent&);
#define wxSpinEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxSpinEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxSpinEventFunction, func)
// macros for handling spin events
#define EVT_SPIN_UP(winid, func) \
- wx__DECLARE_EVT1(wxEVT_SCROLL_LINEUP, winid, wxSpinEventHandler(func))
+ wx__DECLARE_EVT1(wxEVT_SPIN_UP, winid, wxSpinEventHandler(func))
#define EVT_SPIN_DOWN(winid, func) \
- wx__DECLARE_EVT1(wxEVT_SCROLL_LINEDOWN, winid, wxSpinEventHandler(func))
+ wx__DECLARE_EVT1(wxEVT_SPIN_DOWN, winid, wxSpinEventHandler(func))
#define EVT_SPIN(winid, func) \
- wx__DECLARE_EVT1(wxEVT_SCROLL_THUMBTRACK, winid, wxSpinEventHandler(func))
+ wx__DECLARE_EVT1(wxEVT_SPIN, winid, wxSpinEventHandler(func))
#endif // wxUSE_SPINBTN
#include "wx/spinbutt.h" // should make wxSpinEvent visible to the app
+// Events
+class WXDLLIMPEXP_FWD_CORE wxSpinDoubleEvent;
+
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_SPINCTRL_UPDATED, wxSpinEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_SPINCTRLDOUBLE_UPDATED, wxSpinDoubleEvent)
+
// ----------------------------------------------------------------------------
// A spin ctrl is a text control with a spin button which is usually used to
// prompt the user for a numeric input.
typedef void (wxEvtHandler::*wxSpinDoubleEventFunction)(wxSpinDoubleEvent&);
#define wxSpinDoubleEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxSpinDoubleEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxSpinDoubleEventFunction, func)
// macros for handling spinctrl events
#define wxSP_FULLSASH 0
#endif // WXWIN_COMPATIBILITY_2_6
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGING;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_SPLITTER_DOUBLECLICKED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_SPLITTER_UNSPLIT;
+class WXDLLIMPEXP_FWD_CORE wxSplitterEvent;
+
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGED, wxSplitterEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGING, wxSplitterEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_SPLITTER_DOUBLECLICKED, wxSplitterEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_SPLITTER_UNSPLIT, wxSplitterEvent )
#include "wx/generic/splitter.h"
extern WXDLLIMPEXP_DATA_CORE(const char) wxSearchCtrlNameStr[];
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_SEARCHCTRL_CANCEL_BTN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_SEARCHCTRL_SEARCH_BTN;
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_SEARCHCTRL_CANCEL_BTN, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_SEARCHCTRL_SEARCH_BTN, wxCommandEvent)
// ----------------------------------------------------------------------------
// a search ctrl is a text control with a search button and a cancel button
#ifndef SWIG
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_CHANGE;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_STYLENEEDED;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_CHARADDED;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_SAVEPOINTREACHED;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_SAVEPOINTLEFT;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_ROMODIFYATTEMPT;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_KEY;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_DOUBLECLICK;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_UPDATEUI;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_MODIFIED;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_MACRORECORD;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_MARGINCLICK;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_NEEDSHOWN;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_PAINTED;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_USERLISTSELECTION;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_URIDROPPED;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_DWELLSTART;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_DWELLEND;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_START_DRAG;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_DRAG_OVER;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_DO_DROP;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_ZOOM;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_HOTSPOT_CLICK;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_HOTSPOT_DCLICK;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_CALLTIP_CLICK;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_AUTOCOMP_SELECTION;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_INDICATOR_CLICK;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_INDICATOR_RELEASE;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_CHANGE, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_STYLENEEDED, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_CHARADDED, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_SAVEPOINTREACHED, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_SAVEPOINTLEFT, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_ROMODIFYATTEMPT, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_KEY, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_DOUBLECLICK, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_UPDATEUI, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_MODIFIED, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_MACRORECORD, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_MARGINCLICK, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_NEEDSHOWN, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_PAINTED, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_USERLISTSELECTION, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_URIDROPPED, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_DWELLSTART, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_DWELLEND, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_START_DRAG, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_DRAG_OVER, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_DO_DROP, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_ZOOM, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_HOTSPOT_CLICK, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_HOTSPOT_DCLICK, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_CALLTIP_CLICK, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_AUTOCOMP_SELECTION, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_INDICATOR_CLICK, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_INDICATOR_RELEASE, wxStyledTextEvent )
#else
enum {
wxEVT_STC_CHANGE,
#ifndef SWIG
typedef void (wxEvtHandler::*wxStyledTextEventFunction)(wxStyledTextEvent&);
-#define EVT_STC_CHANGE(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_CHANGE, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_STYLENEEDED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_STYLENEEDED, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_CHARADDED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_CHARADDED, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_SAVEPOINTREACHED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_SAVEPOINTREACHED, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_SAVEPOINTLEFT(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_SAVEPOINTLEFT, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_ROMODIFYATTEMPT(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_ROMODIFYATTEMPT, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_KEY(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_KEY, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_DOUBLECLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DOUBLECLICK, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_UPDATEUI(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_UPDATEUI, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_MODIFIED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_MODIFIED, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_MACRORECORD(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_MACRORECORD, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_MARGINCLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_MARGINCLICK, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_NEEDSHOWN(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_NEEDSHOWN, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_PAINTED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_PAINTED, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_USERLISTSELECTION(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_USERLISTSELECTION, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_URIDROPPED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_URIDROPPED, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_DWELLSTART(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DWELLSTART, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_DWELLEND(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DWELLEND, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_START_DRAG(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_START_DRAG, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_DRAG_OVER(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DRAG_OVER, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_DO_DROP(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DO_DROP, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_ZOOM(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_ZOOM, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_HOTSPOT_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_HOTSPOT_CLICK, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_HOTSPOT_DCLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_HOTSPOT_DCLICK, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_CALLTIP_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_CALLTIP_CLICK id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_AUTOCOMP_SELECTION(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_AUTOCOMP_SELECTION id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_INDICATOR_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_INDICATOR_CLICK id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_INDICATOR_RELEASE(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_INDICATOR_RELEASE id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
+#define wxStyledTextEventHandler( func ) \
+ wxEVENT_HANDLER_CAST( wxStyledTextEventFunction, func )
+
+#define EVT_STC_CHANGE(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_CHANGE, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_STYLENEEDED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_STYLENEEDED, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_CHARADDED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_CHARADDED, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_SAVEPOINTREACHED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_SAVEPOINTREACHED, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_SAVEPOINTLEFT(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_SAVEPOINTLEFT, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_ROMODIFYATTEMPT(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_ROMODIFYATTEMPT, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_KEY(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_KEY, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_DOUBLECLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DOUBLECLICK, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_UPDATEUI(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_UPDATEUI, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_MODIFIED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_MODIFIED, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_MACRORECORD(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_MACRORECORD, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_MARGINCLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_MARGINCLICK, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_NEEDSHOWN(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_NEEDSHOWN, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_PAINTED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_PAINTED, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_USERLISTSELECTION(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_USERLISTSELECTION, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_URIDROPPED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_URIDROPPED, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_DWELLSTART(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DWELLSTART, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_DWELLEND(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DWELLEND, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_START_DRAG(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_START_DRAG, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_DRAG_OVER(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DRAG_OVER, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_DO_DROP(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DO_DROP, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_ZOOM(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_ZOOM, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_HOTSPOT_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_HOTSPOT_CLICK, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_HOTSPOT_DCLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_HOTSPOT_DCLICK, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_CALLTIP_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_CALLTIP_CLICK id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_AUTOCOMP_SELECTION(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_AUTOCOMP_SELECTION id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_INDICATOR_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_INDICATOR_CLICK id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_INDICATOR_RELEASE(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_INDICATOR_RELEASE id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
#endif
typedef void (wxEvtHandler::*wxTaskBarIconEventFunction)(wxTaskBarIconEvent&);
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_TASKBAR_MOVE;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_TASKBAR_LEFT_DOWN;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_TASKBAR_LEFT_UP;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_TASKBAR_RIGHT_DOWN;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_TASKBAR_RIGHT_UP;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_TASKBAR_LEFT_DCLICK;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_TASKBAR_RIGHT_DCLICK;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_TASKBAR_BALLOON_TIMEOUT;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_TASKBAR_BALLOON_CLICK;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_TASKBAR_MOVE, wxTaskBarIconEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_TASKBAR_LEFT_DOWN, wxTaskBarIconEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_TASKBAR_LEFT_UP, wxTaskBarIconEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_TASKBAR_RIGHT_DOWN, wxTaskBarIconEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_TASKBAR_RIGHT_UP, wxTaskBarIconEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_TASKBAR_LEFT_DCLICK, wxTaskBarIconEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_TASKBAR_RIGHT_DCLICK, wxTaskBarIconEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_TASKBAR_BALLOON_TIMEOUT, wxTaskBarIconEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_TASKBAR_BALLOON_CLICK, wxTaskBarIconEvent )
#define wxTaskBarIconEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxTaskBarIconEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxTaskBarIconEventFunction, func)
#define wx__DECLARE_TASKBAREVT(evt, fn) \
wx__DECLARE_EVT0(wxEVT_TASKBAR_ ## evt, wxTaskBarIconEventHandler(fn))
// wxTextCtrl events
// ----------------------------------------------------------------------------
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TEXT_UPDATED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TEXT_ENTER;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TEXT_URL;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TEXT_MAXLEN;
+class WXDLLIMPEXP_FWD_CORE wxTextUrlEvent;
+
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_TEXT_UPDATED, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_TEXT_ENTER, wxCommandEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_TEXT_URL, wxTextUrlEvent)
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_CORE, wxEVT_COMMAND_TEXT_MAXLEN, wxCommandEvent)
class WXDLLIMPEXP_CORE wxTextUrlEvent : public wxCommandEvent
{
#define wxTextEventHandler(func) wxCommandEventHandler(func)
#define wxTextUrlEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxTextUrlEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxTextUrlEventFunction, func)
#define wx__DECLARE_TEXTEVT(evt, id, fn) \
wx__DECLARE_EVT1(wxEVT_COMMAND_TEXT_ ## evt, id, wxTextEventHandler(fn))
#include "wx/event.h"
#include "wx/control.h" // base class
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TOGGLEBUTTON_CLICKED;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TOGGLEBUTTON_CLICKED, wxCommandEvent )
// ----------------------------------------------------------------------------
// wxToggleButtonBase
#define wxTIMER_ONE_SHOT true
class WXDLLIMPEXP_FWD_BASE wxTimerImpl;
+class WXDLLIMPEXP_FWD_BASE wxTimerEvent;
+
+// timer event type
+wxDECLARE_EXPORTED_EVENT(WXDLLIMPEXP_BASE, wxEVT_TIMER, wxTimerEvent)
// the interface of wxTimer class
class WXDLLIMPEXP_BASE wxTimer : public wxEvtHandler
typedef void (wxEvtHandler::*wxTimerEventFunction)(wxTimerEvent&);
#define wxTimerEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxTimerEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxTimerEventFunction, func)
#define EVT_TIMER(timerid, func) \
wx__DECLARE_EVT1(wxEVT_TIMER, timerid, wxTimerEventHandler(func))
class WXDLLIMPEXP_FWD_CORE wxToolBarBase;
class WXDLLIMPEXP_FWD_CORE wxCommandEvent;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TOOLBOOK_PAGE_CHANGED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TOOLBOOK_PAGE_CHANGING;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TOOLBOOK_PAGE_CHANGED, wxBookCtrlEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TOOLBOOK_PAGE_CHANGING, wxBookCtrlEvent )
// Use wxButtonToolBar
// tree control events and macros for handling them
// ----------------------------------------------------------------------------
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_BEGIN_DRAG;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_BEGIN_RDRAG;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_BEGIN_LABEL_EDIT;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_END_LABEL_EDIT;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_DELETE_ITEM;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_GET_INFO;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_SET_INFO;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_ITEM_EXPANDED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_ITEM_EXPANDING;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_ITEM_COLLAPSED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_ITEM_COLLAPSING;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_SEL_CHANGED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_SEL_CHANGING;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_KEY_DOWN;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_ITEM_ACTIVATED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_END_DRAG;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_STATE_IMAGE_CLICK;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_ITEM_GETTOOLTIP;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREE_ITEM_MENU;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_BEGIN_DRAG, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_BEGIN_RDRAG, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_BEGIN_LABEL_EDIT, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_END_LABEL_EDIT, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_DELETE_ITEM, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_GET_INFO, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_SET_INFO, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_ITEM_EXPANDED, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_ITEM_EXPANDING, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_ITEM_COLLAPSED, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_ITEM_COLLAPSING, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_SEL_CHANGED, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_SEL_CHANGING, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_KEY_DOWN, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_ITEM_ACTIVATED, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_END_DRAG, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_STATE_IMAGE_CLICK, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_ITEM_GETTOOLTIP, wxTreeEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREE_ITEM_MENU, wxTreeEvent )
#define wxTreeEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxTreeEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxTreeEventFunction, func)
#define wx__DECLARE_TREEEVT(evt, id, fn) \
wx__DECLARE_EVT1(wxEVT_COMMAND_TREE_ ## evt, id, wxTreeEventHandler(fn))
#define wxTreebookEventHandler(func) wxBookCtrlEventHandler(func)
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREEBOOK_PAGE_CHANGED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREEBOOK_PAGE_CHANGING;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREEBOOK_NODE_COLLAPSED;
-extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREEBOOK_NODE_EXPANDED;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREEBOOK_PAGE_CHANGED, wxBookCtrlEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREEBOOK_PAGE_CHANGING, wxBookCtrlEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREEBOOK_NODE_COLLAPSED, wxBookCtrlEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE, wxEVT_COMMAND_TREEBOOK_NODE_EXPANDED, wxBookCtrlEvent )
#define EVT_TREEBOOK_PAGE_CHANGED(winid, fn) \
wx__DECLARE_EVT1(wxEVT_COMMAND_TREEBOOK_PAGE_CHANGED, winid, wxBookCtrlEventHandler(fn))
// Recommended setting: 0 (please update your code)
#define WXWIN_COMPATIBILITY_2_8 1
+// Use the 2.8-compatible events and Connect(): this is set to 0 by default as
+// the new events bring significant benefits in compile-time safety and
+// flexibility but can be disabled to somewhat reduce the compilation time and,
+// especially, to still allow building if the compiler template support is too
+// bad to compile the new code.
+//
+// Default is 0 for all compilers except VC6 currently.
+//
+// Recommended setting: 0 (please upgrade your compiler instead of changing it)
+#define wxEVENTS_COMPATIBILITY_2_8 0
+
// MSW-only: Set to 0 for accurate dialog units, else 1 for old behaviour when
// default system font is used for wxWindow::GetCharWidth/Height() instead of
// the current font.
// macros for handling wxWizardEvents
// ----------------------------------------------------------------------------
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_WIZARD_PAGE_CHANGED;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_WIZARD_PAGE_CHANGING;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_WIZARD_CANCEL;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_WIZARD_HELP;
-extern WXDLLIMPEXP_ADV const wxEventType wxEVT_WIZARD_FINISHED;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_WIZARD_PAGE_CHANGED, wxWizardEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_WIZARD_PAGE_CHANGING, wxWizardEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_WIZARD_CANCEL, wxWizardEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_WIZARD_HELP, wxWizardEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_ADV, wxEVT_WIZARD_FINISHED, wxWizardEvent )
typedef void (wxEvtHandler::*wxWizardEventFunction)(wxWizardEvent&);
#define wxWizardEventHandler(func) \
- (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxWizardEventFunction, &func)
+ wxEVENT_HANDLER_CAST(wxWizardEventFunction, func)
#define wx__DECLARE_WIZARDEVT(evt, id, fn) \
wx__DECLARE_EVT1(wxEVT_WIZARD_ ## evt, id, wxWizardEventHandler(fn))
calendar->Connect(wxEVT_RIGHT_DOWN,
wxMouseEventHandler(MyFrame::OnCalRClick),
NULL,
- wxGetTopLevelParent(this));
+ ( MyFrame * )wxGetTopLevelParent(this));
return calendar;
}
#define WXWIN_COMPATIBILITY_2_8 0
+#define wxEVENTS_COMPATIBILITY_2_8 0
+
#define wxDIALOG_UNIT_COMPATIBILITY 0
WX_DEFINE_OBJARRAY(wxAuiToolBarItemArray)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUITOOLBAR_TOOL_DROPDOWN)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUITOOLBAR_OVERFLOW_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUITOOLBAR_RIGHT_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUITOOLBAR_MIDDLE_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUITOOLBAR_BEGIN_DRAG)
+wxDEFINE_EVENT( wxEVT_COMMAND_AUITOOLBAR_TOOL_DROPDOWN, wxAuiToolBarEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_AUITOOLBAR_OVERFLOW_CLICK, wxAuiToolBarEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_AUITOOLBAR_RIGHT_CLICK, wxAuiToolBarEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_AUITOOLBAR_MIDDLE_CLICK, wxAuiToolBarEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_AUITOOLBAR_BEGIN_DRAG, wxAuiToolBarEvent )
IMPLEMENT_CLASS(wxAuiToolBar, wxControl)
WX_DEFINE_OBJARRAY(wxAuiNotebookPageArray)
WX_DEFINE_OBJARRAY(wxAuiTabContainerButtonArray)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSE)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUINOTEBOOK_PAGE_CHANGING)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUINOTEBOOK_PAGE_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUINOTEBOOK_BUTTON)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUINOTEBOOK_BEGIN_DRAG)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUINOTEBOOK_END_DRAG)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUINOTEBOOK_DRAG_MOTION)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUINOTEBOOK_ALLOW_DND)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUINOTEBOOK_BG_DCLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUINOTEBOOK_DRAG_DONE)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUINOTEBOOK_TAB_MIDDLE_UP)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUINOTEBOOK_TAB_MIDDLE_DOWN)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUINOTEBOOK_TAB_RIGHT_UP)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_AUINOTEBOOK_TAB_RIGHT_DOWN)
+wxDEFINE_EVENT(wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSE, wxAuiNotebookEvent);
+wxDEFINE_EVENT(wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSED, wxAuiNotebookEvent);
+wxDEFINE_EVENT(wxEVT_COMMAND_AUINOTEBOOK_PAGE_CHANGING, wxAuiNotebookEvent);
+wxDEFINE_EVENT(wxEVT_COMMAND_AUINOTEBOOK_PAGE_CHANGED, wxAuiNotebookEvent);
+wxDEFINE_EVENT(wxEVT_COMMAND_AUINOTEBOOK_BUTTON, wxAuiNotebookEvent);
+wxDEFINE_EVENT(wxEVT_COMMAND_AUINOTEBOOK_BEGIN_DRAG, wxAuiNotebookEvent);
+wxDEFINE_EVENT(wxEVT_COMMAND_AUINOTEBOOK_END_DRAG, wxAuiNotebookEvent);
+wxDEFINE_EVENT(wxEVT_COMMAND_AUINOTEBOOK_DRAG_MOTION, wxAuiNotebookEvent);
+wxDEFINE_EVENT(wxEVT_COMMAND_AUINOTEBOOK_ALLOW_DND, wxAuiNotebookEvent);
+wxDEFINE_EVENT(wxEVT_COMMAND_AUINOTEBOOK_BG_DCLICK, wxAuiNotebookEvent);
+wxDEFINE_EVENT(wxEVT_COMMAND_AUINOTEBOOK_DRAG_DONE, wxAuiNotebookEvent);
+wxDEFINE_EVENT(wxEVT_COMMAND_AUINOTEBOOK_TAB_MIDDLE_UP, wxAuiNotebookEvent);
+wxDEFINE_EVENT(wxEVT_COMMAND_AUINOTEBOOK_TAB_MIDDLE_DOWN, wxAuiNotebookEvent);
+wxDEFINE_EVENT(wxEVT_COMMAND_AUINOTEBOOK_TAB_RIGHT_UP, wxAuiNotebookEvent);
+wxDEFINE_EVENT(wxEVT_COMMAND_AUINOTEBOOK_TAB_RIGHT_DOWN, wxAuiNotebookEvent);
IMPLEMENT_CLASS(wxAuiNotebook, wxControl)
IMPLEMENT_CLASS(wxAuiTabCtrl, wxControl)
// -- wxAuiNotebook class implementation --
+#define EVT_AUI_RANGE(id1, id2, event, func) \
+ wx__DECLARE_EVT2(event, id1, id2, wxAuiNotebookEventHandler(func))
+
BEGIN_EVENT_TABLE(wxAuiNotebook, wxControl)
EVT_SIZE(wxAuiNotebook::OnSize)
EVT_CHILD_FOCUS(wxAuiNotebook::OnChildFocusNotebook)
- EVT_COMMAND_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
+ EVT_AUI_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
wxEVT_COMMAND_AUINOTEBOOK_PAGE_CHANGING,
wxAuiNotebook::OnTabClicked)
- EVT_COMMAND_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
+ EVT_AUI_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
wxEVT_COMMAND_AUINOTEBOOK_BEGIN_DRAG,
wxAuiNotebook::OnTabBeginDrag)
- EVT_COMMAND_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
+ EVT_AUI_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
wxEVT_COMMAND_AUINOTEBOOK_END_DRAG,
wxAuiNotebook::OnTabEndDrag)
- EVT_COMMAND_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
+ EVT_AUI_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
wxEVT_COMMAND_AUINOTEBOOK_DRAG_MOTION,
wxAuiNotebook::OnTabDragMotion)
- EVT_COMMAND_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
+ EVT_AUI_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
wxEVT_COMMAND_AUINOTEBOOK_BUTTON,
wxAuiNotebook::OnTabButton)
- EVT_COMMAND_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
+ EVT_AUI_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
wxEVT_COMMAND_AUINOTEBOOK_TAB_MIDDLE_DOWN,
wxAuiNotebook::OnTabMiddleDown)
- EVT_COMMAND_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
+ EVT_AUI_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
wxEVT_COMMAND_AUINOTEBOOK_TAB_MIDDLE_UP,
wxAuiNotebook::OnTabMiddleUp)
- EVT_COMMAND_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
+ EVT_AUI_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
wxEVT_COMMAND_AUINOTEBOOK_TAB_RIGHT_DOWN,
wxAuiNotebook::OnTabRightDown)
- EVT_COMMAND_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
+ EVT_AUI_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
wxEVT_COMMAND_AUINOTEBOOK_TAB_RIGHT_UP,
wxAuiNotebook::OnTabRightUp)
- EVT_COMMAND_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
+ EVT_AUI_RANGE(wxAuiBaseTabCtrlId, wxAuiBaseTabCtrlId+500,
wxEVT_COMMAND_AUINOTEBOOK_BG_DCLICK,
wxAuiNotebook::OnTabBgDClick)
EVT_NAVIGATION_KEY(wxAuiNotebook::OnNavigationKeyNotebook)
evt.Skip();
}
-void wxAuiNotebook::OnTabClicked(wxCommandEvent& command_evt)
+void wxAuiNotebook::OnTabClicked(wxAuiNotebookEvent& evt)
{
- wxAuiNotebookEvent& evt = (wxAuiNotebookEvent&)command_evt;
-
wxAuiTabCtrl* ctrl = (wxAuiTabCtrl*)evt.GetEventObject();
wxASSERT(ctrl != NULL);
SetSelectionToWindow(wnd);
}
-void wxAuiNotebook::OnTabBgDClick(wxCommandEvent& WXUNUSED(evt))
+void wxAuiNotebook::OnTabBgDClick(wxAuiNotebookEvent& WXUNUSED(evt))
{
// notify owner that the tabbar background has been double-clicked
wxAuiNotebookEvent e(wxEVT_COMMAND_AUINOTEBOOK_BG_DCLICK, m_windowId);
GetEventHandler()->ProcessEvent(e);
}
-void wxAuiNotebook::OnTabBeginDrag(wxCommandEvent&)
+void wxAuiNotebook::OnTabBeginDrag(wxAuiNotebookEvent&)
{
m_last_drag_x = 0;
}
-void wxAuiNotebook::OnTabDragMotion(wxCommandEvent& evt)
+void wxAuiNotebook::OnTabDragMotion(wxAuiNotebookEvent& evt)
{
wxPoint screen_pt = ::wxGetMousePosition();
wxPoint client_pt = ScreenToClient(screen_pt);
-void wxAuiNotebook::OnTabEndDrag(wxCommandEvent& command_evt)
+void wxAuiNotebook::OnTabEndDrag(wxAuiNotebookEvent& evt)
{
- wxAuiNotebookEvent& evt = (wxAuiNotebookEvent&)command_evt;
-
m_mgr.HideHint();
}
}
-void wxAuiNotebook::OnTabButton(wxCommandEvent& command_evt)
+void wxAuiNotebook::OnTabButton(wxAuiNotebookEvent& evt)
{
- wxAuiNotebookEvent& evt = (wxAuiNotebookEvent&)command_evt;
wxAuiTabCtrl* tabs = (wxAuiTabCtrl*)evt.GetEventObject();
int button_id = evt.GetInt();
}
-void wxAuiNotebook::OnTabMiddleDown(wxCommandEvent& evt)
+void wxAuiNotebook::OnTabMiddleDown(wxAuiNotebookEvent& evt)
{
// patch event through to owner
wxAuiTabCtrl* tabs = (wxAuiTabCtrl*)evt.GetEventObject();
GetEventHandler()->ProcessEvent(e);
}
-void wxAuiNotebook::OnTabMiddleUp(wxCommandEvent& evt)
+void wxAuiNotebook::OnTabMiddleUp(wxAuiNotebookEvent& evt)
{
// if the wxAUI_NB_MIDDLE_CLICK_CLOSE is specified, middle
// click should act like a tab close action. However, first
OnTabButton(evt);
}
-void wxAuiNotebook::OnTabRightDown(wxCommandEvent& evt)
+void wxAuiNotebook::OnTabRightDown(wxAuiNotebookEvent& evt)
{
// patch event through to owner
wxAuiTabCtrl* tabs = (wxAuiTabCtrl*)evt.GetEventObject();
GetEventHandler()->ProcessEvent(e);
}
-void wxAuiNotebook::OnTabRightUp(wxCommandEvent& evt)
+void wxAuiNotebook::OnTabRightUp(wxAuiNotebookEvent& evt)
{
// patch event through to owner
wxAuiTabCtrl* tabs = (wxAuiTabCtrl*)evt.GetEventObject();
wxAuiPaneInfo wxAuiNullPaneInfo;
wxAuiDockInfo wxAuiNullDockInfo;
-DEFINE_EVENT_TYPE(wxEVT_AUI_PANE_BUTTON)
-DEFINE_EVENT_TYPE(wxEVT_AUI_PANE_CLOSE)
-DEFINE_EVENT_TYPE(wxEVT_AUI_PANE_MAXIMIZE)
-DEFINE_EVENT_TYPE(wxEVT_AUI_PANE_RESTORE)
-DEFINE_EVENT_TYPE(wxEVT_AUI_RENDER)
-DEFINE_EVENT_TYPE(wxEVT_AUI_FIND_MANAGER)
+wxDEFINE_EVENT( wxEVT_AUI_PANE_BUTTON, wxAuiManagerEvent )
+wxDEFINE_EVENT( wxEVT_AUI_PANE_CLOSE, wxAuiManagerEvent )
+wxDEFINE_EVENT( wxEVT_AUI_PANE_MAXIMIZE, wxAuiManagerEvent )
+wxDEFINE_EVENT( wxEVT_AUI_PANE_RESTORE, wxAuiManagerEvent )
+wxDEFINE_EVENT( wxEVT_AUI_RENDER, wxAuiManagerEvent )
+wxDEFINE_EVENT( wxEVT_AUI_FIND_MANAGER, wxAuiManagerEvent )
#ifdef __WXMAC__
// a few defines to avoid nameclashes
(handler->*func)(event);
}
+void wxAppConsoleBase::CallEventHandler(wxEvtHandler *handler,
+ wxEventFunctor& functor,
+ wxEvent& event) const
+{
+ // If the functor holds a method then, for backward compatibility, call
+ // HandleEvent():
+ wxEventFunction eventFunction = functor.GetMethod();
+
+ if ( eventFunction )
+ HandleEvent(handler, eventFunction, event);
+ else
+ functor(handler, event);
+}
+
void wxAppConsoleBase::OnUnhandledException()
{
#ifdef __WXDEBUG__
#include "wx/dateevt.h"
IMPLEMENT_DYNAMIC_CLASS(wxDateEvent, wxCommandEvent)
-DEFINE_EVENT_TYPE(wxEVT_DATE_CHANGED)
+wxDEFINE_EVENT(wxEVT_DATE_CHANGED, wxDateEvent);
#endif // wxUSE_CALENDARCTRL || wxUSE_DATEPICKCTRL
// ----------------------------------------------------------------------------
IMPLEMENT_DYNAMIC_CLASS(wxCalendarEvent, wxDateEvent)
-DEFINE_EVENT_TYPE(wxEVT_CALENDAR_SEL_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_CALENDAR_PAGE_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_CALENDAR_DOUBLECLICKED)
-DEFINE_EVENT_TYPE(wxEVT_CALENDAR_WEEKDAY_CLICKED)
+wxDEFINE_EVENT( wxEVT_CALENDAR_SEL_CHANGED, wxCalendarEvent )
+wxDEFINE_EVENT( wxEVT_CALENDAR_PAGE_CHANGED, wxCalendarEvent )
+wxDEFINE_EVENT( wxEVT_CALENDAR_DOUBLECLICKED, wxCalendarEvent )
+wxDEFINE_EVENT( wxEVT_CALENDAR_WEEKDAY_CLICKED, wxCalendarEvent )
// deprecated events
-DEFINE_EVENT_TYPE(wxEVT_CALENDAR_DAY_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_CALENDAR_MONTH_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_CALENDAR_YEAR_CHANGED)
+wxDEFINE_EVENT( wxEVT_CALENDAR_DAY_CHANGED, wxCalendarEvent )
+wxDEFINE_EVENT( wxEVT_CALENDAR_MONTH_CHANGED, wxCalendarEvent )
+wxDEFINE_EVENT( wxEVT_CALENDAR_YEAR_CHANGED, wxCalendarEvent )
wxCalendarDateAttr wxCalendarDateAttr::m_mark(wxCAL_BORDER_SQUARE);
IMPLEMENT_DYNAMIC_CLASS(wxClipboardEvent,wxEvent)
-DEFINE_EVENT_TYPE(wxEVT_CLIPBOARD_CHANGED)
+wxDEFINE_EVENT( wxEVT_CLIPBOARD_CHANGED, wxClipboardEvent )
// notice that ctors are defined here and not inline to avoid having to include
// wx/dataobj.h from wx/clipbrd.h
// implementation
// ============================================================================
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_COLOURPICKER_CHANGED)
+wxDEFINE_EVENT(wxEVT_COMMAND_COLOURPICKER_CHANGED, wxColourPickerEvent)
IMPLEMENT_DYNAMIC_CLASS(wxColourPickerCtrl, wxPickerBase)
IMPLEMENT_DYNAMIC_CLASS(wxColourPickerEvent, wxEvent)
IMPLEMENT_DYNAMIC_CLASS(wxDataViewEvent,wxNotifyEvent)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_DATAVIEW_SELECTION_CHANGED)
-
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_DATAVIEW_ITEM_ACTIVATED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_DATAVIEW_ITEM_COLLAPSING)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_DATAVIEW_ITEM_COLLAPSED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_DATAVIEW_ITEM_EXPANDING)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_DATAVIEW_ITEM_EXPANDED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_DATAVIEW_ITEM_EDITING_STARTED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_DATAVIEW_ITEM_EDITING_DONE)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_DATAVIEW_ITEM_VALUE_CHANGED)
-
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_DATAVIEW_ITEM_CONTEXT_MENU)
-
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_DATAVIEW_COLUMN_HEADER_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_DATAVIEW_COLUMN_HEADER_RIGHT_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_DATAVIEW_COLUMN_SORTED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_DATAVIEW_COLUMN_REORDERED)
+wxDEFINE_EVENT( wxEVT_COMMAND_DATAVIEW_SELECTION_CHANGED, wxDataViewEvent )
+
+wxDEFINE_EVENT( wxEVT_COMMAND_DATAVIEW_ITEM_ACTIVATED, wxDataViewEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_DATAVIEW_ITEM_COLLAPSING, wxDataViewEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_DATAVIEW_ITEM_COLLAPSED, wxDataViewEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_DATAVIEW_ITEM_EXPANDING, wxDataViewEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_DATAVIEW_ITEM_EXPANDED, wxDataViewEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_DATAVIEW_ITEM_EDITING_STARTED, wxDataViewEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_DATAVIEW_ITEM_EDITING_DONE, wxDataViewEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_DATAVIEW_ITEM_VALUE_CHANGED, wxDataViewEvent )
+
+wxDEFINE_EVENT( wxEVT_COMMAND_DATAVIEW_ITEM_CONTEXT_MENU, wxDataViewEvent )
+
+wxDEFINE_EVENT( wxEVT_COMMAND_DATAVIEW_COLUMN_HEADER_CLICK, wxDataViewEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_DATAVIEW_COLUMN_HEADER_RIGHT_CLICK, wxDataViewEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_DATAVIEW_COLUMN_SORTED, wxDataViewEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_DATAVIEW_COLUMN_REORDERED, wxDataViewEvent )
// -------------------------------------
wxEventHashTable wxEvtHandler::sm_eventHashTable(wxEvtHandler::sm_eventTable);
const wxEventTableEntry wxEvtHandler::sm_eventTableEntries[] =
- { DECLARE_EVENT_TABLE_ENTRY(wxEVT_NULL, 0, 0, (wxObjectEventFunction)NULL, NULL) };
+ { DECLARE_EVENT_TABLE_TERMINATOR() };
// wxUSE_MEMORY_TRACING considers memory freed from the static objects dtors
const wxEventType wxEVT_USER_FIRST = wxEVT_FIRST + 2000;
DEFINE_EVENT_TYPE(wxEVT_NULL)
-DEFINE_EVENT_TYPE(wxEVT_IDLE)
-DEFINE_EVENT_TYPE(wxEVT_SOCKET)
-DEFINE_EVENT_TYPE(wxEVT_TIMER)
+wxDEFINE_EVENT( wxEVT_IDLE, wxIdleEvent )
#endif // wxUSE_BASE
#if wxUSE_GUI
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_BUTTON_CLICKED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_CHECKBOX_CLICKED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_CHOICE_SELECTED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LISTBOX_SELECTED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LISTBOX_DOUBLECLICKED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_CHECKLISTBOX_TOGGLED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_MENU_SELECTED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_SLIDER_UPDATED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RADIOBOX_SELECTED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RADIOBUTTON_SELECTED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_SCROLLBAR_UPDATED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_VLBOX_SELECTED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_COMBOBOX_SELECTED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TOOL_RCLICKED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TOOL_ENTER)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_SPINCTRL_UPDATED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_SPINCTRLDOUBLE_UPDATED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TOOL_DROPDOWN_CLICKED)
+wxDEFINE_EVENT( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LISTBOX_SELECTED, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LISTBOX_DOUBLECLICKED, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_CHECKLISTBOX_TOGGLED, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_MENU_SELECTED, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_SLIDER_UPDATED, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_RADIOBOX_SELECTED, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_RADIOBUTTON_SELECTED, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_SCROLLBAR_UPDATED, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_VLBOX_SELECTED, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_COMBOBOX_SELECTED, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TOOL_RCLICKED, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TOOL_ENTER, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_SPINCTRL_UPDATED, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_SPINCTRLDOUBLE_UPDATED, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TOOL_DROPDOWN_CLICKED, wxCommandEvent )
// Mouse event types
-DEFINE_EVENT_TYPE(wxEVT_LEFT_DOWN)
-DEFINE_EVENT_TYPE(wxEVT_LEFT_UP)
-DEFINE_EVENT_TYPE(wxEVT_MIDDLE_DOWN)
-DEFINE_EVENT_TYPE(wxEVT_MIDDLE_UP)
-DEFINE_EVENT_TYPE(wxEVT_RIGHT_DOWN)
-DEFINE_EVENT_TYPE(wxEVT_RIGHT_UP)
-DEFINE_EVENT_TYPE(wxEVT_MOTION)
-DEFINE_EVENT_TYPE(wxEVT_ENTER_WINDOW)
-DEFINE_EVENT_TYPE(wxEVT_LEAVE_WINDOW)
-DEFINE_EVENT_TYPE(wxEVT_LEFT_DCLICK)
-DEFINE_EVENT_TYPE(wxEVT_MIDDLE_DCLICK)
-DEFINE_EVENT_TYPE(wxEVT_RIGHT_DCLICK)
-DEFINE_EVENT_TYPE(wxEVT_SET_FOCUS)
-DEFINE_EVENT_TYPE(wxEVT_KILL_FOCUS)
-DEFINE_EVENT_TYPE(wxEVT_CHILD_FOCUS)
-DEFINE_EVENT_TYPE(wxEVT_MOUSEWHEEL)
-DEFINE_EVENT_TYPE(wxEVT_AUX1_DOWN)
-DEFINE_EVENT_TYPE(wxEVT_AUX1_UP)
-DEFINE_EVENT_TYPE(wxEVT_AUX1_DCLICK)
-DEFINE_EVENT_TYPE(wxEVT_AUX2_DOWN)
-DEFINE_EVENT_TYPE(wxEVT_AUX2_UP)
-DEFINE_EVENT_TYPE(wxEVT_AUX2_DCLICK)
-
-// Non-client mouse events
-DEFINE_EVENT_TYPE(wxEVT_NC_LEFT_DOWN)
-DEFINE_EVENT_TYPE(wxEVT_NC_LEFT_UP)
-DEFINE_EVENT_TYPE(wxEVT_NC_MIDDLE_DOWN)
-DEFINE_EVENT_TYPE(wxEVT_NC_MIDDLE_UP)
-DEFINE_EVENT_TYPE(wxEVT_NC_RIGHT_DOWN)
-DEFINE_EVENT_TYPE(wxEVT_NC_RIGHT_UP)
-DEFINE_EVENT_TYPE(wxEVT_NC_MOTION)
-DEFINE_EVENT_TYPE(wxEVT_NC_ENTER_WINDOW)
-DEFINE_EVENT_TYPE(wxEVT_NC_LEAVE_WINDOW)
-DEFINE_EVENT_TYPE(wxEVT_NC_LEFT_DCLICK)
-DEFINE_EVENT_TYPE(wxEVT_NC_MIDDLE_DCLICK)
-DEFINE_EVENT_TYPE(wxEVT_NC_RIGHT_DCLICK)
+wxDEFINE_EVENT( wxEVT_LEFT_DOWN, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_LEFT_UP, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_MIDDLE_DOWN, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_MIDDLE_UP, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_RIGHT_DOWN, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_RIGHT_UP, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_MOTION, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_ENTER_WINDOW, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_LEAVE_WINDOW, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_LEFT_DCLICK, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_MIDDLE_DCLICK, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_RIGHT_DCLICK, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_SET_FOCUS, wxFocusEvent )
+wxDEFINE_EVENT( wxEVT_KILL_FOCUS, wxFocusEvent )
+wxDEFINE_EVENT( wxEVT_CHILD_FOCUS, wxChildFocusEvent )
+wxDEFINE_EVENT( wxEVT_MOUSEWHEEL, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_AUX1_DOWN, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_AUX1_UP, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_AUX1_DCLICK, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_AUX2_DOWN, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_AUX2_UP, wxMouseEvent )
+wxDEFINE_EVENT( wxEVT_AUX2_DCLICK, wxMouseEvent )
// Character input event type
-DEFINE_EVENT_TYPE(wxEVT_CHAR)
-DEFINE_EVENT_TYPE(wxEVT_CHAR_HOOK)
-DEFINE_EVENT_TYPE(wxEVT_NAVIGATION_KEY)
-DEFINE_EVENT_TYPE(wxEVT_KEY_DOWN)
-DEFINE_EVENT_TYPE(wxEVT_KEY_UP)
+wxDEFINE_EVENT( wxEVT_CHAR, wxKeyEvent )
+wxDEFINE_EVENT( wxEVT_CHAR_HOOK, wxKeyEvent )
+wxDEFINE_EVENT( wxEVT_NAVIGATION_KEY, wxNavigationKeyEvent )
+wxDEFINE_EVENT( wxEVT_KEY_DOWN, wxKeyEvent )
+wxDEFINE_EVENT( wxEVT_KEY_UP, wxKeyEvent )
#if wxUSE_HOTKEY
-DEFINE_EVENT_TYPE(wxEVT_HOTKEY)
+wxDEFINE_EVENT( wxEVT_HOTKEY, wxKeyEvent )
#endif
// Set cursor event
-DEFINE_EVENT_TYPE(wxEVT_SET_CURSOR)
+wxDEFINE_EVENT( wxEVT_SET_CURSOR, wxSetCursorEvent )
// wxScrollbar and wxSlider event identifiers
-DEFINE_EVENT_TYPE(wxEVT_SCROLL_TOP)
-DEFINE_EVENT_TYPE(wxEVT_SCROLL_BOTTOM)
-DEFINE_EVENT_TYPE(wxEVT_SCROLL_LINEUP)
-DEFINE_EVENT_TYPE(wxEVT_SCROLL_LINEDOWN)
-DEFINE_EVENT_TYPE(wxEVT_SCROLL_PAGEUP)
-DEFINE_EVENT_TYPE(wxEVT_SCROLL_PAGEDOWN)
-DEFINE_EVENT_TYPE(wxEVT_SCROLL_THUMBTRACK)
-DEFINE_EVENT_TYPE(wxEVT_SCROLL_THUMBRELEASE)
-DEFINE_EVENT_TYPE(wxEVT_SCROLL_CHANGED)
+wxDEFINE_EVENT( wxEVT_SCROLL_TOP, wxScrollEvent )
+wxDEFINE_EVENT( wxEVT_SCROLL_BOTTOM, wxScrollEvent )
+wxDEFINE_EVENT( wxEVT_SCROLL_LINEUP, wxScrollEvent )
+wxDEFINE_EVENT( wxEVT_SCROLL_LINEDOWN, wxScrollEvent )
+wxDEFINE_EVENT( wxEVT_SCROLL_PAGEUP, wxScrollEvent )
+wxDEFINE_EVENT( wxEVT_SCROLL_PAGEDOWN, wxScrollEvent )
+wxDEFINE_EVENT( wxEVT_SCROLL_THUMBTRACK, wxScrollEvent )
+wxDEFINE_EVENT( wxEVT_SCROLL_THUMBRELEASE, wxScrollEvent )
+wxDEFINE_EVENT( wxEVT_SCROLL_CHANGED, wxScrollEvent )
// Scroll events from wxWindow
-DEFINE_EVENT_TYPE(wxEVT_SCROLLWIN_TOP)
-DEFINE_EVENT_TYPE(wxEVT_SCROLLWIN_BOTTOM)
-DEFINE_EVENT_TYPE(wxEVT_SCROLLWIN_LINEUP)
-DEFINE_EVENT_TYPE(wxEVT_SCROLLWIN_LINEDOWN)
-DEFINE_EVENT_TYPE(wxEVT_SCROLLWIN_PAGEUP)
-DEFINE_EVENT_TYPE(wxEVT_SCROLLWIN_PAGEDOWN)
-DEFINE_EVENT_TYPE(wxEVT_SCROLLWIN_THUMBTRACK)
-DEFINE_EVENT_TYPE(wxEVT_SCROLLWIN_THUMBRELEASE)
+wxDEFINE_EVENT( wxEVT_SCROLLWIN_TOP, wxScrollWinEvent )
+wxDEFINE_EVENT( wxEVT_SCROLLWIN_BOTTOM, wxScrollWinEvent )
+wxDEFINE_EVENT( wxEVT_SCROLLWIN_LINEUP, wxScrollWinEvent )
+wxDEFINE_EVENT( wxEVT_SCROLLWIN_LINEDOWN, wxScrollWinEvent )
+wxDEFINE_EVENT( wxEVT_SCROLLWIN_PAGEUP, wxScrollWinEvent )
+wxDEFINE_EVENT( wxEVT_SCROLLWIN_PAGEDOWN, wxScrollWinEvent )
+wxDEFINE_EVENT( wxEVT_SCROLLWIN_THUMBTRACK, wxScrollWinEvent )
+wxDEFINE_EVENT( wxEVT_SCROLLWIN_THUMBRELEASE, wxScrollWinEvent )
// System events
-DEFINE_EVENT_TYPE(wxEVT_SIZE)
-DEFINE_EVENT_TYPE(wxEVT_SIZING)
-DEFINE_EVENT_TYPE(wxEVT_MOVE)
-DEFINE_EVENT_TYPE(wxEVT_MOVING)
-DEFINE_EVENT_TYPE(wxEVT_MOVE_START)
-DEFINE_EVENT_TYPE(wxEVT_MOVE_END)
-DEFINE_EVENT_TYPE(wxEVT_CLOSE_WINDOW)
-DEFINE_EVENT_TYPE(wxEVT_END_SESSION)
-DEFINE_EVENT_TYPE(wxEVT_QUERY_END_SESSION)
-DEFINE_EVENT_TYPE(wxEVT_HIBERNATE)
-DEFINE_EVENT_TYPE(wxEVT_ACTIVATE_APP)
-DEFINE_EVENT_TYPE(wxEVT_ACTIVATE)
-DEFINE_EVENT_TYPE(wxEVT_CREATE)
-DEFINE_EVENT_TYPE(wxEVT_DESTROY)
-DEFINE_EVENT_TYPE(wxEVT_SHOW)
-DEFINE_EVENT_TYPE(wxEVT_ICONIZE)
-DEFINE_EVENT_TYPE(wxEVT_MAXIMIZE)
-DEFINE_EVENT_TYPE(wxEVT_MOUSE_CAPTURE_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_MOUSE_CAPTURE_LOST)
-DEFINE_EVENT_TYPE(wxEVT_PAINT)
-DEFINE_EVENT_TYPE(wxEVT_ERASE_BACKGROUND)
-DEFINE_EVENT_TYPE(wxEVT_NC_PAINT)
-DEFINE_EVENT_TYPE(wxEVT_PAINT_ICON)
-DEFINE_EVENT_TYPE(wxEVT_MENU_OPEN)
-DEFINE_EVENT_TYPE(wxEVT_MENU_CLOSE)
-DEFINE_EVENT_TYPE(wxEVT_MENU_HIGHLIGHT)
-DEFINE_EVENT_TYPE(wxEVT_CONTEXT_MENU)
-DEFINE_EVENT_TYPE(wxEVT_SYS_COLOUR_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_DISPLAY_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_SETTING_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_QUERY_NEW_PALETTE)
-DEFINE_EVENT_TYPE(wxEVT_PALETTE_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_JOY_BUTTON_DOWN)
-DEFINE_EVENT_TYPE(wxEVT_JOY_BUTTON_UP)
-DEFINE_EVENT_TYPE(wxEVT_JOY_MOVE)
-DEFINE_EVENT_TYPE(wxEVT_JOY_ZMOVE)
-DEFINE_EVENT_TYPE(wxEVT_DROP_FILES)
-DEFINE_EVENT_TYPE(wxEVT_DRAW_ITEM)
-DEFINE_EVENT_TYPE(wxEVT_MEASURE_ITEM)
-DEFINE_EVENT_TYPE(wxEVT_COMPARE_ITEM)
-DEFINE_EVENT_TYPE(wxEVT_INIT_DIALOG)
-DEFINE_EVENT_TYPE(wxEVT_UPDATE_UI)
+wxDEFINE_EVENT( wxEVT_SIZE, wxSizeEvent )
+wxDEFINE_EVENT( wxEVT_SIZING, wxSizeEvent )
+wxDEFINE_EVENT( wxEVT_MOVE, wxMoveEvent )
+wxDEFINE_EVENT( wxEVT_MOVING, wxMoveEvent )
+wxDEFINE_EVENT( wxEVT_MOVE_START, wxMoveEvent )
+wxDEFINE_EVENT( wxEVT_MOVE_END, wxMoveEvent )
+wxDEFINE_EVENT( wxEVT_CLOSE_WINDOW, wxCloseEvent )
+wxDEFINE_EVENT( wxEVT_END_SESSION, wxCloseEvent )
+wxDEFINE_EVENT( wxEVT_QUERY_END_SESSION, wxCloseEvent )
+wxDEFINE_EVENT( wxEVT_HIBERNATE, wxActivateEvent )
+wxDEFINE_EVENT( wxEVT_ACTIVATE_APP, wxActivateEvent )
+wxDEFINE_EVENT( wxEVT_ACTIVATE, wxActivateEvent )
+wxDEFINE_EVENT( wxEVT_CREATE, wxWindowCreateEvent )
+wxDEFINE_EVENT( wxEVT_DESTROY, wxWindowDestroyEvent )
+wxDEFINE_EVENT( wxEVT_SHOW, wxShowEvent )
+wxDEFINE_EVENT( wxEVT_ICONIZE, wxIconizeEvent )
+wxDEFINE_EVENT( wxEVT_MAXIMIZE, wxMaximizeEvent )
+wxDEFINE_EVENT( wxEVT_MOUSE_CAPTURE_CHANGED, wxMouseCaptureChangedEvent )
+wxDEFINE_EVENT( wxEVT_MOUSE_CAPTURE_LOST, wxMouseCaptureLostEvent )
+wxDEFINE_EVENT( wxEVT_PAINT, wxPaintEvent )
+wxDEFINE_EVENT( wxEVT_ERASE_BACKGROUND, wxEraseEvent )
+wxDEFINE_EVENT( wxEVT_NC_PAINT, wxNcPaintEvent )
+wxDEFINE_EVENT( wxEVT_MENU_OPEN, wxMenuEvent )
+wxDEFINE_EVENT( wxEVT_MENU_CLOSE, wxMenuEvent )
+wxDEFINE_EVENT( wxEVT_MENU_HIGHLIGHT, wxMenuEvent )
+wxDEFINE_EVENT( wxEVT_CONTEXT_MENU, wxContextMenuEvent )
+wxDEFINE_EVENT( wxEVT_SYS_COLOUR_CHANGED, wxSysColourChangedEvent )
+wxDEFINE_EVENT( wxEVT_DISPLAY_CHANGED, wxDisplayChangedEvent )
+wxDEFINE_EVENT( wxEVT_QUERY_NEW_PALETTE, wxQueryNewPaletteEvent )
+wxDEFINE_EVENT( wxEVT_PALETTE_CHANGED, wxPaletteChangedEvent )
+wxDEFINE_EVENT( wxEVT_JOY_BUTTON_DOWN, wxJoystickEvent )
+wxDEFINE_EVENT( wxEVT_JOY_BUTTON_UP, wxJoystickEvent )
+wxDEFINE_EVENT( wxEVT_JOY_MOVE, wxJoystickEvent )
+wxDEFINE_EVENT( wxEVT_JOY_ZMOVE, wxJoystickEvent )
+wxDEFINE_EVENT( wxEVT_DROP_FILES, wxDropFilesEvent )
+wxDEFINE_EVENT( wxEVT_INIT_DIALOG, wxInitDialogEvent )
+wxDEFINE_EVENT( wxEVT_UPDATE_UI, wxUpdateUIEvent )
// Clipboard events
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TEXT_COPY)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TEXT_CUT)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TEXT_PASTE)
+wxDEFINE_EVENT( wxEVT_COMMAND_TEXT_COPY, wxClipboardTextEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TEXT_CUT, wxClipboardTextEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TEXT_PASTE, wxClipboardTextEvent )
// Generic command events
// Note: a click is a higher-level event than button down/up
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LEFT_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LEFT_DCLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RIGHT_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RIGHT_DCLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_SET_FOCUS)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_KILL_FOCUS)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_ENTER)
+wxDEFINE_EVENT( wxEVT_COMMAND_LEFT_CLICK, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LEFT_DCLICK, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_RIGHT_CLICK, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_RIGHT_DCLICK, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_SET_FOCUS, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_KILL_FOCUS, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_ENTER, wxCommandEvent )
// Help events
-DEFINE_EVENT_TYPE(wxEVT_HELP)
-DEFINE_EVENT_TYPE(wxEVT_DETAILED_HELP)
+wxDEFINE_EVENT( wxEVT_HELP, wxHelpEvent )
+wxDEFINE_EVENT( wxEVT_DETAILED_HELP, wxHelpEvent )
#endif // wxUSE_GUI
return s_lastUsedEventType++;
}
+// ----------------------------------------------------------------------------
+// wxEventFunctor
+// ----------------------------------------------------------------------------
+
+wxEventFunctor::~wxEventFunctor()
+{
+}
// ----------------------------------------------------------------------------
// wxEvent
wxEvent::wxEvent(int theId, wxEventType commandType )
{
m_eventType = commandType;
- m_eventObject = (wxObject *) NULL;
+ m_eventObject = NULL;
m_timeStamp = 0;
m_id = theId;
m_skipped = false;
- m_callbackUserData = (wxObject *) NULL;
+ m_callbackUserData = NULL;
m_isCommandEvent = false;
m_propagationLevel = wxEVENT_PROPAGATE_NONE;
}
wxCommandEvent::wxCommandEvent(wxEventType commandType, int theId)
: wxEvent(theId, commandType)
{
- m_clientData = (char *) NULL;
- m_clientObject = (wxClientData *) NULL;
+ m_clientData = NULL;
+ m_clientObject = NULL;
m_extraLong = 0;
m_commandInt = 0;
m_isCommandEvent = true;
wxEvtHandler::wxEvtHandler()
{
- m_nextHandler = (wxEvtHandler *) NULL;
- m_previousHandler = (wxEvtHandler *) NULL;
+ m_nextHandler = NULL;
+ m_previousHandler = NULL;
m_enabled = true;
- m_dynamicEvents = (wxList *) NULL;
- m_pendingEvents = (wxList *) NULL;
+ m_dynamicEvents = NULL;
+ m_pendingEvents = NULL;
// no client data (yet)
m_clientData = NULL;
wxDynamicEventTableEntry *entry = (wxDynamicEventTableEntry*)*it;
// Remove ourselves from sink destructor notifications
- // (this has usually been been done, in wxTrackable destructor)
- wxEvtHandler *eventSink = entry->m_eventSink;
+ // (this has usually been done, in wxTrackable destructor)
+ wxEvtHandler *eventSink = entry->m_fn->GetHandler();
if ( eventSink )
{
wxEventConnectionRef * const
}
}
- if (entry->m_callbackUserData)
- delete entry->m_callbackUserData;
+ delete entry->m_callbackUserData;
delete entry;
}
delete m_dynamicEvents;
// call the handler via wxApp method which allows the user to catch
// any exceptions which may be thrown by any handler in the program
// in one place
- wxTheApp->HandleEvent(handler, (wxEventFunction)entry.m_fn, event);
+ wxTheApp->CallEventHandler(handler, *entry.m_fn, event);
}
else
#endif // wxUSE_EXCEPTIONS
{
- // no need for an extra virtual function call
- (handler->*((wxEventFunction) (entry.m_fn)))(event);
+ (*entry.m_fn)(handler, event);
}
if (!event.GetSkipped())
return false;
}
-void wxEvtHandler::Connect( int id, int lastId,
+void wxEvtHandler::Subscribe( int id, int lastId,
wxEventType eventType,
- wxObjectEventFunction func,
- wxObject *userData,
- wxEvtHandler* eventSink )
+ wxEventFunctor *func,
+ wxObject *userData )
{
wxDynamicEventTableEntry *entry =
- new wxDynamicEventTableEntry(eventType, id, lastId, func, userData, eventSink);
+ new wxDynamicEventTableEntry(eventType, id, lastId, func, userData);
if (!m_dynamicEvents)
m_dynamicEvents = new wxList;
m_dynamicEvents->Insert( (wxObject*) entry );
// Make sure we get to know when a sink is destroyed
+ wxEvtHandler *eventSink = func->GetHandler();
if ( eventSink && eventSink != this )
{
wxEventConnectionRef *evtConnRef = FindRefInTrackerList(eventSink);
}
}
-bool wxEvtHandler::Disconnect( int id, int lastId, wxEventType eventType,
- wxObjectEventFunction func,
- wxObject *userData,
- wxEvtHandler* eventSink )
+bool
+wxEvtHandler::Unsubscribe(int id,
+ int lastId,
+ wxEventType eventType,
+ const wxEventFunctor& func,
+ wxObject *userData)
{
if (!m_dynamicEvents)
return false;
// Remove connection from tracker node (wxEventConnectionRef)
+ wxEvtHandler *eventSink = func.GetHandler();
if ( eventSink && eventSink != this )
{
wxEventConnectionRef *evtConnRef = FindRefInTrackerList(eventSink);
if ((entry->m_id == id) &&
((entry->m_lastId == lastId) || (lastId == wxID_ANY)) &&
((entry->m_eventType == eventType) || (eventType == wxEVT_NULL)) &&
- ((entry->m_fn == func) || (func == (wxObjectEventFunction)NULL)) &&
- ((entry->m_eventSink == eventSink) || (eventSink == (wxEvtHandler*)NULL)) &&
- ((entry->m_callbackUserData == userData) || (userData == (wxObject*)NULL)))
+ (*entry->m_fn == func) &&
+ ((entry->m_callbackUserData == userData) || !userData))
{
- if (entry->m_callbackUserData)
- delete entry->m_callbackUserData;
+ delete entry->m_callbackUserData;
m_dynamicEvents->Erase( node );
delete entry;
return true;
if ((event.GetEventType() == entry->m_eventType) && (entry->m_fn != 0))
{
- wxEvtHandler *handler = entry->m_eventSink ? entry->m_eventSink
- : this;
+ wxEvtHandler *handler = entry->m_fn->GetHandler() ? entry->m_fn->GetHandler() : this;
if ( ProcessEventIfMatches(*entry, handler, event) )
return true;
}
wxDynamicEventTableEntry *entry = (wxDynamicEventTableEntry*)node->GetData();
node_nxt = node->GetNext();
- if ( entry->m_eventSink==sink )
+ if ( entry->m_fn->GetHandler() == sink )
{
- if (entry->m_callbackUserData)
- delete entry->m_callbackUserData;
+ delete entry->m_callbackUserData;
m_dynamicEvents->Erase( node );
delete entry;
}
else
win = win->GetParent();
}
- if (win == (wxWindow*) NULL)
- focusWin = (wxWindow*) NULL;
+ if (win == NULL)
+ focusWin = NULL;
return focusWin;
}
}
#endif // wxUSE_GUI
+
IMPLEMENT_DYNAMIC_CLASS(wxFindDialogEvent, wxCommandEvent)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_FIND)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_FIND_NEXT)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_FIND_REPLACE)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_FIND_REPLACE_ALL)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_FIND_CLOSE)
+wxDEFINE_EVENT( wxEVT_COMMAND_FIND, wxFindDialogEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_FIND_NEXT, wxFindDialogEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_FIND_REPLACE, wxFindDialogEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_FIND_REPLACE_ALL, wxFindDialogEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_FIND_CLOSE, wxFindDialogEvent )
// ============================================================================
// implementations
const char wxFileCtrlNameStr[] = "wxfilectrl";
-DEFINE_EVENT_TYPE( wxEVT_FILECTRL_SELECTIONCHANGED )
-DEFINE_EVENT_TYPE( wxEVT_FILECTRL_FILEACTIVATED )
-DEFINE_EVENT_TYPE( wxEVT_FILECTRL_FOLDERCHANGED )
+wxDEFINE_EVENT( wxEVT_FILECTRL_SELECTIONCHANGED, wxFileCtrlEvent )
+wxDEFINE_EVENT( wxEVT_FILECTRL_FILEACTIVATED, wxFileCtrlEvent )
+wxDEFINE_EVENT( wxEVT_FILECTRL_FOLDERCHANGED, wxFileCtrlEvent )
IMPLEMENT_DYNAMIC_CLASS( wxFileCtrlEvent, wxCommandEvent )
const char wxFilePickerWidgetLabel[] = wxTRANSLATE("Browse");
const char wxDirPickerWidgetLabel[] = wxTRANSLATE("Browse");
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_FILEPICKER_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_DIRPICKER_CHANGED)
+wxDEFINE_EVENT( wxEVT_COMMAND_FILEPICKER_CHANGED, wxFileDirPickerEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_DIRPICKER_CHANGED, wxFileDirPickerEvent )
IMPLEMENT_DYNAMIC_CLASS(wxFileDirPickerEvent, wxCommandEvent)
// ----------------------------------------------------------------------------
// complete sizer creation
wxPickerBase::PostCreation();
- m_picker->Connect(GetEventType(),
- wxFileDirPickerEventHandler(wxFileDirPickerCtrlBase::OnFileDirChange),
- NULL, this);
+ DoConnect( m_picker, this );
// default's wxPickerBase textctrl limit is too small for this control:
// make it bigger
const char wxFontPickerCtrlNameStr[] = "fontpicker";
const char wxFontPickerWidgetNameStr[] = "fontpickerwidget";
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_FONTPICKER_CHANGED)
+wxDEFINE_EVENT(wxEVT_COMMAND_FONTPICKER_CHANGED, wxFontPickerEvent)
IMPLEMENT_DYNAMIC_CLASS(wxFontPickerCtrl, wxPickerBase)
IMPLEMENT_DYNAMIC_CLASS(wxFontPickerEvent, wxCommandEvent)
IMPLEMENT_DYNAMIC_CLASS(wxHeaderCtrlEvent, wxNotifyEvent)
-const wxEventType wxEVT_COMMAND_HEADER_CLICK = wxNewEventType();
-const wxEventType wxEVT_COMMAND_HEADER_RIGHT_CLICK = wxNewEventType();
-const wxEventType wxEVT_COMMAND_HEADER_MIDDLE_CLICK = wxNewEventType();
+wxDEFINE_EVENT( wxEVT_COMMAND_HEADER_CLICK, wxHeaderCtrlEvent);
+wxDEFINE_EVENT( wxEVT_COMMAND_HEADER_RIGHT_CLICK, wxHeaderCtrlEvent);
+wxDEFINE_EVENT( wxEVT_COMMAND_HEADER_MIDDLE_CLICK, wxHeaderCtrlEvent);
-const wxEventType wxEVT_COMMAND_HEADER_DCLICK = wxNewEventType();
-const wxEventType wxEVT_COMMAND_HEADER_RIGHT_DCLICK = wxNewEventType();
-const wxEventType wxEVT_COMMAND_HEADER_MIDDLE_DCLICK = wxNewEventType();
+wxDEFINE_EVENT( wxEVT_COMMAND_HEADER_DCLICK, wxHeaderCtrlEvent);
+wxDEFINE_EVENT( wxEVT_COMMAND_HEADER_RIGHT_DCLICK, wxHeaderCtrlEvent);
+wxDEFINE_EVENT( wxEVT_COMMAND_HEADER_MIDDLE_DCLICK, wxHeaderCtrlEvent);
-const wxEventType wxEVT_COMMAND_HEADER_SEPARATOR_DCLICK = wxNewEventType();
+wxDEFINE_EVENT( wxEVT_COMMAND_HEADER_SEPARATOR_DCLICK, wxHeaderCtrlEvent);
-const wxEventType wxEVT_COMMAND_HEADER_BEGIN_RESIZE = wxNewEventType();
-const wxEventType wxEVT_COMMAND_HEADER_RESIZING = wxNewEventType();
-const wxEventType wxEVT_COMMAND_HEADER_END_RESIZE = wxNewEventType();
+wxDEFINE_EVENT( wxEVT_COMMAND_HEADER_BEGIN_RESIZE, wxHeaderCtrlEvent);
+wxDEFINE_EVENT( wxEVT_COMMAND_HEADER_RESIZING, wxHeaderCtrlEvent);
+wxDEFINE_EVENT( wxEVT_COMMAND_HEADER_END_RESIZE, wxHeaderCtrlEvent);
-const wxEventType wxEVT_COMMAND_HEADER_BEGIN_REORDER = wxNewEventType();
-const wxEventType wxEVT_COMMAND_HEADER_END_REORDER = wxNewEventType();
+wxDEFINE_EVENT( wxEVT_COMMAND_HEADER_BEGIN_REORDER, wxHeaderCtrlEvent);
+wxDEFINE_EVENT( wxEVT_COMMAND_HEADER_END_REORDER, wxHeaderCtrlEvent);
-const wxEventType wxEVT_COMMAND_HEADER_DRAGGING_CANCELLED = wxNewEventType();
+wxDEFINE_EVENT( wxEVT_COMMAND_HEADER_DRAGGING_CANCELLED, wxHeaderCtrlEvent);
#endif // wxUSE_HEADERCTRL
// ============================================================================
IMPLEMENT_DYNAMIC_CLASS(wxHyperlinkEvent, wxCommandEvent)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_HYPERLINK)
+wxDEFINE_EVENT( wxEVT_COMMAND_HYPERLINK, wxHyperlinkEvent )
const char wxHyperlinkCtrlNameStr[] = "hyperlink";
const char wxListCtrlNameStr[] = "listCtrl";
// ListCtrl events
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_BEGIN_DRAG)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_BEGIN_RDRAG)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_END_LABEL_EDIT)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_DELETE_ITEM)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_ITEM_SELECTED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_ITEM_DESELECTED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_KEY_DOWN)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_INSERT_ITEM)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_COL_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_COL_RIGHT_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_COL_BEGIN_DRAG)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_COL_DRAGGING)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_COL_END_DRAG)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_ITEM_ACTIVATED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_ITEM_FOCUSED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_LIST_CACHE_HINT)
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_BEGIN_DRAG, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_BEGIN_RDRAG, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_END_LABEL_EDIT, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_DELETE_ITEM, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_ITEM_SELECTED, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_ITEM_DESELECTED, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_KEY_DOWN, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_INSERT_ITEM, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_COL_CLICK, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_COL_RIGHT_CLICK, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_COL_BEGIN_DRAG, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_COL_DRAGGING, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_COL_END_DRAG, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_ITEM_ACTIVATED, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_ITEM_FOCUSED, wxListEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LIST_CACHE_HINT, wxListEvent )
#endif // wxUSE_LISTCTRL
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
IMPLEMENT_CLASS(wxMediaCtrl, wxControl)
-DEFINE_EVENT_TYPE(wxEVT_MEDIA_STATECHANGED)
-DEFINE_EVENT_TYPE(wxEVT_MEDIA_PLAY)
-DEFINE_EVENT_TYPE(wxEVT_MEDIA_PAUSE)
+wxDEFINE_EVENT( wxEVT_MEDIA_STATECHANGED, wxMediaEvent )
+wxDEFINE_EVENT( wxEVT_MEDIA_PLAY, wxMediaEvent )
+wxDEFINE_EVENT( wxEVT_MEDIA_PAUSE, wxMediaEvent )
IMPLEMENT_CLASS(wxMediaBackend, wxObject)
IMPLEMENT_DYNAMIC_CLASS(wxMediaEvent, wxEvent)
-DEFINE_EVENT_TYPE(wxEVT_MEDIA_FINISHED)
-DEFINE_EVENT_TYPE(wxEVT_MEDIA_LOADED)
-DEFINE_EVENT_TYPE(wxEVT_MEDIA_STOP)
+wxDEFINE_EVENT( wxEVT_MEDIA_FINISHED, wxMediaEvent )
+wxDEFINE_EVENT( wxEVT_MEDIA_LOADED, wxMediaEvent )
+wxDEFINE_EVENT( wxEVT_MEDIA_STOP, wxMediaEvent )
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
//
// implementation
// ============================================================================
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING)
+wxDEFINE_EVENT( wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED, wxBookCtrlEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING, wxBookCtrlEvent )
// ----------------------------------------------------------------------------
// geometry
// ============================================================================
#ifdef wxHAS_POWER_EVENTS
- DEFINE_EVENT_TYPE(wxEVT_POWER_SUSPENDING)
- DEFINE_EVENT_TYPE(wxEVT_POWER_SUSPENDED)
- DEFINE_EVENT_TYPE(wxEVT_POWER_SUSPEND_CANCEL)
- DEFINE_EVENT_TYPE(wxEVT_POWER_RESUME)
+ wxDEFINE_EVENT( wxEVT_POWER_SUSPENDING, wxPowerEvent )
+ wxDEFINE_EVENT( wxEVT_POWER_SUSPENDED, wxPowerEvent )
+ wxDEFINE_EVENT( wxEVT_POWER_SUSPEND_CANCEL, wxPowerEvent )
+ wxDEFINE_EVENT( wxEVT_POWER_RESUME, wxPowerEvent )
IMPLEMENT_DYNAMIC_CLASS(wxPowerEvent, wxEvent)
#endif
// event tables and such
// ----------------------------------------------------------------------------
-DEFINE_EVENT_TYPE(wxEVT_END_PROCESS)
+wxDEFINE_EVENT( wxEVT_END_PROCESS, wxProcessEvent )
IMPLEMENT_DYNAMIC_CLASS(wxProcess, wxEvtHandler)
IMPLEMENT_DYNAMIC_CLASS(wxProcessEvent, wxEvent)
// macros and constants
// --------------------------------------------------------------------------
+// event
+wxDEFINE_EVENT(wxEVT_SOCKET, wxSocketEvent);
+
// discard buffer
#define MAX_DISCARD_SIZE (10 * 1024)
--- /dev/null
+/////////////////////////////////////////////////////////////////////////////
+// Name: src/common/spinbuttcmn.cpp
+// Purpose: define wxSpinButton event types
+// Author: Peter Most
+// Created: 01.11.08
+// RCS-ID: $Id:$
+// Copyright: (c) 2008-2009 wxWidgets team
+// Licence: wxWindows licence
+/////////////////////////////////////////////////////////////////////////////
+
+// ============================================================================
+// declarations
+// ============================================================================
+
+// ----------------------------------------------------------------------------
+// headers
+// ----------------------------------------------------------------------------
+
+// For compilers that support precompilation, includes "wx.h".
+#include "wx/wxprec.h"
+
+#ifdef __BORLANDC__
+ #pragma hdrstop
+#endif
+
+#include "wx/spinbutt.h"
+
+wxDEFINE_EVENT_REFERENCE( wxEVT_SPIN_UP, wxSpinEvent, wxEVT_SCROLL_LINEUP )
+wxDEFINE_EVENT_REFERENCE( wxEVT_SPIN_DOWN, wxSpinEvent, wxEVT_SCROLL_LINEDOWN )
+wxDEFINE_EVENT_REFERENCE( wxEVT_SPIN, wxSpinEvent, wxEVT_SCROLL_THUMBTRACK )
+
--- /dev/null
+/////////////////////////////////////////////////////////////////////////////
+// Name: src/common/spinctrlcmn.cpp
+// Purpose: define wxSpinCtrl event types
+// Author: Peter Most
+// Created: 01.11.08
+// RCS-ID: $Id:$
+// Copyright: (c) 2008-2009 wxWidgets team
+// Licence: wxWindows licence
+/////////////////////////////////////////////////////////////////////////////
+
+// ============================================================================
+// declarations
+// ============================================================================
+
+// ----------------------------------------------------------------------------
+// headers
+// ----------------------------------------------------------------------------
+
+// For compilers that support precompilation, includes "wx.h".
+#include "wx/wxprec.h"
+
+#ifdef __BORLANDC__
+ #pragma hdrstop
+#endif
+
+#include "wx/spinbutt.h"
+#include "wx/spinctrl.h"
+
+wxDEFINE_EVENT(wxEVT_COMMAND_SPINCTRL_UPDATED, wxSpinEvent)
+wxDEFINE_EVENT(wxEVT_COMMAND_SPINCTRLDOUBLE_UPDATED, wxSpinDoubleEvent)
+
const char wxSearchCtrlNameStr[] = "searchCtrl";
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_SEARCHCTRL_CANCEL_BTN)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_SEARCHCTRL_SEARCH_BTN)
+wxDEFINE_EVENT(wxEVT_COMMAND_SEARCHCTRL_CANCEL_BTN, wxCommandEvent);
+wxDEFINE_EVENT(wxEVT_COMMAND_SEARCHCTRL_SEARCH_BTN, wxCommandEvent);
#endif // wxUSE_SEARCHCTRL
#include "wx/taskbar.h"
-DEFINE_EVENT_TYPE( wxEVT_TASKBAR_MOVE )
-DEFINE_EVENT_TYPE( wxEVT_TASKBAR_LEFT_DOWN )
-DEFINE_EVENT_TYPE( wxEVT_TASKBAR_LEFT_UP )
-DEFINE_EVENT_TYPE( wxEVT_TASKBAR_RIGHT_DOWN )
-DEFINE_EVENT_TYPE( wxEVT_TASKBAR_RIGHT_UP )
-DEFINE_EVENT_TYPE( wxEVT_TASKBAR_LEFT_DCLICK )
-DEFINE_EVENT_TYPE( wxEVT_TASKBAR_RIGHT_DCLICK )
-DEFINE_EVENT_TYPE( wxEVT_TASKBAR_BALLOON_TIMEOUT )
-DEFINE_EVENT_TYPE( wxEVT_TASKBAR_BALLOON_CLICK )
+wxDEFINE_EVENT( wxEVT_TASKBAR_MOVE, wxTaskBarIconEvent )
+wxDEFINE_EVENT( wxEVT_TASKBAR_LEFT_DOWN, wxTaskBarIconEvent )
+wxDEFINE_EVENT( wxEVT_TASKBAR_LEFT_UP, wxTaskBarIconEvent )
+wxDEFINE_EVENT( wxEVT_TASKBAR_RIGHT_DOWN, wxTaskBarIconEvent )
+wxDEFINE_EVENT( wxEVT_TASKBAR_RIGHT_UP, wxTaskBarIconEvent )
+wxDEFINE_EVENT( wxEVT_TASKBAR_LEFT_DCLICK, wxTaskBarIconEvent )
+wxDEFINE_EVENT( wxEVT_TASKBAR_RIGHT_DCLICK, wxTaskBarIconEvent )
+wxDEFINE_EVENT( wxEVT_TASKBAR_BALLOON_TIMEOUT, wxTaskBarIconEvent )
+wxDEFINE_EVENT( wxEVT_TASKBAR_BALLOON_CLICK, wxTaskBarIconEvent )
BEGIN_EVENT_TABLE(wxTaskBarIconBase, wxEvtHandler)
IMPLEMENT_DYNAMIC_CLASS(wxTextUrlEvent, wxCommandEvent)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TEXT_UPDATED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TEXT_ENTER)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TEXT_URL)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TEXT_MAXLEN)
+wxDEFINE_EVENT( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TEXT_ENTER, wxCommandEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TEXT_URL, wxTextUrlEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TEXT_MAXLEN, wxCommandEvent )
IMPLEMENT_ABSTRACT_CLASS(wxTextCtrlBase, wxControl)
// define this one even if !wxUSE_TEXTCTRL because it is also used by other
// controls (wxComboBox and wxSpinCtrl)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TEXT_UPDATED)
+wxDEFINE_EVENT( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEvent )
#endif // wxUSE_TEXTCTRL/!wxUSE_TEXTCTRL
IMPLEMENT_DYNAMIC_CLASS(wxTimerEvent, wxEvent)
+wxDEFINE_EVENT(wxEVT_TIMER, wxTimerEvent);
+
// ============================================================================
// wxTimerBase implementation
// ============================================================================
// events
// ----------------------------------------------------------------------------
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_BEGIN_DRAG)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_BEGIN_RDRAG)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_BEGIN_LABEL_EDIT)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_END_LABEL_EDIT)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_DELETE_ITEM)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_GET_INFO)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_SET_INFO)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_ITEM_EXPANDED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_ITEM_EXPANDING)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_ITEM_COLLAPSED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_ITEM_COLLAPSING)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_SEL_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_SEL_CHANGING)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_KEY_DOWN)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_ITEM_ACTIVATED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_END_DRAG)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_STATE_IMAGE_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_ITEM_GETTOOLTIP)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_ITEM_MENU)
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_BEGIN_DRAG, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_BEGIN_RDRAG, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_BEGIN_LABEL_EDIT, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_END_LABEL_EDIT, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_DELETE_ITEM, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_GET_INFO, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_SET_INFO, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_ITEM_EXPANDED, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_ITEM_EXPANDING, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_ITEM_COLLAPSED, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_ITEM_COLLAPSING, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_SEL_CHANGED, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_SEL_CHANGING, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_KEY_DOWN, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_ITEM_ACTIVATED, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_END_DRAG, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_STATE_IMAGE_CLICK, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_ITEM_GETTOOLTIP, wxTreeEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREE_ITEM_MENU, wxTreeEvent )
// ----------------------------------------------------------------------------
// Tree event
NULL, this);
m_spinYear->Connect(m_spinYear->GetId(), wxEVT_COMMAND_SPINCTRL_UPDATED,
- wxCommandEventHandler(wxGenericCalendarCtrl::OnYearChange),
+ wxSpinEventHandler(wxGenericCalendarCtrl::OnYearChange),
NULL, this);
}
SetDateAndNotify(target);
}
-void wxGenericCalendarCtrl::OnYearChange(wxCommandEvent& event)
+void wxGenericCalendarCtrl::HandleYearChange(wxCommandEvent& event)
{
int year = (int)event.GetInt();
if ( year == INT_MIN )
}
}
+void wxGenericCalendarCtrl::OnYearChange(wxSpinEvent& event)
+{
+ HandleYearChange( event );
+}
+
void wxGenericCalendarCtrl::OnYearTextChange(wxCommandEvent& event)
{
SetUserChangedYear();
- OnYearChange(event);
+ HandleYearChange(event);
}
// Responds to colour changes, and passes event on to children.
IMPLEMENT_DYNAMIC_CLASS(wxChoicebook, wxBookCtrlBase)
-const wxEventType wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGING = wxNewEventType();
-const wxEventType wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGED = wxNewEventType();
+wxDEFINE_EVENT( wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGING, wxBookCtrlEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGED, wxBookCtrlEvent )
BEGIN_EVENT_TABLE(wxChoicebook, wxBookCtrlBase)
EVT_CHOICE(wxID_ANY, wxChoicebook::OnChoiceSelected)
// wxGenericCollapsiblePane
//-----------------------------------------------------------------------------
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_COLLPANE_CHANGED)
+wxDEFINE_EVENT( wxEVT_COMMAND_COLLPANE_CHANGED, wxCollapsiblePaneEvent )
IMPLEMENT_DYNAMIC_CLASS(wxGenericCollapsiblePane, wxControl)
IMPLEMENT_DYNAMIC_CLASS(wxCollapsiblePaneEvent, wxCommandEvent)
// events
// ----------------------------------------------------------------------------
-DEFINE_EVENT_TYPE(wxEVT_GRID_CELL_LEFT_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_GRID_CELL_RIGHT_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_GRID_CELL_LEFT_DCLICK)
-DEFINE_EVENT_TYPE(wxEVT_GRID_CELL_RIGHT_DCLICK)
-DEFINE_EVENT_TYPE(wxEVT_GRID_CELL_BEGIN_DRAG)
-DEFINE_EVENT_TYPE(wxEVT_GRID_LABEL_LEFT_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_GRID_LABEL_RIGHT_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_GRID_LABEL_LEFT_DCLICK)
-DEFINE_EVENT_TYPE(wxEVT_GRID_LABEL_RIGHT_DCLICK)
-DEFINE_EVENT_TYPE(wxEVT_GRID_ROW_SIZE)
-DEFINE_EVENT_TYPE(wxEVT_GRID_COL_SIZE)
-DEFINE_EVENT_TYPE(wxEVT_GRID_COL_MOVE)
-DEFINE_EVENT_TYPE(wxEVT_GRID_COL_SORT)
-DEFINE_EVENT_TYPE(wxEVT_GRID_RANGE_SELECT)
-DEFINE_EVENT_TYPE(wxEVT_GRID_CELL_CHANGING)
-DEFINE_EVENT_TYPE(wxEVT_GRID_CELL_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_GRID_SELECT_CELL)
-DEFINE_EVENT_TYPE(wxEVT_GRID_EDITOR_SHOWN)
-DEFINE_EVENT_TYPE(wxEVT_GRID_EDITOR_HIDDEN)
-DEFINE_EVENT_TYPE(wxEVT_GRID_EDITOR_CREATED)
+wxDEFINE_EVENT( wxEVT_GRID_CELL_LEFT_CLICK, wxGridEvent )
+wxDEFINE_EVENT( wxEVT_GRID_CELL_RIGHT_CLICK, wxGridEvent )
+wxDEFINE_EVENT( wxEVT_GRID_CELL_LEFT_DCLICK, wxGridEvent )
+wxDEFINE_EVENT( wxEVT_GRID_CELL_RIGHT_DCLICK, wxGridEvent )
+wxDEFINE_EVENT( wxEVT_GRID_CELL_BEGIN_DRAG, wxGridEvent )
+wxDEFINE_EVENT( wxEVT_GRID_LABEL_LEFT_CLICK, wxGridEvent )
+wxDEFINE_EVENT( wxEVT_GRID_LABEL_RIGHT_CLICK, wxGridEvent )
+wxDEFINE_EVENT( wxEVT_GRID_LABEL_LEFT_DCLICK, wxGridEvent )
+wxDEFINE_EVENT( wxEVT_GRID_LABEL_RIGHT_DCLICK, wxGridEvent )
+wxDEFINE_EVENT( wxEVT_GRID_ROW_SIZE, wxGridSizeEvent )
+wxDEFINE_EVENT( wxEVT_GRID_COL_SIZE, wxGridSizeEvent )
+wxDEFINE_EVENT( wxEVT_GRID_COL_MOVE, wxGridEvent )
+wxDEFINE_EVENT( wxEVT_GRID_COL_SORT, wxGridEvent )
+wxDEFINE_EVENT( wxEVT_GRID_RANGE_SELECT, wxGridRangeSelectEvent )
+wxDEFINE_EVENT( wxEVT_GRID_CELL_CHANGING, wxGridEvent )
+wxDEFINE_EVENT( wxEVT_GRID_CELL_CHANGED, wxGridEvent )
+wxDEFINE_EVENT( wxEVT_GRID_SELECT_CELL, wxGridEvent )
+wxDEFINE_EVENT( wxEVT_GRID_EDITOR_SHOWN, wxGridEvent )
+wxDEFINE_EVENT( wxEVT_GRID_EDITOR_HIDDEN, wxGridEvent )
+wxDEFINE_EVENT( wxEVT_GRID_EDITOR_CREATED, wxGridEditorCreatedEvent )
// ============================================================================
// implementation
IMPLEMENT_DYNAMIC_CLASS(wxQueryLayoutInfoEvent, wxEvent)
IMPLEMENT_DYNAMIC_CLASS(wxCalculateLayoutEvent, wxEvent)
-DEFINE_EVENT_TYPE(wxEVT_QUERY_LAYOUT_INFO)
-DEFINE_EVENT_TYPE(wxEVT_CALCULATE_LAYOUT)
+wxDEFINE_EVENT( wxEVT_QUERY_LAYOUT_INFO, wxQueryLayoutInfoEvent )
+wxDEFINE_EVENT( wxEVT_CALCULATE_LAYOUT, wxCalculateLayoutEvent )
#if wxUSE_SASH
IMPLEMENT_CLASS(wxSashLayoutWindow, wxSashWindow)
IMPLEMENT_DYNAMIC_CLASS(wxListbook, wxBookCtrlBase)
-const wxEventType wxEVT_COMMAND_LISTBOOK_PAGE_CHANGING = wxNewEventType();
-const wxEventType wxEVT_COMMAND_LISTBOOK_PAGE_CHANGED = wxNewEventType();
+wxDEFINE_EVENT( wxEVT_COMMAND_LISTBOOK_PAGE_CHANGING, wxBookCtrlEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_LISTBOOK_PAGE_CHANGED, wxBookCtrlEvent )
BEGIN_EVENT_TABLE(wxListbook, wxBookCtrlBase)
EVT_SIZE(wxListbook::OnSize)
#include "wx/laywin.h"
-DEFINE_EVENT_TYPE(wxEVT_SASH_DRAGGED)
+wxDEFINE_EVENT( wxEVT_SASH_DRAGGED, wxSashEvent )
IMPLEMENT_DYNAMIC_CLASS(wxSashWindow, wxWindow)
IMPLEMENT_DYNAMIC_CLASS(wxSashEvent, wxCommandEvent)
#include <stdlib.h>
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGING)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_SPLITTER_DOUBLECLICKED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_SPLITTER_UNSPLIT)
+wxDEFINE_EVENT( wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGED, wxSplitterEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGING, wxSplitterEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_SPLITTER_DOUBLECLICKED, wxSplitterEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_SPLITTER_UNSPLIT, wxSplitterEvent )
IMPLEMENT_DYNAMIC_CLASS(wxSplitterWindow, wxWindow)
IMPLEMENT_DYNAMIC_CLASS(wxToolbook, wxBookCtrlBase)
-const wxEventType wxEVT_COMMAND_TOOLBOOK_PAGE_CHANGING = wxNewEventType();
-const wxEventType wxEVT_COMMAND_TOOLBOOK_PAGE_CHANGED = wxNewEventType();
+wxDEFINE_EVENT( wxEVT_COMMAND_TOOLBOOK_PAGE_CHANGING, wxBookCtrlEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TOOLBOOK_PAGE_CHANGED, wxBookCtrlEvent )
BEGIN_EVENT_TABLE(wxToolbook, wxBookCtrlBase)
EVT_SIZE(wxToolbook::OnSize)
IMPLEMENT_DYNAMIC_CLASS(wxTreebook, wxBookCtrlBase)
-const wxEventType wxEVT_COMMAND_TREEBOOK_PAGE_CHANGING = wxNewEventType();
-const wxEventType wxEVT_COMMAND_TREEBOOK_PAGE_CHANGED = wxNewEventType();
-const wxEventType wxEVT_COMMAND_TREEBOOK_NODE_COLLAPSED = wxNewEventType();
-const wxEventType wxEVT_COMMAND_TREEBOOK_NODE_EXPANDED = wxNewEventType();
+wxDEFINE_EVENT( wxEVT_COMMAND_TREEBOOK_PAGE_CHANGING, wxBookCtrlEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREEBOOK_PAGE_CHANGED, wxBookCtrlEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREEBOOK_NODE_COLLAPSED, wxBookCtrlEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_TREEBOOK_NODE_EXPANDED, wxBookCtrlEvent )
BEGIN_EVENT_TABLE(wxTreebook, wxBookCtrlBase)
EVT_TREE_SEL_CHANGED (wxID_ANY, wxTreebook::OnTreeSelectionChange)
// event tables and such
// ----------------------------------------------------------------------------
-DEFINE_EVENT_TYPE(wxEVT_WIZARD_PAGE_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_WIZARD_PAGE_CHANGING)
-DEFINE_EVENT_TYPE(wxEVT_WIZARD_CANCEL)
-DEFINE_EVENT_TYPE(wxEVT_WIZARD_FINISHED)
-DEFINE_EVENT_TYPE(wxEVT_WIZARD_HELP)
+wxDEFINE_EVENT( wxEVT_WIZARD_PAGE_CHANGED, wxWizardEvent )
+wxDEFINE_EVENT( wxEVT_WIZARD_PAGE_CHANGING, wxWizardEvent )
+wxDEFINE_EVENT( wxEVT_WIZARD_CANCEL, wxWizardEvent )
+wxDEFINE_EVENT( wxEVT_WIZARD_FINISHED, wxWizardEvent )
+wxDEFINE_EVENT( wxEVT_WIZARD_HELP, wxWizardEvent )
BEGIN_EVENT_TABLE(wxWizard, wxDialog)
EVT_BUTTON(wxID_CANCEL, wxWizard::OnCancel)
const char wxCollapsiblePaneNameStr[] = "collapsiblePane";
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_COLLPANE_CHANGED)
+wxDEFINE_EVENT( wxEVT_COMMAND_COLLPANE_CHANGED, wxCollapsiblePaneEvent )
IMPLEMENT_DYNAMIC_CLASS(wxCollapsiblePaneEvent, wxCommandEvent)
}
}
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TOGGLEBUTTON_CLICKED)
+wxDEFINE_EVENT( wxEVT_COMMAND_TOGGLEBUTTON_CLICKED, wxCommandEvent )
// ------------------------------------------------------------------------
// wxBitmapToggleButton
}
}
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TOGGLEBUTTON_CLICKED)
+wxDEFINE_EVENT( wxEVT_COMMAND_TOGGLEBUTTON_CLICKED, wxCommandEvent )
// ------------------------------------------------------------------------
// wxToggleBitmapButton
IMPLEMENT_DYNAMIC_CLASS( wxWebKitStateChangedEvent, wxCommandEvent )
-DEFINE_EVENT_TYPE( wxEVT_WEBKIT_STATE_CHANGED )
+wxDEFINE_EVENT( wxEVT_WEBKIT_STATE_CHANGED, wxWebKitStateChangedEvent )
wxWebKitStateChangedEvent::wxWebKitStateChangedEvent( wxWindow* win )
{
IMPLEMENT_DYNAMIC_CLASS( wxWebKitBeforeLoadEvent, wxCommandEvent )
-DEFINE_EVENT_TYPE( wxEVT_WEBKIT_BEFORE_LOAD )
+wxDEFINE_EVENT( wxEVT_WEBKIT_BEFORE_LOAD, wxWebKitBeforeLoadEvent )
wxWebKitBeforeLoadEvent::wxWebKitBeforeLoadEvent( wxWindow* win )
{
IMPLEMENT_DYNAMIC_CLASS( wxWebKitNewWindowEvent, wxCommandEvent )
-DEFINE_EVENT_TYPE( wxEVT_WEBKIT_NEW_WINDOW )
+wxDEFINE_EVENT( wxEVT_WEBKIT_NEW_WINDOW, wxWebKitNewWindowEvent )
wxWebKitNewWindowEvent::wxWebKitNewWindowEvent( wxWindow* win )
{
IMPLEMENT_DYNAMIC_CLASS(wxHtmlLinkEvent, wxCommandEvent)
IMPLEMENT_DYNAMIC_CLASS(wxHtmlCellEvent, wxCommandEvent)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_HTML_CELL_CLICKED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_HTML_CELL_HOVER)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_HTML_LINK_CLICKED)
+wxDEFINE_EVENT( wxEVT_COMMAND_HTML_CELL_CLICKED, wxHtmlCellEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_HTML_CELL_HOVER, wxHtmlCellEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_HTML_LINK_CLICKED, wxHtmlLinkEvent )
#if wxUSE_CLIPBOARD
#if wxUSE_TOGGLEBTN
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TOGGLEBUTTON_CLICKED)
+wxDEFINE_EVENT( wxEVT_COMMAND_TOGGLEBUTTON_CLICKED, wxCommandEvent )
IMPLEMENT_DYNAMIC_CLASS(wxToggleButton, wxControl)
bool wxToggleButton::Create( wxWindow* parent, wxWindowID id,
#include "wx/dynlib.h"
-DEFINE_EVENT_TYPE(wxEVT_DIALUP_CONNECTED)
-DEFINE_EVENT_TYPE(wxEVT_DIALUP_DISCONNECTED)
+wxDEFINE_EVENT( wxEVT_DIALUP_CONNECTED, wxDialUpEvent )
+wxDEFINE_EVENT( wxEVT_DIALUP_DISCONNECTED, wxDialUpEvent )
// Doesn't yet compile under VC++ 4, BC++, Watcom C++,
// Wine: no wininet.h
WX_DECLARE_AUTOOLE(wxAutoIConnectionPoint, IConnectionPoint)
WX_DECLARE_AUTOOLE(wxAutoIConnectionPointContainer, IConnectionPointContainer)
-DEFINE_EVENT_TYPE(wxEVT_ACTIVEX)
+wxDEFINE_EVENT( wxEVT_ACTIVEX, wxActiveXEvent )
// Ole class helpers (sort of MFC-like) from wxActiveX
#define DECLARE_OLE_UNKNOWN(cls)\
// macros
// ----------------------------------------------------------------------------
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TOGGLEBUTTON_CLICKED)
+wxDEFINE_EVENT( wxEVT_COMMAND_TOGGLEBUTTON_CLICKED, wxCommandEvent )
// ============================================================================
// implementation
// ----------------------------------------------------------------------------
IMPLEMENT_DYNAMIC_CLASS(wxToggleButton, wxControl)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TOGGLEBUTTON_CLICKED)
+wxDEFINE_EVENT( wxEVT_COMMAND_TOGGLEBUTTON_CLICKED, wxCommandEvent )
#define BUTTON_HEIGHT_FROM_CHAR_HEIGHT(cy) (11*EDIT_HEIGHT_FROM_CHAR_HEIGHT(cy)/10)
// ----------------------------------------------------------------------------
IMPLEMENT_DYNAMIC_CLASS(wxToggleButton, wxControl)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TOGGLEBUTTON_CLICKED)
+wxDEFINE_EVENT( wxEVT_COMMAND_TOGGLEBUTTON_CLICKED, wxCommandEvent )
// ============================================================================
// implementation
// ----------------------------------------------------------------------------
IMPLEMENT_DYNAMIC_CLASS(wxToggleButton, wxControl)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TOGGLEBUTTON_CLICKED)
+wxDEFINE_EVENT( wxEVT_COMMAND_TOGGLEBUTTON_CLICKED, wxCommandEvent )
// ============================================================================
// implementation
IMPLEMENT_DYNAMIC_CLASS(wxPropertyGridEvent, wxCommandEvent)
-DEFINE_EVENT_TYPE( wxEVT_PG_SELECTED )
-DEFINE_EVENT_TYPE( wxEVT_PG_CHANGING )
-DEFINE_EVENT_TYPE( wxEVT_PG_CHANGED )
-DEFINE_EVENT_TYPE( wxEVT_PG_HIGHLIGHTED )
-DEFINE_EVENT_TYPE( wxEVT_PG_RIGHT_CLICK )
-DEFINE_EVENT_TYPE( wxEVT_PG_PAGE_CHANGED )
-DEFINE_EVENT_TYPE( wxEVT_PG_ITEM_EXPANDED )
-DEFINE_EVENT_TYPE( wxEVT_PG_ITEM_COLLAPSED )
-DEFINE_EVENT_TYPE( wxEVT_PG_DOUBLE_CLICK )
+wxDEFINE_EVENT( wxEVT_PG_SELECTED, wxPropertyGridEvent )
+wxDEFINE_EVENT( wxEVT_PG_CHANGING, wxPropertyGridEvent )
+wxDEFINE_EVENT( wxEVT_PG_CHANGED, wxPropertyGridEvent )
+wxDEFINE_EVENT( wxEVT_PG_HIGHLIGHTED, wxPropertyGridEvent )
+wxDEFINE_EVENT( wxEVT_PG_RIGHT_CLICK, wxPropertyGridEvent )
+wxDEFINE_EVENT( wxEVT_PG_PAGE_CHANGED, wxPropertyGridEvent )
+wxDEFINE_EVENT( wxEVT_PG_ITEM_EXPANDED, wxPropertyGridEvent )
+wxDEFINE_EVENT( wxEVT_PG_ITEM_COLLAPSED, wxPropertyGridEvent )
+wxDEFINE_EVENT( wxEVT_PG_DOUBLE_CLICK, wxPropertyGridEvent )
// -----------------------------------------------------------------------
#include "wx/app.h"
WX_CHECK_BUILD_OPTIONS("wxRichTextCtrl")
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RICHTEXT_LEFT_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RICHTEXT_MIDDLE_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RICHTEXT_RIGHT_CLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RICHTEXT_LEFT_DCLICK)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RICHTEXT_RETURN)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RICHTEXT_CHARACTER)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RICHTEXT_DELETE)
-
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RICHTEXT_STYLESHEET_REPLACING)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RICHTEXT_STYLESHEET_REPLACED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RICHTEXT_STYLESHEET_CHANGING)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RICHTEXT_STYLESHEET_CHANGED)
-
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RICHTEXT_CONTENT_INSERTED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RICHTEXT_CONTENT_DELETED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RICHTEXT_STYLE_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RICHTEXT_SELECTION_CHANGED)
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_RICHTEXT_BUFFER_RESET)
+wxDEFINE_EVENT( wxEVT_COMMAND_RICHTEXT_LEFT_CLICK, wxRichTextEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_RICHTEXT_MIDDLE_CLICK, wxRichTextEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_RICHTEXT_RIGHT_CLICK, wxRichTextEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_RICHTEXT_LEFT_DCLICK, wxRichTextEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_RICHTEXT_RETURN, wxRichTextEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_RICHTEXT_CHARACTER, wxRichTextEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_RICHTEXT_DELETE, wxRichTextEvent )
+
+wxDEFINE_EVENT( wxEVT_COMMAND_RICHTEXT_STYLESHEET_REPLACING, wxRichTextEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_RICHTEXT_STYLESHEET_REPLACED, wxRichTextEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_RICHTEXT_STYLESHEET_CHANGING, wxRichTextEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_RICHTEXT_STYLESHEET_CHANGED, wxRichTextEvent )
+
+wxDEFINE_EVENT( wxEVT_COMMAND_RICHTEXT_CONTENT_INSERTED, wxRichTextEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_RICHTEXT_CONTENT_DELETED, wxRichTextEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_RICHTEXT_STYLE_CHANGED, wxRichTextEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_RICHTEXT_SELECTION_CHANGED, wxRichTextEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_RICHTEXT_BUFFER_RESET, wxRichTextEvent )
#if wxRICHTEXT_USE_OWN_CARET
if (idler.state != on) {
// connect or disconnect the EVT_IDLE handler
if (on)
- stc->Connect(wxID_ANY, wxEVT_IDLE,
- (wxObjectEventFunction) (wxEventFunction) (wxIdleEventFunction) &wxStyledTextCtrl::OnIdle);
+ stc->Connect(wxID_ANY, wxEVT_IDLE, wxIdleEventHandler(wxStyledTextCtrl::OnIdle));
else
- stc->Disconnect(wxID_ANY, wxEVT_IDLE,
- (wxObjectEventFunction) (wxEventFunction) (wxIdleEventFunction) &wxStyledTextCtrl::OnIdle);
+ stc->Disconnect(wxID_ANY, wxEVT_IDLE, wxIdleEventHandler(wxStyledTextCtrl::OnIdle));
idler.state = on;
}
return idler.state;
//----------------------------------------------------------------------
-DEFINE_EVENT_TYPE( wxEVT_STC_CHANGE )
-DEFINE_EVENT_TYPE( wxEVT_STC_STYLENEEDED )
-DEFINE_EVENT_TYPE( wxEVT_STC_CHARADDED )
-DEFINE_EVENT_TYPE( wxEVT_STC_SAVEPOINTREACHED )
-DEFINE_EVENT_TYPE( wxEVT_STC_SAVEPOINTLEFT )
-DEFINE_EVENT_TYPE( wxEVT_STC_ROMODIFYATTEMPT )
-DEFINE_EVENT_TYPE( wxEVT_STC_KEY )
-DEFINE_EVENT_TYPE( wxEVT_STC_DOUBLECLICK )
-DEFINE_EVENT_TYPE( wxEVT_STC_UPDATEUI )
-DEFINE_EVENT_TYPE( wxEVT_STC_MODIFIED )
-DEFINE_EVENT_TYPE( wxEVT_STC_MACRORECORD )
-DEFINE_EVENT_TYPE( wxEVT_STC_MARGINCLICK )
-DEFINE_EVENT_TYPE( wxEVT_STC_NEEDSHOWN )
-DEFINE_EVENT_TYPE( wxEVT_STC_PAINTED )
-DEFINE_EVENT_TYPE( wxEVT_STC_USERLISTSELECTION )
-DEFINE_EVENT_TYPE( wxEVT_STC_URIDROPPED )
-DEFINE_EVENT_TYPE( wxEVT_STC_DWELLSTART )
-DEFINE_EVENT_TYPE( wxEVT_STC_DWELLEND )
-DEFINE_EVENT_TYPE( wxEVT_STC_START_DRAG )
-DEFINE_EVENT_TYPE( wxEVT_STC_DRAG_OVER )
-DEFINE_EVENT_TYPE( wxEVT_STC_DO_DROP )
-DEFINE_EVENT_TYPE( wxEVT_STC_ZOOM )
-DEFINE_EVENT_TYPE( wxEVT_STC_HOTSPOT_CLICK )
-DEFINE_EVENT_TYPE( wxEVT_STC_HOTSPOT_DCLICK )
-DEFINE_EVENT_TYPE( wxEVT_STC_CALLTIP_CLICK )
-DEFINE_EVENT_TYPE( wxEVT_STC_AUTOCOMP_SELECTION )
-DEFINE_EVENT_TYPE( wxEVT_STC_INDICATOR_CLICK )
-DEFINE_EVENT_TYPE( wxEVT_STC_INDICATOR_RELEASE )
+wxDEFINE_EVENT( wxEVT_STC_CHANGE, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_STYLENEEDED, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_CHARADDED, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_SAVEPOINTREACHED, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_SAVEPOINTLEFT, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_ROMODIFYATTEMPT, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_KEY, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_DOUBLECLICK, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_UPDATEUI, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_MODIFIED, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_MACRORECORD, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_MARGINCLICK, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_NEEDSHOWN, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_PAINTED, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_USERLISTSELECTION, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_URIDROPPED, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_DWELLSTART, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_DWELLEND, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_START_DRAG, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_DRAG_OVER, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_DO_DROP, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_ZOOM, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_HOTSPOT_CLICK, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_HOTSPOT_DCLICK, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_CALLTIP_CLICK, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_AUTOCOMP_SELECTION, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_INDICATOR_CLICK, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_INDICATOR_RELEASE, wxStyledTextEvent )
//----------------------------------------------------------------------
-DEFINE_EVENT_TYPE( wxEVT_STC_CHANGE )
-DEFINE_EVENT_TYPE( wxEVT_STC_STYLENEEDED )
-DEFINE_EVENT_TYPE( wxEVT_STC_CHARADDED )
-DEFINE_EVENT_TYPE( wxEVT_STC_SAVEPOINTREACHED )
-DEFINE_EVENT_TYPE( wxEVT_STC_SAVEPOINTLEFT )
-DEFINE_EVENT_TYPE( wxEVT_STC_ROMODIFYATTEMPT )
-DEFINE_EVENT_TYPE( wxEVT_STC_KEY )
-DEFINE_EVENT_TYPE( wxEVT_STC_DOUBLECLICK )
-DEFINE_EVENT_TYPE( wxEVT_STC_UPDATEUI )
-DEFINE_EVENT_TYPE( wxEVT_STC_MODIFIED )
-DEFINE_EVENT_TYPE( wxEVT_STC_MACRORECORD )
-DEFINE_EVENT_TYPE( wxEVT_STC_MARGINCLICK )
-DEFINE_EVENT_TYPE( wxEVT_STC_NEEDSHOWN )
-DEFINE_EVENT_TYPE( wxEVT_STC_PAINTED )
-DEFINE_EVENT_TYPE( wxEVT_STC_USERLISTSELECTION )
-DEFINE_EVENT_TYPE( wxEVT_STC_URIDROPPED )
-DEFINE_EVENT_TYPE( wxEVT_STC_DWELLSTART )
-DEFINE_EVENT_TYPE( wxEVT_STC_DWELLEND )
-DEFINE_EVENT_TYPE( wxEVT_STC_START_DRAG )
-DEFINE_EVENT_TYPE( wxEVT_STC_DRAG_OVER )
-DEFINE_EVENT_TYPE( wxEVT_STC_DO_DROP )
-DEFINE_EVENT_TYPE( wxEVT_STC_ZOOM )
-DEFINE_EVENT_TYPE( wxEVT_STC_HOTSPOT_CLICK )
-DEFINE_EVENT_TYPE( wxEVT_STC_HOTSPOT_DCLICK )
-DEFINE_EVENT_TYPE( wxEVT_STC_CALLTIP_CLICK )
-DEFINE_EVENT_TYPE( wxEVT_STC_AUTOCOMP_SELECTION )
-DEFINE_EVENT_TYPE( wxEVT_STC_INDICATOR_CLICK )
-DEFINE_EVENT_TYPE( wxEVT_STC_INDICATOR_RELEASE )
+wxDEFINE_EVENT( wxEVT_STC_CHANGE, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_STYLENEEDED, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_CHARADDED, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_SAVEPOINTREACHED, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_SAVEPOINTLEFT, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_ROMODIFYATTEMPT, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_KEY, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_DOUBLECLICK, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_UPDATEUI, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_MODIFIED, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_MACRORECORD, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_MARGINCLICK, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_NEEDSHOWN, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_PAINTED, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_USERLISTSELECTION, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_URIDROPPED, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_DWELLSTART, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_DWELLEND, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_START_DRAG, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_DRAG_OVER, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_DO_DROP, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_ZOOM, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_HOTSPOT_CLICK, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_HOTSPOT_DCLICK, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_CALLTIP_CLICK, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_AUTOCOMP_SELECTION, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_INDICATOR_CLICK, wxStyledTextEvent )
+wxDEFINE_EVENT( wxEVT_STC_INDICATOR_RELEASE, wxStyledTextEvent )
#ifndef SWIG
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_CHANGE;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_STYLENEEDED;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_CHARADDED;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_SAVEPOINTREACHED;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_SAVEPOINTLEFT;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_ROMODIFYATTEMPT;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_KEY;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_DOUBLECLICK;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_UPDATEUI;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_MODIFIED;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_MACRORECORD;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_MARGINCLICK;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_NEEDSHOWN;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_PAINTED;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_USERLISTSELECTION;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_URIDROPPED;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_DWELLSTART;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_DWELLEND;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_START_DRAG;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_DRAG_OVER;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_DO_DROP;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_ZOOM;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_HOTSPOT_CLICK;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_HOTSPOT_DCLICK;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_CALLTIP_CLICK;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_AUTOCOMP_SELECTION;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_INDICATOR_CLICK;
-extern WXDLLIMPEXP_STC const wxEventType wxEVT_STC_INDICATOR_RELEASE;
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_CHANGE, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_STYLENEEDED, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_CHARADDED, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_SAVEPOINTREACHED, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_SAVEPOINTLEFT, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_ROMODIFYATTEMPT, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_KEY, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_DOUBLECLICK, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_UPDATEUI, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_MODIFIED, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_MACRORECORD, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_MARGINCLICK, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_NEEDSHOWN, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_PAINTED, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_USERLISTSELECTION, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_URIDROPPED, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_DWELLSTART, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_DWELLEND, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_START_DRAG, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_DRAG_OVER, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_DO_DROP, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_ZOOM, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_HOTSPOT_CLICK, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_HOTSPOT_DCLICK, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_CALLTIP_CLICK, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_AUTOCOMP_SELECTION, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_INDICATOR_CLICK, wxStyledTextEvent )
+wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_STC, wxEVT_STC_INDICATOR_RELEASE, wxStyledTextEvent )
#else
enum {
wxEVT_STC_CHANGE,
#ifndef SWIG
typedef void (wxEvtHandler::*wxStyledTextEventFunction)(wxStyledTextEvent&);
-#define EVT_STC_CHANGE(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_CHANGE, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_STYLENEEDED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_STYLENEEDED, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_CHARADDED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_CHARADDED, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_SAVEPOINTREACHED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_SAVEPOINTREACHED, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_SAVEPOINTLEFT(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_SAVEPOINTLEFT, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_ROMODIFYATTEMPT(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_ROMODIFYATTEMPT, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_KEY(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_KEY, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_DOUBLECLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DOUBLECLICK, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_UPDATEUI(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_UPDATEUI, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_MODIFIED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_MODIFIED, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_MACRORECORD(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_MACRORECORD, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_MARGINCLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_MARGINCLICK, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_NEEDSHOWN(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_NEEDSHOWN, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_PAINTED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_PAINTED, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_USERLISTSELECTION(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_USERLISTSELECTION, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_URIDROPPED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_URIDROPPED, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_DWELLSTART(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DWELLSTART, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_DWELLEND(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DWELLEND, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_START_DRAG(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_START_DRAG, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_DRAG_OVER(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DRAG_OVER, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_DO_DROP(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DO_DROP, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_ZOOM(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_ZOOM, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_HOTSPOT_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_HOTSPOT_CLICK, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_HOTSPOT_DCLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_HOTSPOT_DCLICK, id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_CALLTIP_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_CALLTIP_CLICK id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_AUTOCOMP_SELECTION(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_AUTOCOMP_SELECTION id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_INDICATOR_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_INDICATOR_CLICK id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
-#define EVT_STC_INDICATOR_RELEASE(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_INDICATOR_RELEASE id, wxID_ANY, (wxObjectEventFunction) (wxEventFunction) wxStaticCastEvent( wxStyledTextEventFunction, & fn ), (wxObject *) NULL ),
+#define wxStyledTextEventHandler( func ) \
+ wxEVENT_HANDLER_CAST( wxStyledTextEventFunction, func )
+
+#define EVT_STC_CHANGE(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_CHANGE, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_STYLENEEDED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_STYLENEEDED, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_CHARADDED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_CHARADDED, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_SAVEPOINTREACHED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_SAVEPOINTREACHED, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_SAVEPOINTLEFT(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_SAVEPOINTLEFT, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_ROMODIFYATTEMPT(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_ROMODIFYATTEMPT, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_KEY(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_KEY, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_DOUBLECLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DOUBLECLICK, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_UPDATEUI(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_UPDATEUI, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_MODIFIED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_MODIFIED, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_MACRORECORD(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_MACRORECORD, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_MARGINCLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_MARGINCLICK, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_NEEDSHOWN(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_NEEDSHOWN, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_PAINTED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_PAINTED, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_USERLISTSELECTION(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_USERLISTSELECTION, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_URIDROPPED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_URIDROPPED, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_DWELLSTART(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DWELLSTART, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_DWELLEND(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DWELLEND, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_START_DRAG(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_START_DRAG, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_DRAG_OVER(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DRAG_OVER, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_DO_DROP(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_DO_DROP, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_ZOOM(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_ZOOM, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_HOTSPOT_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_HOTSPOT_CLICK, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_HOTSPOT_DCLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_HOTSPOT_DCLICK, id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_CALLTIP_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_CALLTIP_CLICK id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_AUTOCOMP_SELECTION(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_AUTOCOMP_SELECTION id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_INDICATOR_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_INDICATOR_CLICK id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
+#define EVT_STC_INDICATOR_RELEASE(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_STC_INDICATOR_RELEASE id, wxID_ANY, wxStyledTextEventHandler( fn ), (wxObject *) NULL ),
#endif
#include "wx/tglbtn.h"
-DEFINE_EVENT_TYPE(wxEVT_COMMAND_TOGGLEBUTTON_CLICKED)
+wxDEFINE_EVENT( wxEVT_COMMAND_TOGGLEBUTTON_CLICKED, wxCommandEvent )
IMPLEMENT_DYNAMIC_CLASS(wxToggleButton, wxButton)
#include <arpa/inet.h>
#include <errno.h>
-DEFINE_EVENT_TYPE(wxEVT_DIALUP_CONNECTED)
-DEFINE_EVENT_TYPE(wxEVT_DIALUP_DISCONNECTED)
+wxDEFINE_EVENT( wxEVT_DIALUP_CONNECTED, wxDialUpEvent )
+wxDEFINE_EVENT( wxEVT_DIALUP_DISCONNECTED, wxDialUpEvent )
// ----------------------------------------------------------------------------
// A class which groups functions dealing with connecting to the network from a
typedef void (wxEvtHandler::*wxSoundBackendSDLNotificationFunction)
(wxSoundBackendSDLNotification&);
-BEGIN_DECLARE_EVENT_TYPES()
- DECLARE_LOCAL_EVENT_TYPE(wxEVT_SOUND_BACKEND_SDL_NOTIFICATION, -1)
-END_DECLARE_EVENT_TYPES()
+wxDECLARE_LOCAL_EVENT( wxEVT_SOUND_BACKEND_SDL_NOTIFICATION, wxSoundBackendSDLNotification )
#define EVT_SOUND_BACKEND_SDL_NOTIFICATON(func) \
DECLARE_EVENT_TABLE_ENTRY(wxEVT_SOUND_BACKEND_SDL_NOTIFICATION, \
-1, \
-1, \
- (wxObjectEventFunction) wxStaticCastEvent( wxSoundBackendSDLNotificationFunction, & func ), \
+ wxEVENT_HANDLER_CAST( wxSoundBackendSDLNotificationFunction, func ), \
(wxObject *) NULL ),
IMPLEMENT_DYNAMIC_CLASS(wxSoundBackendSDLNotification, wxEvtHandler)
-DEFINE_EVENT_TYPE(wxEVT_SOUND_BACKEND_SDL_NOTIFICATION)
+wxDEFINE_EVENT( wxEVT_SOUND_BACKEND_SDL_NOTIFICATION, wxSoundBackendSDLNotification )
wxSoundBackendSDLNotification::wxSoundBackendSDLNotification()
{
CPPUNIT_ASSERT_EQUAL( "bye", entry->GetValue() );
}
-void TextEntryTestCase::TextChangeEvents()
+namespace
{
class TextTestEventHandler : public wxEvtHandler
{
private:
int m_events;
- } handler;
+ };
+}
+
+void TextEntryTestCase::TextChangeEvents()
+{
+ TextTestEventHandler handler;
GetTestWindow()->Connect
(