OWLNext    7.0
Borland's Object Windows Library for the modern age
Loading...
Searching...
No Matches
eventhan.h File Reference

Definition of TEventHandler and related classes & macros. More...

#include <owl/private/defs.h>
#include <owl/signatur.h>
#include <owl/dispatch.h>
#include <owl/preclass.h>
#include <owl/posclass.h>

Go to the source code of this file.

Classes

class  owl::TEventHandler
 TEventHandler is a base class from which you can derive classes that handle messages. More...
 
class  owl::TEventHandler::TEventInfo
 A nested class, TEventInfo provides specific information about the type of message sent, the class that contains the function to be handled, the corresponding response table entry, and the dispatch function that processes the message. More...
 
class  owl::TResponseTableEntry< T >
 A template class, TResponseTableEntry lets you define a pattern for entries into a response table. More...
 

Namespaces

namespace  owl
 Object Windows Library (OWLNext Core)
 

Macros

#define DECLARE_RESPONSE_TABLE(cls)
 
#define DECLARE_EXPORT_RESPONSE_TABLE(cls)
 
#define DECLARE_IMPORT_RESPONSE_TABLE(cls)
 
#define DEFINE_RESPONSE_TABLE_ENTRIES(cls)    ::owl::TResponseTableEntry< cls > cls::__entries[] = {
 
#define END_RESPONSE_TABLE    {{0}, 0, 0, 0}}
 
#define DEFINE_RESPONSE_TABLE(cls)
 Macro to define a response table for a class with no base response tables.
 
#define DEFINE_RESPONSE_TABLE1(cls, base)
 Macro to define a response table for a class with one base.
 
#define DEFINE_RESPONSE_TABLE2(cls, base1, base2)
 Macro to define a response table for a class with two bases.
 
#define DEFINE_RESPONSE_TABLE3(cls, base1, base2, base3)
 Macro to define a response table for a class with three bases.
 
#define DEFINE_RESPONSE_TABLE4(cls, base1, base2, base3, base4)
 Macro to define a response table for a class with three bases.
 
#define DEFINE_RESPONSE_TABLE5(cls, base1, base2, base3, base4, base5)
 Macro to define a response table for a class with three bases.
 
#define DEFINE_RESPONSE_TABLE6(cls, base1, base2, base3, base4, base5, base6)
 Macro to define a response table for a class with three bases.
 
#define DEFINE_RESPONSE_TABLE7(cls, base1, base2, base3, base4, base5, base6, base7)
 Macro to define a response table for a class with three bases.
 
#define DEFINE_RESPONSE_TABLE8(cls, base1, base2, base3, base4, base5, base6, base7, base8)
 Macro to define a response table for a class with three bases.
 
#define DEFINE_RESPONSE_TABLE9(cls, base1, base2, base3, base4, base5, base6, base7, base8, base9)
 Macro to define a response table for a class with three bases.
 
#define OWL_ID_EV_(msgId, id, method)
 
#define OWL_EV_(msgId, method)   OWL_ID_EV_(msgId, 0, method)
 

Typedefs

typedef TResponseTableEntry< TGenericowl::TGenericTableEntry
 

Detailed Description

Definition of TEventHandler and related classes & macros.

Definition in file eventhan.h.

Macro Definition Documentation

◆ DECLARE_EXPORT_RESPONSE_TABLE

#define DECLARE_EXPORT_RESPONSE_TABLE ( cls)
Value:
private:\
static ::owl::TResponseTableEntry< cls > __entries[];\
typedef ::owl::TResponseTableEntry< cls >::PMF TMyPMF;\
typedef cls TMyClass;\
public:\
auto __declspec(dllexport) Find(TEventInfo&, TEqualOperator = 0) -> bool override
STDAPI __declspec(dllexport) DllRegisterCommand(LPCTSTR cmdLine)
Entry point for complete registration management via command line Don't let any exceptions blow back ...
Definition ocreg.cpp:495

Definition at line 444 of file eventhan.h.

◆ DECLARE_IMPORT_RESPONSE_TABLE

#define DECLARE_IMPORT_RESPONSE_TABLE ( cls)
Value:
private:\
static ::owl::TResponseTableEntry< cls > __entries[];\
typedef ::owl::TResponseTableEntry< cls >::PMF TMyPMF;\
typedef cls TMyClass;\
public:\
auto __declspec(dllimport) Find(TEventInfo&, TEqualOperator = 0) -> bool override

Definition at line 452 of file eventhan.h.

◆ DECLARE_RESPONSE_TABLE

#define DECLARE_RESPONSE_TABLE ( cls)
Value:
private:\
static ::owl::TResponseTableEntry< cls > __entries[];\
typedef ::owl::TResponseTableEntry< cls >::PMF TMyPMF;\
typedef cls TMyClass;\
public:\
auto Find(TEventInfo&, TEqualOperator = 0) -> bool override

Definition at line 436 of file eventhan.h.

◆ DEFINE_RESPONSE_TABLE

#define DEFINE_RESPONSE_TABLE ( cls)
Value:
bool cls::Find(TEventInfo& eventInfo, TEqualOperator equal)\
{\
using namespace ::owl;\
eventInfo.Object = (TGeneric*)this;\
return SearchEntries((TGenericTableEntry *)&__entries[0], eventInfo, equal);\
}\
Object Windows Library (OWLNext Core)
Definition animctrl.h:22

Macro to define a response table for a class with no base response tables.

Use it like this:

#define END_RESPONSE_TABLE
Definition eventhan.h:466
#define DEFINE_RESPONSE_TABLE(cls)
Macro to define a response table for a class with no base response tables.
Definition eventhan.h:479
#define EV_WM_PAINT
Definition windowev.h:353
#define EV_WM_LBUTTONDOWN
Definition windowev.h:313

Definition at line 479 of file eventhan.h.

◆ DEFINE_RESPONSE_TABLE1

#define DEFINE_RESPONSE_TABLE1 ( cls,
base )
Value:
bool cls::Find(TEventInfo& eventInfo, TEqualOperator equal)\
{\
using namespace ::owl;\
eventInfo.Object = (TGeneric*)this;\
return SearchEntries((TGenericTableEntry *)&__entries[0], eventInfo, equal) ||\
base::Find(eventInfo, equal);\
}\

Macro to define a response table for a class with one base.

Use this macro exactly like macro DEFINE_RESPONSE_TABLE

Definition at line 492 of file eventhan.h.

◆ DEFINE_RESPONSE_TABLE2

#define DEFINE_RESPONSE_TABLE2 ( cls,
base1,
base2 )
Value:
bool cls::Find(TEventInfo& eventInfo, TEqualOperator equal)\
{\
using namespace ::owl;\
eventInfo.Object = (TGeneric*)this;\
return SearchEntries((TGenericTableEntry *)&__entries[0], eventInfo, equal) ||\
base1::Find(eventInfo, equal) ||\
base2::Find(eventInfo, equal);\
}\

Macro to define a response table for a class with two bases.

Use this macro exactly like macro DEFINE_RESPONSE_TABLE

Definition at line 506 of file eventhan.h.

◆ DEFINE_RESPONSE_TABLE3

#define DEFINE_RESPONSE_TABLE3 ( cls,
base1,
base2,
base3 )
Value:
bool cls::Find(TEventInfo& eventInfo, TEqualOperator equal)\
{\
using namespace ::owl;\
eventInfo.Object = (TGeneric*)this;\
return SearchEntries((TGenericTableEntry *)&__entries[0], eventInfo, equal) ||\
base1::Find(eventInfo, equal) ||\
base2::Find(eventInfo, equal) ||\
base3::Find(eventInfo, equal);\
}\

Macro to define a response table for a class with three bases.

Use this macro exactly like macro DEFINE_RESPONSE_TABLE

Definition at line 521 of file eventhan.h.

◆ DEFINE_RESPONSE_TABLE4

#define DEFINE_RESPONSE_TABLE4 ( cls,
base1,
base2,
base3,
base4 )
Value:
bool cls::Find(TEventInfo& eventInfo, TEqualOperator equal)\
{\
using namespace ::owl;\
eventInfo.Object = (TGeneric*)this;\
return SearchEntries((TGenericTableEntry *)&__entries[0], eventInfo, equal) ||\
base1::Find(eventInfo, equal) ||\
base2::Find(eventInfo, equal) ||\
base3::Find(eventInfo, equal) ||\
base4::Find(eventInfo, equal);\
}\

Macro to define a response table for a class with three bases.

Use this macro exactly like macro DEFINE_RESPONSE_TABLE

Definition at line 537 of file eventhan.h.

◆ DEFINE_RESPONSE_TABLE5

#define DEFINE_RESPONSE_TABLE5 ( cls,
base1,
base2,
base3,
base4,
base5 )
Value:
bool cls::Find(TEventInfo& eventInfo, TEqualOperator equal)\
{\
using namespace ::owl;\
eventInfo.Object = (TGeneric*)this;\
return SearchEntries((TGenericTableEntry *)&__entries[0], eventInfo, equal) ||\
base1::Find(eventInfo, equal) ||\
base2::Find(eventInfo, equal) ||\
base3::Find(eventInfo, equal) ||\
base4::Find(eventInfo, equal) ||\
base5::Find(eventInfo, equal);\
}\

Macro to define a response table for a class with three bases.

Use this macro exactly like macro DEFINE_RESPONSE_TABLE

Definition at line 554 of file eventhan.h.

◆ DEFINE_RESPONSE_TABLE6

#define DEFINE_RESPONSE_TABLE6 ( cls,
base1,
base2,
base3,
base4,
base5,
base6 )
Value:
bool cls::Find(TEventInfo& eventInfo, TEqualOperator equal)\
{\
using namespace ::owl;\
eventInfo.Object = (TGeneric*)this;\
return SearchEntries((TGenericTableEntry *)&__entries[0], eventInfo, equal) ||\
base1::Find(eventInfo, equal) ||\
base2::Find(eventInfo, equal) ||\
base3::Find(eventInfo, equal) ||\
base4::Find(eventInfo, equal) ||\
base5::Find(eventInfo, equal) ||\
base6::Find(eventInfo, equal);\
}\

Macro to define a response table for a class with three bases.

Use this macro exactly like macro DEFINE_RESPONSE_TABLE

Definition at line 572 of file eventhan.h.

◆ DEFINE_RESPONSE_TABLE7

#define DEFINE_RESPONSE_TABLE7 ( cls,
base1,
base2,
base3,
base4,
base5,
base6,
base7 )
Value:
bool cls::Find(TEventInfo& eventInfo, TEqualOperator equal)\
{\
using namespace ::owl;\
eventInfo.Object = (TGeneric*)this;\
return SearchEntries((TGenericTableEntry *)&__entries[0], eventInfo, equal) ||\
base1::Find(eventInfo, equal) ||\
base2::Find(eventInfo, equal) ||\
base3::Find(eventInfo, equal) ||\
base4::Find(eventInfo, equal) ||\
base5::Find(eventInfo, equal) ||\
base6::Find(eventInfo, equal) ||\
base7::Find(eventInfo, equal);\
}\

Macro to define a response table for a class with three bases.

Use this macro exactly like macro DEFINE_RESPONSE_TABLE

Definition at line 591 of file eventhan.h.

◆ DEFINE_RESPONSE_TABLE8

#define DEFINE_RESPONSE_TABLE8 ( cls,
base1,
base2,
base3,
base4,
base5,
base6,
base7,
base8 )
Value:
bool cls::Find(TEventInfo& eventInfo, TEqualOperator equal)\
{\
using namespace ::owl;\
eventInfo.Object = (TGeneric*)this;\
return SearchEntries((TGenericTableEntry *)&__entries[0], eventInfo, equal) ||\
base1::Find(eventInfo, equal) ||\
base2::Find(eventInfo, equal) ||\
base3::Find(eventInfo, equal) ||\
base4::Find(eventInfo, equal) ||\
base5::Find(eventInfo, equal) ||\
base6::Find(eventInfo, equal) ||\
base7::Find(eventInfo, equal) ||\
base8::Find(eventInfo, equal);\
}\

Macro to define a response table for a class with three bases.

Use this macro exactly like macro DEFINE_RESPONSE_TABLE

Definition at line 611 of file eventhan.h.

◆ DEFINE_RESPONSE_TABLE9

#define DEFINE_RESPONSE_TABLE9 ( cls,
base1,
base2,
base3,
base4,
base5,
base6,
base7,
base8,
base9 )
Value:
bool cls::Find(TEventInfo& eventInfo, TEqualOperator equal)\
{\
using namespace ::owl;\
eventInfo.Object = (TGeneric*)this;\
return SearchEntries((TGenericTableEntry *)&__entries[0], eventInfo, equal) ||\
base1::Find(eventInfo, equal) ||\
base2::Find(eventInfo, equal) ||\
base3::Find(eventInfo, equal) ||\
base4::Find(eventInfo, equal) ||\
base5::Find(eventInfo, equal) ||\
base6::Find(eventInfo, equal) ||\
base7::Find(eventInfo, equal) ||\
base8::Find(eventInfo, equal) ||\
base9::Find(eventInfo, equal);\
}\

Macro to define a response table for a class with three bases.

Use this macro exactly like macro DEFINE_RESPONSE_TABLE

Definition at line 632 of file eventhan.h.

◆ DEFINE_RESPONSE_TABLE_ENTRIES

#define DEFINE_RESPONSE_TABLE_ENTRIES ( cls)     ::owl::TResponseTableEntry< cls > cls::__entries[] = {

Definition at line 463 of file eventhan.h.

◆ END_RESPONSE_TABLE

#define END_RESPONSE_TABLE    {{0}, 0, 0, 0}}

Definition at line 466 of file eventhan.h.

◆ OWL_EV_

#define OWL_EV_ ( msgId,
method )   OWL_ID_EV_(msgId, 0, method)

Definition at line 672 of file eventhan.h.

◆ OWL_ID_EV_

#define OWL_ID_EV_ ( msgId,
id,
method )
Value:
{{static_cast<::owl::TMsgId>(msgId)}, static_cast<::owl::uint>(id),\
#define OWL_DISPATCH(dispatch, method)
Definition dispatch.h:131
Undefined default template for dispatchers Template specialization is used to allow the compiler to l...
Definition dispatch.h:258

Definition at line 666 of file eventhan.h.