Changeset 7958 in josm for trunk/src/org/openstreetmap
- Timestamp:
- 2015-01-11T23:01:33+01:00 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/dialogs/NotesDialog.java
r7937 r7958 8 8 import java.awt.Image; 9 9 import java.awt.event.ActionEvent; 10 import java.awt.event.MouseAdapter; 11 import java.awt.event.MouseEvent; 10 12 import java.text.SimpleDateFormat; 11 13 import java.util.ArrayList; … … 24 26 import javax.swing.ListCellRenderer; 25 27 import javax.swing.ListSelectionModel; 28 import javax.swing.SwingUtilities; 26 29 import javax.swing.event.ListSelectionEvent; 27 30 import javax.swing.event.ListSelectionListener; … … 113 116 updateButtonStates(); 114 117 }}); 118 displayList.addMouseListener(new MouseAdapter() { 119 //center view on selected note on double click 120 @Override 121 public void mouseClicked(MouseEvent e) { 122 if (SwingUtilities.isLeftMouseButton(e) && e.getClickCount() == 2) { 123 if (noteData != null && noteData.getSelectedNote() != null) { 124 Main.map.mapView.zoomTo(noteData.getSelectedNote().getLatLon()); 125 } 126 } 127 } 128 }); 115 129 116 130 JPanel pane = new JPanel(new BorderLayout());
Note:
See TracChangeset
for help on using the changeset viewer.