Skip to content
This repository was archived by the owner on Oct 4, 2021. It is now read-only.

Commit 5c8da2e

Browse files
DavidKarlassandyarmstrong
authored andcommitted
Sync vs-editor-api and adopt code to changes
1 parent a89047e commit 5c8da2e

File tree

8 files changed

+25
-14
lines changed

8 files changed

+25
-14
lines changed

main/Main.sln

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -406,6 +406,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TextLogicUtil", "external\v
406406
EndProject
407407
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TextUIUtil", "external\vs-editor-api\src\Editor\Text\Util\TextUIUtil\TextUIUtil.csproj", "{B2B41590-92EF-4120-B9B8-E861F3903FDD}"
408408
EndProject
409+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TextUICocoaUtil", "external\vs-editor-api\src\Editor\Text\Util\TextUICocoaUtil\TextUICocoaUtil.csproj", "{B2B41590-670F-4169-B3D4-7BC7E77900CE}"
410+
EndProject
409411
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Core", "Core", "{10D43FCD-8287-47D2-A8DD-7BDC77CFBDE7}"
410412
EndProject
411413
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Def", "Def", "{1EA941BE-66DE-4D0E-B840-FC556F5BA803}"
@@ -2435,6 +2437,16 @@ Global
24352437
{B2B41590-92EF-4120-B9B8-E861F3903FDD}.ReleaseMac|Any CPU.ActiveCfg = Release|Any CPU
24362438
{B2B41590-92EF-4120-B9B8-E861F3903FDD}.ReleaseMac|Any CPU.Build.0 = Release|Any CPU
24372439
{B2B41590-92EF-4120-B9B8-E861F3903FDD}.ReleaseWin32|Any CPU.ActiveCfg = Release|Any CPU
2440+
{B2B41590-670F-4169-B3D4-7BC7E77900CE}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
2441+
{B2B41590-670F-4169-B3D4-7BC7E77900CE}.DebugGnome|Any CPU.ActiveCfg = Debug|Any CPU
2442+
{B2B41590-670F-4169-B3D4-7BC7E77900CE}.DebugMac|Any CPU.ActiveCfg = Debug|Any CPU
2443+
{B2B41590-670F-4169-B3D4-7BC7E77900CE}.DebugMac|Any CPU.Build.0 = Debug|Any CPU
2444+
{B2B41590-670F-4169-B3D4-7BC7E77900CE}.DebugWin32|Any CPU.ActiveCfg = Debug|Any CPU
2445+
{B2B41590-670F-4169-B3D4-7BC7E77900CE}.Release|Any CPU.ActiveCfg = Release|Any CPU
2446+
{B2B41590-670F-4169-B3D4-7BC7E77900CE}.ReleaseGnome|Any CPU.ActiveCfg = Release|Any CPU
2447+
{B2B41590-670F-4169-B3D4-7BC7E77900CE}.ReleaseMac|Any CPU.ActiveCfg = Release|Any CPU
2448+
{B2B41590-670F-4169-B3D4-7BC7E77900CE}.ReleaseMac|Any CPU.Build.0 = Release|Any CPU
2449+
{B2B41590-670F-4169-B3D4-7BC7E77900CE}.ReleaseWin32|Any CPU.ActiveCfg = Release|Any CPU
24382450
{3AFF3617-E88F-4F96-AA81-00D3D9E15C05}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
24392451
{3AFF3617-E88F-4F96-AA81-00D3D9E15C05}.DebugGnome|Any CPU.ActiveCfg = Debug|Any CPU
24402452
{3AFF3617-E88F-4F96-AA81-00D3D9E15C05}.DebugMac|Any CPU.ActiveCfg = Debug|Any CPU
@@ -2862,6 +2874,7 @@ Global
28622874
{1206D585-670F-4951-A6BF-493C79C950E4} = {745BF6CA-BC7C-4863-B1B4-C423A828820A}
28632875
{69F195E1-A8C9-43B3-AE91-A8FC79393163} = {745BF6CA-BC7C-4863-B1B4-C423A828820A}
28642876
{B2B41590-92EF-4120-B9B8-E861F3903FDD} = {745BF6CA-BC7C-4863-B1B4-C423A828820A}
2877+
{B2B41590-670F-4169-B3D4-7BC7E77900CE} = {745BF6CA-BC7C-4863-B1B4-C423A828820A}
28652878
{10D43FCD-8287-47D2-A8DD-7BDC77CFBDE7} = {5A92B792-BF17-4748-B29E-34C99B2E8722}
28662879
{1EA941BE-66DE-4D0E-B840-FC556F5BA803} = {10D43FCD-8287-47D2-A8DD-7BDC77CFBDE7}
28672880
{3AFF3617-E88F-4F96-AA81-00D3D9E15C05} = {1EA941BE-66DE-4D0E-B840-FC556F5BA803}

main/external/vs-editor-api

Submodule vs-editor-api updated 37 files

main/msbuild/ReferencesVSEditor.Mac.props

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
<IncludeCopyLocal Include="Microsoft.VisualStudio.Language.StandardClassification.dll" />
1616
<IncludeCopyLocal Include="Microsoft.VisualStudio.Text.Data.Utilities.dll" />
1717
<IncludeCopyLocal Include="Microsoft.VisualStudio.Text.UI.Utilities.dll" />
18+
<IncludeCopyLocal Include="Microsoft.VisualStudio.Text.UI.Cocoa.Utilities.dll" />
1819
<IncludeCopyLocal Include="Microsoft.VisualStudio.UI.Text.AdornmentLibrary.ToolTip.Implementation.dll" />
1920
<IncludeCopyLocal Include="Microsoft.VisualStudio.UI.Text.Cocoa.View.Implementation.dll" />
2021
<IncludeCopyLocal Include="Microsoft.VisualStudio.Language.StandardClassification.Implementation.dll" />

main/src/addins/MonoDevelop.SourceEditor2/VSEditor/IMdTextView.cs

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,12 @@
11
namespace Microsoft.VisualStudio.Text.Editor
22
{
3-
internal interface IMdTextView :
4-
#if WINDOWS
5-
ITextView2
6-
#else
7-
ITextView3
8-
#endif
3+
internal interface IMdTextView : ITextView2
94
{
105
MonoDevelop.SourceEditor.IMDSpaceReservationManager GetSpaceReservationManager(string name);
116

12-
Gtk.Container VisualElement
13-
{
14-
get;
7+
Gtk.Container VisualElement
8+
{
9+
get;
1510
}
1611

1712
void Focus();

main/src/addins/MonoDevelop.TextEditor/MonoDevelop.TextEditor.Cocoa/Properties/MonoDevelop.TextEditor.Cocoa.addin.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
<Import assembly="../../../bin/Microsoft.VisualStudio.Text.PatternMatching.Implementation.dll" />
2323
<Import assembly="../../../bin/Microsoft.VisualStudio.Text.UI.Cocoa.dll" />
2424
<Import assembly="../../../bin/Microsoft.VisualStudio.Text.UI.Utilities.dll" />
25+
<Import assembly="../../../bin/Microsoft.VisualStudio.Text.UI.Cocoa.Utilities.dll" />
2526
<Import assembly="../../../bin/Microsoft.VisualStudio.Text.UI.Wpf.dll" />
2627
<Import assembly="../../../bin/Microsoft.VisualStudio.UI.Text.Commanding.Implementation.dll" />
2728
<Import assembly="../../../bin/Microsoft.VisualStudio.UI.Text.EditorOperations.Implementation.dll" />
@@ -74,6 +75,7 @@
7475
<Assembly file="../../../bin/Microsoft.VisualStudio.Text.Outlining.Implementation.dll" />
7576
<Assembly file="../../../bin/Microsoft.VisualStudio.Text.PatternMatching.Implementation.dll" />
7677
<Assembly file="../../../bin/Microsoft.VisualStudio.Text.UI.Utilities.dll" />
78+
<Assembly file="../../../bin/Microsoft.VisualStudio.Text.UI.Cocoa.Utilities.dll" />
7779
<Assembly file="../../../bin/Microsoft.VisualStudio.Text.UI.Wpf.dll" />
7880
<Assembly file="../../../bin/Microsoft.VisualStudio.Text.UI.Cocoa.dll" />
7981
<Assembly file="../../../bin/Microsoft.VisualStudio.UI.Text.Commanding.Implementation.dll" />

main/src/addins/MonoDevelop.TextEditor/MonoDevelop.TextEditor/TextViewContent.Commands.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -208,8 +208,8 @@ bool CanHandleCommand (object commandId)
208208
}
209209
}
210210
#if !WINDOWS
211-
if (TextView is ITextView3 textView3)
212-
return textView3.IsKeyboardFocused;
211+
if (TextView is ICocoaTextView cocoaTextView)
212+
return cocoaTextView.IsKeyboardFocused;
213213
#endif
214214

215215
return true;

main/src/addins/MonoDevelop.TextEditor/MonoDevelop.TextEditor/TextViewContent.Toolbox.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ void IToolboxConsumer.ConsumeItem (ItemToolboxNode item)
2222
if (item is ITextToolboxNode tn) {
2323
tn.InsertAtCaret (this.Document);
2424
#if !WINDOWS
25-
((ITextView3)TextView).Focus ();
25+
((ICocoaTextView)TextView).Focus ();
2626
#endif
2727
}
2828
}

main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/ViewCommandHandlers.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -526,7 +526,7 @@ protected void UpdateEnableDisableFolding (CommandInfo info)
526526
#else
527527
info.Text = IsFoldMarkerMarginEnabled ? GettextCatalog.GetString ("Disable _Folding") : GettextCatalog.GetString ("Enable _Folding");
528528
info.Enabled = GetContent<IFoldable> () != null ||
529-
GetContent<Microsoft.VisualStudio.Text.Editor.ITextView3> () != null;
529+
GetContent<Microsoft.VisualStudio.Text.Editor.ITextView> () != null;
530530
// As we need to support both the new and the legacy editor, we need to check if perhaps
531531
// we are running in the new one. The legacy editor already implements <see cref="ITextView"/>
532532
// so we can't simply look for that and we do not want to import anything related to Cocoa.

0 commit comments

Comments
 (0)