Changeset 10359 for trunk/sources/HeuristicLab.CodeEditor
- Timestamp:
- 01/20/14 17:56:51 (11 years ago)
- Location:
- trunk/sources
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources
- Property svn:mergeinfo changed
/branches/HLScript (added) merged: 10331-10332,10358
- Property svn:mergeinfo changed
-
trunk/sources/HeuristicLab.CodeEditor/3.3/CodeEditor.cs
r5287 r10359 140 140 if (TextEditorValidated != null) 141 141 TextEditorValidated(this, EventArgs.Empty); 142 } 143 144 public event EventHandler TextEditorTextChanged; 145 146 protected void OnTextEditorTextChanged() { 147 if (TextEditorTextChanged != null) 148 TextEditorTextChanged(this, EventArgs.Empty); 142 149 } 143 150 … … 188 195 189 196 textEditor.Validated += (s, a) => { OnTextEditorValidated(); }; 197 textEditor.TextChanged += (s, a) => { OnTextEditorTextChanged(); }; 190 198 InitializeImageList(); 191 199 } … … 298 306 public void AddAssembly(Assembly a) { 299 307 ShowMessage("Loading " + a.GetName().Name + "..."); 300 if ( assemblies.Contains(a))301 return;302 var reference = projectContentRegistry.GetProjectContentForReference(a.GetName().Name, a.Location);303 projectContent.AddReferencedContent(reference);304 assemblies.Add(a);308 if (!assemblies.Contains(a)) { 309 var reference = projectContentRegistry.GetProjectContentForReference(a.GetName().Name, a.Location); 310 projectContent.AddReferencedContent(reference); 311 assemblies.Add(a); 312 } 305 313 ShowMessage("Ready"); 306 314 } 307 315 public void RemoveAssembly(Assembly a) { 308 316 ShowMessage("Unloading " + a.GetName().Name + "..."); 309 if ( !assemblies.Contains(a))310 return;311 var content = projectContentRegistry.GetExistingProjectContent(a.Location);312 if (content != null) {313 projectContent.ReferencedContents.Remove(content);314 projectContentRegistry.UnloadProjectContent(content);317 if (assemblies.Contains(a)) { 318 var content = projectContentRegistry.GetExistingProjectContent(a.Location); 319 if (content != null) { 320 projectContent.ReferencedContents.Remove(content); 321 projectContentRegistry.UnloadProjectContent(content); 322 } 315 323 } 316 324 ShowMessage("Ready");
Note: See TracChangeset
for help on using the changeset viewer.