Examples of HeadlessException


Examples of ae.java.awt.HeadlessException

        return (JFrame)createInputMethodWindow(title, context, true);
    }

    static Window createInputMethodWindow(String title, InputContext context, boolean isSwing) {
        if (GraphicsEnvironment.isHeadless()) {
            throw new HeadlessException();
        }
        if (isSwing) {
            return new InputMethodJFrame(title, context);
        } else {
            Toolkit toolkit = Toolkit.getDefaultToolkit();
View Full Code Here

Examples of com.google.code.appengine.awt.HeadlessException

        return true;
    }
   
    @Override
    public GraphicsDevice getDefaultScreenDevice() throws HeadlessException {
        throw new HeadlessException();
    }
View Full Code Here

Examples of java.awt.HeadlessException

  public VersionEditor() throws HeadlessException {
    super();

    if(CurrentVersion.fromJar())
      throw new HeadlessException("You may not run the version editor from a JAR");

    setTitle("BNU-Bot Version Editor");

    initializeGui();
View Full Code Here

Examples of java.awt.HeadlessException

        }
        // Declaring the argument as Object rather than Component avoids class not
        // found errors on phoneME foundation profile.
        static long getComponentID(Object o) throws HeadlessException {
            if (GraphicsEnvironment.isHeadless()) {
                throw new HeadlessException("No native windows when headless");
            }
            Component c = (Component)o;
            if (c.isLightweight()) {
                throw new IllegalArgumentException("Component must be heavyweight");
            }
View Full Code Here

Examples of java.awt.HeadlessException

        }
        // Declaring the argument as Object rather than Component avoids class not
        // found errors on phoneME foundation profile.
        static long getComponentID(Object o) throws HeadlessException {
            if (GraphicsEnvironment.isHeadless()) {
                throw new HeadlessException("No native windows when headless");
            }
            Component c = (Component)o;
            if (c.isLightweight()) {
                throw new IllegalArgumentException("Component must be heavyweight");
            }
View Full Code Here

Examples of java.awt.HeadlessException

        setColor(new Color(c));
    }
   
    public void setDragEnabled(final boolean b) {
        if (b && GraphicsEnvironment.isHeadless()) {
            throw new HeadlessException();
        }
        dragEnabled = b;
    }
View Full Code Here

Examples of java.awt.HeadlessException

    DropTargetAutoScroller autoScroller;

    public DropTarget(Component c, int ops, DropTargetListener dtl,
            boolean act, FlavorMap fm) throws HeadlessException {
        if (GraphicsEnvironment.isHeadless()) {
            throw new HeadlessException();
        }
        context = createDropTargetContext();
        setDefaultActionsImpl(ops);
        active = (c != null) ? act : true;
        dropTargetListener = dtl;
View Full Code Here

Examples of java.awt.HeadlessException

        }
    }

    public static DragSource getDefaultDragSource() {
        if (GraphicsEnvironment.isHeadless()) {
            throw new HeadlessException();
        }

        if (defaultSource == null) {
            defaultSource = new DragSource();
        }
View Full Code Here

Examples of java.awt.HeadlessException

        return threshold;
    }

    public DragSource() throws HeadlessException {
        if (GraphicsEnvironment.isHeadless()) {
            throw new HeadlessException();
        }

        dragSourceListeners = new ListenerList<DragSourceListener>();
        dragSourceMotionListeners = new ListenerList<DragSourceMotionListener>();
    }
View Full Code Here

Examples of java.awt.HeadlessException

        }
    }

    public void setDragEnabled(final boolean b) {
        if (GraphicsEnvironment.isHeadless()) {
            throw new HeadlessException();
        }
        isDragEnabled = b; //TODO it may be no enought(some L&F)
        //TODO Really it will not work, because javax.swing.Transfer doesn't
        //provide enough functionality. Appropriate TransferHandler sets by
        // BasicTextUI. But I don't know now, what should I do, if it
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.