Package org.eclipse.jface.dialogs

Examples of org.eclipse.jface.dialogs.Dialog


    /**public for testing purposes only*/
    public @Override Dialog getDialog( Shell shell, final SimpleFeatureType featureType ) {
        if (featureType.getAttributeCount() == 0){
          return null;
        }
        final Dialog dialog = new Dialog(shell){

            @Override
            protected Control createDialogArea( Composite parent ) {
                Composite composite = (Composite) super.createDialogArea(parent);
                combo = new Combo(composite, SWT.DEFAULT);
View Full Code Here


        genericResults = results;
       
        PlatformGIS.syncInDisplayThread(new Runnable(){

            public void run() {
                Dialog dialog = getDialog(display.getActiveShell(), layer[0].getSchema());
                if (dialog != null) {
                    dialog.open();
                }
            }
           
        });
       
View Full Code Here

        results = new GenericValidationResults();
       
        PlatformGIS.syncInDisplayThread(new Runnable(){

            public void run() {
                Dialog dialog = getDialog(display.getActiveShell(), layer.getSchema());
                if (dialog != null) {
                    dialog.open();
                }
            }
           
        });
       
View Full Code Here

   
    @Before
    public void setUp() throws Exception {
        features = UDIGTestUtil.createDefaultTestFeatures(featureTypeName, 1);
        featureType = features[0].getFeatureType();
        dialog = new Dialog(Display.getCurrent().getActiveShell()){
            SimpleFeatureTypeBuilder builder=null;
            @Override
            protected Point getInitialSize() {
                return new Point(500, 500);
            }
View Full Code Here

            multi.add(status);
        }
       
       PlatformGIS.syncInDisplayThread(new Runnable(){
            public void run() {
                Dialog dialog = new ErrorDialog(Display.getDefault().getActiveShell(), Messages.ExceptionDisplayer_very_informative_error, message, multi, IStatus.ERROR);
                dialog.open();
            }
        });
    }
View Full Code Here

    public void open( Shell parentShell, final int selectionType ) {

        runningProcessesMap = OmsBoxPlugin.getDefault().getRunningProcessesMap();

        dialog = new Dialog(parentShell){

            @Override
            protected void configureShell( Shell shell ) {
                super.configureShell(shell);
                shell.setText("Kill selected process"); //$NON-NLS-1$
View Full Code Here

            crsButton.setText("..."); //$NON-NLS-1$
            crsButton.addSelectionListener(new org.eclipse.swt.events.SelectionAdapter(){

                public void widgetSelected( org.eclipse.swt.events.SelectionEvent e ) {
                    Shell shell = new Shell(text.getShell(), SWT.SHELL_TRIM);
                    Dialog dialog = new Dialog(shell){

                        private CRSChooser chooser;
                        private CoordinateReferenceSystem crs;

                        @Override
                        protected void configureShell( Shell shell ) {
                            super.configureShell(shell);
                            shell.setText("Choose CRS");
                        }

                        @Override
                        protected Control createDialogArea( Composite parent ) {
                            Composite comp = (Composite) super.createDialogArea(parent);
                            GridLayout gLayout = (GridLayout) comp.getLayout();

                            gLayout.numColumns = 1;

                            chooser = new CRSChooser(new Controller(){

                                public void handleClose() {
                                    buttonPressed(OK);
                                }

                                public void handleOk() {
                                    buttonPressed(OK);
                                }

                            });

                            return chooser.createControl(parent);
                        }

                        @Override
                        protected void buttonPressed( int buttonId ) {
                            if (buttonId == OK) {
                                crs = chooser.getCRS();

                                try {
                                    String codeFromCrs = OmsBoxUtils.getCodeFromCrs(crs);
                                    text.setText(codeFromCrs);
                                } catch (Exception e) {
                                    e.printStackTrace();
                                }

                            }
                            close();
                        }

                    };

                    dialog.setBlockOnOpen(true);
                    dialog.open();
                }
            });

            // initially set to map's crs
            IMap activeMap = ApplicationGIS.getActiveMap();
View Full Code Here

    private boolean goGo = false;

    public void open( Shell parentShell ) {
        goGo = false;
        Dialog dialog = new Dialog(parentShell){

            @Override
            protected void configureShell( Shell shell ) {
                super.configureShell(shell);
                shell.setText("Choose CRS");
            }

            // @Override
            // protected Point getInitialSize() {
            // return new Point(250, 250);
            // }

            @Override
            protected Control createDialogArea( Composite parent ) {
                Composite comp = (Composite) super.createDialogArea(parent);
                GridLayout gLayout = (GridLayout) comp.getLayout();

                gLayout.numColumns = 1;

                chooser = new CRSChooser(new Controller(){

                    public void handleClose() {
                        buttonPressed(OK);
                    }

                    public void handleOk() {
                        buttonPressed(OK);
                    }

                });

                return chooser.createControl(parent);
            }

            @Override
            protected void buttonPressed( int buttonId ) {
                if (buttonId == OK) {
                    try {
                        crs = chooser.getCRS();
                    } catch (Exception e) {
                    }
                }
                close();
                goGo = true;
            }

        };

        dialog.setBlockOnOpen(true);
        dialog.open();
        while( !goGo ) {
            if (dialog.getShell().isDisposed()) {
                break;
            }

            if (Display.getCurrent().readAndDispatch()) {
                // dialog.getShell().getDisplay().readAndDispatch()) {
View Full Code Here

    public void setLastUsedModuleDescription( ModuleDescription moduleDescription ) {
        this.lastUsedModuleDescription = moduleDescription;
    }

    public void open( final Shell parentShell ) {
        dialog = new Dialog(parentShell){

            protected void configureShell( Shell shell ) {
                super.configureShell(shell);
                shell.setText(title);
                shell.setSize(DIALOG_WIDTH, 700);
View Full Code Here

        String[] retrieveSavedJars = OmsBoxPlugin.getDefault().retrieveSavedJars();
        for( String jarPath : retrieveSavedJars ) {
            resourcesList.add(jarPath);
        }

        dialog = new Dialog(parentShell){

            @Override
            protected void configureShell( Shell shell ) {
                super.configureShell(shell);
                shell.setText(""); //$NON-NLS-1$
View Full Code Here

TOP

Related Classes of org.eclipse.jface.dialogs.Dialog

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.