GP-1628 fixed stack trace when invoking contextMenu without using mouse

This commit is contained in:
ghidravore 2021-12-22 12:19:06 -05:00
parent 3a992382f7
commit 0f078b47bc

View file

@ -228,8 +228,10 @@ public class ActionContext {
* @return this context * @return this context
*/ */
public ActionContext setMouseEvent(MouseEvent e) { public ActionContext setMouseEvent(MouseEvent e) {
this.mouseEvent = e; if (e != null) {
this.eventClickModifiers = e.getModifiersEx(); this.mouseEvent = e;
this.eventClickModifiers = e.getModifiersEx();
}
return this; return this;
} }