Open Inventor
Release 2023.2.3
Loading...
Searching...
No Matches
SoQtInputFocus.h
Go to the documentation of this file.
1
/*=======================================================================
2
*** THE CONTENT OF THIS WORK IS PROPRIETARY TO FEI S.A.S, (FEI S.A.S.), ***
3
*** AND IS DISTRIBUTED UNDER A LICENSE AGREEMENT. ***
4
*** ***
5
*** REPRODUCTION, DISCLOSURE, OR USE, IN WHOLE OR IN PART, OTHER THAN AS ***
6
*** SPECIFIED IN THE LICENSE ARE NOT TO BE UNDERTAKEN EXCEPT WITH PRIOR ***
7
*** WRITTEN AUTHORIZATION OF FEI S.A.S. ***
8
*** ***
9
*** RESTRICTED RIGHTS LEGEND ***
10
*** USE, DUPLICATION, OR DISCLOSURE BY THE GOVERNMENT OF THE CONTENT OF THIS ***
11
*** WORK OR RELATED DOCUMENTATION IS SUBJECT TO RESTRICTIONS AS SET FORTH IN ***
12
*** SUBPARAGRAPH (C)(1) OF THE COMMERCIAL COMPUTER SOFTWARE RESTRICTED RIGHT ***
13
*** CLAUSE AT FAR 52.227-19 OR SUBPARAGRAPH (C)(1)(II) OF THE RIGHTS IN ***
14
*** TECHNICAL DATA AND COMPUTER SOFTWARE CLAUSE AT DFARS 52.227-7013. ***
15
*** ***
16
*** COPYRIGHT (C) 1996-2014 BY FEI S.A.S, ***
17
*** BORDEAUX, FRANCE ***
18
*** ALL RIGHTS RESERVED ***
19
**=======================================================================*/
20
/*=======================================================================
21
** Author : David Mott (MMM yyyy)
22
** Modified by : Gavin Bell (MMM yyyy)
23
**=======================================================================*/
24
25
26
#ifndef _SO_QT_FOCUS_
27
#define _SO_QT_FOCUS_
28
29
#include <
Inventor/Qt/OivQtCompat.h
>
30
#include <
Inventor/Qt/devices/SoQtDevice.h
>
31
32
#define SO_QT_ALL_FOCUS_EVENTS \
33
(EnterWindowMask | LeaveWindowMask)
34
35
36
{
37
38
Q_OBJECT
39
40
public
:
52
SoQtInputFocus(
EventMask
mask =
SO_QT_ALL_FOCUS_EVENTS
);
56
~SoQtInputFocus
() {}
57
58
// these functions will enable/disable this device for the passed widget.
59
// the callback function f will be invoked when events occur in w.
60
// data is the clientData which will be passed.
61
virtual
void
enable
(QWidget *w,
XtEventHandler
f,
XtPointer
data ,
void
* unused=NULL);
62
virtual
void
disable
(QWidget *w,
XtEventHandler
f,
XtPointer
data);
63
//
64
// this converts an X event into an SoEvent,
65
// returning NULL if the event is not from this device.
66
//
67
virtual
const
SoEvent
*
translateEvent
(QEvent *event);
68
69
private
:
70
EventMask
eventMask;
71
72
};
73
74
#endif
/* _SO_QT_FOCUS_ */
75
76
OivQtCompat.h
XtPointer
void * XtPointer
Definition
SoQtDef.h:118
SoQtDevice.h
EventMask
#define EventMask
Definition
SoQtDevice.h:42
SO_QT_ALL_FOCUS_EVENTS
#define SO_QT_ALL_FOCUS_EVENTS
Definition
SoQtInputFocus.h:32
disable
virtual void disable(QWidget *w, XtEventHandler f, XtPointer data)
enable
virtual void enable(QWidget *w, XtEventHandler f, XtPointer data, void *unused=NULL)
translateEvent
virtual const SoEvent * translateEvent(QEvent *event)
~SoQtInputFocus
~SoQtInputFocus()
Destructor.
Definition
SoQtInputFocus.h:56
XtEventHandler
#define XtEventHandler
Definition
SoWinDef.h:121
SoEvent
Base class for all events.
Definition
SoEvent.h:116
Inventor
Qt
devices
SoQtInputFocus.h
Generated by
1.9.8