mirror of
https://github.com/rizonesoft/Notepad3.git
synced 2026-06-28 21:02:59 +08:00
+ fix: correct return result of Styles export
This commit is contained in:
parent
4a7d64fcb1
commit
7ce31d8953
15
src/Styles.c
15
src/Styles.c
@ -819,14 +819,17 @@ bool Style_ExportToFile(const WCHAR* szFile, bool bForceAll)
|
||||
|
||||
bool ok = false;
|
||||
if (StringCchCompareXI(szFilePathNorm, Globals.IniFile) == 0) {
|
||||
ok = OpenSettingsFile();
|
||||
Style_ToIniSection(bForceAll);
|
||||
ok = CloseSettingsFile(true);
|
||||
if (OpenSettingsFile()) {
|
||||
Style_ToIniSection(bForceAll);
|
||||
ok = CloseSettingsFile(true);
|
||||
}
|
||||
}
|
||||
else {
|
||||
LoadIniFile(szFilePathNorm); // reset
|
||||
Style_ToIniSection(bForceAll);
|
||||
SaveIniFile(szFilePathNorm);
|
||||
// reset
|
||||
if (LoadIniFile(szFilePathNorm)) {
|
||||
Style_ToIniSection(bForceAll);
|
||||
ok = SaveIniFile(szFilePathNorm);
|
||||
}
|
||||
}
|
||||
return ok;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user