root / trunk / extensions / extCAD / sm / RotateCADTool.sm @ 3883
History | View | Annotate | Download (993 Bytes)
1 |
// -*- tab-width: 4; -*- |
---|---|
2 |
|
3 |
%{ |
4 |
// |
5 |
// Vicente Caballero Navarro |
6 |
%} |
7 |
|
8 |
%start ExecuteMap::Initial |
9 |
%class RotateCADTool |
10 |
%package com.iver.cit.gvsig.gui.cad.tools.smc |
11 |
%import com.iver.cit.gvsig.gui.cad.tools.RotateCADTool |
12 |
|
13 |
%map ExecuteMap |
14 |
%% |
15 |
// A task begins life in suspended animation. |
16 |
|
17 |
Initial |
18 |
Entry { |
19 |
selection(); |
20 |
setQuestion("ROTAR" + "\n" + |
21 |
"Precise punto base"); |
22 |
setDescription(new String[]{"Cancelar"}); |
23 |
|
24 |
} |
25 |
Exit{ |
26 |
} |
27 |
|
28 |
{ |
29 |
addPoint(pointX:double,pointY:double) |
30 |
First { |
31 |
setQuestion("Precise angulo de rotacion"); |
32 |
setDescription(new String[]{"Cancelar"}); |
33 |
addPoint(pointX,pointY); |
34 |
} |
35 |
} |
36 |
First{ |
37 |
addValue(d:double) |
38 |
Second{ |
39 |
setDescription(new String[]{"Cancelar"}); |
40 |
addValue(d); |
41 |
end(); |
42 |
refresh(); |
43 |
} |
44 |
addPoint(pointX:double,pointY:double) |
45 |
Second { |
46 |
setDescription(new String[]{"Cancelar"}); |
47 |
addPoint(pointX,pointY); |
48 |
end(); |
49 |
refresh(); |
50 |
} |
51 |
} |
52 |
Second{ |
53 |
} |
54 |
Default |
55 |
{ |
56 |
addOption(s:String) |
57 |
[s.equals("Cancelar")] |
58 |
Initial{ |
59 |
end(); |
60 |
} |
61 |
} |
62 |
%% |