Merge branch 'master' into feature/profiles

This commit is contained in:
Nikolaj Olsson 2019-03-12 21:15:29 +01:00
commit 1e1f113f13
2 changed files with 36 additions and 2 deletions

View File

@ -404,6 +404,8 @@
<Word from="Interesuju" to="Zanimaju" />
<Word from="interesuju" to="zanimaju" />
<Word from="isekao" to="izrezao" />
<Word from="islednik" to="detektiv" />
<Word from="Islednik" to="Detektiv" />
<Word from="isljednici" to="detektivi" />
<Word from="isljednicima" to="detektivima" />
<Word from="isljednike" to="detektive" />
@ -703,6 +705,7 @@
<Word from="merdevine" to="ljestve" />
<Word from="merdevinama" to="ljestvama" />
<Word from="merljivo" to="mjerljivo" />
<Word from="mešajte" to="miješajte" />
<Word from="mešane" to="miješane" />
<Word from="mešavina" to="mješavina" />
<Word from="mešavine" to="mješavine" />
@ -991,6 +994,7 @@
<Word from="Plenom" to="Plijenom" />
<Word from="pljenom" to="plijenom" />
<Word from="Pljenom" to="Plijenom" />
<Word from="pocetku" to="početku" />
<Word from="počeću" to="počet ću" />
<Word from="poči" to="poći" />
<Word from="podjelimo" to="podijelimo" />
@ -1584,6 +1588,7 @@
<Word from="tvrtci" to="tvrtki" />
<Word from="ubede" to="uvjere" />
<Word from="Ubeđivao" to="Uvjeravao" />
<Word from="ubeđivao" to="uvjeravao" />
<Word from="ubeđivati" to="uvjeravati" />
<Word from="ubijedio" to="uvjerio" />
<Word from="ubjeđivati" to="uvjeravati" />
@ -3103,8 +3108,8 @@
<RegEx find="varać" replaceWith="varat ć" />
<RegEx find="\bvarvar" replaceWith="barbar" />
<RegEx find="\bVarvar" replaceWith="Barbar" />
<RegEx find="vaskrsn" replaceWith="uskrns" />
<RegEx find="Vaskrsn" replaceWith="Uskrns" />
<RegEx find="vaskrs[en]" replaceWith="uskrns" />
<RegEx find="Vaskrs[en]" replaceWith="Uskrns" />
<RegEx find="vaspitan" replaceWith="obrazovan" />
<RegEx find="Vaspitan" replaceWith="Obrazovan" />
<RegEx find="vaspitn" replaceWith="obrazovn" />
@ -3302,6 +3307,7 @@
<RegEx find="(?&lt;!hva)lisa([ol])" replaceWith="lira$1" />
<RegEx find="(?&lt;!hva)lisati" replaceWith="lirati" />
<RegEx find="irać" replaceWith="irat ć" />
<RegEx find="izovan " replaceWith="iziran" />
<RegEx find="jći" replaceWith="jući" />
<RegEx find="jdin" replaceWith="jedin" />
<RegEx find="kodnevnic" replaceWith="kodnevic" />
@ -3418,6 +3424,7 @@
<RegEx find="s([čć])" replaceWith="š$1" />
<RegEx find="seden" replaceWith="sjeden" />
<RegEx find="selektuj" replaceWith="odaber" />
<RegEx find="sljen" replaceWith="slen" />
<RegEx find="sjp" replaceWith="spj" />
<RegEx find="smeva" replaceWith="smijava" />
<RegEx find="stać(?!i)" replaceWith="stat ć" />

View File

@ -14600,19 +14600,46 @@ namespace Nikse.SubtitleEdit.Forms
{
if (SubtitleListview1.SelectedItems.Count == 1)
{
var historyAdded = false;
var idx = SubtitleListview1.SelectedItems[0].Index;
var p = _subtitle.Paragraphs[idx];
var next = _subtitle.GetParagraphOrDefault(idx + 1);
if (next == null || next.StartTime.TotalMilliseconds > p.EndTime.TotalMilliseconds + Configuration.Settings.General.SubtitleMaximumDisplayMilliseconds + Configuration.Settings.General.MinimumMillisecondsBetweenLines)
{
MakeHistoryForUndo(string.Format(_language.BeforeX, Configuration.Settings.Language.Settings.AdjustExtendCurrentSubtitle));
historyAdded = true;
p.EndTime.TotalMilliseconds = p.StartTime.TotalMilliseconds + Configuration.Settings.General.SubtitleMaximumDisplayMilliseconds;
}
else if (next != null && next.StartTime.TotalMilliseconds > p.EndTime.TotalMilliseconds)
{
MakeHistoryForUndo(string.Format(_language.BeforeX, Configuration.Settings.Language.Settings.AdjustExtendCurrentSubtitle));
historyAdded = true;
p.EndTime.TotalMilliseconds = next.StartTime.TotalMilliseconds - Configuration.Settings.General.MinimumMillisecondsBetweenLines;
}
if (_subtitleAlternate != null && Configuration.Settings.General.AllowEditOfOriginalSubtitle)
{
var original = Utilities.GetOriginalParagraph(idx, p, _subtitleAlternate.Paragraphs);
if (original != null)
{
var originalNext = _subtitleAlternate.GetParagraphOrDefault(_subtitleAlternate.GetIndex(original) + 1);
if (originalNext == null || originalNext.StartTime.TotalMilliseconds > original.EndTime.TotalMilliseconds + Configuration.Settings.General.SubtitleMaximumDisplayMilliseconds + Configuration.Settings.General.MinimumMillisecondsBetweenLines)
{
if (!historyAdded)
{
MakeHistoryForUndo(string.Format(_language.BeforeX, Configuration.Settings.Language.Settings.AdjustExtendCurrentSubtitle));
}
original.EndTime.TotalMilliseconds = original.StartTime.TotalMilliseconds + Configuration.Settings.General.SubtitleMaximumDisplayMilliseconds;
}
else if (originalNext != null && originalNext.StartTime.TotalMilliseconds > original.EndTime.TotalMilliseconds)
{
if (!historyAdded)
{
MakeHistoryForUndo(string.Format(_language.BeforeX, Configuration.Settings.Language.Settings.AdjustExtendCurrentSubtitle));
}
original.EndTime.TotalMilliseconds = originalNext.StartTime.TotalMilliseconds - Configuration.Settings.General.MinimumMillisecondsBetweenLines;
}
}
}
RefreshSelectedParagraph();
e.SuppressKeyPress = true;
}