Index: Core/Components/src/Core.Components.DotSpatial.Forms/Core.Components.DotSpatial.Forms.csproj
===================================================================
diff -u -r653147ae92ff1a7759f7683afe28de029ae7a0be -r2b894d6833741b18aed72819933caaf48350cb2b
--- Core/Components/src/Core.Components.DotSpatial.Forms/Core.Components.DotSpatial.Forms.csproj (.../Core.Components.DotSpatial.Forms.csproj) (revision 653147ae92ff1a7759f7683afe28de029ae7a0be)
+++ Core/Components/src/Core.Components.DotSpatial.Forms/Core.Components.DotSpatial.Forms.csproj (.../Core.Components.DotSpatial.Forms.csproj) (revision 2b894d6833741b18aed72819933caaf48350cb2b)
@@ -23,6 +23,9 @@
True
Resources.resx
+
+ UserControl
+
Index: Core/Components/src/Core.Components.DotSpatial.Forms/MapControl.Designer.cs
===================================================================
diff -u
--- Core/Components/src/Core.Components.DotSpatial.Forms/MapControl.Designer.cs (revision 0)
+++ Core/Components/src/Core.Components.DotSpatial.Forms/MapControl.Designer.cs (revision 2b894d6833741b18aed72819933caaf48350cb2b)
@@ -0,0 +1,140 @@
+// Copyright (C) Stichting Deltares 2021. All rights reserved.
+//
+// This file is part of Riskeer.
+//
+// Riskeer is free software: you can redistribute it and/or modify
+// it under the terms of the GNU Lesser General Public License as published by
+// the Free Software Foundation, either version 3 of the License, or
+// (at your option) any later version.
+//
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public License
+// along with this program. If not, see .
+//
+// All names, logos, and references to "Deltares" are registered trademarks of
+// Stichting Deltares and remain full property of Stichting Deltares at all times.
+// All rights reserved.
+
+using System.ComponentModel;
+
+namespace Core.Components.DotSpatial.Forms
+{
+ partial class MapControl
+ {
+ ///
+ /// Required designer variable.
+ ///
+ private IContainer components = null;
+
+ #region Component Designer generated code
+
+ ///
+ /// Required method for Designer support - do not modify
+ /// the contents of this method with the code editor.
+ ///
+ private void InitializeComponent()
+ {
+ this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
+ this.checkBox1 = new System.Windows.Forms.CheckBox();
+ this.checkBox2 = new System.Windows.Forms.CheckBox();
+ this.checkBox3 = new System.Windows.Forms.CheckBox();
+ this.checkBox4 = new System.Windows.Forms.CheckBox();
+ this.tableLayoutPanel1.SuspendLayout();
+ this.SuspendLayout();
+ //
+ // tableLayoutPanel1
+ //
+ this.tableLayoutPanel1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
+ this.tableLayoutPanel1.AutoSize = true;
+ this.tableLayoutPanel1.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
+ this.tableLayoutPanel1.BackColor = System.Drawing.Color.Transparent;
+ this.tableLayoutPanel1.ColumnCount = 2;
+ this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 25F));
+ this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 25F));
+ this.tableLayoutPanel1.Controls.Add(this.checkBox1, 0, 0);
+ this.tableLayoutPanel1.Controls.Add(this.checkBox2, 1, 0);
+ this.tableLayoutPanel1.Controls.Add(this.checkBox3, 0, 1);
+ this.tableLayoutPanel1.Controls.Add(this.checkBox4, 1, 1);
+ this.tableLayoutPanel1.Location = new System.Drawing.Point(323, 280);
+ this.tableLayoutPanel1.Name = "tableLayoutPanel1";
+ this.tableLayoutPanel1.RowCount = 2;
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
+ this.tableLayoutPanel1.Size = new System.Drawing.Size(50, 50);
+ this.tableLayoutPanel1.TabIndex = 1;
+ //
+ // checkBox1
+ //
+ this.checkBox1.Appearance = System.Windows.Forms.Appearance.Button;
+ this.checkBox1.AutoSize = true;
+ this.checkBox1.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.checkBox1.Image = global::Core.Components.DotSpatial.Forms.Properties.Resources.MapPanZoomImage;
+ this.checkBox1.Location = new System.Drawing.Point(3, 3);
+ this.checkBox1.Name = "checkBox1";
+ this.checkBox1.Size = new System.Drawing.Size(19, 19);
+ this.checkBox1.TabIndex = 0;
+ this.checkBox1.UseVisualStyleBackColor = true;
+ //
+ // checkBox2
+ //
+ this.checkBox2.Appearance = System.Windows.Forms.Appearance.Button;
+ this.checkBox2.AutoSize = true;
+ this.checkBox2.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.checkBox2.Image = global::Core.Components.DotSpatial.Forms.Properties.Resources.zoomrectangle;
+ this.checkBox2.Location = new System.Drawing.Point(28, 3);
+ this.checkBox2.Name = "checkBox2";
+ this.checkBox2.Size = new System.Drawing.Size(19, 19);
+ this.checkBox2.TabIndex = 1;
+ this.checkBox2.UseVisualStyleBackColor = true;
+ //
+ // checkBox3
+ //
+ this.checkBox3.Appearance = System.Windows.Forms.Appearance.Button;
+ this.checkBox3.AutoSize = true;
+ this.checkBox3.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.checkBox3.Image = global::Core.Components.DotSpatial.Forms.Properties.Resources.zoomextents;
+ this.checkBox3.Location = new System.Drawing.Point(3, 28);
+ this.checkBox3.Name = "checkBox3";
+ this.checkBox3.Size = new System.Drawing.Size(19, 19);
+ this.checkBox3.TabIndex = 2;
+ this.checkBox3.UseVisualStyleBackColor = true;
+ //
+ // checkBox4
+ //
+ this.checkBox4.Appearance = System.Windows.Forms.Appearance.Button;
+ this.checkBox4.AutoSize = true;
+ this.checkBox4.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.checkBox4.Image = global::Core.Components.DotSpatial.Forms.Properties.Resources.map_pin;
+ this.checkBox4.Location = new System.Drawing.Point(28, 28);
+ this.checkBox4.Name = "checkBox4";
+ this.checkBox4.Size = new System.Drawing.Size(19, 19);
+ this.checkBox4.TabIndex = 3;
+ this.checkBox4.UseVisualStyleBackColor = true;
+ //
+ // MapControl2
+ //
+ this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 20F);
+ this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.Controls.Add(this.tableLayoutPanel1);
+ this.Name = "MapControl2";
+ this.Size = new System.Drawing.Size(697, 611);
+ this.tableLayoutPanel1.ResumeLayout(false);
+ this.tableLayoutPanel1.PerformLayout();
+ this.ResumeLayout(false);
+ this.PerformLayout();
+
+ }
+
+ #endregion
+
+ private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
+ private System.Windows.Forms.CheckBox checkBox1;
+ private System.Windows.Forms.CheckBox checkBox2;
+ private System.Windows.Forms.CheckBox checkBox3;
+ private System.Windows.Forms.CheckBox checkBox4;
+ }
+}
\ No newline at end of file
Index: Core/Components/src/Core.Components.DotSpatial.Forms/MapControl.cs
===================================================================
diff -u -rb16dadaa41c7f66c4948627472c6595155acf538 -r2b894d6833741b18aed72819933caaf48350cb2b
--- Core/Components/src/Core.Components.DotSpatial.Forms/MapControl.cs (.../MapControl.cs) (revision b16dadaa41c7f66c4948627472c6595155acf538)
+++ Core/Components/src/Core.Components.DotSpatial.Forms/MapControl.cs (.../MapControl.cs) (revision 2b894d6833741b18aed72819933caaf48350cb2b)
@@ -43,7 +43,7 @@
///
/// This class describes a map control with configured projection and function mode.
///
- public class MapControl : UserControl, IMapControl
+ public partial class MapControl : UserControl, IMapControl
{
private const int updateTimerInterval = 10;
private readonly ILog log = LogManager.GetLogger(typeof(MapControl));
@@ -60,11 +60,6 @@
private RdNewMouseCoordinatesMapExtension mouseCoordinatesMapExtension;
private MapDataCollection data;
private ImageBasedMapData backgroundMapData;
- private TableLayoutPanel tableLayoutPanel1;
- private CheckBox checkBox1;
- private CheckBox checkBox2;
- private CheckBox checkBox3;
- private CheckBox checkBox4;
private Timer updateTimer;
///
@@ -140,12 +135,18 @@
protected override void Dispose(bool disposing)
{
+ if (disposing && (components != null))
+ {
+ components.Dispose();
+ }
+
map.Dispose();
mouseCoordinatesMapExtension.Dispose();
mapDataCollectionObserver.Dispose();
backGroundMapDataObserver.Dispose();
backgroundLayerStatus.Dispose();
+
base.Dispose(disposing);
}
@@ -658,96 +659,5 @@
}
#endregion
-
- private void InitializeComponent()
- {
- this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
- this.checkBox1 = new System.Windows.Forms.CheckBox();
- this.checkBox2 = new System.Windows.Forms.CheckBox();
- this.checkBox3 = new System.Windows.Forms.CheckBox();
- this.checkBox4 = new System.Windows.Forms.CheckBox();
- this.tableLayoutPanel1.SuspendLayout();
- this.SuspendLayout();
- //
- // tableLayoutPanel1
- //
- this.tableLayoutPanel1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
- this.tableLayoutPanel1.AutoSize = true;
- this.tableLayoutPanel1.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
- this.tableLayoutPanel1.BackColor = System.Drawing.Color.Transparent;
- this.tableLayoutPanel1.ColumnCount = 2;
- this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 25F));
- this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 25F));
- this.tableLayoutPanel1.Controls.Add(this.checkBox1, 0, 0);
- this.tableLayoutPanel1.Controls.Add(this.checkBox2, 1, 0);
- this.tableLayoutPanel1.Controls.Add(this.checkBox3, 0, 1);
- this.tableLayoutPanel1.Controls.Add(this.checkBox4, 1, 1);
- this.tableLayoutPanel1.Location = new System.Drawing.Point(541, 3);
- this.tableLayoutPanel1.Name = "tableLayoutPanel1";
- this.tableLayoutPanel1.RowCount = 2;
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
- this.tableLayoutPanel1.Size = new System.Drawing.Size(50, 50);
- this.tableLayoutPanel1.TabIndex = 0;
- //
- // checkBox1
- //
- this.checkBox1.Appearance = System.Windows.Forms.Appearance.Button;
- this.checkBox1.AutoSize = true;
- this.checkBox1.Dock = System.Windows.Forms.DockStyle.Fill;
- this.checkBox1.Image = global::Core.Components.DotSpatial.Forms.Properties.Resources.MapPanZoomImage;
- this.checkBox1.Location = new System.Drawing.Point(3, 3);
- this.checkBox1.Name = "checkBox1";
- this.checkBox1.Size = new System.Drawing.Size(19, 19);
- this.checkBox1.TabIndex = 0;
- this.checkBox1.UseVisualStyleBackColor = true;
- //
- // checkBox2
- //
- this.checkBox2.Appearance = System.Windows.Forms.Appearance.Button;
- this.checkBox2.AutoSize = true;
- this.checkBox2.Dock = System.Windows.Forms.DockStyle.Fill;
- this.checkBox2.Image = global::Core.Components.DotSpatial.Forms.Properties.Resources.zoomrectangle;
- this.checkBox2.Location = new System.Drawing.Point(28, 3);
- this.checkBox2.Name = "checkBox2";
- this.checkBox2.Size = new System.Drawing.Size(19, 19);
- this.checkBox2.TabIndex = 1;
- this.checkBox2.UseVisualStyleBackColor = true;
- //
- // checkBox3
- //
- this.checkBox3.Appearance = System.Windows.Forms.Appearance.Button;
- this.checkBox3.AutoSize = true;
- this.checkBox3.Dock = System.Windows.Forms.DockStyle.Fill;
- this.checkBox3.Image = global::Core.Components.DotSpatial.Forms.Properties.Resources.zoomextents;
- this.checkBox3.Location = new System.Drawing.Point(3, 28);
- this.checkBox3.Name = "checkBox3";
- this.checkBox3.Size = new System.Drawing.Size(19, 19);
- this.checkBox3.TabIndex = 2;
- this.checkBox3.UseVisualStyleBackColor = true;
- //
- // checkBox4
- //
- this.checkBox4.Appearance = System.Windows.Forms.Appearance.Button;
- this.checkBox4.AutoSize = true;
- this.checkBox4.Dock = System.Windows.Forms.DockStyle.Fill;
- this.checkBox4.Image = global::Core.Components.DotSpatial.Forms.Properties.Resources.map_pin;
- this.checkBox4.Location = new System.Drawing.Point(28, 28);
- this.checkBox4.Name = "checkBox4";
- this.checkBox4.Size = new System.Drawing.Size(19, 19);
- this.checkBox4.TabIndex = 3;
- this.checkBox4.UseVisualStyleBackColor = true;
- //
- // MapControl
- //
- this.Controls.Add(this.tableLayoutPanel1);
- this.Name = "MapControl";
- this.Size = new System.Drawing.Size(594, 526);
- this.tableLayoutPanel1.ResumeLayout(false);
- this.tableLayoutPanel1.PerformLayout();
- this.ResumeLayout(false);
- this.PerformLayout();
-
- }
}
}
\ No newline at end of file