Revision 5227 trunk/extensions/extCAD/src/com/iver/cit/gvsig/layers/VectorialLayerEdited.java
VectorialLayerEdited.java | ||
---|---|---|
30 | 30 |
import com.iver.cit.gvsig.fmap.layers.FLayer; |
31 | 31 |
import com.iver.cit.gvsig.fmap.layers.FLyrAnnotation; |
32 | 32 |
import com.iver.cit.gvsig.fmap.layers.FLyrVect; |
33 |
import com.iver.cit.gvsig.fmap.layers.LayerCollectionEvent; |
|
34 |
import com.iver.cit.gvsig.fmap.layers.LayerCollectionListener; |
|
33 | 35 |
import com.iver.cit.gvsig.fmap.layers.LayerDrawEvent; |
34 | 36 |
import com.iver.cit.gvsig.fmap.layers.LayerDrawingListener; |
35 | 37 |
import com.iver.cit.gvsig.fmap.layers.LayerEvent; |
38 |
import com.iver.cit.gvsig.fmap.layers.LayerPositionEvent; |
|
39 |
import com.iver.cit.gvsig.gui.View; |
|
36 | 40 |
import com.iver.cit.gvsig.gui.cad.CADTool; |
37 | 41 |
import com.iver.cit.gvsig.gui.cad.CADToolAdapter; |
38 | 42 |
import com.iver.cit.gvsig.gui.cad.tools.SelectionCADTool; |
... | ... | |
413 | 417 |
|
414 | 418 |
public void activationGained(LayerEvent e) { |
415 | 419 |
if (ViewCommandStackExtension.csd!=null){ |
416 |
// com.iver.andami.ui.mdiManager.View f = PluginServices.getMDIManager() |
|
417 |
// .getActiveView(); |
|
418 |
|
|
419 |
// View vista = (View) f; |
|
420 |
// ProjectView model = vista.getModel(); |
|
421 |
// FMap mapa = model.getMapContext(); |
|
422 |
// FLayers layers = mapa.getLayers(); |
|
423 |
// for (int i = 0; i < layers.getLayersCount(); i++) { |
|
424 |
// if (layers.getLayer(i) instanceof FLyrVect) { |
|
425 |
// FLyrVect lyrVect = (FLyrVect) layers.getLayer(i); |
|
426 |
// if (lyrVect.isEditing() && lyrVect.isActive() && lyrVect.getSource() instanceof IEditableSource) { |
|
427 |
ViewCommandStackExtension.csd.setModel(((IEditableSource) ((FLyrVect)getLayer()).getSource()) |
|
428 |
.getCommandRecord()); |
|
429 |
|
|
430 |
// } |
|
431 |
// } |
|
432 |
// } |
|
420 |
ViewCommandStackExtension.csd.setModel(((IEditableSource) ((FLyrVect)getLayer()).getSource()) |
|
421 |
.getCommandRecord()); |
|
433 | 422 |
} |
434 | 423 |
|
435 | 424 |
if (cadtool!=null){ |
... | ... | |
437 | 426 |
PluginServices.getMainFrame().setSelectedTool(cadtool.toString()); |
438 | 427 |
StartEditing.startCommandsApplicable(null,(FLyrVect)getLayer()); |
439 | 428 |
} |
429 |
|
|
440 | 430 |
} |
441 | 431 |
|
442 | 432 |
public void activationLost(LayerEvent e) { |
Also available in: Unified diff