public void bind(final Component destination, final Application application, ViewPort viewPort, boolean main) {

        if (hasApplication()) {
            throw new RuntimeException("This process is already bonded.");
        }

        setApplication(application);
        setEnabled(true);

        this.main = main;
        this.viewPort = viewPort;
        this.viewPort.addProcessor(this);

        if (EventQueue.isDispatchThread()) {
            bindDestination(application, destination);
        } else {
            EventQueue.invokeLater(new Runnable() {

                @Override
                public void run() {
                    bindDestination(application, destination);
                }});
        }
    }
Bind this processor.

@param destination the destination.
@param application the application.
@param viewPort    the view port.
@param main        true if this processor is main.
jme3-desktop/src/main/java/com/jme3/system/AWTFrameProcessor.java