/// <summary> /// Constructor /// </summary> /// <param name="document">The script document to test</param> public ScriptTestDocument(ScriptDocument document) { #pragma warning disable 612 _document = null; _path = null; #pragma warning restore 612 _config = new DynamicNodeConfig(); _config.Label = "node"; _config.Script = document; _config.DirtyChanged += new EventHandler(_config_DirtyChanged); }
/// <summary> /// On deserialization /// </summary> protected override void OnDeserialization() { base.OnDeserialization(); if (_config == null) { _config = new DynamicNodeConfig(); _config.Label = "node"; #pragma warning disable 612 _config.Properties = _props; _config.SelectionPath = _path; _config.ClassName = _classname; _config.Script = _document; _props = null; _classname = null; #pragma warning restore 612 _config.DirtyChanged += new EventHandler(_config_DirtyChanged); } }