Make "Save Folder as Workspace" in Save Session dialog translatable

Fix #9375, close #9383
This commit is contained in:
mere-human 2021-01-11 20:37:10 +02:00 committed by Don HO
parent 1364b199b4
commit 41c4180b2e
No known key found for this signature in database
GPG Key ID: 6C429F1D8D84F46E
2 changed files with 4 additions and 1 deletions

View File

@ -1392,6 +1392,7 @@ Find in all files except exe, obj && log:
<find-result-hits value="($INT_REPLACE$ hits)"/> <find-result-hits value="($INT_REPLACE$ hits)"/>
<find-result-line-prefix value="Line"/> <!-- Must not begin with space or tab character --> <find-result-line-prefix value="Line"/> <!-- Must not begin with space or tab character -->
<find-regex-zero-length-match value="zero length match" /> <find-regex-zero-length-match value="zero length match" />
<session-save-folder-as-workspace value="Save Folder as Workspace" />
</MiscStrings> </MiscStrings>
</Native-Langue> </Native-Langue>
</NotepadPlus> </NotepadPlus>

View File

@ -2326,7 +2326,9 @@ const TCHAR * Notepad_plus::fileSaveSession(size_t nbFile, TCHAR ** fileNames)
} }
fDlg.setExtFilter(TEXT("All types"), TEXT(".*")); fDlg.setExtFilter(TEXT("All types"), TEXT(".*"));
const bool isCheckboxActive = _pFileBrowser && !_pFileBrowser->isClosed(); const bool isCheckboxActive = _pFileBrowser && !_pFileBrowser->isClosed();
fDlg.setCheckbox(TEXT("Save Folder as Workspace"), isCheckboxActive); const generic_string checkboxLabel = _nativeLangSpeaker.getLocalizedStrFromID("session-save-folder-as-workspace",
TEXT("Save Folder as Workspace"));
fDlg.setCheckbox(checkboxLabel.c_str(), isCheckboxActive);
sessionFileName = fDlg.doSaveDlg(); sessionFileName = fDlg.doSaveDlg();
return fileSaveSession(nbFile, fileNames, sessionFileName, fDlg.getCheckboxState()); return fileSaveSession(nbFile, fileNames, sessionFileName, fDlg.getCheckboxState());