Examples of MouseButtonEvent3D


Examples of org.jdesktop.wonderland.client.jme.input.MouseButtonEvent3D

                    setRenderState(innerOrb, DEFAULT_MATERIALSTATE);
                    setRenderState(innerOrb, DEFAULT_SHADESTATE);
                }
            }
            if (event instanceof MouseButtonEvent3D) {
                MouseButtonEvent3D buttonEvent = (MouseButtonEvent3D) event;
                if (buttonEvent.isPressed() && (buttonEvent.getButton() == ButtonId.BUTTON1)) {
                    logger.info("Orb Selected");
                    ((OrbCell) cell).orbSelected();
                }
                //For testing only
                if (buttonEvent.isPressed() && (buttonEvent.getButton() == ButtonId.BUTTON3)) {
                    if (!buttonEvent.getAwtEvent().isControlDown()) {
                        enableSpeakingAnimations(true);
                    }
                    if (!buttonEvent.getAwtEvent().isShiftDown()){
                        enableSpeakingAnimations(false);
                    }
                }
            }
        }
View Full Code Here

Examples of org.jdesktop.wonderland.client.jme.input.MouseButtonEvent3D

        Action action = null;

        switch (me.getID()) {

        case MouseEvent.MOUSE_PRESSED:
            MouseButtonEvent3D buttonEvent = (MouseButtonEvent3D) me3d;
            if (configState == ConfigState.IDLE &&
                me.getButton() == MouseEvent.BUTTON1 &&
                me.getModifiersEx() == MouseEvent.BUTTON1_DOWN_MASK) {

                // Remember: the move occurs in parent coords
                View2DEntity parentView = (View2DEntity) view.getParent();
                if (parentView == null) {
                    // Note: we don't yet support dragging of primaries
                    return null;
                }

                configState = ConfigState.DRAG_ACTIVE;
                action = new Action(ActionType.DRAG_START);
                dragStartScreen = new Point(me.getX(), me.getY());
                dragStartWorld = buttonEvent.getIntersectionPointWorld();
                configDragType = ConfigDragType.MOVING_PLANAR;

                dragStartLocal = parentView.getNode().worldToLocal(dragStartWorld, new Vector3f());
            }
            return action;
View Full Code Here

Examples of org.jdesktop.wonderland.client.jme.input.MouseButtonEvent3D

        Action action = null;

        switch (me.getID()) {

        case MouseEvent.MOUSE_PRESSED:
            MouseButtonEvent3D buttonEvent = (MouseButtonEvent3D) me3d;
            if (configState == ConfigState.IDLE &&
                me.getButton() == MouseEvent.BUTTON1 &&
                me.getModifiersEx() == MouseEvent.BUTTON1_DOWN_MASK) {

                configState = ConfigState.DRAG_ACTIVE;
                action = new Action(ActionType.DRAG_START);
                dragStartScreen = new Point(me.getX(), me.getY());
                dragStartWorld = buttonEvent.getIntersectionPointWorld();
                dragStartLocal = view.getNode().worldToLocal(dragStartWorld, new Vector3f());
            }
            return action;

        case MouseEvent.MOUSE_DRAGGED:
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.