| 165 | |
| 166 | |
| 167 | void ConfigManager::upgrade() |
| 168 | { |
| 169 | // Skip the upgrade if versions match |
| 170 | if ( m_version == LMMS_VERSION ) |
| 171 | { |
| 172 | return; |
| 173 | } |
| 174 | |
| 175 | ProjectVersion createdWith = m_version; |
| 176 | |
| 177 | if ( createdWith.setCompareType(ProjectVersion::Build) < "1.1.90" ) |
| 178 | { |
| 179 | upgrade_1_1_90(); |
| 180 | } |
| 181 | |
| 182 | if ( createdWith.setCompareType(ProjectVersion::Build) < "1.1.91" ) |
| 183 | { |
| 184 | upgrade_1_1_91(); |
| 185 | } |
| 186 | |
| 187 | // Don't use old themes as they break the UI (i.e. 0.4 != 1.0, etc) |
| 188 | if ( createdWith.setCompareType(ProjectVersion::Minor) != LMMS_VERSION ) |
| 189 | { |
| 190 | m_artworkDir = defaultArtworkDir(); |
| 191 | } |
| 192 | |
| 193 | // Bump the version, now that we are upgraded |
| 194 | m_version = LMMS_VERSION; |
| 195 | } |
| 196 | |
| 197 | QString ConfigManager::defaultVersion() const |
| 198 | { |
nothing calls this directly
no test coverage detected