private VbeEvents(IVBE vbe) { _components = new Dictionary <string, IVBComponents>(); _references = new Dictionary <string, IReferences>(); if (_projects != null) { return; } _projects = vbe.VBProjects; if (_projects.IsWrappingNullReference) { return; } _projects.AttachEvents(); _projects.ProjectAdded += ProjectAddedHandler; _projects.ProjectRemoved += ProjectRemovedHandler; _projects.ProjectRenamed += ProjectRenamedHandler; _projects.ProjectActivated += ProjectActivatedHandler; foreach (var project in _projects) { using (project) { { RegisterProjectHandlers(project); } } } }
private VBEEvents(IVBE vbe) { _components = new Dictionary <string, IVBComponents>(); if (_projects != null) { return; } _projects = vbe.VBProjects; _projects.AttachEvents(); _projects.ProjectAdded += ProjectAddedHandler; _projects.ProjectRemoved += ProjectRemovedHandler; _projects.ProjectRenamed += ProjectRenamedHandler; _projects.ProjectActivated += ProjectActivatedHandler; foreach (var project in _projects) { using (project) { { RegisterComponents(project); } } } }
public void Dispose() { if (_disposed) { return; } ExecuteWithinWriteLock(() => ClearCollections()); _disposed = true; _projectsCollection.Dispose(); _projectsCollection = null; _refreshProtectionLock.Dispose(); }
protected virtual void Dispose(bool disposing) { if (_disposed || !disposing) { return; } ExecuteWithinWriteLock(() => ClearCollections()); _disposed = true; _projectsCollection.Dispose(); _projectsCollection = null; _refreshProtectionLock.Dispose(); }
public bool Equals(IVBProjects other) { return(Equals(other as SafeComWrapper <VB.VBProjects>)); }
public ProjectsRepository(IVBE vbe) { _projectsCollection = vbe.VBProjects; }
public bool Equals(IVBProjects other) { throw new NotImplementedException(); }