@Override
    public void cleanup() {
        final AWTComponentRenderer frameTransfer = getFrameTransfer();

        if (frameTransfer != null) {
            frameTransfer.dispose();
            setFrameTransfer(null);
        }
    }
The flag is true if this processor is main.
jme3-desktop/src/main/java/com/jme3/system/AWTFrameProcessor.java