impr: Clean up window setup code

This commit is contained in:
WerWolv
2025-08-10 12:34:03 +02:00
parent 3e98d0a0f8
commit 5028b354cc
16 changed files with 120 additions and 129 deletions

View File

@@ -1,5 +1,11 @@
#include <hex/api/events/requests_interaction.hpp>
#include <hex/api/task_manager.hpp>
#include <hex/api/content_registry.hpp>
#include <hex/api/tutorial_manager.hpp>
#include <hex/api/shortcut_manager.hpp>
#include <hex/api/events/events_lifecycle.hpp>
#include <hex/helpers/utils.hpp>
#include <init/splash_window.hpp>
@@ -35,11 +41,26 @@ namespace hex::init {
return splashWindow;
}
void initializationFinished() {
ContentRegistry::Settings::impl::store();
ContentRegistry::Settings::impl::load();
EventImHexStartupFinished::post();
TutorialManager::init();
#if defined(OS_MACOS)
ShortcutManager::enableMacOSMode();
#endif
}
/**
* @brief Deinitializes ImHex by running all exit tasks
*/
void deinitializeImHex() {
ContentRegistry::Settings::impl::store();
// Run exit tasks
init::runExitTasks();