Package org.openide.cookies.EditorCookie

Examples of org.openide.cookies.EditorCookie.Observable


     * TODO: If opening a system file, make it open in a read only editor.
     *
     * @param dataObj
     */
    private void openEditor(DataObject dataObj) {
        final Observable ec = dataObj.getCookie(Observable.class);
        if (ec != null) {
            javax.swing.SwingUtilities.invokeLater(new Runnable() {
                @Override
                public void run() {
                    ec.open();
                }
            });
        }
    }
View Full Code Here


        javax.swing.SwingUtilities.invokeLater(new Runnable() {
            @Override
            public void run() {
                try {
                    EditorCookie ck = dataObj.getCookie(EditorCookie.class);
                    final Observable ec = dataObj.getCookie(Observable.class);
                    if (ck != null && ec != null) {
                        ec.open();
                        //open the document
                        JEditorPane[] p = ck.getOpenedPanes();
                        if (p.length > 0) {
                            //Need to do this since we're disabling the window system's
                            //auto focus mechanism
View Full Code Here

            errorNode = getSelectedErrorNode();
        }
    }

    private void openEditor(DataObject dataObj) {
        final Observable ec = dataObj.getCookie(Observable.class);

        if (ec != null) {
            runInEventDispatchThread(new Runnable() {

                @Override
                public void run() {
                    ec.open();
                }
            });
        }
    }
View Full Code Here

     * TODO: If opening a system file, make it open in a read only editor.
     *
     * @param dataObj
     */
    private void openEditor(DataObject dataObj) {
        final Observable ec = dataObj.getCookie(Observable.class);
        if (ec != null) {
            javax.swing.SwingUtilities.invokeLater(new Runnable() {
                @Override
                public void run() {
                    ec.open();
                }
            });
        }
    }
View Full Code Here

        javax.swing.SwingUtilities.invokeLater(new Runnable() {
            @Override
            public void run() {
                try {
                    EditorCookie ck = dataObj.getCookie(EditorCookie.class);
                    final Observable ec = dataObj.getCookie(Observable.class);
                    if (ck != null && ec != null) {
                        ec.open();
                        //open the document
                        JEditorPane[] p = ck.getOpenedPanes();
                        if (p.length > 0) {
                            //Need to do this since we're disabling the window system's
                            //auto focus mechanism
View Full Code Here

            Exceptions.printStackTrace(ioe);
        }
    }

    private void openEditor(DataObject dataObj) {
        final Observable ec = dataObj.getCookie(Observable.class);

        if (ec != null) {
            runInEventDispatchThread(new Runnable() {

                public void run() {
                    ec.open();
                }
            });
        }
    }
View Full Code Here

TOP

Related Classes of org.openide.cookies.EditorCookie.Observable

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.