[mapguide-commits] r7924 - trunk/Tools/Maestro/Maestro.Base/Editor
svn_mapguide at osgeo.org
svn_mapguide at osgeo.org
Sun Nov 24 07:52:37 PST 2013
Author: jng
Date: 2013-11-24 07:52:37 -0800 (Sun, 24 Nov 2013)
New Revision: 7924
Modified:
trunk/Tools/Maestro/Maestro.Base/Editor/EditorContentBase.cs
Log:
Return a null IResource if attempting to get the IResource of an editor before the EditorService is set
Modified: trunk/Tools/Maestro/Maestro.Base/Editor/EditorContentBase.cs
===================================================================
--- trunk/Tools/Maestro/Maestro.Base/Editor/EditorContentBase.cs 2013-11-24 15:36:10 UTC (rev 7923)
+++ trunk/Tools/Maestro/Maestro.Base/Editor/EditorContentBase.cs 2013-11-24 15:52:37 UTC (rev 7924)
@@ -138,7 +138,15 @@
/// <summary>
/// Gets the edited resource
/// </summary>
- public IResource Resource { get { return this.EditorService.GetEditedResource(); } }
+ public IResource Resource
+ {
+ get
+ {
+ if (this.EditorService == null)
+ return null;
+ return this.EditorService.GetEditedResource();
+ }
+ }
private void OpenAffectedResource(IResource res)
{
More information about the mapguide-commits
mailing list