mirror of https://github.com/odrling/Aegisub
Hopefully fixed crash on search dialog.
Originally committed to SVN as r1861.
This commit is contained in:
parent
8e7f84c818
commit
d23733da21
|
@ -311,9 +311,11 @@ void SearchReplaceEngine::ReplaceNext(bool DoReplace) {
|
||||||
}
|
}
|
||||||
|
|
||||||
wxArrayInt sels = grid->GetSelection();
|
wxArrayInt sels = grid->GetSelection();
|
||||||
|
int firstLine = 0;
|
||||||
|
if (sels.Count() > 0) firstLine = sels[0];
|
||||||
// if selection has changed reset values
|
// if selection has changed reset values
|
||||||
if (sels[0] < curLine) {
|
if (firstLine < curLine) {
|
||||||
curLine = sels[0];
|
curLine = firstLine;
|
||||||
Modified = false;
|
Modified = false;
|
||||||
LastWasFind = true;
|
LastWasFind = true;
|
||||||
pos = 0;
|
pos = 0;
|
||||||
|
|
Loading…
Reference in New Issue