| 233 | } |
| 234 | |
| 235 | void CColorCopApp::CloseApplication() { |
| 236 | CString settingsFolder = GetSettingsFolder(); |
| 237 | CString strInitFile = settingsFolder + INI_FILE; |
| 238 | |
| 239 | TRACE(_T("Portable mode: %d\n"), m_PortableMode); |
| 240 | TRACE(_T("INI path: %s\n"), strInitFile.GetString()); |
| 241 | |
| 242 | |
| 243 | if (!m_PortableMode) { |
| 244 | // Ensure folder exists in installed mode |
| 245 | CreateDirectory(settingsFolder, NULL); |
| 246 | } |
| 247 | |
| 248 | CFile file; |
| 249 | if (file.Open(strInitFile, CFile::modeWrite | CFile::modeCreate)) { |
| 250 | CArchive ar(&file, CArchive::store); |
| 251 | Serialize(ar); |
| 252 | } |
| 253 | } |
| 254 | |
| 255 | void CColorCopApp::Serialize(CArchive& ar) { |
| 256 | if (ar.IsStoring()) { |
nothing calls this directly
no outgoing calls
no test coverage detected