Revision 5550 trunk/extensions/extGeoreferencing/src/com/iver/cit/gvsig/fmap/tools/Behavior/GeoRedimBehavior.java
GeoRedimBehavior.java | ||
---|---|---|
218 | 218 |
double maxX = lyrGeoRaster.getAssignExtent().getMax().getX(); |
219 | 219 |
double maxY = lyrGeoRaster.getAssignExtent().getMax().getY(); |
220 | 220 |
|
221 |
|
|
222 | 221 |
if(iconActive[0]){//Estirar en horizontal activado |
223 | 222 |
if(wcX > (maxX - WIDTH_BORDER) && wcX < maxX) |
224 | 223 |
redimActive[0] = true; |
... | ... | |
236 | 235 |
pointInit = e.getPoint(); |
237 | 236 |
rectInit = new Rectangle2D.Double(tmpUl.getX(), tmpUl.getY(), tmpLr.getX() - tmpUl.getX(), tmpLr.getY() - tmpUl.getY()); |
238 | 237 |
} |
239 |
|
|
240 | 238 |
} |
241 | 239 |
|
242 |
if (listener.cancelDrawing()) {
|
|
240 |
if (listener.cancelDrawing()) |
|
243 | 241 |
getMapControl().cancelDrawing(); |
244 |
} |
|
245 |
|
|
246 |
//getMapControl().repaint(); |
|
247 |
//getMapControl().drawMap(true); |
|
248 | 242 |
} |
249 | 243 |
|
250 | 244 |
/** |
... | ... | |
278 | 272 |
//Si la capa tiene puntos de control hacemos un update de estos |
279 | 273 |
//a su posici?n para que se actualicen los controles |
280 | 274 |
for(int i=0; i<lyrGeoRaster.getFLyrPoints().getCountPoints(); i++){ |
281 |
|
|
282 | 275 |
Point2D center = lyrGeoRaster.img2World(lyrGeoRaster.getFLyrPoints().getPoint(i).pixelPoint); |
283 | 276 |
lyrGeoRaster.getFLyrPoints().setMiniExtent( i, |
284 | 277 |
center, |
285 | 278 |
//lyrGeoRaster.getGeoDialog().getZoomControlLeft().getCanvas().initViewPort(vp, center, lyrGeoRaster.getFLyrPoints().getPoint(i).leftViewPort), |
286 |
lyrGeoRaster.getGeoDialog().getLeftInitViewport(vp, center, lyrGeoRaster.getFLyrPoints().getPoint(i).leftViewPort), |
|
279 |
lyrGeoRaster.getGeoDialog().getLeftInitViewport(vp, center, lyrGeoRaster.getFLyrPoints().getPoint(i).leftViewPort, 1),
|
|
287 | 280 |
false); |
281 |
if(i == lyrGeoRaster.getGeoDialog().getSelectedPoint()){ |
|
282 |
lyrGeoRaster.updateData(i + 1, lyrGeoRaster.getFLyrPoints().getPoint(i).pixelPoint, null, theView); |
|
283 |
theView.getMapControl().getMapContext().invalidate(); |
|
284 |
} |
|
288 | 285 |
} |
289 |
|
|
290 |
//Repintamos la vista y las mini im?genes |
|
291 |
int selection = lyrGeoRaster.getGeoDialog().getSelectedPoint(); |
|
292 |
GeoPoint gp = lyrGeoRaster.getFLyrPoints().getPoint(selection); |
|
293 |
Point2D px = null; |
|
294 |
Point2D map = null; |
|
295 |
if(gp != null){ |
|
296 |
px = gp.pixelPoint; |
|
297 |
map = gp.mapPoint; |
|
298 |
} |
|
299 |
|
|
300 |
lyrGeoRaster.updateData(selection + 1, px, map, theView); |
|
301 |
if(px == null && map == null) |
|
302 |
theView.getMapControl().getMapContext().invalidate(); |
|
303 |
|
|
286 |
|
|
304 | 287 |
tmpUl = null; |
305 | 288 |
tmpLr = null; |
306 | 289 |
|
Also available in: Unified diff