From 6618985e3d0355b6c2ffb098635661a50134b834 Mon Sep 17 00:00:00 2001 From: Takashi Sawanaka Date: Mon, 17 Jun 2019 00:45:24 +0900 Subject: [PATCH] MergeEditView.cpp: When merging differences in the selected area, if the selected area completely encloses a diff block, do a normal merge instead of a word-level merge. (2) --- Src/MergeEditView.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Src/MergeEditView.cpp b/Src/MergeEditView.cpp index f58622cc0..ffef2b091 100644 --- a/Src/MergeEditView.cpp +++ b/Src/MergeEditView.cpp @@ -354,7 +354,7 @@ void CMergeEditView::GetFullySelectedDiffs(int & firstDiff, int & lastDiff, int if (ptStart != ptEnd) { VERIFY(pd->m_diffList.GetDiff(firstDiff, di)); - if (lastLineIsNotInDiff && (firstLineIsNotInDiff || di.dbegin == firstLine)) + if (lastLineIsNotInDiff && (firstLineIsNotInDiff || (di.dbegin == firstLine && ptStart.x == 0))) { firstWordDiff = -1; return; @@ -3461,7 +3461,7 @@ void CMergeEditView::OnOpenFileWithEditor() return; int nRealLine = ComputeRealLine(GetCursorPos().y) + 1; - theApp.OpenFileToExternalEditor(sFileName.c_str(), nRealLine); + theApp.OpenFileToExternalEditor(sFileName, nRealLine); } /** -- 2.11.0