cgv
choice_event.h
1
#pragma once
2
3
#include "event.h"
4
#include "shortcut.h"
5
6
#include "lib_begin.h"
7
8
namespace
cgv
{
9
namespace
gui {
10
12
enum
ChoiceEventType
13
{
14
CET_GRAB_FOCUS,
15
CET_LOOSE_FOCUS,
16
CET_SELECTED,
17
CET_UNSELECTED
18
};
19
21
extern
CGV_API std::string
get_choice_type_string
(
ChoiceEventType
type);
22
24
class
CGV_API
choice_event
:
public
event
25
{
26
protected
:
28
ChoiceEventType
type
;
29
public
:
31
choice_event
(
ChoiceEventType
_type,
unsigned
char
_modifiers = 0,
unsigned
char
_toggle_keys = 0,
double
_time = 0);
33
void
stream_out(std::ostream& os)
const
;
35
void
stream_in(std::istream& is);
37
ChoiceEventType
get_type()
const
;
39
void
set_type(
ChoiceEventType
_type);
40
};
41
42
}
43
}
44
45
#include <cgv/config/lib_end.h>
cgv::gui::get_choice_type_string
std::string get_choice_type_string(ChoiceEventType type)
convert a choice event type into a readable string
Definition:
choice_event.cxx:7
cgv::gui::choice_event::type
ChoiceEventType type
store type of choice event
Definition:
choice_event.h:28
cgv::gui::choice_event
class to represent choice events that include focus change and selection change events
Definition:
choice_event.h:25
cgv::gui::event
Definition:
event.h:59
cgv
the cgv namespace
Definition:
vr_calib.cxx:9
cgv::gui::ChoiceEventType
ChoiceEventType
different choice event types
Definition:
choice_event.h:13
projects
git
cgv
cgv
gui
choice_event.h
Generated by
1.8.18