List of usage examples for java.awt.event InputEvent isControlDown
public boolean isControlDown()
From source file:ucar.unidata.idv.flythrough.Flythrough.java
/** * _more_//from w ww .j a va 2s . c o m * * @param event _more_ * * @throws RemoteException _more_ * @throws VisADException _more_ */ public void displayChanged(DisplayEvent event) throws VisADException, RemoteException { if (!isActive()) { return; } double[] viewpoint = viewManager.getDisplayMatrix(); if (!Misc.arraysEquals(viewpoint, lastViewpoint)) { lastViewpoint = viewpoint; updateDashboard(); } if (goToClick && (event.getId() == DisplayEvent.MOUSE_PRESSED)) { InputEvent inputEvent = event.getInputEvent(); int mods = inputEvent.getModifiers(); if ((mods & InputEvent.BUTTON1_MASK) != 0 && !inputEvent.isShiftDown() && !inputEvent.isControlDown()) { NavigatedDisplay navDisplay = viewManager.getNavigatedDisplay(); location = navDisplay.screenToEarthLocation(event.getX(), event.getY()); doDrive(false, heading); } } }