Example usage for java.awt.event InputEvent getModifiersEx

List of usage examples for java.awt.event InputEvent getModifiersEx

Introduction

In this page you can find the example usage for java.awt.event InputEvent getModifiersEx.

Prototype

public int getModifiersEx() 

Source Link

Document

Returns the extended modifier mask for this event.

Usage

From source file:Main.java

static boolean isControlDown(final InputEvent event) {
    final int modifiersEx = event.getModifiersEx();
    final int flag = modifiersEx & InputEvent.CTRL_DOWN_MASK;
    return flag != 0;
}