src/hbcore/image/hbiconanimationmanager.cpp
changeset 1 f7ac710697a9
parent 0 16d8024aca5e
child 2 06ff229162e9
equal deleted inserted replaced
0:16d8024aca5e 1:f7ac710697a9
   208 {
   208 {
   209     // Theme has changed, clear name list and animation data, and reload all
   209     // Theme has changed, clear name list and animation data, and reload all
   210     // animation definitions (or at least try to reload; some defs may now be
   210     // animation definitions (or at least try to reload; some defs may now be
   211     // missing if they were present in the previous theme but not in the new
   211     // missing if they were present in the previous theme but not in the new
   212     // one).
   212     // one).
   213     animations.clear();
   213     foreach (const QString &iconName, animations.keys()) {
       
   214         // Do not remove animations that were not created from files.
       
   215         if (animations.value(iconName).definitionFileName) {
       
   216             animations.remove(iconName);
       
   217         }
       
   218     }
   214     definitionFileNames.clear();
   219     definitionFileNames.clear();
   215     //
   220     //
   216     // Cannot use definitionFileNames here because it is cleared upon every
   221     // Cannot use definitionFileNames here because it is cleared upon every
   217     // theme change. Use allDefNames which contains all the names passed to
   222     // theme change. Use allDefNames which contains all the names passed to
   218     // addDefinitionFile() since the creation of this instance. This enables to
   223     // addDefinitionFile() since the creation of this instance. This enables to