1
/**************************************************************************\
3
* This file is part of the Coin 3D visualization library.
4
* Copyright (C) 1998-2005 by Systems in Motion. All rights reserved.
6
* This library is free software; you can redistribute it and/or
7
* modify it under the terms of the GNU General Public License
8
* ("GPL") version 2 as published by the Free Software Foundation.
9
* See the file LICENSE.GPL at the root directory of this source
10
* distribution for additional information about the GNU GPL.
12
* For using Coin with software that can not be combined with the GNU
13
* GPL, and for taking advantage of the additional benefits of our
14
* support services, please contact Systems in Motion about acquiring
15
* a Coin Professional Edition License.
17
* See <URL:http://www.coin3d.org/> for more information.
19
* Systems in Motion, Postboks 1283, Pirsenteret, 7462 Trondheim, NORWAY.
20
* <URL:http://www.sim.no/>.
22
\**************************************************************************/
24
#ifndef SOQT_KEYBOARD_H
25
#define SOQT_KEYBOARD_H
27
#include <Inventor/Qt/devices/SoQtDevice.h>
29
class SoKeyboardEvent;
31
// *************************************************************************
33
#define SO_QT_ALL_KEYBOARD_EVENTS SoQtKeyboard::ALL
35
class SOQT_DLL_API SoQtKeyboard : public SoQtDevice {
36
SOQT_OBJECT_HEADER(SoQtKeyboard, SoQtDevice);
42
ALL_EVENTS = KEY_PRESS | KEY_RELEASE
45
SoQtKeyboard(int eventmask = ALL_EVENTS);
46
virtual ~SoQtKeyboard(void);
48
virtual void enable(QWidget * widget, SoQtEventHandler * handler, void * closure);
49
virtual void disable(QWidget * widget, SoQtEventHandler * handler, void * closure);
51
virtual const SoEvent * translateEvent(QEvent * event);
54
class SoQtKeyboardP * pimpl;
55
friend class SoQtKeyboardP;
56
friend class SoGuiKeyboardP;
59
// *************************************************************************
61
#endif // ! SOQT_KEYBOARD_H