svn-gvsig-desktop / trunk / org.gvsig.desktop / org.gvsig.desktop.library / org.gvsig.fmap.control / src / main / java / org / gvsig / fmap / mapcontrol / CompoundLayersTreeModel.java @ 45535
History | View | Annotate | Download (586 Bytes)
1 |
package org.gvsig.fmap.mapcontrol; |
---|---|
2 |
|
3 |
import org.gvsig.fmap.mapcontext.layers.FLayers; |
4 |
|
5 |
|
6 |
public class CompoundLayersTreeModel extends LayersTreeModel { |
7 |
|
8 |
public CompoundLayersTreeModel() {
|
9 |
super(new FLayers()); |
10 |
} |
11 |
|
12 |
public void addLayers(FLayers layers) { |
13 |
try {
|
14 |
FLayers lyrs = layers.cloneLayer(); |
15 |
lyrs.setMapContext(null);
|
16 |
this.layers.add(lyrs);
|
17 |
} catch (Exception ex) { |
18 |
throw new RuntimeException("Can't add layers to model", ex); |
19 |
} |
20 |
} |
21 |
} |