0023649: Visualization, AIS_LocalContext - make highlighting of already selected...
[occt.git] / src / ViewerTest / ViewerTest_EventManager.cdl
CommitLineData
b311480e 1-- Created on: 1998-08-27
2-- Created by: Robert COUBLANC
3-- Copyright (c) 1998-1999 Matra Datavision
973c2be1 4-- Copyright (c) 1999-2014 OPEN CASCADE SAS
b311480e 5--
973c2be1 6-- This file is part of Open CASCADE Technology software library.
b311480e 7--
d5f74e42 8-- This library is free software; you can redistribute it and/or modify it under
9-- the terms of the GNU Lesser General Public License version 2.1 as published
973c2be1 10-- by the Free Software Foundation, with special exception defined in the file
11-- OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12-- distribution for complete text of the license and disclaimer of any warranty.
b311480e 13--
973c2be1 14-- Alternatively, this file may be used under the terms of Open CASCADE
15-- commercial license or contractual agreement.
7fd59977 16
17class EventManager from ViewerTest inherits TShared from MMgt
18
ff8178ef 19 ---Purpose: used to manage mouse event (move,select,shiftselect)
20 -- By default the events are transmitted to interactive context.
21
7fd59977 22
23uses
24 View from V3d,
4754e164 25 InteractiveContext from AIS,
26 Array1OfPnt2d from TColgp
7fd59977 27is
28
29 Create (aView: View from V3d;
30 aCtx :InteractiveContext from AIS)
6e33d3ce 31 returns EventManager from ViewerTest;
7fd59977 32
33 MoveTo (me:mutable;
34 xpix, ypix : Integer from Standard) is virtual;
35
36 Select(me:mutable) is virtual;
37
38 ShiftSelect(me:mutable) is virtual;
39
40 Select(me:mutable;xmin,ymin,xmax,ymax:Integer) is virtual;
41
42 ShiftSelect(me:mutable;xmin,ymin,xmax,ymax:Integer) is virtual;
4754e164 43
44 Select(me:mutable;thePolyline:Array1OfPnt2d from TColgp) is virtual;
45
46 ShiftSelect(me:mutable;thePolyline:Array1OfPnt2d from TColgp) is virtual;
7fd59977 47
48 Context(me) returns InteractiveContext from AIS;
49 ---C++: inline
50 ---C++: return const&
51
c398b00e 52 GetCurrentPosition (me; theXPix, theYPix: out Integer from Standard);
53 ---Purpose: Gets current mouse position. It tracks change of mouse position
54 -- with mouse drugging or with DRAW command call (vmoveto).
7fd59977 55fields
56
57 myCtx : InteractiveContext from AIS;
58 myView: View from V3d;
59 myX : Integer from Standard;
60 myY : Integer from Standard;
61
62end EventManager;