<s> import wx <EOL> from python_toolbox import caching <EOL> from python_toolbox import dict_tools <EOL> from . event_handler_grokker import EventHandlerGrokker <EOL> class BindSavvyEvtHandlerType ( type ( wx . EvtHandler ) ) : <EOL> '''<STR_LIT>''' <EOL> event_modules = [ ] <EOL> '''<STR_LIT>''' <EOL> @ property <EOL> @ caching . cache ( ) <EOL> def _BindSavvyEvtHandlerType__event_handler_grokkers ( cls ) : <EOL> '''<STR_LIT>''' <EOL> names_to_event_handlers = dict_tools . filter_items ( <EOL> vars ( cls ) , <EOL> lambda name , value : <EOL> cls . _BindSavvyEvtHandlerType__name_parser . match ( name , <EOL> cls . __name__ ) and <EOL> callable ( value ) and <EOL> getattr ( value , '<STR_LIT>' , <EOL> None ) is not True , <EOL> force_dict_type = dict <EOL> ) <EOL> '''<STR_LIT>''' <EOL> return [ EventHandlerGrokker ( name , value , cls ) for ( name , value ) in <EOL> names_to_event_handlers . items ( ) ] <EOL> @ staticmethod <EOL> def dont_bind_automatically ( function ) : <EOL> '''<STR_LIT>''' <EOL> function . _BindSavvyEvtHandlerType__dont_bind_automatically = True <EOL> return function </s>
