### Godot version

v4.1.1.stable.official [bd6af8e0e]

### System information

Godot v4.1.1.stable - Debian GNU/Linux trixie/sid trixie - Vulkan (Compatibility) - Mesa Intel(R) HD Graphics 520 (SKL GT2) () - Intel(R) Core(TM) i7-6500U CPU @ 2.50GHz (4 Threads)

### Issue description

After right clicking in thet "Filter Nodes" menu in the scene tree dock, the sub-menu is populated with a "Search" icon.

If I later switch themes in the same session, this icon is never updated to match the new theme.

![image](https://github.com/godotengine/godot/assets/660911/14336bb3-12ca-48c8-b030-8ada6ac27ec6)


### Steps to reproduce

1. Right click in the "Filter Nodes" menu in scene tree dock
2. Switch themes
3. Right click again in the "Filter Nodes" menu

Expected result: Icon has updated to match the theme I am currently using
Actual result: Icon is still using the theme I launched Godot with

### Minimal reproduction project

N/A
String filter_parameter;
	switch (p_option) {
		case FILTER_BY_TYPE: {
			filter_parameter = "type";
		} break;
		case FILTER_BY_GROUP: {
			filter_parameter = "group";
		} break;
	}
	if (!filter_parameter.is_empty()) {
		set_filter((get_filter() + " " + filter_parameter + ":").strip_edges());
		filter->set_caret_column(filter->get_text().length());
		filter->grab_focus();
	}
}
void SceneTreeDock::_append_filter_options_to(PopupMenu *p_menu, bool p_include_separator) {
	if (p_include_separator) {
		p_menu->add_separator();
		p_menu->set_item_text(-1, TTR("Filters"));
		p_menu->set_item_icon(-1, get_theme_icon(SNAME("Search"), SNAME("EditorIcons")));
		p_menu->set_item_indent(-1, -2);
	}
	p_menu->add_item(TTR("Filter by Type"), FILTER_BY_TYPE);
	p_menu->add_item(TTR("Filter by Group"), FILTER_BY_GROUP);
	p_menu->set_item_icon(p_menu->get_item_index(FILTER_BY_TYPE), get_theme_icon(SNAME("Node"), SNAME("EditorIcons")));
	p_menu->set_item_icon(p_menu->get_item_index(FILTER_BY_GROUP), get_theme_icon(SNAME("Groups"), SNAME("EditorIcons")));
	p_menu->set_item_tooltip(p_menu->get_item_index(FILTER_BY_TYPE), TTR("Selects all Nodes of the given type."));
	p_menu->set_item_tooltip(p_menu->get_item_index(FILTER_BY_GROUP), TTR("Selects all Nodes belonging to the given group.\nIf empty, selects any Node belonging to any group."));
}
String SceneTreeDock::get_filter() {