Kaynağa Gözat

Check window exists before using it

Fixes issue 4457

Change-Id: Iae1297c043b2c65836db2c276cb39d71cce827aa
Reviewed-on: http://gerrit.dmdirc.com/1504
Automatic-Compile: DMDirc Local Commits <dmdirc@googlemail.com>
Reviewed-by: Chris Smith <chris@dmdirc.com>
tags/0.6.5
Greg Holmes 13 yıl önce
ebeveyn
işleme
cb383eedc1

+ 4
- 1
src/com/dmdirc/addons/ui_swing/framemanager/windowmenu/WindowMenuFrameManager.java Dosyayı Görüntüle

@@ -357,7 +357,10 @@ public final class WindowMenuFrameManager extends JMenu implements
357 357
      * @param window parent to inform
358 358
      */
359 359
     protected void parentSelection(final FrameContainer window) {
360
-        menus.get(window).childSelected();
360
+        final FrameContainerMenu menuItem = menus.get(window);
361
+        if (menuItem != null) {
362
+            menuItem.childSelected();
363
+        }
361 364
     }
362 365
 
363 366
     /**

Loading…
İptal
Kaydet