* UIInspector now stores move-only event connections in a node-based map, avoiding the MSVC vector copy error.

* Batch results now initialize as a JSON object. The previous initialization created an array, causing both reported Linux and macOS test failures.
This commit is contained in:
Martín Lucas Golini
2026-09-28 10:10:44 -03:00
parent 4ffba20d07
commit 27bfbb4b3a
2 changed files with 5 additions and 2 deletions
+4 -1
View File
@@ -7,6 +7,7 @@
#include <eepp/ui/uiscenenode.hpp>
#include <eepp/ui/uiwidget.hpp>
#include <string>
#include <unordered_map>
namespace EE { namespace UI {
@@ -48,7 +49,9 @@ class EE_API UIInspector {
Scene::Node* node{ nullptr };
Scene::EventConnection close;
};
using NodeHandles = UnorderedMap<std::string, NodeEntry>;
// EventConnection is move-only; keep these entries in a node-based map so map operations do not
// require copying the connection through the dense map's vector storage.
using NodeHandles = std::unordered_map<std::string, NodeEntry>;
using ReverseNodeHandles = UnorderedMap<Scene::Node*, std::string>;
std::string registerNode( Scene::Node* node, const char* prefix, NodeHandles& handles,
+1 -1
View File
@@ -192,7 +192,7 @@ struct UIInspectorServer::Impl {
Uint64 client;
json id;
json commands;
json results{ json::object() };
json results = json::object();
std::map<std::string, json> named;
size_t index{ 0 };
unsigned frames{ 0 };