From b6a68c830ec3fecb573887fd561349099268cc20 Mon Sep 17 00:00:00 2001 From: Green Sky Date: Tue, 2 Sep 2025 10:57:34 +0200 Subject: [PATCH] misc stuff --- plugins/plugin_crdtnotes.cpp | 1 + src/solanaceae/crdtnotes/crdtnotes_sync.cpp | 2 +- src/solanaceae/crdtnotes_imgui/crdtnotes_imgui.cpp | 3 ++- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/plugins/plugin_crdtnotes.cpp b/plugins/plugin_crdtnotes.cpp index fb119eb..993a4f2 100644 --- a/plugins/plugin_crdtnotes.cpp +++ b/plugins/plugin_crdtnotes.cpp @@ -42,6 +42,7 @@ SOLANA_PLUGIN_EXPORT uint32_t solana_plugin_start(struct SolanaAPI* solana_api) g_crdtns = std::make_unique(*g_crdtn, *cs); // register types + PLUG_PROVIDE_INSTANCE(CRDTNotes, plugin_name, g_crdtn.get()); PLUG_PROVIDE_INSTANCE(CRDTNotesSync, plugin_name, g_crdtns.get()); PLUG_PROVIDE_INSTANCE(CRDTNotesEventI, plugin_name, g_crdtns.get()); } catch (const ResolveException& e) { diff --git a/src/solanaceae/crdtnotes/crdtnotes_sync.cpp b/src/solanaceae/crdtnotes/crdtnotes_sync.cpp index cf7766f..1a444c3 100644 --- a/src/solanaceae/crdtnotes/crdtnotes_sync.cpp +++ b/src/solanaceae/crdtnotes/crdtnotes_sync.cpp @@ -81,7 +81,7 @@ float CRDTNotesSync::iterate(float time_delta) { _fetch_frontier_queue.erase(it); } - return 1.f; + return 2.f; } CRDTNotes::Doc* CRDTNotesSync::getDoc(const CRDTNotes::DocID& doc_id) { diff --git a/src/solanaceae/crdtnotes_imgui/crdtnotes_imgui.cpp b/src/solanaceae/crdtnotes_imgui/crdtnotes_imgui.cpp index 678f7fb..5e727bc 100644 --- a/src/solanaceae/crdtnotes_imgui/crdtnotes_imgui.cpp +++ b/src/solanaceae/crdtnotes_imgui/crdtnotes_imgui.cpp @@ -106,6 +106,7 @@ float CRDTNotesImGui::render(void) { const std::string docid_str = "Doc " + detail::to_hex(docid); bool open = true; + ImGui::SetNextWindowSize({200, 200}, ImGuiCond_Appearing); if (ImGui::Begin(docid_str.c_str(), &open)) { renderDoc(docid); } @@ -120,7 +121,7 @@ float CRDTNotesImGui::render(void) { } } - return 1.f; + return 2.f; } bool CRDTNotesImGui::renderContactListContactSmall(const Contact4 c, const bool selected) const {