aboutsummaryrefslogtreecommitdiffstatsci
path: root/src/GraphicObjects/Group.cs
diff options
context:
space:
mode:
authorjp <jp_bruyere@hotmail.com>2016-02-03 11:59:24 +0100
committerjp <jp_bruyere@hotmail.com>2016-02-03 11:59:24 +0100
commit46560c8595bc6a36b51493214cbbff89c0694ef5 (patch)
treec2a9a9bc7ef0671c72405450782047916dde91dc /src/GraphicObjects/Group.cs
parent577c18f51074b5c4f343bade99dc0776e0fcb72d (diff)
add error handling for CrowType not found in group children
Diffstat (limited to 'src/GraphicObjects/Group.cs')
-rw-r--r--src/GraphicObjects/Group.cs2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/GraphicObjects/Group.cs b/src/GraphicObjects/Group.cs
index 087cd38d..5107ccc5 100644
--- a/src/GraphicObjects/Group.cs
+++ b/src/GraphicObjects/Group.cs
@@ -290,6 +290,8 @@ namespace Crow
break;
Type t = Type.GetType("Crow." + subTree.Name);
+ if (t == null)
+ throw new Exception ("Crow." + subTree.Name + " type not found");
GraphicObject go = (GraphicObject)Activator.CreateInstance(t);
(go as IXmlSerializable).ReadXml(subTree);
addChild(go);