diff options
| author | Sebastien Braun | 2010-10-10 01:39:14 +0200 |
|---|---|---|
| committer | Sebastien Braun | 2010-10-10 14:05:35 +0200 |
| commit | d45ad40dd76250d3f342d70159b3737be8562139 (patch) | |
| tree | 3329c6b6632fbf760abd9a63ab358e11bd55cfa9 /src/input/inputEventHandler.h | |
| parent | Code cleanup for X11FakeKeyboardHandler.cpp (diff) | |
| download | pvs-d45ad40dd76250d3f342d70159b3737be8562139.tar.gz pvs-d45ad40dd76250d3f342d70159b3737be8562139.tar.xz pvs-d45ad40dd76250d3f342d70159b3737be8562139.zip | |
Code cleanup for inputEvent.h
- Use Qt's fixed-width integral types instead of stdint.h, which I
forgot to include anyway
- CamelCase identifiers
- fix underscore position on instance variables
Diffstat (limited to 'src/input/inputEventHandler.h')
| -rw-r--r-- | src/input/inputEventHandler.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/input/inputEventHandler.h b/src/input/inputEventHandler.h index 5b03a90..71a530b 100644 --- a/src/input/inputEventHandler.h +++ b/src/input/inputEventHandler.h @@ -176,7 +176,7 @@ struct InputEventHandlerPolicyBase // The actual handler class need to provide doHandle and can override // allow and isApplicable. ///////////////////////////////////////////////////////////////////////// -/* interface */ class InputEventHandlerBase +class InputEventHandlerBase { public: enum HandlerStatus @@ -246,9 +246,15 @@ private: // Unfortunately, we cannot specialize member functions of a template. // So, we need to make this a class with a static non-template member. ///////////////////////////////////////////////////////////////////////// - template<bool Applicable, typename HandlerType> + template<bool Compatible, typename HandlerType> struct ConditionallyAppend { + ///////////////////////////////////////////////////////////////////////// + // This method will never be instantiated for handlers that are + // not Compatible, thus generating no reference to HandlerType + // and permitting compilation to proceed without + // tedious nested preprocessor conditionals. + ///////////////////////////////////////////////////////////////////////// static void doIt(InputEventHandlerChain* chain) { chain->handlers.append(new HandlerType); |
