Index: src/DeltaShell/DeltaShell.Plugins.SharpMapGis.Gui/Commands/MapViewCommand.cs =================================================================== diff -u -r8f6ae890fed8e8eae3a32f9c0498a10f82e0ddf9 -r5fc71a385897af92ccb092f2f969b5709afab85a --- src/DeltaShell/DeltaShell.Plugins.SharpMapGis.Gui/Commands/MapViewCommand.cs (.../MapViewCommand.cs) (revision 8f6ae890fed8e8eae3a32f9c0498a10f82e0ddf9) +++ src/DeltaShell/DeltaShell.Plugins.SharpMapGis.Gui/Commands/MapViewCommand.cs (.../MapViewCommand.cs) (revision 5fc71a385897af92ccb092f2f969b5709afab85a) @@ -7,40 +7,50 @@ { public abstract class MapViewCommand : Command { - protected override void OnExecute(params object[] arguments) + public override bool Enabled { + get + { + return MapView != null; + } } - protected MapView MapView + public override bool Checked { - get { return SharpMapGisGuiPlugin.GetFocusedMapView(); } + get + { + return CurrentTool != null && CurrentTool.IsActive; + } + set + { + base.Checked = value; + } } - protected IMap Map + protected MapView MapView { - get { return MapView != null ? MapView.Map : null; } + get + { + return SharpMapGisGuiPlugin.GetFocusedMapView(); + } } - protected virtual IMapTool CurrentTool + protected IMap Map { - get { return null; } - } - - public override bool Enabled - { get { - return MapView != null; + return MapView != null ? MapView.Map : null; } } - public override bool Checked + protected virtual IMapTool CurrentTool { get { - return CurrentTool != null && CurrentTool.IsActive; + return null; } - set { base.Checked = value; } } + + protected override void OnExecute(params object[] arguments) {} } } \ No newline at end of file