OpendTect  6.6
keyboardevent.h
Go to the documentation of this file.
1 #pragma once
2 
3 /*+
4 ________________________________________________________________________
5 
6  (C) dGB Beheer B.V.; (LICENSE) http://opendtect.org/OpendTect_license.txt
7  Author: Nanne Hemstra
8  Date: August 2007
9  RCS: $Id$
10 ________________________________________________________________________
11 
12 -*/
13 
14 #include "generalmod.h"
15 #include "keyenum.h"
16 #include "geometry.h"
17 
23 {
24 public:
26 
28  OD::ButtonState modifier_; //Alt/Ctrl/Shift++
29  bool isrepeat_;
30 
31  bool operator ==(const KeyboardEvent&) const;
32  bool operator !=( const KeyboardEvent& ev ) const;
33  static bool isUnDo(const KeyboardEvent&);
34  static bool isReDo(const KeyboardEvent&);
35  static bool isSave(const KeyboardEvent&);
36  static bool isSaveAs(const KeyboardEvent&);
37  static bool isSelectAll(const KeyboardEvent&);
38 
39 };
40 
41 
47 {
48 public:
50 
53 
56 
57  bool hasEvent() const { return event_; }
58  const KeyboardEvent& event() const { return *event_; }
61  bool isHandled() const { return ishandled_; }
62  void setHandled( bool yn ) { ishandled_ = yn; }
63 
64 protected:
66  bool ishandled_;
67 };
68 
69 
KeyboardEventHandler::triggerKeyReleased
void triggerKeyReleased(const KeyboardEvent &)
geometry.h
KeyboardEvent::modifier_
OD::ButtonState modifier_
Definition: keyboardevent.h:28
KeyboardEventHandler::setHandled
void setHandled(bool yn)
Definition: keyboardevent.h:62
KeyboardEventHandler
Handles KeyboardEvent.
Definition: keyboardevent.h:47
mExpClass
#define mExpClass(module)
Definition: commondefs.h:177
KeyboardEventHandler::keyReleased
Notifier< KeyboardEventHandler > keyReleased
Definition: keyboardevent.h:55
KeyboardEvent::KeyboardEvent
KeyboardEvent()
KeyboardEventHandler::hasEvent
bool hasEvent() const
Definition: keyboardevent.h:57
KeyboardEvent::isReDo
static bool isReDo(const KeyboardEvent &)
KeyboardEventHandler::isHandled
bool isHandled() const
Definition: keyboardevent.h:61
CallBacker
Inherit from this class to be able to send and/or receive CallBacks.
Definition: callback.h:185
operator==
bool operator==(const ArrayNDInfo &a1, const ArrayNDInfo &a2)
Definition: arrayndinfo.h:81
OD::ButtonState
ButtonState
Definition: keyenum.h:20
keyenum.h
KeyboardEvent::key_
OD::KeyboardKey key_
Definition: keyboardevent.h:27
KeyboardEventHandler::triggerKeyPressed
void triggerKeyPressed(const KeyboardEvent &)
KeyboardEvent::isUnDo
static bool isUnDo(const KeyboardEvent &)
KeyboardEventHandler::keyPressed
Notifier< KeyboardEventHandler > keyPressed
Definition: keyboardevent.h:54
KeyboardEvent
Keyboard event.
Definition: keyboardevent.h:23
KeyboardEvent::isSave
static bool isSave(const KeyboardEvent &)
operator!=
bool operator!=(const ArrayNDInfo &a1, const ArrayNDInfo &a2)
Definition: arrayndinfo.h:90
KeyboardEventHandler::ishandled_
bool ishandled_
Definition: keyboardevent.h:66
Notifier< KeyboardEventHandler >
KeyboardEventHandler::KeyboardEventHandler
KeyboardEventHandler()
KeyboardEventHandler::event
const KeyboardEvent & event() const
Definition: keyboardevent.h:58
KeyboardEventHandler::event_
const KeyboardEvent * event_
Definition: keyboardevent.h:65
KeyboardEvent::isrepeat_
bool isrepeat_
Definition: keyboardevent.h:29
OD::KeyboardKey
KeyboardKey
Definition: keyenum.h:35
KeyboardEvent::isSelectAll
static bool isSelectAll(const KeyboardEvent &)
KeyboardEvent::isSaveAs
static bool isSaveAs(const KeyboardEvent &)

Generated at for the OpendTect seismic interpretation project. Copyright (C): dGB Beheer B.V. 1995-2021