[mapguide-commits] r4826 - in trunk/Tools/Maestro: Maestro Maestro/FusionEditor Maestro/LoginForm Maestro/ResourceEditors Maestro/ResourceEditors/FeatureSourceEditors/ArcSDE Maestro/ResourceEditors/FeatureSourceEditors/Filebased Maestro/ResourceEditors/FeatureSourceEditors/Gdal Maestro/ResourceEditors/FeatureSourceEditors/King.Informix Maestro/ResourceEditors/FeatureSourceEditors/King.KML Maestro/ResourceEditors/FeatureSourceEditors/King.MSSql Maestro/ResourceEditors/FeatureSourceEditors/King.Oracle Maestro/ResourceEditors/FeatureSourceEditors/MSSQLSpatial Maestro/ResourceEditors/FeatureSourceEditors/MySQL Maestro/ResourceEditors/FeatureSourceEditors/ODBC Maestro/ResourceEditors/FeatureSourceEditors/OGR Maestro/ResourceEditors/FeatureSourceEditors/PostGIS Maestro/ResourceEditors/FeatureSourceEditors/WFS Maestro/ResourceEditors/FeatureSourceEditors/WMS MaestroAPI

svn_mapguide at osgeo.org svn_mapguide at osgeo.org
Tue May 4 03:51:41 EDT 2010


Author: jng
Date: 2010-05-04 03:51:41 -0400 (Tue, 04 May 2010)
New Revision: 4826

Added:
   trunk/Tools/Maestro/Maestro/LoginForm/FormLogin.Designer.cs
   trunk/Tools/Maestro/Maestro/LoginForm/HttpLoginCtrl.Designer.cs
   trunk/Tools/Maestro/Maestro/LoginForm/HttpLoginCtrl.cs
   trunk/Tools/Maestro/Maestro/LoginForm/HttpLoginCtrl.resx
   trunk/Tools/Maestro/Maestro/LoginForm/ILoginCtrl.cs
   trunk/Tools/Maestro/Maestro/LoginForm/LocalNativeLoginCtrl.Designer.cs
   trunk/Tools/Maestro/Maestro/LoginForm/LocalNativeLoginCtrl.cs
   trunk/Tools/Maestro/Maestro/LoginForm/LocalNativeLoginCtrl.resx
Modified:
   trunk/Tools/Maestro/Maestro/FormMain.cs
   trunk/Tools/Maestro/Maestro/FusionEditor/ApplicationDefinitionEditor.cs
   trunk/Tools/Maestro/Maestro/LoginForm/FormLogin.cs
   trunk/Tools/Maestro/Maestro/LoginForm/FormLogin.resx
   trunk/Tools/Maestro/Maestro/LoginForm/OSGeo.MapGuide.Maestro.LoginForm.csproj
   trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditorBase.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditorGeneric.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/ArcSDE/FeatureSourceEditorArcSDE.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/Filebased/FilebasedFeatureSourceEditor.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/Gdal/FeatureSourceEditorGdal.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/King.Informix/FeatureSourceEditorKingInformix.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/King.KML/FeatureSourceEditorKingKML.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/King.MSSql/FeatureSourceEditorKingMSSql.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/King.Oracle/FeatureSourceEditorKingOracle.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/MSSQLSpatial/FeatureSourceEditorMSSQLSpatial.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/MySQL/FeatureSourceEditorMySQL.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/ODBC/FeatureSourceEditorODBC.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/OGR/FeatureSourceEditorOGR.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/PostGIS/FeatureSourceEditorPostGIS.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/WFS/FeatureSourceEditorWFS.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/WMS/FeatureSourceEditorWMS.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/LayerEditor.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/LayoutEditor.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/MapEditor.cs
   trunk/Tools/Maestro/Maestro/ResourceEditors/SymbolLibraryEditor.cs
   trunk/Tools/Maestro/MaestroAPI/HttpServerConnection.cs
   trunk/Tools/Maestro/MaestroAPI/LocalNativeConnection.cs
   trunk/Tools/Maestro/MaestroAPI/ServerConnectionI.cs
Log:
This submission includes the following changes:

- Add a new SupportsResourcePreviews API to ServerConnectionI which returns true for the http impl and false for the native impl
- Modify the SupportsPreview return value for all editors to return this new API value (for ones that previously returned true always). Ones that always returned false are unchanged, and those which are dependent on other conditions are AND'ed with this API return value.
- #1340 and #1113: Re build the login form to support native mode connection, as a result Maestro can now be used theoretically without an active web tier. Because there are now multiple modes of connection, the auto-connect option no longer makes sense and has been removed as a result.

Modified: trunk/Tools/Maestro/Maestro/FormMain.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/FormMain.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/FormMain.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -1029,7 +1029,7 @@
             frm.Icon = FormMain.MaestroIcon;
 
             frm.StartPosition = FormStartPosition.CenterParent;
-			frm.UseAutoConnect = true;
+			//frm.UseAutoConnect = true;
 
             if (frm.ShowDialog(this) == DialogResult.OK)
                 m_connection = frm.Connection;

Modified: trunk/Tools/Maestro/Maestro/FusionEditor/ApplicationDefinitionEditor.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/FusionEditor/ApplicationDefinitionEditor.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/FusionEditor/ApplicationDefinitionEditor.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -1431,7 +1431,7 @@
 
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
     }

Added: trunk/Tools/Maestro/Maestro/LoginForm/FormLogin.Designer.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/LoginForm/FormLogin.Designer.cs	                        (rev 0)
+++ trunk/Tools/Maestro/Maestro/LoginForm/FormLogin.Designer.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -0,0 +1,135 @@
+namespace OSGeo.MapGuide.Maestro
+{
+    partial class FormLogin
+    {
+        /// <summary>
+        /// Required designer variable.
+        /// </summary>
+        private System.ComponentModel.IContainer components = null;
+
+        /// <summary>
+        /// Clean up any resources being used.
+        /// </summary>
+        /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
+        protected override void Dispose(bool disposing)
+        {
+            if (disposing && (components != null))
+            {
+                components.Dispose();
+            }
+            base.Dispose(disposing);
+        }
+
+        #region Windows Form Designer generated code
+
+        /// <summary>
+        /// Required method for Designer support - do not modify
+        /// the contents of this method with the code editor.
+        /// </summary>
+        private void InitializeComponent()
+        {
+            this.chkSavePassword = new System.Windows.Forms.CheckBox();
+            this.btnCancel = new System.Windows.Forms.Button();
+            this.btnOK = new System.Windows.Forms.Button();
+            this.rdHttp = new System.Windows.Forms.RadioButton();
+            this.rdTcpIp = new System.Windows.Forms.RadioButton();
+            this.loginPanel = new System.Windows.Forms.Panel();
+            this.SuspendLayout();
+            // 
+            // chkSavePassword
+            // 
+            this.chkSavePassword.FlatStyle = System.Windows.Forms.FlatStyle.System;
+            this.chkSavePassword.ImeMode = System.Windows.Forms.ImeMode.NoControl;
+            this.chkSavePassword.Location = new System.Drawing.Point(206, 178);
+            this.chkSavePassword.Name = "chkSavePassword";
+            this.chkSavePassword.Size = new System.Drawing.Size(161, 16);
+            this.chkSavePassword.TabIndex = 15;
+            this.chkSavePassword.Text = "Save password on computer";
+            // 
+            // btnCancel
+            // 
+            this.btnCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
+            this.btnCancel.FlatStyle = System.Windows.Forms.FlatStyle.System;
+            this.btnCancel.ImeMode = System.Windows.Forms.ImeMode.NoControl;
+            this.btnCancel.Location = new System.Drawing.Point(206, 233);
+            this.btnCancel.Name = "btnCancel";
+            this.btnCancel.Size = new System.Drawing.Size(96, 32);
+            this.btnCancel.TabIndex = 13;
+            this.btnCancel.Text = "Cancel";
+            this.btnCancel.Click += new System.EventHandler(this.btnCancel_Click);
+            // 
+            // btnOK
+            // 
+            this.btnOK.Enabled = false;
+            this.btnOK.FlatStyle = System.Windows.Forms.FlatStyle.System;
+            this.btnOK.ImeMode = System.Windows.Forms.ImeMode.NoControl;
+            this.btnOK.Location = new System.Drawing.Point(94, 233);
+            this.btnOK.Name = "btnOK";
+            this.btnOK.Size = new System.Drawing.Size(96, 32);
+            this.btnOK.TabIndex = 12;
+            this.btnOK.Text = "OK";
+            this.btnOK.Click += new System.EventHandler(this.btnOK_Click);
+            // 
+            // rdHttp
+            // 
+            this.rdHttp.AutoSize = true;
+            this.rdHttp.Location = new System.Drawing.Point(61, 178);
+            this.rdHttp.Name = "rdHttp";
+            this.rdHttp.Size = new System.Drawing.Size(114, 17);
+            this.rdHttp.TabIndex = 16;
+            this.rdHttp.TabStop = true;
+            this.rdHttp.Text = "Connect via HTTP";
+            this.rdHttp.UseVisualStyleBackColor = true;
+            this.rdHttp.CheckedChanged += new System.EventHandler(this.rdHttp_CheckedChanged);
+            // 
+            // rdTcpIp
+            // 
+            this.rdTcpIp.AutoSize = true;
+            this.rdTcpIp.Location = new System.Drawing.Point(61, 202);
+            this.rdTcpIp.Name = "rdTcpIp";
+            this.rdTcpIp.Size = new System.Drawing.Size(121, 17);
+            this.rdTcpIp.TabIndex = 17;
+            this.rdTcpIp.TabStop = true;
+            this.rdTcpIp.Text = "Connect via TCP/IP";
+            this.rdTcpIp.UseVisualStyleBackColor = true;
+            this.rdTcpIp.CheckedChanged += new System.EventHandler(this.rdTcpIp_CheckedChanged);
+            // 
+            // loginPanel
+            // 
+            this.loginPanel.Location = new System.Drawing.Point(12, 12);
+            this.loginPanel.Name = "loginPanel";
+            this.loginPanel.Size = new System.Drawing.Size(374, 160);
+            this.loginPanel.TabIndex = 18;
+            // 
+            // FormLogin
+            // 
+            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
+            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+            this.ClientSize = new System.Drawing.Size(398, 277);
+            this.Controls.Add(this.loginPanel);
+            this.Controls.Add(this.rdTcpIp);
+            this.Controls.Add(this.rdHttp);
+            this.Controls.Add(this.chkSavePassword);
+            this.Controls.Add(this.btnCancel);
+            this.Controls.Add(this.btnOK);
+            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
+            this.MaximizeBox = false;
+            this.MinimizeBox = false;
+            this.Name = "FormLogin";
+            this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
+            this.Text = "Log on to a MapGuide Server";
+            this.ResumeLayout(false);
+            this.PerformLayout();
+
+        }
+
+        #endregion
+
+        private System.Windows.Forms.CheckBox chkSavePassword;
+        private System.Windows.Forms.Button btnCancel;
+        private System.Windows.Forms.Button btnOK;
+        private System.Windows.Forms.RadioButton rdHttp;
+        private System.Windows.Forms.RadioButton rdTcpIp;
+        private System.Windows.Forms.Panel loginPanel;
+    }
+}
\ No newline at end of file

Modified: trunk/Tools/Maestro/Maestro/LoginForm/FormLogin.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/LoginForm/FormLogin.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/LoginForm/FormLogin.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -1,6 +1,6 @@
-#region Disclaimer / License
-// Copyright (C) 2009, Kenneth Skovhede
-// http://www.hexad.dk, opensource at hexad.dk
+#region Disclaimer / License
+// Copyright (C) 2010, Jackie Ng
+// http://trac.osgeo.org/mapguide/wiki/maestro, jumpinjackie at gmail.com
 // 
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
@@ -18,318 +18,193 @@
 // 
 #endregion
 using System;
-using System.Drawing;
-using System.Collections;
+using System.Collections.Generic;
 using System.ComponentModel;
+using System.Data;
+using System.Drawing;
+using System.Text;
 using System.Windows.Forms;
-using System.Collections.Generic;
+using OSGeo.MapGuide.MaestroAPI;
 
 namespace OSGeo.MapGuide.Maestro
 {
-	/// <summary>
-	/// Summary description for FormLogin.
-	/// </summary>
-	public class FormLogin : System.Windows.Forms.Form
-	{
-		private OSGeo.MapGuide.MaestroAPI.ServerConnectionI m_connection;
-		private bool m_useAutoConnect = false;
+    public partial class FormLogin : Form
+    {
+        private int _selectedIndex;
+        private ILoginCtrl[] _controls;
+        private ServerConnectionI _conn;
 
-		private System.Windows.Forms.Label label1;
-		private System.Windows.Forms.Label label2;
-		private System.Windows.Forms.Label label3;
-		private System.Windows.Forms.Label label4;
-		private System.Windows.Forms.ComboBox cmbServerUrl;
-		private System.Windows.Forms.TextBox txtStartingpoint;
-		private System.Windows.Forms.TextBox txtUsername;
-		private System.Windows.Forms.TextBox txtPassword;
-		private System.Windows.Forms.Button btnOK;
-		private System.Windows.Forms.Button btnCancel;
-		private System.Windows.Forms.CheckBox chkAutoConnect;
-		private System.Windows.Forms.CheckBox chkSavePassword;
-		private System.Windows.Forms.ToolTip toolTip;
-		private System.ComponentModel.IContainer components;
-		private PreferedSiteList m_sitelist = new PreferedSiteList();
-		private System.Windows.Forms.Label label5;
-		private System.Windows.Forms.ComboBox cmbLanguage;
-        private List<System.Globalization.CultureInfo> m_supportedLanguages = new List<System.Globalization.CultureInfo>();
+        private PreferedSiteList _siteList;
 
-		public FormLogin()
-		{
-			//
-			// Required for Windows Form Designer support
-			//
-			InitializeComponent();
+        private HttpLoginCtrl _http;
+        private LocalNativeLoginCtrl _local;
 
-            m_supportedLanguages.Add(System.Globalization.CultureInfo.GetCultureInfo("en-US"));
+        public FormLogin()
+        {
+            InitializeComponent();
+            _http = new HttpLoginCtrl() { Dock = DockStyle.Fill };
+            _local = new LocalNativeLoginCtrl() { Dock = DockStyle.Fill };
+            _controls = new ILoginCtrl[] 
+            {
+                _http,
+                _local
+            };
+            _controls[0].EnableOk += OnEnableOk;
+            _controls[1].EnableOk += OnEnableOk;
+            _controls[0].CheckSavedPassword += (sender, e) => { chkSavePassword.Checked = true; };
+            _controls[1].CheckSavedPassword += (sender, e) => { chkSavePassword.Checked = true; };
+            _controls[0].DisabledOk += OnDisableOk;
+            _controls[1].DisabledOk += OnDisableOk;
+        }
 
-            System.Text.RegularExpressions.Regex cix = new System.Text.RegularExpressions.Regex("[A-z][A-z](\\-[A-z][A-z])?");
+        public string Username
+        {
+            get { return _controls[_selectedIndex].Username; }
+        }
 
-            foreach (string f in System.IO.Directory.GetDirectories(Application.StartupPath))
-                if (cix.Match(System.IO.Path.GetFileName(f)).Length == System.IO.Path.GetFileName(f).Length)
-                    try
-                    {
-                        m_supportedLanguages.Add(System.Globalization.CultureInfo.GetCultureInfo(System.IO.Path.GetFileName(f)));
-                    }
-                    catch { }
+        public string Password
+        {
+            get { return _controls[_selectedIndex].Password; }
+        }
 
-            cmbLanguage.Items.Clear();
-            foreach (System.Globalization.CultureInfo ci in m_supportedLanguages)
-                cmbLanguage.Items.Add(ci.DisplayName);
+        protected override void OnLoad(EventArgs e)
+        {
+            _siteList = PreferedSiteList.Load();
 
-            try
+            if (_siteList.Sites.Length == 0)
             {
-                for (int i = 0; i < m_supportedLanguages.Count; i++)
-                    if (string.Compare(m_supportedLanguages[i].Name, System.Threading.Thread.CurrentThread.CurrentUICulture.Name, true) == 0)
-                    {
-                        cmbLanguage.SelectedIndex = i;
-                        break;
-                    }
+                _http.Server = "http://localhost/mapguide/mapagent/mapagent.fcgi";
+                _http.StartingPoint = "Library://";
+                _http.Username = "Administrator";
+                _http.Password = "admin";
+                chkSavePassword.Checked = true;
+                //chkAutoConnect.Checked = false;
             }
-            catch { }
+            else
+            {
+                _http.AddSites(_siteList.Sites);
+                //In case the site was removed...
+                try { _http.SetPreferredSite(_siteList.PreferedSite); }
+                catch { }
+                //chkAutoConnect.Checked = _siteList.AutoConnect;
+            }
 
+            _http.SiteList = _siteList;
 
-			if (cmbLanguage.SelectedIndex < 0)
-				cmbLanguage.SelectedIndex = 0;
+            base.OnLoad(e);
+            rdHttp.Checked = true;
+        }
 
+        private void OnEnableOk(object sender, EventArgs e)
+        {
+            btnOK.Enabled = true;
+        }
 
-		}
+        private void OnDisableOk(object sender, EventArgs e)
+        {
+            btnOK.Enabled = false;
+        }
 
-		/// <summary>
-		/// Clean up any resources being used.
-		/// </summary>
-		protected override void Dispose( bool disposing )
-		{
-			if( disposing )
-			{
-				if(components != null)
-				{
-					components.Dispose();
-				}
-			}
-			base.Dispose( disposing );
-		}
+        public ServerConnectionI Connection
+        {
+            get { return _conn; }
+        }
 
-		#region Windows Form Designer generated code
-		/// <summary>
-		/// Required method for Designer support - do not modify
-		/// the contents of this method with the code editor.
-		/// </summary>
-		private void InitializeComponent()
-		{
-            this.components = new System.ComponentModel.Container();
-            System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FormLogin));
-            this.label1 = new System.Windows.Forms.Label();
-            this.cmbServerUrl = new System.Windows.Forms.ComboBox();
-            this.label2 = new System.Windows.Forms.Label();
-            this.txtStartingpoint = new System.Windows.Forms.TextBox();
-            this.label3 = new System.Windows.Forms.Label();
-            this.label4 = new System.Windows.Forms.Label();
-            this.txtUsername = new System.Windows.Forms.TextBox();
-            this.txtPassword = new System.Windows.Forms.TextBox();
-            this.btnOK = new System.Windows.Forms.Button();
-            this.btnCancel = new System.Windows.Forms.Button();
-            this.chkAutoConnect = new System.Windows.Forms.CheckBox();
-            this.chkSavePassword = new System.Windows.Forms.CheckBox();
-            this.toolTip = new System.Windows.Forms.ToolTip(this.components);
-            this.cmbLanguage = new System.Windows.Forms.ComboBox();
-            this.label5 = new System.Windows.Forms.Label();
-            this.SuspendLayout();
-            // 
-            // label1
-            // 
-            this.label1.FlatStyle = System.Windows.Forms.FlatStyle.System;
-            resources.ApplyResources(this.label1, "label1");
-            this.label1.Name = "label1";
-            // 
-            // cmbServerUrl
-            // 
-            resources.ApplyResources(this.cmbServerUrl, "cmbServerUrl");
-            this.cmbServerUrl.Name = "cmbServerUrl";
-            this.toolTip.SetToolTip(this.cmbServerUrl, resources.GetString("cmbServerUrl.ToolTip"));
-            this.cmbServerUrl.SelectedIndexChanged += new System.EventHandler(this.cmbServerUrl_SelectedIndexChanged);
-            this.cmbServerUrl.TextChanged += new System.EventHandler(this.txtPassword_TextChanged);
-            // 
-            // label2
-            // 
-            resources.ApplyResources(this.label2, "label2");
-            this.label2.FlatStyle = System.Windows.Forms.FlatStyle.System;
-            this.label2.Name = "label2";
-            // 
-            // txtStartingpoint
-            // 
-            resources.ApplyResources(this.txtStartingpoint, "txtStartingpoint");
-            this.txtStartingpoint.Name = "txtStartingpoint";
-            this.toolTip.SetToolTip(this.txtStartingpoint, resources.GetString("txtStartingpoint.ToolTip"));
-            // 
-            // label3
-            // 
-            this.label3.FlatStyle = System.Windows.Forms.FlatStyle.System;
-            resources.ApplyResources(this.label3, "label3");
-            this.label3.Name = "label3";
-            // 
-            // label4
-            // 
-            this.label4.FlatStyle = System.Windows.Forms.FlatStyle.System;
-            resources.ApplyResources(this.label4, "label4");
-            this.label4.Name = "label4";
-            // 
-            // txtUsername
-            // 
-            resources.ApplyResources(this.txtUsername, "txtUsername");
-            this.txtUsername.Name = "txtUsername";
-            this.toolTip.SetToolTip(this.txtUsername, resources.GetString("txtUsername.ToolTip"));
-            this.txtUsername.TextChanged += new System.EventHandler(this.txtPassword_TextChanged);
-            // 
-            // txtPassword
-            // 
-            resources.ApplyResources(this.txtPassword, "txtPassword");
-            this.txtPassword.Name = "txtPassword";
-            this.toolTip.SetToolTip(this.txtPassword, resources.GetString("txtPassword.ToolTip"));
-            this.txtPassword.TextChanged += new System.EventHandler(this.txtPassword_TextChanged);
-            // 
-            // btnOK
-            // 
-            resources.ApplyResources(this.btnOK, "btnOK");
-            this.btnOK.Name = "btnOK";
-            this.btnOK.Click += new System.EventHandler(this.btnOK_Click);
-            // 
-            // btnCancel
-            // 
-            this.btnCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
-            resources.ApplyResources(this.btnCancel, "btnCancel");
-            this.btnCancel.Name = "btnCancel";
-            this.btnCancel.Click += new System.EventHandler(this.btnCancel_Click);
-            // 
-            // chkAutoConnect
-            // 
-            resources.ApplyResources(this.chkAutoConnect, "chkAutoConnect");
-            this.chkAutoConnect.Name = "chkAutoConnect";
-            this.toolTip.SetToolTip(this.chkAutoConnect, resources.GetString("chkAutoConnect.ToolTip"));
-            this.chkAutoConnect.CheckedChanged += new System.EventHandler(this.chkAutoConnect_CheckedChanged);
-            // 
-            // chkSavePassword
-            // 
-            resources.ApplyResources(this.chkSavePassword, "chkSavePassword");
-            this.chkSavePassword.Name = "chkSavePassword";
-            this.toolTip.SetToolTip(this.chkSavePassword, resources.GetString("chkSavePassword.ToolTip"));
-            // 
-            // cmbLanguage
-            // 
-            this.cmbLanguage.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
-            resources.ApplyResources(this.cmbLanguage, "cmbLanguage");
-            this.cmbLanguage.Name = "cmbLanguage";
-            this.toolTip.SetToolTip(this.cmbLanguage, resources.GetString("cmbLanguage.ToolTip"));
-            this.cmbLanguage.SelectedIndexChanged += new System.EventHandler(this.cmbLanguage_SelectedIndexChanged);
-            // 
-            // label5
-            // 
-            this.label5.FlatStyle = System.Windows.Forms.FlatStyle.System;
-            resources.ApplyResources(this.label5, "label5");
-            this.label5.Name = "label5";
-            // 
-            // FormLogin
-            // 
-            this.AcceptButton = this.btnOK;
-            resources.ApplyResources(this, "$this");
-            this.CancelButton = this.btnCancel;
-            this.Controls.Add(this.cmbLanguage);
-            this.Controls.Add(this.label5);
-            this.Controls.Add(this.chkSavePassword);
-            this.Controls.Add(this.chkAutoConnect);
-            this.Controls.Add(this.btnCancel);
-            this.Controls.Add(this.btnOK);
-            this.Controls.Add(this.txtPassword);
-            this.Controls.Add(this.txtUsername);
-            this.Controls.Add(this.txtStartingpoint);
-            this.Controls.Add(this.label4);
-            this.Controls.Add(this.label3);
-            this.Controls.Add(this.label2);
-            this.Controls.Add(this.cmbServerUrl);
-            this.Controls.Add(this.label1);
-            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
-            this.MaximizeBox = false;
-            this.MinimizeBox = false;
-            this.Name = "FormLogin";
-            this.Load += new System.EventHandler(this.FormLogin_Load);
-            this.ResumeLayout(false);
-            this.PerformLayout();
+        public void SetLoginControl(Control c)
+        {
+            loginPanel.Controls.Clear();
+            loginPanel.Controls.Add(c);
+        }
 
-		}
-		#endregion
+        private void rdHttp_CheckedChanged(object sender, EventArgs e)
+        {
+            _selectedIndex = 0;
+            SetLoginControl((Control)_controls[_selectedIndex]);
+        }
 
-		private void btnCancel_Click(object sender, System.EventArgs e)
-		{
-			this.DialogResult = DialogResult.Cancel;
-			this.Close();
-		}
+        private void rdTcpIp_CheckedChanged(object sender, EventArgs e)
+        {
+            _selectedIndex = 1;
+            SetLoginControl((Control)_controls[_selectedIndex]);
+        }
 
-		private void btnOK_Click(object sender, System.EventArgs e)
-		{
-			using(new WaitCursor(this))
-			{
-				try
+        private void btnCancel_Click(object sender, EventArgs e)
+        {
+
+        }
+
+        private void btnOK_Click(object sender, EventArgs e)
+        {
+            using (new WaitCursor(this))
+            {
+                try
 				{
-					PreferedSite ps = null;
-					int index = 0;
-					foreach(PreferedSite s in cmbServerUrl.Items)
-						if (s.SiteURL == cmbServerUrl.Text)
-						{
-							ps = s;
-							break;
-						}
-						else
-							index++;
+                    PreferedSite ps = null;
 
-					if (ps == null)
-						ps = new PreferedSite();
+                    if (_selectedIndex == 0) //HTTP
+                    {
+                        _conn = ConnectionFactory.CreateHttpConnection(new Uri(_http.Server), _http.Username, _http.Password, _http.Language, true);
+                        (_conn as HttpServerConnection).UserAgent = "MapGuide Maestro v" + System.Reflection.Assembly.GetExecutingAssembly().GetName().Version.ToString();
 
-					if (ps.ApprovedVersion == null)
-						ps.ApprovedVersion = new Version(0,0,0,0);
+                        //Update preferred site entry if it exists
+                        int index = 0;
+                        foreach (PreferedSite s in _http.GetSites())
+                        {
+                            if (s.SiteURL == _http.Server)
+                            {
+                                ps = s;
+                                break;
+                            }
+                            else
+                                index++;
+                        }
 
-#if TEST_NATIVE
-					OSGeo.MapGuide.MaestroAPI.ServerConnectionI con;
-					if (new Uri(cmbServerUrl.Text).Host.ToLower() == "localhost")
-						con = new OSGeo.MapGuide.MaestroAPI.LocalNativeConnection(@"C:\Programmer\MapGuideOpenSource2.0\WebServerExtensions\www\webconfig.ini", txtUsername.Text, txtPassword.Text, System.Globalization.CultureInfo.CurrentCulture.TwoLetterISOLanguageName);
-					else
-						con = new OSGeo.MapGuide.MaestroAPI.HttpServerConnection(new Uri(cmbServerUrl.Text), txtUsername.Text, txtPassword.Text, System.Globalization.CultureInfo.CurrentCulture.TwoLetterISOLanguageName, true);
-#else
-					OSGeo.MapGuide.MaestroAPI.ServerConnectionI con = OSGeo.MapGuide.MaestroAPI.ConnectionFactory.CreateHttpConnection(new Uri(cmbServerUrl.Text), txtUsername.Text, txtPassword.Text, System.Globalization.CultureInfo.CurrentCulture.TwoLetterISOLanguageName, true);
-                    ((OSGeo.MapGuide.MaestroAPI.HttpServerConnection)con).UserAgent = "MapGuide Maestro v" + System.Reflection.Assembly.GetExecutingAssembly().GetName().Version.ToString();
-#endif
-					if (con.SiteVersion > con.MaxTestedVersion && con.SiteVersion > ps.ApprovedVersion)
-					{
-						if (MessageBox.Show(this, Strings.FormLogin.UntestedServerVersion, Application.ProductName, MessageBoxButtons.YesNoCancel, MessageBoxIcon.Warning) != DialogResult.Yes)
-							return;
-					}
+                        if (ps == null)
+                            ps = new PreferedSite();
 
-					m_connection = con;
-					m_connection.AutoRestartSession = true;
-					
-					try
-					{
-						ps.SiteURL = cmbServerUrl.Text;
-						ps.StartingPoint = txtStartingpoint.Text;
-						ps.Username = txtUsername.Text;
-						ps.SavePassword = chkSavePassword.Checked;
-						ps.ApprovedVersion = ps.ApprovedVersion > con.SiteVersion ? ps.ApprovedVersion : con.SiteVersion;
-						if (ps.SavePassword)
-							ps.UnscrambledPassword = txtPassword.Text;
-						else
-							ps.ScrambledPassword = "";
+                        if (ps.ApprovedVersion == null)
+                            ps.ApprovedVersion = new Version(0, 0, 0, 0);
 
-						if (index >= m_sitelist.Sites.Length)
-							m_sitelist.AddSite(ps);
+                        if (_conn.SiteVersion > _conn.MaxTestedVersion && _conn.SiteVersion > ps.ApprovedVersion)
+                        {
+                            if (MessageBox.Show(this, Strings.FormLogin.UntestedServerVersion, Application.ProductName, MessageBoxButtons.YesNoCancel, MessageBoxIcon.Warning) != DialogResult.Yes)
+                                return;
+                        }
 
-						m_sitelist.AutoConnect = chkAutoConnect.Checked;
-						m_sitelist.PreferedSite = index;
-                        m_sitelist.GUILanguage = m_supportedLanguages[cmbLanguage.SelectedIndex].Name;
+                        try
+                        {
+                            ps.SiteURL = _http.Server;
+                            ps.StartingPoint = _http.StartingPoint;
+                            ps.Username = _http.Username;
+                            ps.SavePassword = chkSavePassword.Checked;
+                            ps.ApprovedVersion = ps.ApprovedVersion > _conn.SiteVersion ? ps.ApprovedVersion : _conn.SiteVersion;
+                            if (ps.SavePassword)
+                                ps.UnscrambledPassword = _http.Password;
+                            else
+                                ps.ScrambledPassword = "";
 
-                        m_sitelist.Save();
-					}
-					catch (Exception ex)
-					{
-						string s = ex.Message;
-					}
+                            if (index >= _siteList.Sites.Length)
+                                _siteList.AddSite(ps);
+
+                            //_siteList.AutoConnect = chkAutoConnect.Checked;
+                            _siteList.PreferedSite = index;
+                            _siteList.GUILanguage = _http.Language;
+
+                            _siteList.Save();
+                        }
+                        catch (Exception ex)
+                        {
+                            string s = ex.Message;
+                        }
+                    }
+                    else //Native
+                    {
+                        _conn = ConnectionFactory.CreateLocalNativeConnection(_local.WebConfigPath, _local.Username, _local.Password, System.Globalization.CultureInfo.CurrentCulture.TwoLetterISOLanguageName);
+                    }
+
+                    _conn.AutoRestartSession = true;
+
+                    
 					
 					this.DialogResult = DialogResult.OK;
 					this.Close();
@@ -339,100 +214,7 @@
 				{
 					MessageBox.Show(this, string.Format(Strings.FormLogin.ConnectionFailedError, ex.Message), Application.ProductName, MessageBoxButtons.OK, MessageBoxIcon.Error);
 				}
-			}
-		}
-
-		private void FormLogin_Load(object sender, System.EventArgs e)
-		{
-            m_sitelist = PreferedSiteList.Load();
-
-            if (m_sitelist.Sites.Length == 0)
-			{
-				cmbServerUrl.Text = "http://localhost/mapguide/mapagent/mapagent.fcgi";
-				txtStartingpoint.Text = "Library://";
-				txtUsername.Text = "Administrator";
-				txtPassword.Text = "admin";
-				chkSavePassword.Checked = true;
-				chkAutoConnect.Checked = false;
-			}
-			else
-			{
-				cmbServerUrl.Items.AddRange(m_sitelist.Sites);
-                //In case the site was removed...
-                try { cmbServerUrl.SelectedIndex = m_sitelist.PreferedSite; }
-                catch { } 
-				chkAutoConnect.Checked = m_sitelist.AutoConnect;
-			}
-
-            txtPassword_TextChanged(null, null);
-
-			//TODO: Enable the Starting Point, once the functionality is created
-			if (m_useAutoConnect && chkAutoConnect.Checked)
-			{
-				this.Refresh();
-				btnOK.PerformClick();
-			}
-		}
-
-		private void chkAutoConnect_CheckedChanged(object sender, System.EventArgs e)
-		{
-		
-		}
-
-		private void cmbServerUrl_SelectedIndexChanged(object sender, System.EventArgs e)
-		{
-			PreferedSite site = cmbServerUrl.SelectedItem as PreferedSite;
-			if (site == null)
-				return;
-
-			txtStartingpoint.Text = site.StartingPoint;
-			txtUsername.Text = site.Username;
-			if (site.SavePassword)
-				txtPassword.Text = site.UnscrambledPassword;
-			else
-				txtPassword.Text = "";
-			chkSavePassword.Checked = site.SavePassword;
-		}
-
-		private void cmbLanguage_SelectedIndexChanged(object sender, System.EventArgs e)
-		{
-            if (cmbLanguage.SelectedIndex >= 0 && cmbLanguage.SelectedIndex < m_supportedLanguages.Count)
-            {
-                //System.Threading.Thread.CurrentThread.CurrentCulture = m_supportedLanguages[cmbLanguage.SelectedIndex];
-                //System.Threading.Thread.CurrentThread.CurrentUICulture = m_supportedLanguages[cmbLanguage.SelectedIndex];
-
-                if (this.Visible)
-                {
-                    try
-                    {
-                        m_sitelist.GUILanguage = m_supportedLanguages[cmbLanguage.SelectedIndex].Name;
-                        m_sitelist.Save();
-                    }
-                    catch { }
-
-                    MessageBox.Show(this, Strings.FormLogin.RestartForLanguageChange, Application.ProductName, MessageBoxButtons.OK, MessageBoxIcon.Information);
-                }
             }
-		}
-
-		public OSGeo.MapGuide.MaestroAPI.ServerConnectionI Connection
-		{
-			get { return m_connection; }
-		}
-
-		public bool UseAutoConnect
-		{
-			get { return m_useAutoConnect; }
-			set { m_useAutoConnect = value; }
-		}
-
-        private void txtPassword_TextChanged(object sender, EventArgs e)
-        {
-            btnOK.Enabled = cmbServerUrl.Text.Length > 0 && txtUsername.Text.Length > 0;
         }
-
-        public string Username { get { return txtUsername.Text; } }
-
-        public string Password { get { return txtPassword.Text; } }
-	}
+    }
 }

Modified: trunk/Tools/Maestro/Maestro/LoginForm/FormLogin.resx
===================================================================
--- trunk/Tools/Maestro/Maestro/LoginForm/FormLogin.resx	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/LoginForm/FormLogin.resx	2010-05-04 07:51:41 UTC (rev 4826)
@@ -117,418 +117,4 @@
   <resheader name="writer">
     <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
   </resheader>
-  <assembly alias="System.Drawing" name="System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
-  <data name="label1.Location" type="System.Drawing.Point, System.Drawing">
-    <value>16, 16</value>
-  </data>
-  <data name="label1.Size" type="System.Drawing.Size, System.Drawing">
-    <value>64, 16</value>
-  </data>
-  <assembly alias="mscorlib" name="mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
-  <data name="label1.TabIndex" type="System.Int32, mscorlib">
-    <value>0</value>
-  </data>
-  <data name="label1.Text" xml:space="preserve">
-    <value>Server:</value>
-  </data>
-  <data name="&gt;&gt;label1.Name" xml:space="preserve">
-    <value>label1</value>
-  </data>
-  <data name="&gt;&gt;label1.Type" xml:space="preserve">
-    <value>System.Windows.Forms.Label, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
-  </data>
-  <data name="&gt;&gt;label1.Parent" xml:space="preserve">
-    <value>$this</value>
-  </data>
-  <data name="&gt;&gt;label1.ZOrder" xml:space="preserve">
-    <value>13</value>
-  </data>
-  <metadata name="toolTip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
-    <value>17, 17</value>
-  </metadata>
-  <data name="cmbServerUrl.Location" type="System.Drawing.Point, System.Drawing">
-    <value>96, 16</value>
-  </data>
-  <data name="cmbServerUrl.Size" type="System.Drawing.Size, System.Drawing">
-    <value>288, 21</value>
-  </data>
-  <data name="cmbServerUrl.TabIndex" type="System.Int32, mscorlib">
-    <value>1</value>
-  </data>
-  <data name="cmbServerUrl.Text" xml:space="preserve">
-    <value>http://localhost/mapguide/mapagent/mapagent.fcgi</value>
-  </data>
-  <data name="cmbServerUrl.ToolTip" xml:space="preserve">
-    <value>Enter the full URL of the MapAgent service here</value>
-  </data>
-  <data name="&gt;&gt;cmbServerUrl.Name" xml:space="preserve">
-    <value>cmbServerUrl</value>
-  </data>
-  <data name="&gt;&gt;cmbServerUrl.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="&gt;&gt;cmbServerUrl.Parent" xml:space="preserve">
-    <value>$this</value>
-  </data>
-  <data name="&gt;&gt;cmbServerUrl.ZOrder" xml:space="preserve">
-    <value>12</value>
-  </data>
-  <data name="label2.Enabled" type="System.Boolean, mscorlib">
-    <value>False</value>
-  </data>
-  <data name="label2.Location" type="System.Drawing.Point, System.Drawing">
-    <value>16, 48</value>
-  </data>
-  <data name="label2.Size" type="System.Drawing.Size, System.Drawing">
-    <value>72, 16</value>
-  </data>
-  <data name="label2.TabIndex" type="System.Int32, mscorlib">
-    <value>2</value>
-  </data>
-  <data name="label2.Text" xml:space="preserve">
-    <value>Startingpoint</value>
-  </data>
-  <data name="&gt;&gt;label2.Name" xml:space="preserve">
-    <value>label2</value>
-  </data>
-  <data name="&gt;&gt;label2.Type" xml:space="preserve">
-    <value>System.Windows.Forms.Label, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
-  </data>
-  <data name="&gt;&gt;label2.Parent" xml:space="preserve">
-    <value>$this</value>
-  </data>
-  <data name="&gt;&gt;label2.ZOrder" xml:space="preserve">
-    <value>11</value>
-  </data>
-  <data name="txtStartingpoint.Enabled" type="System.Boolean, mscorlib">
-    <value>False</value>
-  </data>
-  <data name="txtStartingpoint.Location" type="System.Drawing.Point, System.Drawing">
-    <value>96, 48</value>
-  </data>
-  <data name="txtStartingpoint.Size" type="System.Drawing.Size, System.Drawing">
-    <value>288, 20</value>
-  </data>
-  <data name="txtStartingpoint.TabIndex" type="System.Int32, mscorlib">
-    <value>3</value>
-  </data>
-  <data name="txtStartingpoint.Text" xml:space="preserve">
-    <value>Library://</value>
-  </data>
-  <data name="txtStartingpoint.ToolTip" xml:space="preserve">
-    <value>Enter the initial directory here</value>
-  </data>
-  <data name="&gt;&gt;txtStartingpoint.Name" xml:space="preserve">
-    <value>txtStartingpoint</value>
-  </data>
-  <data name="&gt;&gt;txtStartingpoint.Type" xml:space="preserve">
-    <value>System.Windows.Forms.TextBox, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
-  </data>
-  <data name="&gt;&gt;txtStartingpoint.Parent" xml:space="preserve">
-    <value>$this</value>
-  </data>
-  <data name="&gt;&gt;txtStartingpoint.ZOrder" xml:space="preserve">
-    <value>8</value>
-  </data>
-  <data name="label3.Location" type="System.Drawing.Point, System.Drawing">
-    <value>16, 80</value>
-  </data>
-  <data name="label3.Size" type="System.Drawing.Size, System.Drawing">
-    <value>80, 16</value>
-  </data>
-  <data name="label3.TabIndex" type="System.Int32, mscorlib">
-    <value>4</value>
-  </data>
-  <data name="label3.Text" xml:space="preserve">
-    <value>Username</value>
-  </data>
-  <data name="&gt;&gt;label3.Name" xml:space="preserve">
-    <value>label3</value>
-  </data>
-  <data name="&gt;&gt;label3.Type" xml:space="preserve">
-    <value>System.Windows.Forms.Label, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
-  </data>
-  <data name="&gt;&gt;label3.Parent" xml:space="preserve">
-    <value>$this</value>
-  </data>
-  <data name="&gt;&gt;label3.ZOrder" xml:space="preserve">
-    <value>10</value>
-  </data>
-  <data name="label4.Location" type="System.Drawing.Point, System.Drawing">
-    <value>16, 112</value>
-  </data>
-  <data name="label4.Size" type="System.Drawing.Size, System.Drawing">
-    <value>80, 16</value>
-  </data>
-  <data name="label4.TabIndex" type="System.Int32, mscorlib">
-    <value>5</value>
-  </data>
-  <data name="label4.Text" xml:space="preserve">
-    <value>Password</value>
-  </data>
-  <data name="&gt;&gt;label4.Name" xml:space="preserve">
-    <value>label4</value>
-  </data>
-  <data name="&gt;&gt;label4.Type" xml:space="preserve">
-    <value>System.Windows.Forms.Label, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
-  </data>
-  <data name="&gt;&gt;label4.Parent" xml:space="preserve">
-    <value>$this</value>
-  </data>
-  <data name="&gt;&gt;label4.ZOrder" xml:space="preserve">
-    <value>9</value>
-  </data>
-  <data name="txtUsername.Location" type="System.Drawing.Point, System.Drawing">
-    <value>96, 80</value>
-  </data>
-  <data name="txtUsername.Size" type="System.Drawing.Size, System.Drawing">
-    <value>288, 20</value>
-  </data>
-  <data name="txtUsername.TabIndex" type="System.Int32, mscorlib">
-    <value>6</value>
-  </data>
-  <data name="txtUsername.Text" xml:space="preserve">
-    <value>Administrator</value>
-  </data>
-  <data name="txtUsername.ToolTip" xml:space="preserve">
-    <value>Enter the username used for login here</value>
-  </data>
-  <data name="&gt;&gt;txtUsername.Name" xml:space="preserve">
-    <value>txtUsername</value>
-  </data>
-  <data name="&gt;&gt;txtUsername.Type" xml:space="preserve">
-    <value>System.Windows.Forms.TextBox, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
-  </data>
-  <data name="&gt;&gt;txtUsername.Parent" xml:space="preserve">
-    <value>$this</value>
-  </data>
-  <data name="&gt;&gt;txtUsername.ZOrder" xml:space="preserve">
-    <value>7</value>
-  </data>
-  <data name="txtPassword.Location" type="System.Drawing.Point, System.Drawing">
-    <value>96, 112</value>
-  </data>
-  <data name="txtPassword.PasswordChar" type="System.Char, mscorlib" xml:space="preserve">
-    <value>*</value>
-  </data>
-  <data name="txtPassword.Size" type="System.Drawing.Size, System.Drawing">
-    <value>288, 20</value>
-  </data>
-  <data name="txtPassword.TabIndex" type="System.Int32, mscorlib">
-    <value>7</value>
-  </data>
-  <data name="txtPassword.Text" xml:space="preserve">
-    <value>admin</value>
-  </data>
-  <data name="txtPassword.ToolTip" xml:space="preserve">
-    <value>Enter the site password here</value>
-  </data>
-  <data name="&gt;&gt;txtPassword.Name" xml:space="preserve">
-    <value>txtPassword</value>
-  </data>
-  <data name="&gt;&gt;txtPassword.Type" xml:space="preserve">
-    <value>System.Windows.Forms.TextBox, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
-  </data>
-  <data name="&gt;&gt;txtPassword.Parent" xml:space="preserve">
-    <value>$this</value>
-  </data>
-  <data name="&gt;&gt;txtPassword.ZOrder" xml:space="preserve">
-    <value>6</value>
-  </data>
-  <data name="btnOK.Enabled" type="System.Boolean, mscorlib">
-    <value>False</value>
-  </data>
-  <assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
-  <data name="btnOK.FlatStyle" type="System.Windows.Forms.FlatStyle, System.Windows.Forms">
-    <value>System</value>
-  </data>
-  <data name="btnOK.Location" type="System.Drawing.Point, System.Drawing">
-    <value>96, 232</value>
-  </data>
-  <data name="btnOK.Size" type="System.Drawing.Size, System.Drawing">
-    <value>96, 32</value>
-  </data>
-  <data name="btnOK.TabIndex" type="System.Int32, mscorlib">
-    <value>8</value>
-  </data>
-  <data name="btnOK.Text" xml:space="preserve">
-    <value>OK</value>
-  </data>
-  <data name="&gt;&gt;btnOK.Name" xml:space="preserve">
-    <value>btnOK</value>
-  </data>
-  <data name="&gt;&gt;btnOK.Type" xml:space="preserve">
-    <value>System.Windows.Forms.Button, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
-  </data>
-  <data name="&gt;&gt;btnOK.Parent" xml:space="preserve">
-    <value>$this</value>
-  </data>
-  <data name="&gt;&gt;btnOK.ZOrder" xml:space="preserve">
-    <value>5</value>
-  </data>
-  <data name="btnCancel.FlatStyle" type="System.Windows.Forms.FlatStyle, System.Windows.Forms">
-    <value>System</value>
-  </data>
-  <data name="btnCancel.Location" type="System.Drawing.Point, System.Drawing">
-    <value>208, 232</value>
-  </data>
-  <data name="btnCancel.Size" type="System.Drawing.Size, System.Drawing">
-    <value>96, 32</value>
-  </data>
-  <data name="btnCancel.TabIndex" type="System.Int32, mscorlib">
-    <value>9</value>
-  </data>
-  <data name="btnCancel.Text" xml:space="preserve">
-    <value>Cancel</value>
-  </data>
-  <data name="&gt;&gt;btnCancel.Name" xml:space="preserve">
-    <value>btnCancel</value>
-  </data>
-  <data name="&gt;&gt;btnCancel.Type" xml:space="preserve">
-    <value>System.Windows.Forms.Button, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
-  </data>
-  <data name="&gt;&gt;btnCancel.Parent" xml:space="preserve">
-    <value>$this</value>
-  </data>
-  <data name="&gt;&gt;btnCancel.ZOrder" xml:space="preserve">
-    <value>4</value>
-  </data>
-  <data name="chkAutoConnect.Enabled" type="System.Boolean, mscorlib">
-    <value>False</value>
-  </data>
-  <data name="chkAutoConnect.FlatStyle" type="System.Windows.Forms.FlatStyle, System.Windows.Forms">
-    <value>System</value>
-  </data>
-  <data name="chkAutoConnect.Location" type="System.Drawing.Point, System.Drawing">
-    <value>96, 200</value>
-  </data>
-  <data name="chkAutoConnect.Size" type="System.Drawing.Size, System.Drawing">
-    <value>288, 16</value>
-  </data>
-  <data name="chkAutoConnect.TabIndex" type="System.Int32, mscorlib">
-    <value>10</value>
-  </data>
-  <data name="chkAutoConnect.Text" xml:space="preserve">
-    <value>Log in automatically</value>
-  </data>
-  <data name="chkAutoConnect.ToolTip" xml:space="preserve">
-    <value>Check this box to have Maestro log in to this site on startup automatically.</value>
-  </data>
-  <data name="&gt;&gt;chkAutoConnect.Name" xml:space="preserve">
-    <value>chkAutoConnect</value>
-  </data>
-  <data name="&gt;&gt;chkAutoConnect.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="&gt;&gt;chkAutoConnect.Parent" xml:space="preserve">
-    <value>$this</value>
-  </data>
-  <data name="&gt;&gt;chkAutoConnect.ZOrder" xml:space="preserve">
-    <value>3</value>
-  </data>
-  <data name="chkSavePassword.FlatStyle" type="System.Windows.Forms.FlatStyle, System.Windows.Forms">
-    <value>System</value>
-  </data>
-  <data name="chkSavePassword.Location" type="System.Drawing.Point, System.Drawing">
-    <value>96, 176</value>
-  </data>
-  <data name="chkSavePassword.Size" type="System.Drawing.Size, System.Drawing">
-    <value>288, 16</value>
-  </data>
-  <data name="chkSavePassword.TabIndex" type="System.Int32, mscorlib">
-    <value>11</value>
-  </data>
-  <data name="chkSavePassword.Text" xml:space="preserve">
-    <value>Save password on computer</value>
-  </data>
-  <data name="chkSavePassword.ToolTip" xml:space="preserve">
-    <value>If checked, a scrambled version of the password is stored on the computer. Please not that the password is NOT encrypted and may be read by a third party. Storing the password on the computer is considered unsafe, but increases convinience.</value>
-  </data>
-  <data name="&gt;&gt;chkSavePassword.Name" xml:space="preserve">
-    <value>chkSavePassword</value>
-  </data>
-  <data name="&gt;&gt;chkSavePassword.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="&gt;&gt;chkSavePassword.Parent" xml:space="preserve">
-    <value>$this</value>
-  </data>
-  <data name="&gt;&gt;chkSavePassword.ZOrder" xml:space="preserve">
-    <value>2</value>
-  </data>
-  <metadata name="toolTip.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
-    <value>17, 17</value>
-  </metadata>
-  <data name="cmbLanguage.Location" type="System.Drawing.Point, System.Drawing">
-    <value>96, 144</value>
-  </data>
-  <data name="cmbLanguage.Size" type="System.Drawing.Size, System.Drawing">
-    <value>288, 21</value>
-  </data>
-  <data name="cmbLanguage.TabIndex" type="System.Int32, mscorlib">
-    <value>13</value>
-  </data>
-  <data name="cmbLanguage.ToolTip" xml:space="preserve">
-    <value>Select your prefered language here</value>
-  </data>
-  <data name="&gt;&gt;cmbLanguage.Name" xml:space="preserve">
-    <value>cmbLanguage</value>
-  </data>
-  <data name="&gt;&gt;cmbLanguage.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="&gt;&gt;cmbLanguage.Parent" xml:space="preserve">
-    <value>$this</value>
-  </data>
-  <data name="&gt;&gt;cmbLanguage.ZOrder" xml:space="preserve">
-    <value>0</value>
-  </data>
-  <data name="label5.Location" type="System.Drawing.Point, System.Drawing">
-    <value>16, 144</value>
-  </data>
-  <data name="label5.Size" type="System.Drawing.Size, System.Drawing">
-    <value>64, 16</value>
-  </data>
-  <data name="label5.TabIndex" type="System.Int32, mscorlib">
-    <value>12</value>
-  </data>
-  <data name="label5.Text" xml:space="preserve">
-    <value>Language</value>
-  </data>
-  <data name="&gt;&gt;label5.Name" xml:space="preserve">
-    <value>label5</value>
-  </data>
-  <data name="&gt;&gt;label5.Type" xml:space="preserve">
-    <value>System.Windows.Forms.Label, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
-  </data>
-  <data name="&gt;&gt;label5.Parent" xml:space="preserve">
-    <value>$this</value>
-  </data>
-  <data name="&gt;&gt;label5.ZOrder" xml:space="preserve">
-    <value>1</value>
-  </data>
-  <metadata name="$this.Localizable" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <data name="$this.AutoScaleBaseSize" type="System.Drawing.Size, System.Drawing">
-    <value>5, 13</value>
-  </data>
-  <data name="$this.ClientSize" type="System.Drawing.Size, System.Drawing">
-    <value>408, 287</value>
-  </data>
-  <data name="$this.Text" xml:space="preserve">
-    <value>Log on to a MapGuide Server</value>
-  </data>
-  <data name="&gt;&gt;toolTip.Name" xml:space="preserve">
-    <value>toolTip</value>
-  </data>
-  <data name="&gt;&gt;toolTip.Type" xml:space="preserve">
-    <value>System.Windows.Forms.ToolTip, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
-  </data>
-  <data name="&gt;&gt;$this.Name" xml:space="preserve">
-    <value>FormLogin</value>
-  </data>
-  <data name="&gt;&gt;$this.Type" xml:space="preserve">
-    <value>System.Windows.Forms.Form, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
-  </data>
 </root>
\ No newline at end of file

Added: trunk/Tools/Maestro/Maestro/LoginForm/HttpLoginCtrl.Designer.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/LoginForm/HttpLoginCtrl.Designer.cs	                        (rev 0)
+++ trunk/Tools/Maestro/Maestro/LoginForm/HttpLoginCtrl.Designer.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -0,0 +1,183 @@
+namespace OSGeo.MapGuide.Maestro
+{
+    partial class HttpLoginCtrl
+    {
+        /// <summary> 
+        /// Required designer variable.
+        /// </summary>
+        private System.ComponentModel.IContainer components = null;
+
+        /// <summary> 
+        /// Clean up any resources being used.
+        /// </summary>
+        /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
+        protected override void Dispose(bool disposing)
+        {
+            if (disposing && (components != null))
+            {
+                components.Dispose();
+            }
+            base.Dispose(disposing);
+        }
+
+        #region Component Designer generated code
+
+        /// <summary> 
+        /// Required method for Designer support - do not modify 
+        /// the contents of this method with the code editor.
+        /// </summary>
+        private void InitializeComponent()
+        {
+            this.cmbLanguage = new System.Windows.Forms.ComboBox();
+            this.label5 = new System.Windows.Forms.Label();
+            this.txtPassword = new System.Windows.Forms.TextBox();
+            this.txtUsername = new System.Windows.Forms.TextBox();
+            this.txtStartingpoint = new System.Windows.Forms.TextBox();
+            this.label4 = new System.Windows.Forms.Label();
+            this.label3 = new System.Windows.Forms.Label();
+            this.label2 = new System.Windows.Forms.Label();
+            this.cmbServerUrl = new System.Windows.Forms.ComboBox();
+            this.label1 = new System.Windows.Forms.Label();
+            this.SuspendLayout();
+            // 
+            // cmbLanguage
+            // 
+            this.cmbLanguage.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
+                        | System.Windows.Forms.AnchorStyles.Right)));
+            this.cmbLanguage.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+            this.cmbLanguage.Location = new System.Drawing.Point(82, 108);
+            this.cmbLanguage.Name = "cmbLanguage";
+            this.cmbLanguage.Size = new System.Drawing.Size(279, 21);
+            this.cmbLanguage.TabIndex = 23;
+            this.cmbLanguage.SelectedIndexChanged += new System.EventHandler(this.cmbLanguage_SelectedIndexChanged);
+            // 
+            // label5
+            // 
+            this.label5.FlatStyle = System.Windows.Forms.FlatStyle.System;
+            this.label5.ImeMode = System.Windows.Forms.ImeMode.NoControl;
+            this.label5.Location = new System.Drawing.Point(2, 108);
+            this.label5.Name = "label5";
+            this.label5.Size = new System.Drawing.Size(64, 16);
+            this.label5.TabIndex = 22;
+            this.label5.Text = "Language";
+            // 
+            // txtPassword
+            // 
+            this.txtPassword.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
+                        | System.Windows.Forms.AnchorStyles.Right)));
+            this.txtPassword.Location = new System.Drawing.Point(82, 82);
+            this.txtPassword.Name = "txtPassword";
+            this.txtPassword.PasswordChar = '*';
+            this.txtPassword.Size = new System.Drawing.Size(279, 20);
+            this.txtPassword.TabIndex = 21;
+            this.txtPassword.Text = "admin";
+            this.txtPassword.TextChanged += new System.EventHandler(this.txtPassword_TextChanged);
+            // 
+            // txtUsername
+            // 
+            this.txtUsername.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
+                        | System.Windows.Forms.AnchorStyles.Right)));
+            this.txtUsername.Location = new System.Drawing.Point(82, 56);
+            this.txtUsername.Name = "txtUsername";
+            this.txtUsername.Size = new System.Drawing.Size(279, 20);
+            this.txtUsername.TabIndex = 20;
+            this.txtUsername.Text = "Administrator";
+            // 
+            // txtStartingpoint
+            // 
+            this.txtStartingpoint.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
+                        | System.Windows.Forms.AnchorStyles.Right)));
+            this.txtStartingpoint.Enabled = false;
+            this.txtStartingpoint.Location = new System.Drawing.Point(82, 30);
+            this.txtStartingpoint.Name = "txtStartingpoint";
+            this.txtStartingpoint.Size = new System.Drawing.Size(279, 20);
+            this.txtStartingpoint.TabIndex = 17;
+            this.txtStartingpoint.Text = "Library://";
+            // 
+            // label4
+            // 
+            this.label4.FlatStyle = System.Windows.Forms.FlatStyle.System;
+            this.label4.ImeMode = System.Windows.Forms.ImeMode.NoControl;
+            this.label4.Location = new System.Drawing.Point(2, 82);
+            this.label4.Name = "label4";
+            this.label4.Size = new System.Drawing.Size(80, 16);
+            this.label4.TabIndex = 19;
+            this.label4.Text = "Password";
+            // 
+            // label3
+            // 
+            this.label3.FlatStyle = System.Windows.Forms.FlatStyle.System;
+            this.label3.ImeMode = System.Windows.Forms.ImeMode.NoControl;
+            this.label3.Location = new System.Drawing.Point(2, 56);
+            this.label3.Name = "label3";
+            this.label3.Size = new System.Drawing.Size(80, 16);
+            this.label3.TabIndex = 18;
+            this.label3.Text = "Username";
+            // 
+            // label2
+            // 
+            this.label2.Enabled = false;
+            this.label2.FlatStyle = System.Windows.Forms.FlatStyle.System;
+            this.label2.ImeMode = System.Windows.Forms.ImeMode.NoControl;
+            this.label2.Location = new System.Drawing.Point(2, 30);
+            this.label2.Name = "label2";
+            this.label2.Size = new System.Drawing.Size(72, 16);
+            this.label2.TabIndex = 16;
+            this.label2.Text = "Startingpoint";
+            // 
+            // cmbServerUrl
+            // 
+            this.cmbServerUrl.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
+                        | System.Windows.Forms.AnchorStyles.Right)));
+            this.cmbServerUrl.Location = new System.Drawing.Point(82, 3);
+            this.cmbServerUrl.Name = "cmbServerUrl";
+            this.cmbServerUrl.Size = new System.Drawing.Size(279, 21);
+            this.cmbServerUrl.TabIndex = 15;
+            this.cmbServerUrl.Text = "http://localhost/mapguide/mapagent/mapagent.fcgi";
+            this.cmbServerUrl.SelectedIndexChanged += new System.EventHandler(this.cmbServerUrl_SelectedIndexChanged);
+            // 
+            // label1
+            // 
+            this.label1.FlatStyle = System.Windows.Forms.FlatStyle.System;
+            this.label1.ImeMode = System.Windows.Forms.ImeMode.NoControl;
+            this.label1.Location = new System.Drawing.Point(2, 3);
+            this.label1.Name = "label1";
+            this.label1.Size = new System.Drawing.Size(64, 16);
+            this.label1.TabIndex = 14;
+            this.label1.Text = "Server:";
+            // 
+            // HttpLoginCtrl
+            // 
+            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
+            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+            this.Controls.Add(this.cmbLanguage);
+            this.Controls.Add(this.label5);
+            this.Controls.Add(this.txtPassword);
+            this.Controls.Add(this.txtUsername);
+            this.Controls.Add(this.txtStartingpoint);
+            this.Controls.Add(this.label4);
+            this.Controls.Add(this.label3);
+            this.Controls.Add(this.label2);
+            this.Controls.Add(this.cmbServerUrl);
+            this.Controls.Add(this.label1);
+            this.Name = "HttpLoginCtrl";
+            this.Size = new System.Drawing.Size(364, 133);
+            this.ResumeLayout(false);
+            this.PerformLayout();
+
+        }
+
+        #endregion
+
+        private System.Windows.Forms.ComboBox cmbLanguage;
+        private System.Windows.Forms.Label label5;
+        private System.Windows.Forms.TextBox txtPassword;
+        private System.Windows.Forms.TextBox txtUsername;
+        private System.Windows.Forms.TextBox txtStartingpoint;
+        private System.Windows.Forms.Label label4;
+        private System.Windows.Forms.Label label3;
+        private System.Windows.Forms.Label label2;
+        private System.Windows.Forms.ComboBox cmbServerUrl;
+        private System.Windows.Forms.Label label1;
+    }
+}

Added: trunk/Tools/Maestro/Maestro/LoginForm/HttpLoginCtrl.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/LoginForm/HttpLoginCtrl.cs	                        (rev 0)
+++ trunk/Tools/Maestro/Maestro/LoginForm/HttpLoginCtrl.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -0,0 +1,208 @@
+#region Disclaimer / License
+// Copyright (C) 2010, Jackie Ng
+// http://trac.osgeo.org/mapguide/wiki/maestro, jumpinjackie at gmail.com
+// 
+// This library 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 2.1 of the License, or (at your option) any later version.
+// 
+// This library 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 library; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
+// 
+#endregion
+using System;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Drawing;
+using System.Data;
+using System.Text;
+using System.Windows.Forms;
+using System.Globalization;
+
+namespace OSGeo.MapGuide.Maestro
+{
+    public partial class HttpLoginCtrl : UserControl, ILoginCtrl
+    {
+        private bool _loading = true;
+
+        public HttpLoginCtrl()
+        {
+            InitializeComponent();
+        }
+
+        protected override void OnLoad(EventArgs e)
+        {
+            base.OnLoad(e);
+
+            List<CultureInfo> supported = new List<CultureInfo>();
+            supported.Add(CultureInfo.GetCultureInfo("en-US"));
+
+            //Probe for language bundles and add them as well
+            System.Text.RegularExpressions.Regex cix = new System.Text.RegularExpressions.Regex("[A-z][A-z](\\-[A-z][A-z])?");
+            foreach (string f in System.IO.Directory.GetDirectories(Application.StartupPath))
+            {
+                if (cix.Match(System.IO.Path.GetFileName(f)).Length == System.IO.Path.GetFileName(f).Length)
+                {
+                    try
+                    {
+                        supported.Add(System.Globalization.CultureInfo.GetCultureInfo(System.IO.Path.GetFileName(f)));
+                    }
+                    catch { }
+                }
+            }
+
+            cmbLanguage.DisplayMember = "DisplayName";
+            cmbLanguage.ValueMember = "Name";
+
+            //Set default language based on current thread culture
+            int selected = -1;
+            foreach (var ci in supported)
+            {
+                int index = cmbLanguage.Items.Add(ci);
+                if (string.Compare(ci.Name, System.Threading.Thread.CurrentThread.CurrentUICulture.Name, true) == 0)
+                {
+                    selected = index;
+                }
+            }
+
+            if (selected >= 0)
+                cmbLanguage.SelectedIndex = selected;
+
+            _loading = false;
+            UpdateButtonStatus();
+        }
+
+        public PreferedSite[] GetSites()
+        {
+            List<PreferedSite> items = new List<PreferedSite>();
+            foreach (PreferedSite s in cmbServerUrl.Items)
+            {
+                items.Add(s);
+            }
+            return items.ToArray();
+        }
+
+        public void AddSites(PreferedSite[] sites)
+        {
+            cmbServerUrl.Items.AddRange(sites);
+        }
+
+        public void SetPreferredSite(int index)
+        {
+            cmbServerUrl.SelectedIndex = index;
+        }
+
+        #region ILoginCtrl Members
+
+        public string Username
+        {
+            get { return txtUsername.Text; }
+            set { txtUsername.Text = value; }
+        }
+
+        public string Password
+        {
+            get { return txtPassword.Text; }
+            set { txtPassword.Text = value; }
+        }
+
+        #endregion
+
+        public string Server
+        {
+            get { return cmbServerUrl.Text; }
+            set { cmbServerUrl.Text = value; }
+        }
+
+        public string StartingPoint
+        {
+            get { return txtStartingpoint.Text; }
+            set { txtStartingpoint.Text = value; }
+        }
+
+        public string Language
+        {
+            get 
+            { 
+                var ci = cmbLanguage.SelectedItem as CultureInfo;
+                if (ci != null)
+                {
+                    return ci.Name;
+                }
+                return null;
+            }
+        }
+
+        private void txtPassword_TextChanged(object sender, EventArgs e)
+        {
+            UpdateButtonStatus();
+        }
+
+        private void UpdateButtonStatus()
+        {
+            if (this.Username.Trim().Length > 0 && this.Server.Trim().Length > 0)
+                EnableOk(this, EventArgs.Empty);
+            else
+                DisabledOk(this, EventArgs.Empty);
+        }
+
+        public PreferedSiteList SiteList
+        {
+            get;
+            set;
+        }
+
+        public event EventHandler EnableOk = delegate { };
+
+        public event EventHandler DisabledOk = delegate { };
+
+        public event EventHandler CheckSavedPassword = delegate { };
+
+        private void cmbLanguage_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            if (!_loading)
+            {
+                if (cmbLanguage.SelectedIndex >= 0)
+                {
+                    //System.Threading.Thread.CurrentThread.CurrentCulture = m_supportedLanguages[cmbLanguage.SelectedIndex];
+                    //System.Threading.Thread.CurrentThread.CurrentUICulture = m_supportedLanguages[cmbLanguage.SelectedIndex];
+
+                    if (this.Visible)
+                    {
+                        try
+                        {
+                            this.SiteList.GUILanguage = this.Language;
+                            this.SiteList.Save();
+                        }
+                        catch { }
+
+                        MessageBox.Show(this, Strings.FormLogin.RestartForLanguageChange, Application.ProductName, MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    }
+                }
+            }
+        }
+
+        private void cmbServerUrl_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            PreferedSite site = cmbServerUrl.SelectedItem as PreferedSite;
+            if (site == null)
+                return;
+
+            txtStartingpoint.Text = site.StartingPoint;
+            txtUsername.Text = site.Username;
+            if (site.SavePassword)
+                txtPassword.Text = site.UnscrambledPassword;
+            else
+                txtPassword.Text = "";
+
+            CheckSavedPassword(this, EventArgs.Empty);
+        }
+    }
+}

Added: trunk/Tools/Maestro/Maestro/LoginForm/HttpLoginCtrl.resx
===================================================================
--- trunk/Tools/Maestro/Maestro/LoginForm/HttpLoginCtrl.resx	                        (rev 0)
+++ trunk/Tools/Maestro/Maestro/LoginForm/HttpLoginCtrl.resx	2010-05-04 07:51:41 UTC (rev 4826)
@@ -0,0 +1,120 @@
+<?xml version="1.0" encoding="utf-8"?>
+<root>
+  <!-- 
+    Microsoft ResX Schema 
+    
+    Version 2.0
+    
+    The primary goals of this format is to allow a simple XML format 
+    that is mostly human readable. The generation and parsing of the 
+    various data types are done through the TypeConverter classes 
+    associated with the data types.
+    
+    Example:
+    
+    ... ado.net/XML headers & schema ...
+    <resheader name="resmimetype">text/microsoft-resx</resheader>
+    <resheader name="version">2.0</resheader>
+    <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
+    <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+    <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
+    <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
+    <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
+        <value>[base64 mime encoded serialized .NET Framework object]</value>
+    </data>
+    <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
+        <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
+        <comment>This is a comment</comment>
+    </data>
+                
+    There are any number of "resheader" rows that contain simple 
+    name/value pairs.
+    
+    Each data row contains a name, and value. The row also contains a 
+    type or mimetype. Type corresponds to a .NET class that support 
+    text/value conversion through the TypeConverter architecture. 
+    Classes that don't support this are serialized and stored with the 
+    mimetype set.
+    
+    The mimetype is used for serialized objects, and tells the 
+    ResXResourceReader how to depersist the object. This is currently not 
+    extensible. For a given mimetype the value must be set accordingly:
+    
+    Note - application/x-microsoft.net.object.binary.base64 is the format 
+    that the ResXResourceWriter will generate, however the reader can 
+    read any of the formats listed below.
+    
+    mimetype: application/x-microsoft.net.object.binary.base64
+    value   : The object must be serialized with 
+            : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
+            : and then encoded with base64 encoding.
+    
+    mimetype: application/x-microsoft.net.object.soap.base64
+    value   : The object must be serialized with 
+            : System.Runtime.Serialization.Formatters.Soap.SoapFormatter
+            : and then encoded with base64 encoding.
+
+    mimetype: application/x-microsoft.net.object.bytearray.base64
+    value   : The object must be serialized into a byte array 
+            : using a System.ComponentModel.TypeConverter
+            : and then encoded with base64 encoding.
+    -->
+  <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
+    <xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
+    <xsd:element name="root" msdata:IsDataSet="true">
+      <xsd:complexType>
+        <xsd:choice maxOccurs="unbounded">
+          <xsd:element name="metadata">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" />
+              </xsd:sequence>
+              <xsd:attribute name="name" use="required" type="xsd:string" />
+              <xsd:attribute name="type" type="xsd:string" />
+              <xsd:attribute name="mimetype" type="xsd:string" />
+              <xsd:attribute ref="xml:space" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="assembly">
+            <xsd:complexType>
+              <xsd:attribute name="alias" type="xsd:string" />
+              <xsd:attribute name="name" type="xsd:string" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="data">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+                <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
+              <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
+              <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
+              <xsd:attribute ref="xml:space" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="resheader">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" use="required" />
+            </xsd:complexType>
+          </xsd:element>
+        </xsd:choice>
+      </xsd:complexType>
+    </xsd:element>
+  </xsd:schema>
+  <resheader name="resmimetype">
+    <value>text/microsoft-resx</value>
+  </resheader>
+  <resheader name="version">
+    <value>2.0</value>
+  </resheader>
+  <resheader name="reader">
+    <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=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+  </resheader>
+</root>
\ No newline at end of file

Added: trunk/Tools/Maestro/Maestro/LoginForm/ILoginCtrl.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/LoginForm/ILoginCtrl.cs	                        (rev 0)
+++ trunk/Tools/Maestro/Maestro/LoginForm/ILoginCtrl.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -0,0 +1,35 @@
+#region Disclaimer / License
+// Copyright (C) 2010, Jackie Ng
+// http://trac.osgeo.org/mapguide/wiki/maestro, jumpinjackie at gmail.com
+// 
+// This library 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 2.1 of the License, or (at your option) any later version.
+// 
+// This library 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 library; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
+// 
+#endregion
+using System;
+using System.Collections.Generic;
+using System.Text;
+
+namespace OSGeo.MapGuide.Maestro
+{
+    public interface ILoginCtrl
+    {
+        string Username { get; }
+        string Password { get; }
+
+        event EventHandler EnableOk;
+        event EventHandler DisabledOk;
+        event EventHandler CheckSavedPassword;
+    }
+}

Added: trunk/Tools/Maestro/Maestro/LoginForm/LocalNativeLoginCtrl.Designer.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/LoginForm/LocalNativeLoginCtrl.Designer.cs	                        (rev 0)
+++ trunk/Tools/Maestro/Maestro/LoginForm/LocalNativeLoginCtrl.Designer.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -0,0 +1,139 @@
+namespace OSGeo.MapGuide.Maestro
+{
+    partial class LocalNativeLoginCtrl
+    {
+        /// <summary> 
+        /// Required designer variable.
+        /// </summary>
+        private System.ComponentModel.IContainer components = null;
+
+        /// <summary> 
+        /// Clean up any resources being used.
+        /// </summary>
+        /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
+        protected override void Dispose(bool disposing)
+        {
+            if (disposing && (components != null))
+            {
+                components.Dispose();
+            }
+            base.Dispose(disposing);
+        }
+
+        #region Component Designer generated code
+
+        /// <summary> 
+        /// Required method for Designer support - do not modify 
+        /// the contents of this method with the code editor.
+        /// </summary>
+        private void InitializeComponent()
+        {
+            this.txtPassword = new System.Windows.Forms.TextBox();
+            this.txtUsername = new System.Windows.Forms.TextBox();
+            this.label4 = new System.Windows.Forms.Label();
+            this.label3 = new System.Windows.Forms.Label();
+            this.label1 = new System.Windows.Forms.Label();
+            this.txtWebConfig = new System.Windows.Forms.TextBox();
+            this.btnBrowse = new System.Windows.Forms.Button();
+            this.SuspendLayout();
+            // 
+            // txtPassword
+            // 
+            this.txtPassword.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
+                        | System.Windows.Forms.AnchorStyles.Right)));
+            this.txtPassword.Location = new System.Drawing.Point(100, 93);
+            this.txtPassword.Name = "txtPassword";
+            this.txtPassword.PasswordChar = '*';
+            this.txtPassword.Size = new System.Drawing.Size(308, 20);
+            this.txtPassword.TabIndex = 25;
+            this.txtPassword.Text = "admin";
+            // 
+            // txtUsername
+            // 
+            this.txtUsername.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
+                        | System.Windows.Forms.AnchorStyles.Right)));
+            this.txtUsername.Location = new System.Drawing.Point(100, 67);
+            this.txtUsername.Name = "txtUsername";
+            this.txtUsername.Size = new System.Drawing.Size(308, 20);
+            this.txtUsername.TabIndex = 24;
+            this.txtUsername.Text = "Administrator";
+            // 
+            // label4
+            // 
+            this.label4.FlatStyle = System.Windows.Forms.FlatStyle.System;
+            this.label4.ImeMode = System.Windows.Forms.ImeMode.NoControl;
+            this.label4.Location = new System.Drawing.Point(20, 96);
+            this.label4.Name = "label4";
+            this.label4.Size = new System.Drawing.Size(74, 16);
+            this.label4.TabIndex = 23;
+            this.label4.Text = "Password";
+            // 
+            // label3
+            // 
+            this.label3.FlatStyle = System.Windows.Forms.FlatStyle.System;
+            this.label3.ImeMode = System.Windows.Forms.ImeMode.NoControl;
+            this.label3.Location = new System.Drawing.Point(20, 70);
+            this.label3.Name = "label3";
+            this.label3.Size = new System.Drawing.Size(74, 16);
+            this.label3.TabIndex = 22;
+            this.label3.Text = "Username";
+            // 
+            // label1
+            // 
+            this.label1.AutoSize = true;
+            this.label1.Location = new System.Drawing.Point(20, 12);
+            this.label1.Name = "label1";
+            this.label1.Size = new System.Drawing.Size(135, 13);
+            this.label1.TabIndex = 26;
+            this.label1.Text = "Web Tier Configuration File";
+            // 
+            // txtWebConfig
+            // 
+            this.txtWebConfig.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
+                        | System.Windows.Forms.AnchorStyles.Right)));
+            this.txtWebConfig.Location = new System.Drawing.Point(23, 29);
+            this.txtWebConfig.Name = "txtWebConfig";
+            this.txtWebConfig.Size = new System.Drawing.Size(385, 20);
+            this.txtWebConfig.TabIndex = 27;
+            this.txtWebConfig.TextChanged += new System.EventHandler(this.txtWebConfig_TextChanged);
+            // 
+            // btnBrowse
+            // 
+            this.btnBrowse.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
+            this.btnBrowse.Location = new System.Drawing.Point(414, 26);
+            this.btnBrowse.Name = "btnBrowse";
+            this.btnBrowse.Size = new System.Drawing.Size(26, 23);
+            this.btnBrowse.TabIndex = 28;
+            this.btnBrowse.Text = "...";
+            this.btnBrowse.UseVisualStyleBackColor = true;
+            this.btnBrowse.Click += new System.EventHandler(this.btnBrowse_Click);
+            // 
+            // LocalNativeLoginCtrl
+            // 
+            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
+            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+            this.Controls.Add(this.btnBrowse);
+            this.Controls.Add(this.txtWebConfig);
+            this.Controls.Add(this.label1);
+            this.Controls.Add(this.txtPassword);
+            this.Controls.Add(this.txtUsername);
+            this.Controls.Add(this.label4);
+            this.Controls.Add(this.label3);
+            this.Name = "LocalNativeLoginCtrl";
+            this.Size = new System.Drawing.Size(453, 150);
+            this.ResumeLayout(false);
+            this.PerformLayout();
+
+        }
+
+        #endregion
+
+        private System.Windows.Forms.TextBox txtPassword;
+        private System.Windows.Forms.TextBox txtUsername;
+        private System.Windows.Forms.Label label4;
+        private System.Windows.Forms.Label label3;
+        private System.Windows.Forms.Label label1;
+        private System.Windows.Forms.TextBox txtWebConfig;
+        private System.Windows.Forms.Button btnBrowse;
+    }
+}

Added: trunk/Tools/Maestro/Maestro/LoginForm/LocalNativeLoginCtrl.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/LoginForm/LocalNativeLoginCtrl.cs	                        (rev 0)
+++ trunk/Tools/Maestro/Maestro/LoginForm/LocalNativeLoginCtrl.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -0,0 +1,89 @@
+#region Disclaimer / License
+// Copyright (C) 2010, Jackie Ng
+// http://trac.osgeo.org/mapguide/wiki/maestro, jumpinjackie at gmail.com
+// 
+// This library 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 2.1 of the License, or (at your option) any later version.
+// 
+// This library 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 library; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
+// 
+#endregion
+using System;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Drawing;
+using System.Data;
+using System.Text;
+using System.Windows.Forms;
+using System.IO;
+
+namespace OSGeo.MapGuide.Maestro
+{
+    public partial class LocalNativeLoginCtrl : UserControl, ILoginCtrl
+    {
+        public LocalNativeLoginCtrl()
+        {
+            InitializeComponent();
+        }
+
+        protected override void OnLoad(EventArgs e)
+        {
+            base.OnLoad(e);
+            DisabledOk(this, EventArgs.Empty);
+        }
+
+        #region ILoginCtrl Members
+
+        public string Username
+        {
+            get { return txtUsername.Text; }
+        }
+
+        public string Password
+        {
+            get { return txtPassword.Text; }
+        }
+
+        #endregion
+
+        public string WebConfigPath
+        {
+            get { return txtWebConfig.Text; }
+        }
+
+        public event EventHandler EnableOk = delegate { };
+
+        public event EventHandler DisabledOk = delegate { };
+
+        public event EventHandler CheckSavedPassword = delegate { };
+
+        private void txtWebConfig_TextChanged(object sender, EventArgs e)
+        {
+            if (this.WebConfigPath.Trim().Length > 0 && File.Exists(this.WebConfigPath))
+                EnableOk(this, EventArgs.Empty);
+            else
+                DisabledOk(this, EventArgs.Empty);
+        }
+
+        private void btnBrowse_Click(object sender, EventArgs e)
+        {
+            using (var dlg = new OpenFileDialog())
+            {
+                dlg.Filter = "*.ini|*.ini";
+                if (dlg.ShowDialog() == DialogResult.OK)
+                {
+                    txtWebConfig.Text = dlg.FileName;
+                }
+            }
+        }
+    }
+}

Added: trunk/Tools/Maestro/Maestro/LoginForm/LocalNativeLoginCtrl.resx
===================================================================
--- trunk/Tools/Maestro/Maestro/LoginForm/LocalNativeLoginCtrl.resx	                        (rev 0)
+++ trunk/Tools/Maestro/Maestro/LoginForm/LocalNativeLoginCtrl.resx	2010-05-04 07:51:41 UTC (rev 4826)
@@ -0,0 +1,120 @@
+<?xml version="1.0" encoding="utf-8"?>
+<root>
+  <!-- 
+    Microsoft ResX Schema 
+    
+    Version 2.0
+    
+    The primary goals of this format is to allow a simple XML format 
+    that is mostly human readable. The generation and parsing of the 
+    various data types are done through the TypeConverter classes 
+    associated with the data types.
+    
+    Example:
+    
+    ... ado.net/XML headers & schema ...
+    <resheader name="resmimetype">text/microsoft-resx</resheader>
+    <resheader name="version">2.0</resheader>
+    <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
+    <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+    <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
+    <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
+    <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
+        <value>[base64 mime encoded serialized .NET Framework object]</value>
+    </data>
+    <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
+        <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
+        <comment>This is a comment</comment>
+    </data>
+                
+    There are any number of "resheader" rows that contain simple 
+    name/value pairs.
+    
+    Each data row contains a name, and value. The row also contains a 
+    type or mimetype. Type corresponds to a .NET class that support 
+    text/value conversion through the TypeConverter architecture. 
+    Classes that don't support this are serialized and stored with the 
+    mimetype set.
+    
+    The mimetype is used for serialized objects, and tells the 
+    ResXResourceReader how to depersist the object. This is currently not 
+    extensible. For a given mimetype the value must be set accordingly:
+    
+    Note - application/x-microsoft.net.object.binary.base64 is the format 
+    that the ResXResourceWriter will generate, however the reader can 
+    read any of the formats listed below.
+    
+    mimetype: application/x-microsoft.net.object.binary.base64
+    value   : The object must be serialized with 
+            : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
+            : and then encoded with base64 encoding.
+    
+    mimetype: application/x-microsoft.net.object.soap.base64
+    value   : The object must be serialized with 
+            : System.Runtime.Serialization.Formatters.Soap.SoapFormatter
+            : and then encoded with base64 encoding.
+
+    mimetype: application/x-microsoft.net.object.bytearray.base64
+    value   : The object must be serialized into a byte array 
+            : using a System.ComponentModel.TypeConverter
+            : and then encoded with base64 encoding.
+    -->
+  <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
+    <xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
+    <xsd:element name="root" msdata:IsDataSet="true">
+      <xsd:complexType>
+        <xsd:choice maxOccurs="unbounded">
+          <xsd:element name="metadata">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" />
+              </xsd:sequence>
+              <xsd:attribute name="name" use="required" type="xsd:string" />
+              <xsd:attribute name="type" type="xsd:string" />
+              <xsd:attribute name="mimetype" type="xsd:string" />
+              <xsd:attribute ref="xml:space" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="assembly">
+            <xsd:complexType>
+              <xsd:attribute name="alias" type="xsd:string" />
+              <xsd:attribute name="name" type="xsd:string" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="data">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+                <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
+              <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
+              <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
+              <xsd:attribute ref="xml:space" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="resheader">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" use="required" />
+            </xsd:complexType>
+          </xsd:element>
+        </xsd:choice>
+      </xsd:complexType>
+    </xsd:element>
+  </xsd:schema>
+  <resheader name="resmimetype">
+    <value>text/microsoft-resx</value>
+  </resheader>
+  <resheader name="version">
+    <value>2.0</value>
+  </resheader>
+  <resheader name="reader">
+    <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=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+  </resheader>
+</root>
\ No newline at end of file

Modified: trunk/Tools/Maestro/Maestro/LoginForm/OSGeo.MapGuide.Maestro.LoginForm.csproj
===================================================================
--- trunk/Tools/Maestro/Maestro/LoginForm/OSGeo.MapGuide.Maestro.LoginForm.csproj	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/LoginForm/OSGeo.MapGuide.Maestro.LoginForm.csproj	2010-05-04 07:51:41 UTC (rev 4826)
@@ -3,7 +3,7 @@
   <PropertyGroup>
     <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
     <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
-    <ProductVersion>9.0.21022</ProductVersion>
+    <ProductVersion>9.0.30729</ProductVersion>
     <SchemaVersion>2.0</SchemaVersion>
     <ProjectGuid>{4B79021A-5117-4894-BBC0-39452E4F40E3}</ProjectGuid>
     <OutputType>Library</OutputType>
@@ -43,6 +43,22 @@
     <Compile Include="FormLogin.cs">
       <SubType>Form</SubType>
     </Compile>
+    <Compile Include="FormLogin.Designer.cs">
+      <DependentUpon>FormLogin.cs</DependentUpon>
+    </Compile>
+    <Compile Include="HttpLoginCtrl.cs">
+      <SubType>UserControl</SubType>
+    </Compile>
+    <Compile Include="HttpLoginCtrl.Designer.cs">
+      <DependentUpon>HttpLoginCtrl.cs</DependentUpon>
+    </Compile>
+    <Compile Include="ILoginCtrl.cs" />
+    <Compile Include="LocalNativeLoginCtrl.cs">
+      <SubType>UserControl</SubType>
+    </Compile>
+    <Compile Include="LocalNativeLoginCtrl.Designer.cs">
+      <DependentUpon>LocalNativeLoginCtrl.cs</DependentUpon>
+    </Compile>
     <Compile Include="PreferedSite.cs" />
     <Compile Include="Properties\AssemblyInfo.cs" />
     <Compile Include="Strings\FormLogin.Designer.cs">
@@ -59,8 +75,13 @@
   <ItemGroup>
     <EmbeddedResource Include="FormLogin.resx">
       <DependentUpon>FormLogin.cs</DependentUpon>
-      <SubType>Designer</SubType>
     </EmbeddedResource>
+    <EmbeddedResource Include="HttpLoginCtrl.resx">
+      <DependentUpon>HttpLoginCtrl.cs</DependentUpon>
+    </EmbeddedResource>
+    <EmbeddedResource Include="LocalNativeLoginCtrl.resx">
+      <DependentUpon>LocalNativeLoginCtrl.cs</DependentUpon>
+    </EmbeddedResource>
     <EmbeddedResource Include="Strings\FormLogin.resx">
       <Generator>ResXFileCodeGenerator</Generator>
       <LastGenOutput>FormLogin.Designer.cs</LastGenOutput>

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditorBase.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditorBase.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditorBase.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -530,7 +530,7 @@
 
             return m_child.ValidateResource(recurse); 
         }
-        public bool SupportsPreview { get { return m_child.SupportsPreview; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews && m_child.SupportsPreview; } }
         public bool SupportsValidate { get { return m_child.SupportsValidate; } }
         public bool SupportsProfiling { get { return m_child.SupportsProfiling; } }
 

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditorGeneric.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditorGeneric.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditorGeneric.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -334,7 +334,7 @@
 
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
 

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/ArcSDE/FeatureSourceEditorArcSDE.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/ArcSDE/FeatureSourceEditorArcSDE.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/ArcSDE/FeatureSourceEditorArcSDE.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -248,7 +248,7 @@
 
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
     }

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/Filebased/FilebasedFeatureSourceEditor.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/Filebased/FilebasedFeatureSourceEditor.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/Filebased/FilebasedFeatureSourceEditor.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -266,7 +266,7 @@
     
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
     }

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/Gdal/FeatureSourceEditorGdal.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/Gdal/FeatureSourceEditorGdal.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/Gdal/FeatureSourceEditorGdal.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -236,7 +236,7 @@
 
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
 

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/King.Informix/FeatureSourceEditorKingInformix.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/King.Informix/FeatureSourceEditorKingInformix.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/King.Informix/FeatureSourceEditorKingInformix.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -248,7 +248,7 @@
 
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
 

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/King.KML/FeatureSourceEditorKingKML.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/King.KML/FeatureSourceEditorKingKML.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/King.KML/FeatureSourceEditorKingKML.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -209,7 +209,7 @@
 
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
     

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/King.MSSql/FeatureSourceEditorKingMSSql.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/King.MSSql/FeatureSourceEditorKingMSSql.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/King.MSSql/FeatureSourceEditorKingMSSql.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -248,7 +248,7 @@
 
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
 

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/King.Oracle/FeatureSourceEditorKingOracle.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/King.Oracle/FeatureSourceEditorKingOracle.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/King.Oracle/FeatureSourceEditorKingOracle.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -247,7 +247,7 @@
     
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
     }

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/MSSQLSpatial/FeatureSourceEditorMSSQLSpatial.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/MSSQLSpatial/FeatureSourceEditorMSSQLSpatial.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/MSSQLSpatial/FeatureSourceEditorMSSQLSpatial.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -217,7 +217,7 @@
 
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
     }

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/MySQL/FeatureSourceEditorMySQL.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/MySQL/FeatureSourceEditorMySQL.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/MySQL/FeatureSourceEditorMySQL.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -217,7 +217,7 @@
 
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
     }

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/ODBC/FeatureSourceEditorODBC.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/ODBC/FeatureSourceEditorODBC.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/ODBC/FeatureSourceEditorODBC.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -897,7 +897,7 @@
             Save(null);
             return true; 
         }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
 

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/OGR/FeatureSourceEditorOGR.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/OGR/FeatureSourceEditorOGR.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/OGR/FeatureSourceEditorOGR.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -470,7 +470,7 @@
 
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
     

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/PostGIS/FeatureSourceEditorPostGIS.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/PostGIS/FeatureSourceEditorPostGIS.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/PostGIS/FeatureSourceEditorPostGIS.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -292,7 +292,7 @@
 
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
     }

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/WFS/FeatureSourceEditorWFS.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/WFS/FeatureSourceEditorWFS.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/WFS/FeatureSourceEditorWFS.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -187,7 +187,7 @@
 
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
     

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/WMS/FeatureSourceEditorWMS.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/WMS/FeatureSourceEditorWMS.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/FeatureSourceEditors/WMS/FeatureSourceEditorWMS.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -217,7 +217,7 @@
     
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
     }

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/LayerEditor.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/LayerEditor.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/LayerEditor.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -626,7 +626,7 @@
     
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return true; } }
 

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/LayoutEditor.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/LayoutEditor.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/LayoutEditor.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -2164,7 +2164,7 @@
     
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
     }

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/MapEditor.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/MapEditor.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/MapEditor.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -2221,7 +2221,7 @@
     
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return true; } }
 

Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/SymbolLibraryEditor.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/SymbolLibraryEditor.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/SymbolLibraryEditor.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -127,7 +127,7 @@
     
         public bool Profile() { return true; }
         public bool ValidateResource(bool recurse) { return true; }
-        public bool SupportsPreview { get { return true; } }
+        public bool SupportsPreview { get { return m_editor.CurrentConnection.SupportsResourcePreviews; } }
         public bool SupportsValidate { get { return true; } }
         public bool SupportsProfiling { get { return false; } }
     }

Modified: trunk/Tools/Maestro/MaestroAPI/HttpServerConnection.cs
===================================================================
--- trunk/Tools/Maestro/MaestroAPI/HttpServerConnection.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/MaestroAPI/HttpServerConnection.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -1465,5 +1465,10 @@
             get { return m_reqBuilder.UserAgent; }
             set { m_reqBuilder.UserAgent = value; }
         }
+
+        public bool SupportsResourcePreviews
+        {
+            get { return true; }
+        }
     }
 }

Modified: trunk/Tools/Maestro/MaestroAPI/LocalNativeConnection.cs
===================================================================
--- trunk/Tools/Maestro/MaestroAPI/LocalNativeConnection.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/MaestroAPI/LocalNativeConnection.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -885,6 +885,11 @@
 
 		#endregion
 
+        public bool SupportsResourcePreviews
+        {
+            get { return false; }
+        }
+
         #region IDisposable Members
 
         public override void Dispose()

Modified: trunk/Tools/Maestro/MaestroAPI/ServerConnectionI.cs
===================================================================
--- trunk/Tools/Maestro/MaestroAPI/ServerConnectionI.cs	2010-05-04 05:19:34 UTC (rev 4825)
+++ trunk/Tools/Maestro/MaestroAPI/ServerConnectionI.cs	2010-05-04 07:51:41 UTC (rev 4826)
@@ -418,5 +418,10 @@
         /// <param name="callback"></param>
         /// <returns>A list of resource IDs that were created or updated from the execution of this load procedure</returns>
         string[] ExecuteLoadProcedure(string resourceID, bool ignoreUnsupportedFeatures, LengthyOperationProgressCallBack callback);
+
+        /// <summary>
+        /// Indicates whether previewing capabilities are possible with this connection
+        /// </summary>
+        bool SupportsResourcePreviews { get; }
     }
 }



More information about the mapguide-commits mailing list