aboutsummaryrefslogtreecommitdiffstats
path: root/src/screens
diff options
context:
space:
mode:
Diffstat (limited to 'src/screens')
-rw-r--r--src/screens/UScreenEditSub.pas13
-rw-r--r--src/screens/UScreenSingModi.pas1
2 files changed, 11 insertions, 3 deletions
diff --git a/src/screens/UScreenEditSub.pas b/src/screens/UScreenEditSub.pas
index 07113363..d30781fe 100644
--- a/src/screens/UScreenEditSub.pas
+++ b/src/screens/UScreenEditSub.pas
@@ -876,9 +876,8 @@ begin
NStart := CurrentNote;
Lines[0].Line[CNew].Start := Lines[0].Line[CStart].Note[NStart].Start;
Lines[0].Line[CNew].Lyric := '';
- Lines[0].Line[CNew].LyricWidth := 0;
Lines[0].Line[CNew].End_ := 0;
- Lines[0].Line[CNew].BaseNote := 0; // 0.5.0: we modify it later in this procedure
+ Lines[0].Line[CNew].BaseNote := 0;//High(Integer); // TODO: High (Integer) will causes a memory exception later in this procedure. Weird!
Lines[0].Line[CNew].HighNote := -1;
SetLength(Lines[0].Line[CNew].Note, 0);
@@ -905,6 +904,16 @@ begin
Lines[0].Line[CStart].Note[NStart-1].Length;
SetLength(Lines[0].Line[CStart].Note, Lines[0].Line[CStart].HighNote + 1);
+ //recalculate BaseNote of the divided Sentence
+ with Lines[0].Line[CStart] do
+ begin
+ BaseNote := High(Integer);
+
+ For N := 0 to HighNote do
+ if Note[N].Tone < BaseNote then
+ BaseNote := Note[N].Tone;
+ end;
+
Lines[0].Current := Lines[0].Current + 1;
CurrentNote := 0;
Lines[0].Line[Lines[0].Current].Note[CurrentNote].Color := 1;
diff --git a/src/screens/UScreenSingModi.pas b/src/screens/UScreenSingModi.pas
index 525e06a3..75c7195e 100644
--- a/src/screens/UScreenSingModi.pas
+++ b/src/screens/UScreenSingModi.pas
@@ -167,7 +167,6 @@ begin
Result.Sentence[I].Start := Lines.Line[I].Start;
Result.Sentence[I].StartNote := Lines.Line[I].Note[0].Start;
Result.Sentence[I].Lyric := Lines.Line[I].Lyric;
- Result.Sentence[I].LyricWidth := Lines.Line[I].LyricWidth;
Result.Sentence[I].End_ := Lines.Line[I].End_;
Result.Sentence[I].BaseNote := Lines.Line[I].BaseNote;
Result.Sentence[I].HighNote := Lines.Line[I].HighNote;