Esempio n. 1
0
 private void GraticuleForm_FormClosed(object sender, FormClosedEventArgs e)
 {
     Graticule.GraticuleExtentChanged -= OnGraticuleExtentChanged;
     Graticule.MapRedrawNeeded        -= OnRedrawNeeded;
     _instance   = null;
     _parentForm = null;
     CleanUp();
 }
 public static Grid25GenerateForm GetInstance(MapperForm parent)
 {
     if (_instance == null)
     {
         _instance = new Grid25GenerateForm(parent);
     }
     return(_instance);
 }
Esempio n. 3
0
 public static ShapefileAttributesForm GetInstance(MapperForm parentForm, MapInterActionHandler mapInterActionHandler)
 {
     if (_instance == null)
     {
         _instance = new ShapefileAttributesForm(parentForm, mapInterActionHandler);
     }
     return(_instance);
 }
Esempio n. 4
0
 public static MapperForm GetInstance(Form parentForm)
 {
     if (_instance == null)
     {
         _instance = new MapperForm(parentForm);
     }
     return(_instance);
 }
Esempio n. 5
0
 public static MapLayersForm GetInstance(MapLayersHandler mapLayers, MapperForm parent)
 {
     if (_instance == null)
     {
         _instance = new MapLayersForm(mapLayers, parent);
     }
     return(_instance);
 }
Esempio n. 6
0
 /// <summary>
 /// Constructor
 /// </summary>
 /// <param name="parent"></param>
 /// <param name="mapInterActionHandler"></param>
 public ShapefileAttributesForm(MapperForm parent, MapInterActionHandler mapInterActionHandler)
 {
     InitializeComponent();
     MapInterActionHandler            = mapInterActionHandler;
     MapInterActionHandler.Selection += OnLayerSelection;
     MapInterActionHandler.MapLayersHandler.CurrentLayer += OnCurrentLayer;
     _parentForm      = parent;
     _currentMapLayer = MapInterActionHandler.MapLayersHandler.CurrentMapLayer;
 }
 public Grid25GenerateForm(MapperForm parent)
 {
     InitializeComponent();
     _parentForm                            = parent;
     _grid25MajorGrid                       = parent.Grid25MajorGrid;
     _grid25MajorGrid.LayerSaved           += OnGrid25LayerSaved;
     _grid25MajorGrid.GridRetrieved        += OnGrid25GridRetrieved;
     _grid25MajorGrid.ExtentCreatedInLayer += OnExtentCreated;
     _grid25MajorGrid.OnGridInPanelCreated += OnGridInPanelCreated;
 }
 private void CleanUp()
 {
     _parentForm      = null;
     _grid25MajorGrid = null;
     if (_labelAndGridProperties != null)
     {
         _labelAndGridProperties.Clear();
         _labelAndGridProperties = null;
     }
     _savedGridLayers = null;
     _instance        = null;
 }
Esempio n. 9
0
 public MapLayersForm(MapLayersHandler mapLayers, MapperForm parent)
 {
     InitializeComponent();
     _parentForm                           = parent;
     _mapLayersHandler                     = mapLayers;
     _mapLayersHandler.LayerRead          += OnLayerRead;
     _mapLayersHandler.LayerRemoved       += OnLayerDeleted;
     _mapLayersHandler.OnLayerNameUpdate  += OnLayerNameUpdated;
     _mapLayersHandler.LayerRefreshNeeded += OnLayerRefreshRequest;
     layerGrid.CellClick                  += OnCellClick;
     layerGrid.CellMouseDown              += OnCellMouseDown;
     layerGrid.CellDoubleClick            += OnCellDoubleClick;
     layerGrid.DragDrop                   += OnLayerGrid_DragDrop;
     layerGrid.DragOver                   += OnLayerGrid_DragOver;
     layerGrid.MouseDown                  += OnLayerGrid_MouseDown;
     layerGrid.MouseMove                  += OnLayerGrid_MouseMove;
 }
Esempio n. 10
0
 public static void Cleanup()
 {
     _mapForm = null;
     foreach (var item in _tempFiles)
     {
         if (File.Exists(item))
         {
             try
             {
                 File.Delete(item);
             }
             catch
             {
                 //ignore
             }
         }
     }
 }
Esempio n. 11
0
        private void OnMapperForm_Closed(object sender, FormClosedEventArgs e)
        {
            if (_saveMapImage != null)
            {
                _saveMapImage.PointSizeExceed100Error -= OnPointSizeRenderError;
            }
            global.MappingForm = null;
            CleanUp();

            _instance = null;
            global.SaveFormSettings(this);
            EventHandler handler = MapperClosed;

            if (handler != null)
            {
                handler(this, EventArgs.Empty);
            }
            global.mainForm.SetMapDependendMenus();
        }
Esempio n. 12
0
 public GraticuleForm(MapperForm parent)
 {
     InitializeComponent();
     _parentForm = parent;
 }