Coin Logo http://www.coin3d.org/
http://www.kongsberg.com/kogt/

SoQtKeyboard.h

00001 #ifndef SOQT_KEYBOARD_H
00002 #define SOQT_KEYBOARD_H
00003 
00004 // src/Inventor/Qt/devices/SoQtKeyboard.h.  Generated from SoGuiKeyboard.h.in by configure.
00005 
00006 /**************************************************************************\
00007  * Copyright (c) Kongsberg Oil & Gas Technologies AS
00008  * All rights reserved.
00009  * 
00010  * Redistribution and use in source and binary forms, with or without
00011  * modification, are permitted provided that the following conditions are
00012  * met:
00013  * 
00014  * Redistributions of source code must retain the above copyright notice,
00015  * this list of conditions and the following disclaimer.
00016  * 
00017  * Redistributions in binary form must reproduce the above copyright
00018  * notice, this list of conditions and the following disclaimer in the
00019  * documentation and/or other materials provided with the distribution.
00020  * 
00021  * Neither the name of the copyright holder nor the names of its
00022  * contributors may be used to endorse or promote products derived from
00023  * this software without specific prior written permission.
00024  * 
00025  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
00026  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
00027  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
00028  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
00029  * HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
00030  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
00031  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
00032  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
00033  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
00034  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
00035  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
00036 \**************************************************************************/
00037 
00038 #include <Inventor/Qt/devices/SoQtDevice.h>
00039 
00040 class SoKeyboardEvent;
00041 
00042 // *************************************************************************
00043 
00044 #define SO_QT_ALL_KEYBOARD_EVENTS SoQtKeyboard::ALL
00045 
00046 class SOQT_DLL_API SoQtKeyboard : public SoQtDevice {
00047   SOQT_OBJECT_HEADER(SoQtKeyboard, SoQtDevice);
00048 
00049 public:
00050   enum Events {
00051     KEY_PRESS = 0x01,
00052     KEY_RELEASE = 0x02,
00053     ALL_EVENTS = KEY_PRESS | KEY_RELEASE
00054   };
00055 
00056   SoQtKeyboard(int eventmask = ALL_EVENTS);
00057   virtual ~SoQtKeyboard(void);
00058 
00059   virtual void enable(QWidget * widget, SoQtEventHandler * handler, void * closure);
00060   virtual void disable(QWidget * widget, SoQtEventHandler * handler, void * closure);
00061 
00062   virtual const SoEvent * translateEvent(QEvent * event);
00063 
00064 private:
00065   class SoQtKeyboardP * pimpl;
00066   friend class SoQtKeyboardP;
00067   friend class SoGuiKeyboardP;
00068 };
00069 
00070 // *************************************************************************
00071 
00072 #endif // ! SOQT_KEYBOARD_H

Copyright © by Kongsberg Oil & Gas Technologies. All rights reserved.

Generated on Mon Sep 7 11:22:57 2015 for SoQt by Doxygen 1.5.6.