IDEA-204015 IllegalArgumentException because event getcomponent is null (from TrayIcon)

This commit is contained in:
Alexander Lobas
2018-12-13 18:15:37 +03:00
parent 40daf408b6
commit d8e4166b0d
2 changed files with 2 additions and 5 deletions
@@ -335,6 +335,8 @@ public class IdeEventQueue extends EventQueue {
if (isMetaKeyPressedOnLinux(e)) return;
if (e.getSource() instanceof TrayIcon) return;
checkForTimeJump();
if (!appIsLoaded()) {
@@ -124,11 +124,6 @@ public final class IdeMouseEventDispatcher {
public boolean dispatchMouseEvent(MouseEvent e) {
Component c = e.getComponent();
// dispatch tray events by default
if (c == null && e.getSource() instanceof TrayIcon) {
return false;
}
//frame activation by mouse click
if (e.getID() == MOUSE_PRESSED && c instanceof IdeFrame && !c.hasFocus()) {
IdeFocusManager focusManager = IdeFocusManager.getGlobalInstance();