MCPcopy Create free account
hub / github.com/DISTRHO/Cardinal / Initialize

Method Initialize

plugins/Cardinal/src/DearImGui/imgui.cpp:4198–4227  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4196}
4197
4198void ImGui::Initialize(ImGuiContext* context)
4199{
4200 ImGuiContext& g = *context;
4201 IM_ASSERT(!g.Initialized && !g.SettingsLoaded);
4202
4203 // Add .ini handle for ImGuiWindow type
4204 {
4205 ImGuiSettingsHandler ini_handler;
4206 ini_handler.TypeName = "Window";
4207 ini_handler.TypeHash = ImHashStr("Window");
4208 ini_handler.ClearAllFn = WindowSettingsHandler_ClearAll;
4209 ini_handler.ReadOpenFn = WindowSettingsHandler_ReadOpen;
4210 ini_handler.ReadLineFn = WindowSettingsHandler_ReadLine;
4211 ini_handler.ApplyAllFn = WindowSettingsHandler_ApplyAll;
4212 ini_handler.WriteAllFn = WindowSettingsHandler_WriteAll;
4213 g.SettingsHandlers.push_back(ini_handler);
4214 }
4215
4216 // Add .ini handle for ImGuiTable type
4217 TableSettingsInstallHandler(context);
4218
4219 // Create default viewport
4220 ImGuiViewportP* viewport = IM_NEW(ImGuiViewportP)();
4221 g.Viewports.push_back(viewport);
4222
4223#ifdef IMGUI_HAS_DOCK
4224#endif
4225
4226 g.Initialized = true;
4227}
4228
4229// This function is merely here to free heap allocations.
4230void ImGui::Shutdown(ImGuiContext* context)

Callers

nothing calls this directly

Calls 2

ImHashStrFunction · 0.85
push_backMethod · 0.80

Tested by

no test coverage detected