Changeset 13117 in josm


Ignore:
Timestamp:
2017-11-12T15:45:08+01:00 (6 days ago)
Author:
Don-vip
Message:

see #11217, fix #15541 - hide note tooltip when selected note is no longer visible + drop old url copy code (does not work anymore with new system)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/layer/NoteLayer.java

    r13111 r13117  
    3838import org.openstreetmap.josm.gui.MainFrame;
    3939import org.openstreetmap.josm.gui.MapView;
    40 import org.openstreetmap.josm.gui.datatransfer.ClipboardUtils;
    4140import org.openstreetmap.josm.gui.dialogs.LayerListDialog;
    4241import org.openstreetmap.josm.gui.dialogs.LayerListPopup;
     
    4645import org.openstreetmap.josm.gui.progress.ProgressMonitor;
    4746import org.openstreetmap.josm.gui.widgets.HtmlPanel;
    48 import org.openstreetmap.josm.io.OsmApi;
    4947import org.openstreetmap.josm.io.XmlWriter;
    5048import org.openstreetmap.josm.spi.preferences.Config;
     
    199197        displayedWindow.pack();
    200198        displayedWindow.setLocation(tx, ty);
    201         displayedWindow.setVisible(true);
     199        displayedWindow.setVisible(mv.contains(p));
    202200        displayedNote = selectedNote;
    203201    }
     
    303301    @Override
    304302    public void mouseClicked(MouseEvent e) {
    305         if (SwingUtilities.isRightMouseButton(e) && noteData.getSelectedNote() != null) {
    306             final String url = OsmApi.getOsmApi().getBaseUrl() + "notes/" + noteData.getSelectedNote().getId();
    307             ClipboardUtils.copyString(url);
    308             return;
    309         } else if (!SwingUtilities.isLeftMouseButton(e)) {
     303        if (!SwingUtilities.isLeftMouseButton(e)) {
    310304            return;
    311305        }
Note: See TracChangeset for help on using the changeset viewer.