gvsig-3d / 2.1 / trunk / org.gvsig.view3d / org.gvsig.view3d.swing / org.gvsig.view3d.swing.impl / src / main / java / org / gvsig / view3d / swing / impl / properties / DefaultViewProperties3DPanel.java @ 693
History | View | Annotate | Download (2.41 KB)
1 |
package org.gvsig.view3d.swing.impl.properties; |
---|---|
2 |
|
3 |
import javax.swing.JComponent; |
4 |
|
5 |
import org.gvsig.view3d.swing.api.properties.MapControlProperties3D; |
6 |
|
7 |
public class DefaultViewProperties3DPanel extends AbstractViewProperties3DPanel { |
8 |
|
9 |
private static final long serialVersionUID = -3563717730935555229L; |
10 |
|
11 |
private MapControlProperties3D properties;
|
12 |
|
13 |
public DefaultViewProperties3DPanel(MapControlProperties3D theProperties) {
|
14 |
super();
|
15 |
|
16 |
this.properties = theProperties;
|
17 |
|
18 |
fillPanel(); |
19 |
} |
20 |
|
21 |
private void fillPanel() { |
22 |
|
23 |
getSphereVerticalExaggerationField().setText( |
24 |
String.valueOf(properties.getSphereVerticalExaggeration()));
|
25 |
|
26 |
getFlatVerticalExaggerationField().setText( |
27 |
String.valueOf(properties.getFlatVerticalExaggeration()));
|
28 |
|
29 |
getAutoLayerSynchronizeCheckBox().setSelected( |
30 |
properties.getAutoLayerSynchronize()); |
31 |
getAutoViewPortSynchronizeCheckBox().setSelected( |
32 |
properties.getAutoViewPortSynchronize()); |
33 |
getShowBlueMarbleLayerCheckBox().setSelected( |
34 |
properties.getBlueMarbleLayerVisibility()); |
35 |
getShowNasaLandsatLayerCheckBox().setSelected( |
36 |
properties.getNasaLandsatLayerVisibility()); |
37 |
getShowDefaultElevationCheckBox().setSelected( |
38 |
properties.getDefaultElevationVisibility()); |
39 |
getAnaglyphModeCheckBox().setSelected(properties.getAnaglyphMode()); |
40 |
} |
41 |
|
42 |
public JComponent asJComponent() { |
43 |
return this; |
44 |
} |
45 |
|
46 |
public boolean getAutoLayerSynchronize() { |
47 |
return getAutoLayerSynchronizeCheckBox().isSelected();
|
48 |
} |
49 |
|
50 |
public boolean getAutoViewPortSynchronize() { |
51 |
return getAutoViewPortSynchronizeCheckBox().isSelected();
|
52 |
} |
53 |
|
54 |
public boolean getShowBlueMarble() { |
55 |
return getShowBlueMarbleLayerCheckBox().isSelected();
|
56 |
} |
57 |
|
58 |
public boolean getShowDefaultElevation() { |
59 |
return getShowDefaultElevationCheckBox().isSelected();
|
60 |
} |
61 |
|
62 |
public boolean getShowNasaLandsat() { |
63 |
return getShowNasaLandsatLayerCheckBox().isSelected();
|
64 |
} |
65 |
|
66 |
public double getFlatVerticalExaggeration() { |
67 |
return Double.valueOf(getFlatVerticalExaggerationField().getText()); |
68 |
} |
69 |
|
70 |
public double getSphereVerticalExaggeration() { |
71 |
return Double.valueOf(getSphereVerticalExaggerationField().getText()); |
72 |
} |
73 |
|
74 |
public boolean getAnaglyphMode(){ |
75 |
return getAnaglyphModeCheckBox().isSelected();
|
76 |
} |
77 |
|
78 |
} |