Package java.awt

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


        return threshold;
    }

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

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

        }
    }

    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

        return (TableCellEditor) getClosestClass(columnClass, defaultEditorsByColumnClass);
    }

    public void setDragEnabled(boolean enabled) {
        if (enabled && GraphicsEnvironment.isHeadless()) {
            throw new HeadlessException();
        }
        dragEnabled = enabled;
    }
View Full Code Here

    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

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

        throw new HeadlessException();
    }

    @Override
    public GraphicsDevice[] getScreenDevices() throws HeadlessException {
        throw new HeadlessException();
    }
View Full Code Here

        return cellRenderer;
    }

    public void setDragEnabled(final boolean dragEnabled) {
        if (dragEnabled && GraphicsEnvironment.isHeadless()) {
            throw new HeadlessException(Messages.getString("swing.18")); //$NON-NLS-1$
        }

        this.dragEnabled = dragEnabled;
    }
View Full Code Here

                           PrintRequestAttributeSet dialogAttrs,
                           Window owner)
    {
        if (GraphicsEnvironment.isHeadless()) {
            dialogResult = SETUP_ERROR;
            throw new HeadlessException();
        }
   
        if (owner instanceof Frame) {
            printDialog = new JDialog((Frame)owner, "Print", true, gc);
        } else if(owner instanceof Dialog) {
View Full Code Here

   
        dialogType = PAGE_DIALOG;
   
        if (GraphicsEnvironment.isHeadless()) {
            dialogResult = SETUP_ERROR;
            throw new HeadlessException();
        }
   
        if (owner instanceof Frame) {
            printDialog = new JDialog((Frame)owner, "Print", true, gc);
        } else if (owner instanceof Dialog) {
View Full Code Here

TOP

Related Classes of java.awt.HeadlessException

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.