Ignore:
Timestamp:
2013-06-28T17:39:49+02:00 (13 years ago)
Author:
akks
Message:

fix #8829: relation was often hanging JOSM after 6036 + better highlighting

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/dialogs/RelationListDialog.java

    r6025 r6038  
    66import java.awt.BorderLayout;
    77import java.awt.Color;
     8import java.awt.Component;
    89import java.awt.event.ActionEvent;
    910import java.awt.event.KeyEvent;
     
    2021import javax.swing.AbstractListModel;
    2122import javax.swing.DefaultListSelectionModel;
     23import javax.swing.FocusManager;
    2224import javax.swing.JComponent;
    2325import javax.swing.JList;
     
    189191        popupMenuHandler.setPrimitives(sel);
    190192       
     193        Component focused = FocusManager.getCurrentKeyboardFocusManager().getFocusOwner();
     194       
    191195        //update highlights
    192         if (Main.isDisplayingMapView()) {
    193             highlightHelper.highlightOnly(sel);
    194             Main.map.mapView.repaint();
     196        if (focused==displaylist && Main.isDisplayingMapView()) {
     197            if (highlightHelper.highlightOnly(sel)) {
     198                Main.map.mapView.repaint();
     199            }
    195200        }
    196201    }
Note: See TracChangeset for help on using the changeset viewer.