Revision 5880 trunk/extensions/extCAD/src/com/iver/cit/gvsig/gui/cad/tools/RotateCADTool.java
RotateCADTool.java | ||
---|---|---|
56 | 56 |
import com.iver.cit.gvsig.fmap.drivers.DriverIOException; |
57 | 57 |
import com.iver.cit.gvsig.fmap.edition.DefaultRowEdited; |
58 | 58 |
import com.iver.cit.gvsig.fmap.edition.EditionEvent; |
59 |
import com.iver.cit.gvsig.fmap.edition.IRowEdited; |
|
60 | 59 |
import com.iver.cit.gvsig.fmap.edition.UtilFunctions; |
61 | 60 |
import com.iver.cit.gvsig.fmap.edition.VectorialEditableAdapter; |
62 | 61 |
import com.iver.cit.gvsig.gui.cad.DefaultCADTool; |
... | ... | |
136 | 135 |
RotateCADToolState actualState = (RotateCADToolState) _fsm.getPreviousState(); |
137 | 136 |
String status = actualState.getName(); |
138 | 137 |
ArrayList selectedRow=getSelectedRows(); |
139 |
ArrayList selectedRowAux=new ArrayList(); |
|
140 | 138 |
VectorialLayerEdited vle=getVLE(); |
141 | 139 |
VectorialEditableAdapter vea = vle.getVEA(); |
142 | 140 |
if (status.equals("Rotate.PointMain")) { |
... | ... | |
152 | 150 |
|
153 | 151 |
try { |
154 | 152 |
vea.startComplexRow(); |
155 |
for (int i = 0; i < selectedRow.size(); i++) { |
|
153 |
///ArrayList selectedRowAux=new ArrayList(); |
|
154 |
for (int i = 0; i < selectedRow.size(); i++) { |
|
156 | 155 |
DefaultRowEdited row=(DefaultRowEdited) selectedRow.get(i); |
157 | 156 |
DefaultFeature fea = (DefaultFeature) row.getLinkedRow().cloneRow(); |
158 | 157 |
// Rotamos la geometry |
... | ... | |
161 | 160 |
+ (Math.PI / 2), firstPoint.getX(), firstPoint |
162 | 161 |
.getY()); |
163 | 162 |
|
164 |
int index=vea.modifyRow(row.getIndex(), fea,
|
|
163 |
vea.modifyRow(row.getIndex(), fea, |
|
165 | 164 |
getName(),EditionEvent.GRAPHIC); |
166 |
selectedRowAux.add(new DefaultRowEdited(fea,IRowEdited.STATUS_MODIFIED,index)); |
|
165 |
///selectedRowAux.add(new DefaultRowEdited(fea,IRowEdited.STATUS_MODIFIED,index));
|
|
167 | 166 |
} |
168 | 167 |
|
169 | 168 |
vea.endComplexRow(); |
170 | 169 |
clearSelection(); |
171 |
selectedRow.addAll(selectedRowAux);
|
|
170 |
///selectedRow=selectedRowAux;
|
|
172 | 171 |
} catch (DriverIOException e) { |
173 | 172 |
e.printStackTrace(); |
174 | 173 |
} catch (IOException e1) { |
Also available in: Unified diff