Skip to content
This repository was archived by the owner on Sep 11, 2023. It is now read-only.

Commit 8f7373e

Browse files
committed
fix #103
1 parent ed1e5bb commit 8f7373e

File tree

3 files changed

+4
-12
lines changed

3 files changed

+4
-12
lines changed

SourcepawnCondenser/SourcepawnCondenser/SourcemodDefinition/SMDefinition.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ public void AppendFiles(IEnumerable<string> paths, out List<string> rejectedPath
7373
foreach (var file in files)
7474
{
7575
var fInfo = new FileInfo(file);
76-
var subCondenser = new Condenser(File.ReadAllText(fInfo.FullName), fInfo.Name);
76+
var subCondenser = new Condenser(File.ReadAllText(fInfo.FullName), fInfo.FullName);
7777
var subDefinition = subCondenser.Condense();
7878
Functions.AddRange(subDefinition.Functions);
7979
Enums.AddRange(subDefinition.Enums);

UI/Components/EditorElement/EditorElement.xaml.cs

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -661,28 +661,21 @@ private void ParseIncludes(object sender, EventArgs e)
661661
var text = el.editor.Document.Text;
662662
if (fInfo.Extension.Trim('.').ToLowerInvariant() == "inc")
663663
{
664-
definitions[i] =
665-
new Condenser(text
666-
, fInfo.Name).Condense();
664+
definitions[i] = new Condenser(text, fInfo.FullName).Condense();
667665
}
668666

669667
if (fInfo.Extension.Trim('.').ToLowerInvariant() == "sp")
670668
{
671669
if (el.IsLoaded)
672670
{
673671
caret = el.editor.CaretOffset;
674-
definitions[i] =
675-
new Condenser(text, fInfo.Name)
676-
.Condense();
672+
definitions[i] = new Condenser(text, fInfo.FullName).Condense();
677673
currentFunctions = definitions[i].Functions;
678674
if (el == ce)
679675
{
680676
currentSmDef = definitions[i];
681677
var caret1 = caret;
682-
currentSmDef.currentFunction =
683-
currentFunctions.FirstOrDefault(
684-
func => func.Index <= caret1 && caret1 <= func.EndPos);
685-
678+
currentSmDef.currentFunction = currentFunctions.FirstOrDefault(func => func.Index <= caret1 && caret1 <= func.EndPos);
686679
}
687680
}
688681
}

UI/Components/EditorElement/EditorElementGoToDefinition.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ public partial class EditorElement
2020
public async Task GoToDefinition(MouseButtonEventArgs e)
2121
{
2222
var word = GetWordAtMousePosition(e);
23-
Debug.Print($"The word: {word}");
2423
if (word.Trim().Length == 0)
2524
{
2625
return;

0 commit comments

Comments
 (0)