Changeset 10490 in josm for trunk/src/org
- Timestamp:
- 2016-06-25T11:58:24+02:00 (8 years ago)
- Location:
- trunk/src/org/openstreetmap/josm/gui/dialogs/changeset
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/dialogs/changeset/ChangesetContentPanel.java
r10453 r10490 54 54 import org.openstreetmap.josm.tools.ImageProvider; 55 55 import org.openstreetmap.josm.tools.Utils; 56 import org.openstreetmap.josm.tools.bugreport.BugReport;57 56 import org.openstreetmap.josm.tools.bugreport.BugReportExceptionHandler; 58 57 … … 100 99 new ComponentAdapter() { 101 100 @Override 101 public void componentShown(ComponentEvent e) { 102 Main.getLayerManager().addAndFireActiveLayerChangeListener(actSelectInCurrentLayerAction); 103 Main.getLayerManager().addAndFireActiveLayerChangeListener(actZoomInCurrentLayerAction); 104 } 105 106 @Override 102 107 public void componentHidden(ComponentEvent e) { 103 // make sure the listener is unregistered when the panel becomes 104 // invisible 105 try { 106 Main.getLayerManager().removeActiveLayerChangeListener(actSelectInCurrentLayerAction); 107 Main.getLayerManager().removeActiveLayerChangeListener(actZoomInCurrentLayerAction); 108 } catch (IllegalArgumentException t) { 109 throw BugReport.intercept(t).put("hint", "This Component can only be hidden once."); 110 } 108 // make sure the listener is unregistered when the panel becomes invisible 109 Main.getLayerManager().removeActiveLayerChangeListener(actSelectInCurrentLayerAction); 110 Main.getLayerManager().removeActiveLayerChangeListener(actZoomInCurrentLayerAction); 111 111 } 112 112 } -
trunk/src/org/openstreetmap/josm/gui/dialogs/changeset/ChangesetDetailPanel.java
r10453 r10490 96 96 new ComponentAdapter() { 97 97 @Override 98 public void componentShown(ComponentEvent e) { 99 Main.getLayerManager().addAndFireActiveLayerChangeListener(actSelectInCurrentLayer); 100 Main.getLayerManager().addAndFireActiveLayerChangeListener(actZoomInCurrentLayerAction); 101 } 102 103 @Override 98 104 public void componentHidden(ComponentEvent e) { 99 // make sure the listener is unregistered when the panel becomes 100 // invisible 105 // make sure the listener is unregistered when the panel becomes invisible 101 106 Main.getLayerManager().removeActiveLayerChangeListener(actSelectInCurrentLayer); 102 107 Main.getLayerManager().removeActiveLayerChangeListener(actZoomInCurrentLayerAction);
Note:
See TracChangeset
for help on using the changeset viewer.