瀏覽代碼

Bug fix: Extensions were not loaded when configuration is empty

Source commit: b8a25b7539ff4dff6b84714daae4df4e141e4164
Martin Prikryl 7 年之前
父節點
當前提交
4d9053616f
共有 1 個文件被更改,包括 7 次插入6 次删除
  1. 7 6
      source/windows/WinConfiguration.cpp

+ 7 - 6
source/windows/WinConfiguration.cpp

@@ -1144,8 +1144,9 @@ void __fastcall TWinConfiguration::LoadFrom(THierarchicalStorage * Storage)
 
     TCustomWinConfiguration::LoadFrom(Storage);
 
-    // This needs to be done even if there's no Configuration key in the storage,
+    // Following needs to be done even if there's no Configuration key in the storage,
     // so it cannot be in LoadData
+
     int EditorCount = FEditorList->Count;
     if (EditorCount == 0)
     {
@@ -1187,6 +1188,11 @@ void __fastcall TWinConfiguration::LoadFrom(THierarchicalStorage * Storage)
         FEditorList->Add(AlternativeEditor);
       }
     }
+
+    // Additionally, this needs to be after Locale is loaded
+    LoadExtensionTranslations();
+    // and this after the ExtensionsDeleted, ExtensionsOrder and ExtensionsShortCuts are loaded
+    LoadExtensionList();
   }
   __finally
   {
@@ -1436,11 +1442,6 @@ void __fastcall TWinConfiguration::LoadData(THierarchicalStorage * Storage)
   #pragma warn +eas
   #undef KEYEX
 
-  // Load after Locale
-  LoadExtensionTranslations();
-  // Load after the ExtensionsDeleted,  ExtensionsOrder and ExtensionsShortCuts
-  LoadExtensionList();
-
   // to reflect changes to PanelFont
   UpdateIconFont();