From dbe2b698b14b015a002d69187b3c3e2f1bcac952 Mon Sep 17 00:00:00 2001 From: Don HO Date: Sun, 11 Jun 2017 13:07:48 +0200 Subject: [PATCH] Fix replace in files regression. Make focus always on main editor, so we don't need to set document as read only while it's being peeked. --- PowerEditor/src/NppNotification.cpp | 1 + PowerEditor/src/WinControls/DocumentMap/documentSnapshot.cpp | 1 - 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/PowerEditor/src/NppNotification.cpp b/PowerEditor/src/NppNotification.cpp index d2c21bd9f..9318e1daf 100644 --- a/PowerEditor/src/NppNotification.cpp +++ b/PowerEditor/src/NppNotification.cpp @@ -177,6 +177,7 @@ BOOL Notepad_plus::notify(SCNotification *notification) if (pBuf != currentBufMain && pBuf != currentBufSub) // if hover on other tab { _documentPeeker.doDialog(p, pBuf, *(const_cast(pTabDocView->getScintillaEditView()))); + _pEditView->getFocus(); } else // if hover on current active tab { diff --git a/PowerEditor/src/WinControls/DocumentMap/documentSnapshot.cpp b/PowerEditor/src/WinControls/DocumentMap/documentSnapshot.cpp index 687ed700d..de2d0ce56 100644 --- a/PowerEditor/src/WinControls/DocumentMap/documentSnapshot.cpp +++ b/PowerEditor/src/WinControls/DocumentMap/documentSnapshot.cpp @@ -100,7 +100,6 @@ void DocumentPeeker::syncDisplay(Buffer *buf, ScintillaEditView & scintSource) _pPeekerView->showMargin(2, false); _pPeekerView->showMargin(3, false); - _pPeekerView->execute(SCI_SETREADONLY, true); _pPeekerView->execute(SCI_SETCARETSTYLE, CARETSTYLE_INVISIBLE); Window::display(); }