Ignore:
Timestamp:
2018-09-15T13:20:45+02:00 (6 years ago)
Author:
Don-vip
Message:

see #16730 - one file missed

File:
1 edited

Legend:

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

    r14221 r14250  
    761761            if (org.openstreetmap.josm.actions.search.SearchAction.getSearchHistory().isEmpty())
    762762                return;
    763             JPopupMenu menu = new SearchPopupMenu();
    764             Rectangle r = parent.getBounds();
    765             menu.show(parent, r.x, r.y + r.height);
     763            if (parent.isShowing()) {
     764                JPopupMenu menu = new SearchPopupMenu();
     765                Rectangle r = parent.getBounds();
     766                menu.show(parent, r.x, r.y + r.height);
     767            }
    766768        }
    767769
     
    841843        public static void launch(Component parent, Collection<Collection<? extends OsmPrimitive>> history) {
    842844            if (history == null || history.isEmpty()) return;
    843             JPopupMenu menu = new SelectionHistoryPopup(history);
    844             Rectangle r = parent.getBounds();
    845             menu.show(parent, r.x, r.y + r.height);
     845            if (parent.isShowing()) {
     846                JPopupMenu menu = new SelectionHistoryPopup(history);
     847                Rectangle r = parent.getBounds();
     848                menu.show(parent, r.x, r.y + r.height);
     849            }
    846850        }
    847851
Note: See TracChangeset for help on using the changeset viewer.