### Godot version

v4.0.beta.custom_build [eaf306e0b]

### System information

Windows 10

### Issue description

Selecting a `Window` node in the Editor's SceneTree results in the message
```
editor/editor_data.cpp:1058 - Parameter "p_node" is null.
```
and the Inspector shows empty content instead of the Window's properties.

I would expect, that clicking on a node in the SceneTree lets me edit the properties of the node.

Bisecting shows that this behavior got introduced in #71770

### Steps to reproduce

1. Create a Window node
2. Click on the Window node in the Editor's SceneTree

### Minimal reproduction project

N/A
return leading_stylebox.pinned && leading_stylebox.stylebox == p_stylebox;
}
ThemeTypeEditor::ThemeTypeEditor() {
	VBoxContainer *main_vb = memnew(VBoxContainer);
	add_child(main_vb);
	HBoxContainer *type_list_hb = memnew(HBoxContainer);
	main_vb->add_child(type_list_hb);
	Label *type_list_label = memnew(Label);
	type_list_label->set_text(TTR("Type:"));
	type_list_hb->add_child(type_list_label);
	theme_type_list = memnew(OptionButton);
	theme_type_list->set_h_size_flags(SIZE_EXPAND_FILL);
	theme_type_list->set_text_overrun_behavior(TextServer::OVERRUN_TRIM_ELLIPSIS);
	type_list_hb->add_child(theme_type_list);
	theme_type_list->connect("item_selected", callable_mp(this, &ThemeTypeEditor::_list_type_selected));
	add_type_button = memnew(Button);
	add_type_button->set_tooltip_text(TTR("Add a type from a list of available types or create a new one."));
	type_list_hb->add_child(add_type_button);
	add_type_button->connect("pressed", callable_mp(this, &ThemeTypeEditor::_add_type_button_cbk));
	HBoxContainer *type_controls = memnew(HBoxContainer);
	main_vb->add_child(type_controls);
	show_default_items_button = memnew(CheckButton);
	show_default_items_button->set_h_size_flags(SIZE_EXPAND_FILL);
	show_default_items_button->set_text(TTR("Show Default"));
	show_default_items_button->set_tooltip_text(TTR("Show default type items alongside items that have been overridden."));
	show_default_items_button->set_pressed(true);
	type_controls->add_child(show_default_items_button);
	show_default_items_button->connect("pressed", callable_mp(this, &ThemeTypeEditor::_update_type_items));
	Button *add_default_items_button = memnew(Button);
	add_default_items_button->set_h_size_flags(SIZE_EXPAND_FILL);