diff --git a/plugins/builtin/source/content/settings_entries.cpp b/plugins/builtin/source/content/settings_entries.cpp index 4124dd5d3..2c873ad67 100644 --- a/plugins/builtin/source/content/settings_entries.cpp +++ b/plugins/builtin/source/content/settings_entries.cpp @@ -585,13 +585,13 @@ namespace hex::plugin::builtin { if (data.is_null()) return; + for (auto &[priority, menuItem] : ContentRegistry::Interface::impl::getMenuItemsMutable()) + menuItem.toolbarIndex = -1; + auto toolbarItems = data.get>>(); if (toolbarItems.empty()) return; - for (auto &[priority, menuItem] : ContentRegistry::Interface::impl::getMenuItemsMutable()) - menuItem.toolbarIndex = -1; - for (auto &[priority, menuItem] : ContentRegistry::Interface::impl::getMenuItemsMutable()) { for (const auto &[index, value] : toolbarItems) { const auto &[name, color] = value;