Fix 1756: Disable seek when selecting text on Decompiler Widget (#1917)

This commit is contained in:
Itay Cohen 2019-12-14 12:42:24 +02:00 committed by GitHub
parent 807e24edc6
commit 108fff8925
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -204,6 +204,12 @@ void DecompilerWidget::connectCursorPositionChanged(bool disconnect)
void DecompilerWidget::cursorPositionChanged()
{
// Do not perform seeks along with the cursor while selecting multiple lines
if (!ui->textEdit->textCursor().selectedText().isEmpty())
{
return;
}
size_t pos = ui->textEdit->textCursor().position();
RVA offset = code.OffsetForPosition(pos);
if (offset != RVA_INVALID && offset != Core()->getOffset()) {