MeVisLab Toolbox Reference
SoInteractionCoordinatorElement.h
Go to the documentation of this file.
1/*************************************************************************************
2**
3** Copyright 2008, MeVis Medical Solutions AG
4**
5** The user may use this file in accordance with the license agreement provided with
6** the Software or, alternatively, in accordance with the terms contained in a
7** written agreement between the user and MeVis Medical Solutions AG.
8**
9** For further information use the contact form at https://www.mevislab.de/contact
10**
11**************************************************************************************/
12
13#ifndef SO_INTERACTION_COORDINATOR_ELEMENT_H
14#define SO_INTERACTION_COORDINATOR_ELEMENT_H
15
17
19
21
22#include <ThirdPartyWarningsDisable.h>
23#include <Inventor/elements/SoSubElement.h>
24#include <ThirdPartyWarningsRestore.h>
25
26class SoAction;
29
32{
33 SO_ELEMENT_HEADER(SoInteractionCoordinatorElement);
34
35 public:
37 void init(SoState *state) override;
38
40 void push(SoState *state) override;
42 void pop(SoState *state, const SoElement *prevTopElement) override;
43
46 SbBool matches(const SoElement *elt) const override;
47
49 SoElement* copyMatchInfo() const override;
50
53
56
59
60 SoINTERNAL public:
62 static void initClass();
63
64 protected:
66 SoInteractionCoordinator* _coordinator{};
67
70 size_t _mapperCount{};
71
73};
74
75#endif // __SoInteractionCoordinatorElement_H
#define SOMANAGEDINTERACTION_API
File to resolve system dependencies in View2D library.
Element that stores a proxy object to the currently active viewer.
void pop(SoState *state, const SoElement *prevTopElement) override
Restores initial number of mappers in the coordinator/.
static SoInteractionCoordinator * get(SoState *state)
Returns the coordinator (might be NULL!).
SoElement * copyMatchInfo() const override
Creates and returns a copy of this element.
~SoInteractionCoordinatorElement() override=default
void push(SoState *state) override
Copies coordinator from previous element in push, remembers number of mappers.
SbBool matches(const SoElement *elt) const override
Always returns TRUE, since this element should never be a criterion for cache invalidation.
static void set(SoState *state, SoInteractionCoordinator *coordinator)
Sets the coordinator.
static void initClass()
Initializes the SoViewerElement class.
static void addMapper(SoState *state, SoInteractionMapper *mapper)
Adds a new interaction mapper to current coordinator.
void init(SoState *state) override
Initializes this element.
Provides coordinating interface to the SoInteractionHandlers in the scene.
SoInteractionMapper is the base class for instances that map SoPointingActions or SoCommandActions to...
Target mlrange_cast(Source arg)
Generic version of checked ML casts.