Skip to content

Commit 46fae23

Browse files
committed
Merge branch 'rubberduck-vba/next' into next
2 parents f78d8ef + 3f29abd commit 46fae23

File tree

816 files changed

+2046
-961
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

816 files changed

+2046
-961
lines changed

Installer Build Script.iss

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
1-
#define BuildDir SourcePath + "RetailCoder.VBE\bin\Release"
1+
#define BuildDir SourcePath + "Rubberduck.Main\bin\Release"
22
#define AppName "Rubberduck"
33
#define AddinDLL "Rubberduck.dll"
4-
#define InspectionsDLL "Rubberduck.Inspections.dll"
5-
#define AppVersion GetFileVersion(SourcePath + "RetailCoder.VBE\bin\Release\Rubberduck.dll")
4+
#define AppVersion GetFileVersion(SourcePath + "Rubberduck.Main\bin\Release\Rubberduck.dll")
65
#define AppPublisher "Rubberduck"
76
#define AppURL "http://rubberduckvba.com"
87
#define License SourcePath + "\License.rtf"
@@ -42,7 +41,6 @@ Source: "{#BuildDir}\lib\win32\x64\*"; DestDir: "{app}"; Flags: ignoreversion; E
4241
Source: "{#BuildDir}\lib\win32\x86\*"; DestDir: "{app}"; Flags: ignoreversion; Excludes: "{#AddinDLL}"; Check: Is32BitOfficeInstalled
4342

4443
Source: "{#BuildDir}\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs; Excludes: "{#AddinDLL},\NativeBinaries"
45-
Source: "{#BuildDir}\{#InspectionsDLL}"; DestDir: "{app}"; Flags: ignoreversion
4644
Source: "{#BuildDir}\{#AddinDLL}"; DestDir: "{app}"; Flags: ignoreversion; AfterInstall: RegisterAddin
4745

4846
[Run]

license renamed to LICENSE

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
GNU GENERAL PUBLIC LICENSE
1+
GNU GENERAL PUBLIC LICENSE
22
Version 3, 29 June 2007
33

44
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
@@ -631,8 +631,8 @@ to attach them to the start of each source file to most effectively
631631
state the exclusion of warranty; and each file should have at least
632632
the "copyright" line and a pointer to where the full notice is found.
633633

634-
{one line to give the program's name and a brief idea of what it does.}
635-
Copyright (C) {year} {name of author}
634+
<one line to give the program's name and a brief idea of what it does.>
635+
Copyright (C) <year> <name of author>
636636

637637
This program is free software: you can redistribute it and/or modify
638638
it under the terms of the GNU General Public License as published by
@@ -652,7 +652,7 @@ Also add information on how to contact you by electronic and paper mail.
652652
If the program does terminal interaction, make it output a short
653653
notice like this when it starts in an interactive mode:
654654

655-
{project} Copyright (C) {year} {fullname}
655+
<program> Copyright (C) <year> <name of author>
656656
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
657657
This is free software, and you are welcome to redistribute it
658658
under certain conditions; type `show c' for details.

README.md

Lines changed: 1 addition & 1 deletion

RetailCoder.VBE/Rubberduck.csproj.DotSettings

Lines changed: 0 additions & 4 deletions
This file was deleted.

RetailCoder.VBE/UnitTesting/FakesProviderFactory.cs

Lines changed: 0 additions & 15 deletions
This file was deleted.

RetailCoder.VBE/API/VBA/ParserState.cs renamed to Rubberduck.API/API/VBA/ParserState.cs

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,12 @@
88
using Rubberduck.Parsing.PreProcessing;
99
using Rubberduck.Parsing.Symbols.DeclarationLoaders;
1010
using Rubberduck.Parsing.VBA;
11-
using Rubberduck.UI.Command.MenuItems;
1211
using Rubberduck.Parsing.Symbols;
1312
using Rubberduck.Parsing.UIContext;
1413
using Rubberduck.VBEditor.ComManagement;
1514
using Rubberduck.VBEditor.Events;
1615
using Rubberduck.VBEditor.SafeComWrappers.VBA;
16+
using Rubberduck.VBEditor.Utility;
1717

1818
namespace Rubberduck.API.VBA
1919
{
@@ -52,11 +52,13 @@ public sealed class ParserState : IParserState, IDisposable
5252
private AttributeParser _attributeParser;
5353
private ParseCoordinator _parser;
5454
private VBE _vbe;
55+
private IVBEEvents _vbeEvents;
56+
private readonly IUiDispatcher _dispatcher;
5557

5658
public ParserState()
5759
{
58-
UiDispatcher.Initialize();
59-
ComMessagePumper.Initialize();
60+
UiContextProvider.Initialize();
61+
_dispatcher = new UiDispatcher(UiContextProvider.Instance());
6062
}
6163

6264
public void Initialize(Microsoft.Vbe.Interop.VBE vbe)
@@ -67,9 +69,10 @@ public void Initialize(Microsoft.Vbe.Interop.VBE vbe)
6769
}
6870

6971
_vbe = new VBE(vbe);
72+
_vbeEvents = VBEEvents.Initialize(_vbe);
7073
var declarationFinderFactory = new ConcurrentlyConstructedDeclarationFinderFactory();
7174
var projectRepository = new ProjectsRepository(_vbe);
72-
_state = new RubberduckParserState(null, projectRepository, declarationFinderFactory);
75+
_state = new RubberduckParserState(null, projectRepository, declarationFinderFactory, _vbeEvents);
7376
_state.StateChanged += _state_StateChanged;
7477

7578
var exporter = new ModuleExporter();
@@ -146,7 +149,7 @@ public void Parse()
146149
public void BeginParse()
147150
{
148151
// non-blocking call
149-
UiDispatcher.Invoke(() => _state.OnParseRequested(this));
152+
_dispatcher.Invoke(() => _state.OnParseRequested(this));
150153
}
151154

152155
public event Action OnParsed;
@@ -166,19 +169,19 @@ private void _state_StateChanged(object sender, EventArgs e)
166169
var errorHandler = OnError;
167170
if (_state.Status == Parsing.VBA.ParserState.Error && errorHandler != null)
168171
{
169-
UiDispatcher.Invoke(errorHandler.Invoke);
172+
_dispatcher.Invoke(errorHandler.Invoke);
170173
}
171174

172175
var parsedHandler = OnParsed;
173176
if (_state.Status == Parsing.VBA.ParserState.Parsed && parsedHandler != null)
174177
{
175-
UiDispatcher.Invoke(parsedHandler.Invoke);
178+
_dispatcher.Invoke(parsedHandler.Invoke);
176179
}
177180

178181
var readyHandler = OnReady;
179182
if (_state.Status == Parsing.VBA.ParserState.Ready && readyHandler != null)
180183
{
181-
UiDispatcher.Invoke(readyHandler.Invoke);
184+
_dispatcher.Invoke(readyHandler.Invoke);
182185
}
183186
}
184187

0 commit comments

Comments
 (0)