[mapguide-commits] r7678 - branches/maestro-4.0.x/Maestro.Editors/FeatureSource/Providers/Gdal
svn_mapguide at osgeo.org
svn_mapguide at osgeo.org
Tue Jul 9 05:53:47 PDT 2013
Author: jng
Date: 2013-07-09 05:53:47 -0700 (Tue, 09 Jul 2013)
New Revision: 7678
Modified:
branches/maestro-4.0.x/Maestro.Editors/FeatureSource/Providers/Gdal/GdalProviderCtrl.Designer.cs
branches/maestro-4.0.x/Maestro.Editors/FeatureSource/Providers/Gdal/GdalProviderCtrl.cs
branches/maestro-4.0.x/Maestro.Editors/FeatureSource/Providers/Gdal/GdalProviderCtrl.resx
Log:
#2306: Port to 4.0.x
Modified: branches/maestro-4.0.x/Maestro.Editors/FeatureSource/Providers/Gdal/GdalProviderCtrl.Designer.cs
===================================================================
--- branches/maestro-4.0.x/Maestro.Editors/FeatureSource/Providers/Gdal/GdalProviderCtrl.Designer.cs 2013-07-09 12:47:04 UTC (rev 7677)
+++ branches/maestro-4.0.x/Maestro.Editors/FeatureSource/Providers/Gdal/GdalProviderCtrl.Designer.cs 2013-07-09 12:53:47 UTC (rev 7678)
@@ -35,15 +35,15 @@
this.btnTest = new System.Windows.Forms.Button();
this.label1 = new System.Windows.Forms.Label();
this.txtStatus = new System.Windows.Forms.TextBox();
- this.lblResamplingMethod = new System.Windows.Forms.Label();
this.cmbResamplingMethod = new System.Windows.Forms.ComboBox();
+ this.chkResamplingMethod = new System.Windows.Forms.CheckBox();
this.contentPanel.SuspendLayout();
this.SuspendLayout();
//
// contentPanel
//
+ this.contentPanel.Controls.Add(this.chkResamplingMethod);
this.contentPanel.Controls.Add(this.cmbResamplingMethod);
- this.contentPanel.Controls.Add(this.lblResamplingMethod);
this.contentPanel.Controls.Add(this.txtStatus);
this.contentPanel.Controls.Add(this.label1);
this.contentPanel.Controls.Add(this.btnTest);
@@ -92,11 +92,6 @@
this.txtStatus.Name = "txtStatus";
this.txtStatus.ReadOnly = true;
//
- // lblResamplingMethod
- //
- resources.ApplyResources(this.lblResamplingMethod, "lblResamplingMethod");
- this.lblResamplingMethod.Name = "lblResamplingMethod";
- //
// cmbResamplingMethod
//
resources.ApplyResources(this.cmbResamplingMethod, "cmbResamplingMethod");
@@ -105,6 +100,13 @@
this.cmbResamplingMethod.Name = "cmbResamplingMethod";
this.cmbResamplingMethod.SelectedIndexChanged += new System.EventHandler(this.cmbResamplingMethod_SelectedIndexChanged);
//
+ // chkResamplingMethod
+ //
+ resources.ApplyResources(this.chkResamplingMethod, "chkResamplingMethod");
+ this.chkResamplingMethod.Name = "chkResamplingMethod";
+ this.chkResamplingMethod.UseVisualStyleBackColor = true;
+ this.chkResamplingMethod.CheckedChanged += new System.EventHandler(this.chkResamplingMethod_CheckedChanged);
+ //
// GdalProviderCtrl
//
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
@@ -125,6 +127,6 @@
private System.Windows.Forms.Label label1;
private System.Windows.Forms.TextBox txtStatus;
private System.Windows.Forms.ComboBox cmbResamplingMethod;
- private System.Windows.Forms.Label lblResamplingMethod;
+ private System.Windows.Forms.CheckBox chkResamplingMethod;
}
}
Modified: branches/maestro-4.0.x/Maestro.Editors/FeatureSource/Providers/Gdal/GdalProviderCtrl.cs
===================================================================
--- branches/maestro-4.0.x/Maestro.Editors/FeatureSource/Providers/Gdal/GdalProviderCtrl.cs 2013-07-09 12:47:04 UTC (rev 7677)
+++ branches/maestro-4.0.x/Maestro.Editors/FeatureSource/Providers/Gdal/GdalProviderCtrl.cs 2013-07-09 12:53:47 UTC (rev 7678)
@@ -59,27 +59,35 @@
_bSupportsResample = false;
_service = service;
_fs = (IFeatureSource)_service.GetEditedResource();
-
+
var provInfo = _service.FeatureService.GetFeatureProvider("OSGeo.Gdal");
foreach (var prop in provInfo.ConnectionProperties)
{
if (prop.Name == "ResamplingMethod")
{
- lblResamplingMethod.Visible =
+ chkResamplingMethod.Visible =
cmbResamplingMethod.Visible =
cmbResamplingMethod.Enabled = true;
cmbResamplingMethod.DataSource = new List<string>(prop.Value);
var method = _fs.GetConnectionProperty("ResamplingMethod");
if (!string.IsNullOrEmpty(method))
+ {
+ chkResamplingMethod.Checked = true;
cmbResamplingMethod.SelectedItem = method;
+ }
else
+ {
cmbResamplingMethod.SelectedIndex = 0;
+ chkResamplingMethod.Checked = false;
+ }
_bSupportsResample = true;
break;
}
}
+ cmbResamplingMethod.Enabled = chkResamplingMethod.Checked;
+
_sing.Bind(service);
_comp.Bind(service);
if (!string.IsNullOrEmpty(_fs.GetConfigurationContent()))
@@ -128,11 +136,28 @@
private void cmbResamplingMethod_SelectedIndexChanged(object sender, EventArgs e)
{
- if (!_bSupportsResample)
+ if (_init || !_bSupportsResample || !chkResamplingMethod.Checked)
return;
if (cmbResamplingMethod.SelectedItem != null)
- _fs.SetConnectionProperty("ResamplingMethod", cmbResamplingMethod.SelectedItem.ToString());
+ _fs.SetConnectionProperty("ResamplingMethod", cmbResamplingMethod.SelectedItem.ToString()); //NOXLATE
}
+
+ private void chkResamplingMethod_CheckedChanged(object sender, EventArgs e)
+ {
+ if (_init)
+ return;
+
+ cmbResamplingMethod.Enabled = chkResamplingMethod.Checked;
+ if (chkResamplingMethod.Checked)
+ {
+ if (cmbResamplingMethod.SelectedItem != null)
+ _fs.SetConnectionProperty("ResamplingMethod", cmbResamplingMethod.SelectedItem.ToString()); //NOXLATE
+ }
+ else
+ {
+ _fs.SetConnectionProperty("ResamplingMethod", null); //NOXLATE
+ }
+ }
}
}
Modified: branches/maestro-4.0.x/Maestro.Editors/FeatureSource/Providers/Gdal/GdalProviderCtrl.resx
===================================================================
--- branches/maestro-4.0.x/Maestro.Editors/FeatureSource/Providers/Gdal/GdalProviderCtrl.resx 2013-07-09 12:47:04 UTC (rev 7677)
+++ branches/maestro-4.0.x/Maestro.Editors/FeatureSource/Providers/Gdal/GdalProviderCtrl.resx 2013-07-09 12:53:47 UTC (rev 7678)
@@ -112,69 +112,72 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
- <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
- <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
- <assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
- <data name="cmbResamplingMethod.Anchor" type="System.Windows.Forms.AnchorStyles, System.Windows.Forms">
- <value>Top, Left, Right</value>
+ <assembly alias="mscorlib" name="mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
+ <data name="chkResamplingMethod.AutoSize" type="System.Boolean, mscorlib">
+ <value>True</value>
</data>
- <assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
- <data name="cmbResamplingMethod.Location" type="System.Drawing.Point, System.Drawing">
- <value>316, 14</value>
+ <assembly alias="System.Drawing" name="System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+ <data name="chkResamplingMethod.Location" type="System.Drawing.Point, System.Drawing">
+ <value>195, 16</value>
</data>
- <data name="cmbResamplingMethod.Size" type="System.Drawing.Size, System.Drawing">
- <value>119, 21</value>
+ <data name="chkResamplingMethod.Size" type="System.Drawing.Size, System.Drawing">
+ <value>120, 17</value>
</data>
- <assembly alias="mscorlib" name="mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
- <data name="cmbResamplingMethod.TabIndex" type="System.Int32, mscorlib">
- <value>7</value>
+ <data name="chkResamplingMethod.TabIndex" type="System.Int32, mscorlib">
+ <value>8</value>
</data>
- <data name="cmbResamplingMethod.Visible" type="System.Boolean, mscorlib">
+ <data name="chkResamplingMethod.Text" xml:space="preserve">
+ <value>Resampling Method</value>
+ </data>
+ <data name="chkResamplingMethod.Visible" type="System.Boolean, mscorlib">
<value>False</value>
</data>
- <data name=">>cmbResamplingMethod.Name" xml:space="preserve">
- <value>cmbResamplingMethod</value>
+ <data name=">>chkResamplingMethod.Name" xml:space="preserve">
+ <value>chkResamplingMethod</value>
</data>
- <data name=">>cmbResamplingMethod.Type" xml:space="preserve">
- <value>System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <data name=">>chkResamplingMethod.Type" xml:space="preserve">
+ <value>System.Windows.Forms.CheckBox, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
- <data name=">>cmbResamplingMethod.Parent" xml:space="preserve">
+ <data name=">>chkResamplingMethod.Parent" xml:space="preserve">
<value>contentPanel</value>
</data>
- <data name=">>cmbResamplingMethod.ZOrder" xml:space="preserve">
+ <data name=">>chkResamplingMethod.ZOrder" xml:space="preserve">
<value>0</value>
</data>
- <data name="lblResamplingMethod.AutoSize" type="System.Boolean, mscorlib">
- <value>True</value>
+ <assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
+ <data name="cmbResamplingMethod.Anchor" type="System.Windows.Forms.AnchorStyles, System.Windows.Forms">
+ <value>Top, Left, Right</value>
</data>
- <data name="lblResamplingMethod.Location" type="System.Drawing.Point, System.Drawing">
- <value>209, 17</value>
+ <data name="cmbResamplingMethod.Enabled" type="System.Boolean, mscorlib">
+ <value>False</value>
</data>
- <data name="lblResamplingMethod.Size" type="System.Drawing.Size, System.Drawing">
- <value>101, 13</value>
+ <data name="cmbResamplingMethod.Location" type="System.Drawing.Point, System.Drawing">
+ <value>321, 14</value>
</data>
- <data name="lblResamplingMethod.TabIndex" type="System.Int32, mscorlib">
- <value>6</value>
+ <data name="cmbResamplingMethod.Size" type="System.Drawing.Size, System.Drawing">
+ <value>114, 21</value>
</data>
- <data name="lblResamplingMethod.Text" xml:space="preserve">
- <value>Resampling Method</value>
+ <data name="cmbResamplingMethod.TabIndex" type="System.Int32, mscorlib">
+ <value>7</value>
</data>
- <data name="lblResamplingMethod.Visible" type="System.Boolean, mscorlib">
+ <data name="cmbResamplingMethod.Visible" type="System.Boolean, mscorlib">
<value>False</value>
</data>
- <data name=">>lblResamplingMethod.Name" xml:space="preserve">
- <value>lblResamplingMethod</value>
+ <data name=">>cmbResamplingMethod.Name" xml:space="preserve">
+ <value>cmbResamplingMethod</value>
</data>
- <data name=">>lblResamplingMethod.Type" xml:space="preserve">
- <value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <data name=">>cmbResamplingMethod.Type" xml:space="preserve">
+ <value>System.Windows.Forms.ComboBox, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
- <data name=">>lblResamplingMethod.Parent" xml:space="preserve">
+ <data name=">>cmbResamplingMethod.Parent" xml:space="preserve">
<value>contentPanel</value>
</data>
- <data name=">>lblResamplingMethod.ZOrder" xml:space="preserve">
+ <data name=">>cmbResamplingMethod.ZOrder" xml:space="preserve">
<value>1</value>
</data>
<data name="txtStatus.Anchor" type="System.Windows.Forms.AnchorStyles, System.Windows.Forms">
@@ -196,7 +199,7 @@
<value>txtStatus</value>
</data>
<data name=">>txtStatus.Type" xml:space="preserve">
- <value>System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Windows.Forms.TextBox, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name=">>txtStatus.Parent" xml:space="preserve">
<value>contentPanel</value>
@@ -223,7 +226,7 @@
<value>label1</value>
</data>
<data name=">>label1.Type" xml:space="preserve">
- <value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Windows.Forms.Label, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name=">>label1.Parent" xml:space="preserve">
<value>contentPanel</value>
@@ -250,7 +253,7 @@
<value>btnTest</value>
</data>
<data name=">>btnTest.Type" xml:space="preserve">
- <value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Windows.Forms.Button, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name=">>btnTest.Parent" xml:space="preserve">
<value>contentPanel</value>
@@ -274,7 +277,7 @@
<value>panel1</value>
</data>
<data name=">>panel1.Type" xml:space="preserve">
- <value>System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Windows.Forms.Panel, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name=">>panel1.Parent" xml:space="preserve">
<value>contentPanel</value>
@@ -301,7 +304,7 @@
<value>rdComposite</value>
</data>
<data name=">>rdComposite.Type" xml:space="preserve">
- <value>System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Windows.Forms.RadioButton, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name=">>rdComposite.Parent" xml:space="preserve">
<value>contentPanel</value>
@@ -328,7 +331,7 @@
<value>rdSingle</value>
</data>
<data name=">>rdSingle.Type" xml:space="preserve">
- <value>System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Windows.Forms.RadioButton, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name=">>rdSingle.Parent" xml:space="preserve">
<value>contentPanel</value>
@@ -343,7 +346,7 @@
<value>contentPanel</value>
</data>
<data name=">>contentPanel.Type" xml:space="preserve">
- <value>System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Windows.Forms.Panel, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name=">>contentPanel.Parent" xml:space="preserve">
<value>$this</value>
@@ -351,7 +354,7 @@
<data name=">>contentPanel.ZOrder" xml:space="preserve">
<value>0</value>
</data>
- <metadata name="$this.Localizable" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+ <metadata name="$this.Localizable" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<data name="$this.HeaderText" xml:space="preserve">
@@ -364,6 +367,6 @@
<value>GdalProviderCtrl</value>
</data>
<data name=">>$this.Type" xml:space="preserve">
- <value>Maestro.Editors.Common.EditorBindableCollapsiblePanel, Maestro.Editors, Version=5.0.0.6640, Culture=neutral, PublicKeyToken=f526c48929fda856</value>
+ <value>Maestro.Editors.Common.EditorBindableCollapsiblePanel, Maestro.Editors, Version=4.0.1.6639, Culture=neutral, PublicKeyToken=f526c48929fda856</value>
</data>
</root>
\ No newline at end of file
More information about the mapguide-commits
mailing list