IDEA-192349: fixed NPE

broken in IDEA-163208: fix order of message dialog buttons

fixed IDEA-192349 'Open project in a new window' confirmation popup broken: shows several popups instead of one, leads to inability to quit IDE (regression)
This commit is contained in:
Artem Bochkarev
2018-05-21 15:38:05 +07:00
parent 95fd7e0a14
commit 7dc7ca86c9
@@ -142,7 +142,8 @@ class SheetMessage implements Disposable {
LaterInvocator.enterModal(myWindow);
final Runnable closer = _showTouchBar(buttons, defaultButton);
myWindow.setVisible(true);
closer.run();
if (closer != null)
closer.run();
LaterInvocator.leaveModal(myWindow);
Component focusCandidate = beforeShowFocusOwner.get();