diff options
| author | Roy Ben Shabat <Roy.mail.net@gmail.com> | 2020-04-29 13:07:33 +0300 |
|---|---|---|
| committer | Roy Ben Shabat <Roy.mail.net@gmail.com> | 2020-04-29 13:07:33 +0300 |
| commit | 25b6658dbb640edc46254489435103c06fadd814 (patch) | |
| tree | 6878f52dc1f9b8efb18ea746f2c01b38e91d7604 /Software | |
| parent | 330c34d62c8dfe8ce03041c82b41f51e13ecefed (diff) | |
| download | Tango-25b6658dbb640edc46254489435103c06fadd814.tar.gz Tango-25b6658dbb640edc46254489435103c06fadd814.zip | |
TestDesigner error highlight jump to line.
Diffstat (limited to 'Software')
4 files changed, 6 insertions, 5 deletions
diff --git a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Stubs/Contracts/ITestDesignerView.cs b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Stubs/Contracts/ITestDesignerView.cs index 04287e765..f6566765e 100644 --- a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Stubs/Contracts/ITestDesignerView.cs +++ b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Stubs/Contracts/ITestDesignerView.cs @@ -10,7 +10,7 @@ namespace Tango.FSE.Stubs.Contracts public interface ITestDesignerView : IFSEView { void FormatCode(); - void HighlightCode(int position, int length); + void HighlightCode(int position, int length, int line); void InsertCode(String code); void InvalidateHighlighting(); } diff --git a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Stubs/ViewModels/TestDesignerViewVM.cs b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Stubs/ViewModels/TestDesignerViewVM.cs index 7c0b0e01f..3a64437c6 100644 --- a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Stubs/ViewModels/TestDesignerViewVM.cs +++ b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Stubs/ViewModels/TestDesignerViewVM.cs @@ -936,7 +936,7 @@ namespace Tango.FSE.Stubs.ViewModels if (errorScript != null) { OpenScript(errorScript); - View.HighlightCode(error.Position, error.Length); + View.HighlightCode(error.Position, error.Length, error.Line); } } diff --git a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Stubs/Views/TestDesignerView.xaml.cs b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Stubs/Views/TestDesignerView.xaml.cs index 60b215112..e310afc89 100644 --- a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Stubs/Views/TestDesignerView.xaml.cs +++ b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Stubs/Views/TestDesignerView.xaml.cs @@ -49,9 +49,9 @@ namespace Tango.FSE.Stubs.Views GetCurrentEditor()?.FormatCode(); } - public void HighlightCode(int position, int length) + public void HighlightCode(int position, int length, int line) { - GetCurrentEditor()?.Highlight(position, length); + GetCurrentEditor()?.Highlight(position, length, line); } public void InsertCode(string code) diff --git a/Software/Visual_Studio/Scripting/Tango.Scripting.Editors/ScriptEditor.cs b/Software/Visual_Studio/Scripting/Tango.Scripting.Editors/ScriptEditor.cs index 7fd6d99e7..f63cedcdc 100644 --- a/Software/Visual_Studio/Scripting/Tango.Scripting.Editors/ScriptEditor.cs +++ b/Software/Visual_Studio/Scripting/Tango.Scripting.Editors/ScriptEditor.cs @@ -2121,9 +2121,10 @@ namespace Tango.Scripting.Editors } } - public void Highlight(int position, int length) + public void Highlight(int position, int length, int line) { Select(position, Math.Max(length, 1)); + ScrollToLine(line); } public void InsertCode(String code) |
