| 1395 | } |
| 1396 | |
| 1397 | audacity::BasicSettings *PluginManager::GetSettings() |
| 1398 | { |
| 1399 | if (!mSettings) |
| 1400 | { |
| 1401 | mSettings = sFactory(FileNames::PluginSettings()); |
| 1402 | |
| 1403 | // Check for a settings version that we can understand |
| 1404 | if (mSettings->HasEntry(SETVERKEY)) |
| 1405 | { |
| 1406 | wxString setver = mSettings->Read(SETVERKEY, SETVERKEY); |
| 1407 | if (setver < SETVERCUR ) |
| 1408 | { |
| 1409 | // This is where we'd put in conversion code when the |
| 1410 | // settings version changes. |
| 1411 | // |
| 1412 | // Should also check for a settings file that is newer than |
| 1413 | // what we can understand. |
| 1414 | } |
| 1415 | } |
| 1416 | else |
| 1417 | { |
| 1418 | // Make sure is has a version string |
| 1419 | mSettings->Write(SETVERKEY, SETVERCUR); |
| 1420 | mSettings->Flush(); |
| 1421 | } |
| 1422 | } |
| 1423 | |
| 1424 | return mSettings.get(); |
| 1425 | } |
| 1426 | |
| 1427 | bool PluginManager::HasGroup(const RegistryPath & groupName) |
| 1428 | { |
no test coverage detected