svn-gvsig-desktop / tags / v1_0_2_Build_897 / extensions / extGeoreferencing / src / com / iver / cit / gvsig / fmap / tools / GeorefDraggListenerImpl.java @ 10444
History | View | Annotate | Download (2.44 KB)
1 |
/* gvSIG. Sistema de Informaci?n Geogr?fica de la Generalitat Valenciana
|
---|---|
2 |
*
|
3 |
* Copyright (C) 2006 IVER T.I. and Generalitat Valenciana.
|
4 |
*
|
5 |
* This program is free software; you can redistribute it and/or
|
6 |
* modify it under the terms of the GNU General Public License
|
7 |
* as published by the Free Software Foundation; either version 2
|
8 |
* of the License, or (at your option) any later version.
|
9 |
*
|
10 |
* This program is distributed in the hope that it will be useful,
|
11 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
12 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
13 |
* GNU General Public License for more details.
|
14 |
*
|
15 |
* You should have received a copy of the GNU General Public License
|
16 |
* along with this program; if not, write to the Free Software
|
17 |
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,USA.
|
18 |
*/
|
19 |
package com.iver.cit.gvsig.fmap.tools; |
20 |
|
21 |
import java.awt.Cursor; |
22 |
import java.awt.Image; |
23 |
import java.awt.Point; |
24 |
import java.awt.Toolkit; |
25 |
|
26 |
import javax.swing.ImageIcon; |
27 |
|
28 |
|
29 |
import com.iver.cit.gvsig.fmap.MapControl; |
30 |
import com.iver.cit.gvsig.fmap.tools.BehaviorException; |
31 |
import com.iver.cit.gvsig.fmap.tools.Events.PointEvent; |
32 |
import com.iver.cit.gvsig.fmap.tools.Listeners.DraggedListener; |
33 |
|
34 |
|
35 |
/**
|
36 |
* Implementaci?n de la interfaz PointListener como herramienta para seleccionar
|
37 |
* puntos georeferenciados sobre una capa LyrPoints
|
38 |
*
|
39 |
* @author Nacho Brodin (brodin_ign@gva.es)
|
40 |
*/
|
41 |
public class GeorefDraggListenerImpl implements DraggedListener { |
42 |
private final Image img = new ImageIcon(MapControl.class.getResource( |
43 |
"images/PointSelectCursor.gif")).getImage();
|
44 |
private Cursor cur = Toolkit.getDefaultToolkit().createCustomCursor(img, |
45 |
new Point(16, 16), ""); |
46 |
|
47 |
/**
|
48 |
* Crea un nuevo GeorefPointerListenerImpl.
|
49 |
*
|
50 |
* @param mc MapControl.
|
51 |
*/
|
52 |
public GeorefDraggListenerImpl() {
|
53 |
|
54 |
} |
55 |
|
56 |
/**
|
57 |
* Obtiene el puntero del rat?n
|
58 |
* @return cursor
|
59 |
*/
|
60 |
public Cursor getCursor() { |
61 |
return cur;
|
62 |
} |
63 |
|
64 |
/**
|
65 |
* M?todo vacio implementado por las clases derivadas
|
66 |
*/
|
67 |
public void dragg(PointEvent event) throws BehaviorException { |
68 |
} |
69 |
|
70 |
/**
|
71 |
* M?todo vacio implementado por las clases derivadas
|
72 |
*/
|
73 |
public void press(PointEvent event) throws BehaviorException { |
74 |
} |
75 |
|
76 |
/**
|
77 |
* M?todo vacio implementado por las clases derivadas
|
78 |
*/
|
79 |
public void release(PointEvent event) throws BehaviorException { |
80 |
} |
81 |
|
82 |
/**
|
83 |
* @see com.iver.cit.gvsig.fmap.tools.Listeners.ToolListener#cancelDrawing()
|
84 |
*/
|
85 |
public boolean cancelDrawing() { |
86 |
return false; |
87 |
} |
88 |
} |