[mapguide-commits] r7065 - in branches/2.4/MgDev/Desktop: MapViewer MapViewer/AppLayoutEngine MgAppLayout

svn_mapguide at osgeo.org svn_mapguide at osgeo.org
Wed Oct 3 07:05:19 PDT 2012


Author: jng
Date: 2012-10-03 07:05:15 -0700 (Wed, 03 Oct 2012)
New Revision: 7065

Modified:
   branches/2.4/MgDev/Desktop/MapViewer/AppLayoutEngine/AppLayout.cs
   branches/2.4/MgDev/Desktop/MapViewer/AppLayoutEngine/Shell.cs
   branches/2.4/MgDev/Desktop/MapViewer/IMapViewer.cs
   branches/2.4/MgDev/Desktop/MapViewer/MgComponent.cs
   branches/2.4/MgDev/Desktop/MapViewer/MgLegend.cs
   branches/2.4/MgDev/Desktop/MapViewer/MgMapViewer.cs
   branches/2.4/MgDev/Desktop/MapViewer/Strings.Designer.cs
   branches/2.4/MgDev/Desktop/MapViewer/Strings.resx
   branches/2.4/MgDev/Desktop/MgAppLayout/Sheboygan.AppLayout
   branches/2.4/MgDev/Desktop/MgAppLayout/SheboyganTiled.AppLayout
Log:
mg-desktop: This submission contains the following changes:
 - Fix node click hit testing to account for nodes that don't have checkboxes rendered.
 - Make IMapViewer also an IMapComponent, allowing for its properties (tagged with MgComponentPropertyAttribute) to be dynamically set via the AppLayout engine.
 - Change the AppLayout schema so that the <Settings> element is now a list of NameValue elements, which behaves just like Component Definition properties.
 - Fix implementation of IMapComponent.SetPropertyValue, so that basic CLR type conversion can be done. (eg. "true" auto-converts to boolean true if called on a boolean CLR property)

Modified: branches/2.4/MgDev/Desktop/MapViewer/AppLayoutEngine/AppLayout.cs
===================================================================
--- branches/2.4/MgDev/Desktop/MapViewer/AppLayoutEngine/AppLayout.cs	2012-10-03 13:00:20 UTC (rev 7064)
+++ branches/2.4/MgDev/Desktop/MapViewer/AppLayoutEngine/AppLayout.cs	2012-10-03 14:05:15 UTC (rev 7065)
@@ -16,8 +16,8 @@
         [XmlElement]
         public string Language { get; set; }
 
-        [XmlElement]
-        public AppLayoutSettings Settings { get; set; }
+        [XmlArray]
+        public List<NameValue> Settings { get; set; }
 
         [XmlElement]
         public InfoPaneSettings InfoPane { get; set; }
@@ -44,15 +44,15 @@
         {
             var layout = new AppLayout();
             layout.Title = title;
-            layout.Settings = new AppLayoutSettings()
+            layout.Settings = new List<NameValue>()
             {
-                ConvertTiledGroupsToNonTiled = true,
-                UseRenderMap = true,
-                SelectionColor = Util.ToHtmlColorWithAlpha(System.Drawing.Color.Blue),
-                ShowVertexCoordinatesWhenDigitizing = false,
-                ZoomInFactor = 0.5,
-                ZoomOutFactor = 2.0,
-                PointPixelBuffer = 3
+                new NameValue() { Name = "ConvertTiledGroupsToNonTiled", Value = "true" }, //NOXLATE
+                new NameValue() { Name = "UseRenderMap", Value = "true" }, //NOXLATE
+                new NameValue() { Name = "SelectionColor", Value = "color:" + Util.ToHtmlColorWithAlpha(System.Drawing.Color.Blue) }, //NOXLATE
+                new NameValue() { Name = "ShowVertexCoordinatesWhenDigitizing", Value = "true" }, //NOXLATE
+                new NameValue() { Name = "ZoomInFactor", Value = "0.5" }, //NOXLATE
+                new NameValue() { Name = "ZoomOutFactor", Value = "2.0" }, //NOXLATE
+                new NameValue() { Name = "PointPixelBuffer", Value = "3" } //NOXLATE
             };
             layout.InfoPane = new InfoPaneSettings()
             {
@@ -258,36 +258,6 @@
         }
     }
 
-    public class AppLayoutSettings
-    {
-        [XmlElement]
-        public string InvokeOnStartup { get; set; }
-
-        [XmlElement]
-        public string SelectionColor { get; set; }
-
-        [XmlElement]
-        public bool ConvertTiledGroupsToNonTiled { get; set; }
-
-        [XmlElement]
-        public bool UseRenderMap { get; set; }
-
-        [XmlElement]
-        public bool RespectFiniteScales { get; set; }
-
-        [XmlElement]
-        public bool ShowVertexCoordinatesWhenDigitizing { get; set; }
-
-        [XmlElement]
-        public double ZoomInFactor { get; set; }
-
-        [XmlElement]
-        public double ZoomOutFactor { get; set; }
-
-        [XmlElement]
-        public int PointPixelBuffer { get; set; }
-    }
-
     public class InfoPaneSettings
     {
         [XmlElement]
@@ -442,11 +412,11 @@
     /// </summary>
     public class StringPrefixes
     {
-        public const string MAPDEFINITION = "map:";
-        public const string COMPONENTID = "component:";
-        public const string COLOR = "color:";
-        public const string ENUM = "enum:";
-        public const string VIEWERID = "viewer:";
-        public const string TASKPANEID = "taskpane:";
+        public const string MAPDEFINITION = "map:"; //NOXLATE
+        public const string COMPONENTID = "component:"; //NOXLATE
+        public const string COLOR = "color:"; //NOXLATE
+        public const string ENUM = "enum:"; //NOXLATE
+        public const string VIEWERID = "viewer:"; //NOXLATE
+        public const string TASKPANEID = "taskpane:"; //NOXLATE
     }
 }

Modified: branches/2.4/MgDev/Desktop/MapViewer/AppLayoutEngine/Shell.cs
===================================================================
--- branches/2.4/MgDev/Desktop/MapViewer/AppLayoutEngine/Shell.cs	2012-10-03 13:00:20 UTC (rev 7064)
+++ branches/2.4/MgDev/Desktop/MapViewer/AppLayoutEngine/Shell.cs	2012-10-03 14:05:15 UTC (rev 7065)
@@ -48,7 +48,7 @@
                 }
                 catch (Exception ex)
                 {
-                    MessageBox.Show(ex.Message, "Set Language");
+                    MessageBox.Show(ex.Message, Strings.SetLanguage);
                 }
             }
 
@@ -93,12 +93,12 @@
             mapViewer.PropertyChanged += new PropertyChangedEventHandler(OnMapViewerPropertyChanged);
         }
 
-        const string RESERVED_CHARS = "\\:*?\"<>|&'%=/";
+        const string RESERVED_CHARS = "\\:*?\"<>|&'%=/"; //NOXLATE
 
         private static void ValidateMapNames(AppLayout layout)
         {
             string mapName = layout.Map.Name;
-            if (mapName.Contains(" "))
+            if (mapName.Contains(" ")) //NOXLATE
                 throw new InvalidOperationException(string.Format(Strings.ErrorInvalidMapName, mapName));
 
             foreach (char c in mapName)
@@ -115,7 +115,7 @@
             //current language
             ComponentResourceManager resources = new ComponentResourceManager(this.GetType());
             ApplyResourceToControl(resources, this, lang);
-            resources.ApplyResources(this, "$this", lang);
+            resources.ApplyResources(this, "$this", lang); //NOXLATE
 
             //NOTE: Property pane is a separate case that has to be handled individually
             propertyPane.SetLanguage(lang);
@@ -178,6 +178,8 @@
         private AppLayout _layout;
         private MgMapViewerProvider _provider;
 
+        private string _invokeComponentOnStartup;
+
         protected override void OnLoad(EventArgs e)
         {
             //Optimization: If legend or property pane aren't visible
@@ -192,15 +194,15 @@
             new MapViewerController(mapViewer, theLegend, this, thePropertyPane);
             mapViewer.Init(_provider);
 
-            if (!string.IsNullOrEmpty(_layout.Settings.InvokeOnStartup))
+            if (!string.IsNullOrEmpty(_invokeComponentOnStartup))
             {
-                if (_components.ContainsKey(_layout.Settings.InvokeOnStartup))
+                if (_components.ContainsKey(_invokeComponentOnStartup))
                 {
-                    _components[_layout.Settings.InvokeOnStartup].Invoke();
+                    _components[_invokeComponentOnStartup].Invoke();
                 }
                 else
                 {
-                    MessageBox.Show(string.Format(Strings.WarnInvokeNonExistentComponent, _layout.Settings.InvokeOnStartup));
+                    MessageBox.Show(string.Format(Strings.WarnInvokeNonExistentComponent, _invokeComponentOnStartup));
                 }
             }
         }
@@ -347,11 +349,12 @@
             var assemblies = new Dictionary<string, Assembly>();
             _components = new Dictionary<string, MgComponent>();
 
-            // We do this in 3 passes:
+            // We do this in 4 passes:
             //
             // 1. Create the components in the component set
             // 2. Then set the properties of the instantiated components
             // 3. Assign the viewer to all these components
+            // 4. Set the owner parent and Task Pane of any MgViewerComponent instances to this instance
 
             // 1st pass
             foreach (var compDef in layout.Components)
@@ -424,7 +427,7 @@
                     }
                     else if (prop.Value.StartsWith(StringPrefixes.ENUM))
                     {
-                        string [] tokens = prop.Value.Split(':');
+                        string [] tokens = prop.Value.Split(':'); //NOXLATE
                         if (tokens.Length != 3)
                             throw new InvalidOperationException(Strings.ErrorMalformedEnumString);
                         comp.SetPropertyValue(prop.Name, Enum.Parse(Type.GetType(tokens[1]), tokens[2]));
@@ -446,21 +449,60 @@
 
             //Apply viewer properties. We do this here because we want to respect the viewer options component
             //So we apply before the viewer options component gets its chance to
-            mapViewer.ConvertTiledGroupsToNonTiled = layout.Settings.ConvertTiledGroupsToNonTiled;
-            mapViewer.UseRenderMapIfTiledLayersExist = layout.Settings.UseRenderMap;
-            mapViewer.RespectFiniteDisplayScales = layout.Settings.RespectFiniteScales;
-            mapViewer.SelectionColor = Util.FromHtmlColor(layout.Settings.SelectionColor);
-            mapViewer.ShowVertexCoordinatesWhenDigitizing = layout.Settings.ShowVertexCoordinatesWhenDigitizing;
-            mapViewer.ZoomInFactor = layout.Settings.ZoomInFactor;
-            mapViewer.ZoomOutFactor = layout.Settings.ZoomOutFactor;
 
+            foreach (var prop in layout.Settings)
+            {
+                if (prop.Value.StartsWith(StringPrefixes.MAPDEFINITION))
+                {
+                    var mapName = prop.Value.Substring(StringPrefixes.MAPDEFINITION.Length);
+                    //TODO: Update for multi-maps if/when we support it
+                    if (layout.Map.Name == mapName)
+                        mapViewer.SetPropertyValue(prop.Name, mapName);
+                    else
+                        throw new InvalidOperationException(string.Format(Strings.ErrorMapNotFound, mapName));
+                }
+                else if (prop.Value.StartsWith(StringPrefixes.COLOR))
+                {
+                    var colorStr = prop.Value.Substring(StringPrefixes.COLOR.Length);
+                    var color = Util.FromHtmlColor(colorStr);
+                    mapViewer.SetPropertyValue(prop.Name, color);
+                }
+                else if (prop.Value.StartsWith(StringPrefixes.COMPONENTID))
+                {
+                    var compID = prop.Value.Substring(StringPrefixes.COMPONENTID.Length);
+                    if (!_components.ContainsKey(compID))
+                        throw new InvalidOperationException(string.Format(Strings.ErrorComponentNotFound, compID));
+
+                    mapViewer.SetPropertyValue(prop.Name, _components[compID]);
+                }
+                else if (prop.Value.StartsWith(StringPrefixes.ENUM))
+                {
+                    string[] tokens = prop.Value.Split(':'); //NOXLATE
+                    if (tokens.Length != 3)
+                        throw new InvalidOperationException(Strings.ErrorMalformedEnumString);
+                    mapViewer.SetPropertyValue(prop.Name, Enum.Parse(Type.GetType(tokens[1]), tokens[2]));
+                }
+                else if (prop.Value.StartsWith(StringPrefixes.TASKPANEID)) //NOTE: only one taskpane instance, but we're checking this as a forward-looking measure
+                {
+                    mapViewer.SetPropertyValue(prop.Name, taskPane);
+                }
+                else if (prop.Value.StartsWith(StringPrefixes.VIEWERID)) //NOTE: only one viewer instance, but we're checking this as a forward-looking measure
+                {
+                    mapViewer.SetPropertyValue(prop.Name, mapViewer);
+                }
+                else
+                {
+                    mapViewer.SetPropertyValue(prop.Name, prop.Value);
+                }
+            }
+
             //3rd pass
             foreach (var compDef in layout.Components)
             {
                 _components[compDef.ComponentID].Viewer = mapViewer;
             }
 
-            //4th pass, set the owner parent of any MgViewerComponent instances
+            //4th pass, set the owner parent and Task Pane of any MgViewerComponent instances
             //to this instance
             foreach (var comp in _components.Values)
             {

Modified: branches/2.4/MgDev/Desktop/MapViewer/IMapViewer.cs
===================================================================
--- branches/2.4/MgDev/Desktop/MapViewer/IMapViewer.cs	2012-10-03 13:00:20 UTC (rev 7064)
+++ branches/2.4/MgDev/Desktop/MapViewer/IMapViewer.cs	2012-10-03 14:05:15 UTC (rev 7065)
@@ -57,7 +57,7 @@
     /// <summary>
     /// A map viewer component
     /// </summary>
-    public interface IMapViewer : IMapViewerComponent, INotifyPropertyChanged
+    public interface IMapViewer : IMapViewerComponent, INotifyPropertyChanged, IMapComponent
     {
         /// <summary>
         /// Clears the current selection

Modified: branches/2.4/MgDev/Desktop/MapViewer/MgComponent.cs
===================================================================
--- branches/2.4/MgDev/Desktop/MapViewer/MgComponent.cs	2012-10-03 13:00:20 UTC (rev 7064)
+++ branches/2.4/MgDev/Desktop/MapViewer/MgComponent.cs	2012-10-03 14:05:15 UTC (rev 7065)
@@ -9,19 +9,36 @@
 
 namespace OSGeo.MapGuide.Viewer
 {
+    /// <summary>
+    /// Defines a map viewer component
+    /// </summary>
     public interface IMapComponent
     {
+        /// <summary>
+        /// Gets the list of component properties
+        /// </summary>
         IEnumerable<PropertyInfo> ComponentProperties { get; }
 
+        /// <summary>
+        /// Sets the value of the specified component property
+        /// </summary>
+        /// <param name="propertyName"></param>
+        /// <param name="value"></param>
         void SetPropertyValue(string propertyName, object value);
 
+        /// <summary>
+        /// Gets the value of the specified component property
+        /// </summary>
+        /// <param name="propertyName"></param>
+        /// <returns></returns>
         object GetPropertyValue(string propertyName);
     }
 
     /// <summary>
-    /// Indicates that a given CLR property is dynamically invokable
+    /// Indicates that a given CLR property is dynamically invokable. Primarily used for property
+    /// value assignment by the AppLayout engine
     /// </summary>
-    [AttributeUsage(AttributeTargets.Property)]
+    [AttributeUsage(AttributeTargets.Property, Inherited = true)]
     public class MgComponentPropertyAttribute : Attribute
     {
 
@@ -224,7 +241,8 @@
             if (!_properties.ContainsKey(propertyName))
                 throw new InvalidOperationException(string.Format(Strings.ErrorInvalidComponentProperty, propertyName));
 
-            _properties[propertyName].SetValue(this, value, null);
+            var prop = _properties[propertyName];
+            prop.SetValue(this, Convert.ChangeType(value, prop.PropertyType), null);
         }
 
         public object GetPropertyValue(string propertyName)

Modified: branches/2.4/MgDev/Desktop/MapViewer/MgLegend.cs
===================================================================
--- branches/2.4/MgDev/Desktop/MapViewer/MgLegend.cs	2012-10-03 13:00:20 UTC (rev 7064)
+++ branches/2.4/MgDev/Desktop/MapViewer/MgLegend.cs	2012-10-03 14:05:15 UTC (rev 7065)
@@ -365,6 +365,11 @@
                 var box = new Rectangle(
                     new Point((e.Node.Bounds.Location.X - 36) + 16, e.Node.Bounds.Location.Y), 
                     new Size(16, e.Node.Bounds.Height));
+
+                //Uncheckable items need to move 16px to the left
+                if (!meta.Checkable)
+                    box.Offset(-16, 0);
+
                 if (box.Contains(e.X, e.Y))
                 {
                     var layer = meta.Layer;

Modified: branches/2.4/MgDev/Desktop/MapViewer/MgMapViewer.cs
===================================================================
--- branches/2.4/MgDev/Desktop/MapViewer/MgMapViewer.cs	2012-10-03 13:00:20 UTC (rev 7064)
+++ branches/2.4/MgDev/Desktop/MapViewer/MgMapViewer.cs	2012-10-03 14:05:15 UTC (rev 7065)
@@ -13,6 +13,7 @@
 using System.Collections.Specialized;
 using System.Collections.ObjectModel;
 using System.Globalization;
+using System.Reflection;
 
 namespace OSGeo.MapGuide.Viewer
 {
@@ -370,6 +371,7 @@
         /// </summary>
         [Category("MapGuide Viewer")] //NOXLATE
         [Description("The minimum allowed zoom scale for this viewer")] //NOXLATE
+        [MgComponentProperty]
         public int MinScale { get; set; }
 
         /// <summary>
@@ -377,6 +379,7 @@
         /// </summary>
         [Category("MapGuide Viewer")] //NOXLATE
         [Description("The maximum allowed zoom scale for this viewer")] //NOXLATE
+        [MgComponentProperty]
         public int MaxScale { get; set; }
 
         /// <summary>
@@ -384,6 +387,7 @@
         /// </summary>
         [Category("MapGuide Viewer")] //NOXLATE
         [Description("The amount of time (in ms) to wait to re-render after a mouse wheel scroll")] //NOXLATE
+        [MgComponentProperty]
         public int MouseWheelDelayRenderInterval { get; set; }
 
         /// <summary>
@@ -391,6 +395,7 @@
         /// </summary>
         [Category("MapGuide Viewer")] //NOXLATE
         [Description("The amount of time (in ms) to wait to fire off a tooltip request after the mouse pointer becomes stationary")] //NOXLATE
+        [MgComponentProperty]
         public int TooltipDelayInterval { get; set; }
 
         private Color _selColor;
@@ -400,6 +405,7 @@
         /// </summary>
         [Category("MapGuide Viewer")] //NOXLATE
         [Description("The color to use for active selections")] //NOXLATE
+        [MgComponentProperty]
         public Color SelectionColor
         {
             get { return _selColor; }
@@ -488,6 +494,7 @@
         [Category("MapGuide Viewer")] //NOXLATE
         [Description("Indicates whether coordinate values are shown when digitizing geometry")] //NOXLATE
         [DefaultValue(false)]
+        [MgComponentProperty]
         public bool ShowVertexCoordinatesWhenDigitizing
         {
             get { return _showVertexCoords; }
@@ -662,6 +669,7 @@
 
         [Category("MapGuide Viewer")] //NOXLATE
         [Description("The amount of pixels to buffer out by when doing point-based selections with the Select tool")] //NOXLATE
+        [MgComponentProperty]
         public int PointPixelBuffer { get; set; }
 
         private Color _digitizingFillColor;
@@ -847,6 +855,7 @@
         /// </summary>
         [Browsable(false)]
         [DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)]
+        [MgComponentProperty]
         public bool FeatureTooltipsEnabled
         {
             get { return _featTooltipsEnabled; }
@@ -1296,31 +1305,34 @@
         [Category("MapGuide Viewer")] //NOXLATE
         [Description("If true, the map being viewed will have all its tiled groups converted to non-tiled groups. Tiled groups are not supported by this viewer and are not rendered")] //NOXLATE
         [DefaultValue(false)]
+        [MgComponentProperty]
         public bool ConvertTiledGroupsToNonTiled
         {
             get;
             set;
         }
 
-        [Category("MapGuide Viewer")] //NOXLATE
-        [Description("If true, the viewer will use the RenderMap API instead of RenderDynamicOverlay allowing tiled layers to be rendered to the final image. Setting this property to true nullifies the ConvertTiledGroupsToNonTiled property")] //NOXLATE
-        [DefaultValue(true)]
         /// <summary>
         /// Gets whether to use the RenderMap API instead of RenderDynamicOverlay if the map has tiled
         /// layers. RenderMap includes tiled layers as part of the output image, but will not take advantage
         /// of any tile caching mechanisms. Setting this property to true nullifies any effect of the 
         /// <see cref="P:OSGeo.MapGuide.Viewer.IMapViewer.ConvertTiledGroupsToNonTiled"/> property
         /// </summary>
+        [Category("MapGuide Viewer")] //NOXLATE
+        [Description("If true, the viewer will use the RenderMap API instead of RenderDynamicOverlay allowing tiled layers to be rendered to the final image. Setting this property to true nullifies the ConvertTiledGroupsToNonTiled property")] //NOXLATE
+        [DefaultValue(true)]
+        [MgComponentProperty]
         public bool UseRenderMapIfTiledLayersExist { get; set; }
 
-        [Category("MapGuide Viewer")] //NOXLATE
-        [Description("If true, all zooms will snap to the nearest finite display scale defined in the map being viewed")] //NOXLATE
-        [DefaultValue(true)]
         /// <summary>
         /// Gets whether to respect the list of finite display scales in a map being viewed if there are any defined.
         /// If true, all zooms will "snap" to the nearest finite display scale. Otherwise, the viewer will disregard
         /// this list when zooming in or out.
         /// </summary>
+        [Category("MapGuide Viewer")] //NOXLATE
+        [Description("If true, all zooms will snap to the nearest finite display scale defined in the map being viewed")] //NOXLATE
+        [DefaultValue(true)]
+        [MgComponentProperty]
         public bool RespectFiniteDisplayScales { get; set; }
 
         /// <summary>
@@ -2151,6 +2163,7 @@
         /// </summary>
         [Category("MapGuide Viewer")] //NOXLATE
         [Description("The zoom in factor")] //NOXLATE
+        [MgComponentProperty]
         public double ZoomInFactor
         {
             get { return _zoomInFactor; }
@@ -2168,6 +2181,7 @@
         /// </summary>
         [Category("MapGuide Viewer")] //NOXLATE
         [Description("The zoom out factor")] //NOXLATE
+        [MgComponentProperty]
         public double ZoomOutFactor
         {
             get { return _zoomOutFactor; }
@@ -2876,6 +2890,7 @@
         /// </summary>
         [Browsable(false)]
         [DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)]
+        [MgComponentProperty]
         public MapActiveTool ActiveTool
         {
             get
@@ -2984,5 +2999,57 @@
         public event PaintEventHandler PreMapRender;
 
         public event PaintEventHandler PostMapRender;
+
+        private Dictionary<string, PropertyInfo> _properties;
+
+        public IEnumerable<PropertyInfo> ComponentProperties
+        {
+            get
+            {
+                CheckAndInitProperties();
+                return _properties.Values;
+            }
+        }
+
+        private void CheckAndInitProperties()
+        {
+            if (_properties == null)
+            {
+                _properties = new Dictionary<string, PropertyInfo>();
+                var props = this.GetType().GetProperties();
+                foreach (var p in props)
+                {
+                    var attributes = p.GetCustomAttributes(true);
+                    foreach (var att in attributes)
+                    {
+                        var compAttr = att as MgComponentPropertyAttribute;
+                        if (compAttr != null)
+                        {
+                            _properties[p.Name] = p;
+                            break;
+                        }
+                    }
+                }
+            }
+        }
+
+        public void SetPropertyValue(string propertyName, object value)
+        {
+            CheckAndInitProperties();
+            if (!_properties.ContainsKey(propertyName))
+                throw new InvalidOperationException(string.Format(Strings.ErrorInvalidComponentProperty, propertyName));
+
+            var prop = _properties[propertyName];
+            prop.SetValue(this, Convert.ChangeType(value, prop.PropertyType), null);
+        }
+
+        public object GetPropertyValue(string propertyName)
+        {
+            CheckAndInitProperties();
+            if (!_properties.ContainsKey(propertyName))
+                throw new InvalidOperationException(string.Format(Strings.ErrorInvalidComponentProperty, propertyName));
+
+            return _properties[propertyName].GetValue(propertyName, null);
+        }
     }
 }

Modified: branches/2.4/MgDev/Desktop/MapViewer/Strings.Designer.cs
===================================================================
--- branches/2.4/MgDev/Desktop/MapViewer/Strings.Designer.cs	2012-10-03 13:00:20 UTC (rev 7064)
+++ branches/2.4/MgDev/Desktop/MapViewer/Strings.Designer.cs	2012-10-03 14:05:15 UTC (rev 7065)
@@ -394,6 +394,15 @@
         }
         
         /// <summary>
+        ///   Looks up a localized string similar to Set Language.
+        /// </summary>
+        internal static string SetLanguage {
+            get {
+                return ResourceManager.GetString("SetLanguage", resourceCulture);
+            }
+        }
+        
+        /// <summary>
         ///   Looks up a localized string similar to {0} features selected.
         /// </summary>
         internal static string StatFeaturesSelected {

Modified: branches/2.4/MgDev/Desktop/MapViewer/Strings.resx
===================================================================
--- branches/2.4/MgDev/Desktop/MapViewer/Strings.resx	2012-10-03 13:00:20 UTC (rev 7064)
+++ branches/2.4/MgDev/Desktop/MapViewer/Strings.resx	2012-10-03 14:05:15 UTC (rev 7065)
@@ -387,4 +387,7 @@
   <data name="ErrorMapNotFound" xml:space="preserve">
     <value>A map named ({0}) was not found in the AppLayout</value>
   </data>
+  <data name="SetLanguage" xml:space="preserve">
+    <value>Set Language</value>
+  </data>
 </root>
\ No newline at end of file

Modified: branches/2.4/MgDev/Desktop/MgAppLayout/Sheboygan.AppLayout
===================================================================
--- branches/2.4/MgDev/Desktop/MgAppLayout/Sheboygan.AppLayout	2012-10-03 13:00:20 UTC (rev 7064)
+++ branches/2.4/MgDev/Desktop/MgAppLayout/Sheboygan.AppLayout	2012-10-03 14:05:15 UTC (rev 7065)
@@ -3,14 +3,38 @@
   <Title>MapGuide Desktop App Layout Example</Title>
   <Icon>app.ico</Icon>
   <Settings>
-    <SelectionColor>0000FF</SelectionColor>
-    <ConvertTiledGroupsToNonTiled>false</ConvertTiledGroupsToNonTiled>
-    <UseRenderMap>false</UseRenderMap>
-    <RespectFiniteScales>false</RespectFiniteScales>
-    <ShowVertexCoordinatesWhenDigitizing>false</ShowVertexCoordinatesWhenDigitizing>
-    <ZoomInFactor>0.5</ZoomInFactor>
-    <ZoomOutFactor>2</ZoomOutFactor>
-    <PointPixelBuffer>3</PointPixelBuffer>
+    <NameValue>
+      <Name>SelectionColor</Name>
+      <Value>color:0000FF</Value>
+    </NameValue>
+    <NameValue>
+      <Name>ConvertTiledGroupsToNonTiled</Name>
+      <Value>false</Value>
+    </NameValue>
+    <NameValue>
+      <Name>UseRenderMapIfTiledLayersExist</Name>
+      <Value>false</Value>
+    </NameValue>
+    <NameValue>
+      <Name>RespectFiniteDisplayScales</Name>
+      <Value>false</Value>
+    </NameValue>
+    <NameValue>
+      <Name>ShowVertexCoordinatesWhenDigitizing</Name>
+      <Value>false</Value>
+    </NameValue>
+    <NameValue>
+      <Name>ZoomInFactor</Name>
+      <Value>0.5</Value>
+    </NameValue>
+    <NameValue>
+      <Name>ZoomOutFactor</Name>
+      <Value>2</Value>
+    </NameValue>
+    <NameValue>
+      <Name>PointPixelBuffer</Name>
+      <Value>3</Value>
+    </NameValue>
   </Settings>
   <InfoPane>
     <Width>200</Width>

Modified: branches/2.4/MgDev/Desktop/MgAppLayout/SheboyganTiled.AppLayout
===================================================================
--- branches/2.4/MgDev/Desktop/MgAppLayout/SheboyganTiled.AppLayout	2012-10-03 13:00:20 UTC (rev 7064)
+++ branches/2.4/MgDev/Desktop/MgAppLayout/SheboyganTiled.AppLayout	2012-10-03 14:05:15 UTC (rev 7065)
@@ -3,14 +3,38 @@
   <Title>MapGuide Desktop App Layout Example</Title>
   <Icon>app.ico</Icon>
   <Settings>
-    <SelectionColor>0000FF</SelectionColor>
-    <ConvertTiledGroupsToNonTiled>false</ConvertTiledGroupsToNonTiled>
-    <UseRenderMap>true</UseRenderMap>
-    <RespectFiniteScales>true</RespectFiniteScales>
-    <ShowVertexCoordinatesWhenDigitizing>false</ShowVertexCoordinatesWhenDigitizing>
-    <ZoomInFactor>0.5</ZoomInFactor>
-    <ZoomOutFactor>2</ZoomOutFactor>
-    <PointPixelBuffer>3</PointPixelBuffer>
+    <NameValue>
+      <Name>SelectionColor</Name>
+      <Value>color:0000FF</Value>
+    </NameValue>
+    <NameValue>
+      <Name>ConvertTiledGroupsToNonTiled</Name>
+      <Value>false</Value>
+    </NameValue>
+    <NameValue>
+      <Name>UseRenderMapIfTiledLayersExist</Name>
+      <Value>true</Value>
+    </NameValue>
+    <NameValue>
+      <Name>RespectFiniteDisplayScales</Name>
+      <Value>true</Value>
+    </NameValue>
+    <NameValue>
+      <Name>ShowVertexCoordinatesWhenDigitizing</Name>
+      <Value>false</Value>
+    </NameValue>
+    <NameValue>
+      <Name>ZoomInFactor</Name>
+      <Value>0.5</Value>
+    </NameValue>
+    <NameValue>
+      <Name>ZoomOutFactor</Name>
+      <Value>2</Value>
+    </NameValue>
+    <NameValue>
+      <Name>PointPixelBuffer</Name>
+      <Value>3</Value>
+    </NameValue>
   </Settings>
   <InfoPane>
     <Width>200</Width>



More information about the mapguide-commits mailing list