Package org.locationtech.udig.mapgraphic

Examples of org.locationtech.udig.mapgraphic.MapGraphicChooserDialog.open()


    public void perform() {
        graphic = null;
        MapGraphicChooserDialog dialog = new MapGraphicChooserDialog(Display.getCurrent().getActiveShell(), false);
        dialog.setBlockOnOpen(true);
       
        dialog.open();
       
        if( dialog.getReturnCode() == Window.OK ){
            List<MapGraphicResource> selectedResources = dialog.getSelectedResources();
            if( selectedResources!=null && !selectedResources.isEmpty()){
                this.graphic = selectedResources.get(0);
View Full Code Here


    public void init( IWorkbenchWindow window ) {
    }

    public void run( IAction action ) {
        MapGraphicChooserDialog d = new MapGraphicChooserDialog(Display.getCurrent().getActiveShell(), true);
        d.open();
       
        List<IGeoResource> resources = new ArrayList<IGeoResource>();
        for( IGeoResource geoResource : d.getSelectedResources() ) {
            resources.add(geoResource);
        }
View Full Code Here

        final Display display = findDisplay();
        display.asyncExec(new Runnable(){
            public void run() {
                MapGraphicChooserDialog dialog = new MapGraphicChooserDialog(display
                        .getActiveShell(), false);
                dialog.open();
                if (dialog.getSelectedResources().isEmpty()) {
                    layer = NULL;
                } else {
                    IGeoResource resource = dialog.getSelectedResources().get(0);
                    setMapGraphic((MapGraphicResource) resource);
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.