copy history excludes appended filename path segment; always check open output folder, unless manually changing registry

This commit is contained in:
shunf4
2024-09-03 00:21:26 +08:00
parent fb962a8070
commit dee3259e58
4 changed files with 19 additions and 7 deletions

View File

@@ -63,6 +63,7 @@ bool CCopyDialog::OnInit()
m_sizeMinWindow.cy = (RECT_SIZE_Y(rc))*4/5;
/////////////////////////////////////////////////////////
m_strRealFileName.Empty();
ValueBeforeAppendingFilename.Empty();
if (IsDirectory(m_currentFolderPrefix))
{
EnableItem(IDC_COPY_ADD_FILE_NAME, false);
@@ -264,12 +265,16 @@ void CCopyDialog::OnButtonAddFileName()
}
if (strLastDir != m_strRealFileName)
{
ValueBeforeAppendingFilename = currentPath;
currentPath += L'\\';
currentPath += m_strRealFileName;
_path.SetText(currentPath);
isActuallyAppendingFilename = true;
} else {
_path.SetText(currentPath.Mid(0, n));
isActuallyAppendingFilename = false;
}
_path.SetFocus();
}