示例#1
0
 public UserControl build_editor(BaseProperty property)
 {
     Type t = property.GetType();
     if (t == typeof(FloatProperty))
     {
         FloatEditor ed = new FloatEditor();
         ed.set_target((FloatProperty)property);
         return ed;
     }
     else
     {
         //TODO -- better message
         string msg = "Unknown type";
         throw new Exception(msg);
     }
 }
示例#2
0
        public UserControl build_editor(BaseProperty property)
        {
            Type t = property.GetType();

            if (t == typeof(FloatProperty))
            {
                FloatEditor ed = new FloatEditor();
                ed.set_target((FloatProperty)property);
                return(ed);
            }
            else
            {
                //TODO -- better message
                string msg = "Unknown type";
                throw new Exception(msg);
            }
        }