Ignore:
Timestamp:
2007-08-03T09:34:48+02:00 (17 years ago)
Author:
christofd
Message:

fixed nullpointerexception when deleting the last mapFrame

File:
1 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/livegps/livegps/LiveGpsPlugin.java

    r3340 r3895  
    151151    @Override
    152152    public void mapFrameInitialized(MapFrame oldFrame, MapFrame newFrame) {
    153         // add dialog
    154         newFrame.addToggleDialog(lgpsdialog = new LiveGpsDialog(newFrame));
    155         // connect listeners with acquirer:
    156         addPropertyChangeListener(lgpsdialog);
     153        if(newFrame != null) {
     154            // add dialog
     155            newFrame.addToggleDialog(lgpsdialog = new LiveGpsDialog(newFrame));
     156            // connect listeners with acquirer:
     157            addPropertyChangeListener(lgpsdialog);
     158        }
    157159    }
    158160
     
    166168
    167169}
     170
Note: See TracChangeset for help on using the changeset viewer.