Package org.joshy.gfx.event

Examples of org.joshy.gfx.event.Callback


                JFrame frame = (JFrame) stage.getNativeWindow();
                device.setFullScreenWindow(frame);
            } else {
                System.err.println("Full screen not supported");
            }
            undoFullscreen = new Callback(){
                public void call(Object event) {
                    GraphicsDevice device = GraphicsEnvironment.
                            getLocalGraphicsEnvironment().
                            getDefaultScreenDevice();
                    device.setFullScreenWindow(null);
View Full Code Here


            Toolkit tk = Toolkit.getDefaultToolkit();
            Insets insets = tk.getScreenInsets(GraphicsEnvironment.getLocalGraphicsEnvironment().getDefaultScreenDevice().getDefaultConfiguration());
            Dimension size = tk.getScreenSize();
            stage.setUndecorated(true);
            final JFrame frame = (JFrame) stage.getNativeWindow();
            undoFullscreen = new Callback() {
                public void call(Object event) {
                    stage.setUndecorated(false);
                    frame.setLocation(oldLocation);
                    frame.setSize(oldSize);
                }
View Full Code Here

    @Override
    public void execute() throws Exception {
        final Stage stage = Stage.createStage();
        stage.setTitle("About Leonardo");
        Callback openLink = new org.joshy.gfx.event.Callback<ActionEvent>() {
            public void call(ActionEvent actionEvent) throws Exception {
                OSUtil.openBrowser("http://leonardosketch.org/download-source/");
            }
        };
        Callback closeStage = new Callback<ActionEvent>() {
            public void call(ActionEvent actionEvent) throws Exception {
                stage.hide();
            }
        };
       
View Full Code Here

    private void fadeOutIndicator() {
        KeyFrameAnimator kf = KeyFrameAnimator.create(this,"indicatorOpacity")
                .keyFrame(01.0)
                .keyFrame(0.2,0.0)
                .doAfter(new Callback() {
                    public void call(Object event) {
                        showIndicator = false;
                        context.redraw();
                    }
                });
View Full Code Here

TOP

Related Classes of org.joshy.gfx.event.Callback

Copyright © 2018 www.massapicom. 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.