Revision 9428

View differences:

trunk/extensions/extAddIDEELayers/src/com/iver/gvsig/addIDEElayers/AddIDEELayersExtension.java
40 40
 */
41 41
package com.iver.gvsig.addIDEElayers;
42 42

  
43
import java.io.IOException;
43 44
import java.util.HashMap;
44 45

  
46
import javax.swing.JOptionPane;
47

  
45 48
import com.iver.andami.PluginServices;
46 49
import com.iver.andami.plugins.Extension;
47 50
import com.iver.andami.ui.mdiManager.IWindow;
48 51
import com.iver.cit.gvsig.fmap.MapControl;
52
import com.iver.cit.gvsig.fmap.drivers.DriverIOException;
49 53
import com.iver.cit.gvsig.fmap.layers.FLyrWMS;
50 54
import com.iver.cit.gvsig.project.documents.view.gui.View;
51 55

  
......
114 118
			 mapControl.getMapContext().endAtomicEvent();
115 119
		    
116 120
			 // Refresh the view
117
			 mapControl.getMapContext().invalidate();	
118
		 } catch(Exception e) {
121
			 mapControl.getMapContext().invalidate();
122
			 
123
		 } catch(DriverIOException e) {
124
			 // To notify the problem to the user
119 125
			 e.printStackTrace();
126
			 JOptionPane.showMessageDialog(null, PluginServices.getText(null, "error") + ":\n" + e.getMessage(), PluginServices.getText(null, "error"), JOptionPane.ERROR_MESSAGE);
120 127
			 return false;
128
		 } catch (Exception ex) {
129
			 // To notify the problem to the user
130
			 ex.printStackTrace();
131
			 JOptionPane.showMessageDialog(null, PluginServices.getText(null, "error") + ":\n" + ex.getMessage(), PluginServices.getText(null, "error"), JOptionPane.ERROR_MESSAGE);
132
			 return false;
121 133
		 }
122 134
        
123 135
      return true;

Also available in: Unified diff