### Godot version

4.1 Stable

### System information

MacBook Ventura 13.4

### Issue description

Undo/Redo manager `history_changed` events stop being emitted when clicking on the same editor inspector property. This also stops creating Undo/Redo events, so "undo" actions stop working.

### Steps to reproduce

The steps to reproduce is kind of finnicky, but I was able to reproduce it with relative easy using the "position" propert:

- Click "Y" position and change it to any value; press Enter.
- Click the "Y" position again and change it to any value; press Enter.
- Click the "Y" position again (again), and change it to any value; press Enter.

On the third time changing the value, "history_changed" events stop being emitted. Checking the "History" tab, you'll see only the two events are logged (other changes in the position are not).



### Minimal reproduction project

This can be reproduced in any project, but I'm attaching a project with an addon that logs a "history_changed" event on the console so you know when it stops being emitted.
[HistoryIssue.zip](https://github.com/godotengine/godot/files/12053128/HistoryIssue.zip)

ClassDB::bind_method(D_METHOD("create_action", "name", "merge_mode", "custom_context", "backward_undo_ops"), &EditorUndoRedoManager::create_action, DEFVAL(UndoRedo::MERGE_DISABLE), DEFVAL((Object *)nullptr), DEFVAL(false));
	ClassDB::bind_method(D_METHOD("commit_action", "execute"), &EditorUndoRedoManager::commit_action, DEFVAL(true));
	ClassDB::bind_method(D_METHOD("is_committing_action"), &EditorUndoRedoManager::is_committing_action);
	{
		MethodInfo mi;
		mi.name = "add_do_method";
		mi.arguments.push_back(PropertyInfo(Variant::OBJECT, "object"));
		mi.arguments.push_back(PropertyInfo(Variant::STRING_NAME, "method"));
		ClassDB::bind_vararg_method(METHOD_FLAGS_DEFAULT, "add_do_method", &EditorUndoRedoManager::_add_do_method, mi, varray(), false);
	}
	{
		MethodInfo mi;
		mi.name = "add_undo_method";
		mi.arguments.push_back(PropertyInfo(Variant::OBJECT, "object"));
		mi.arguments.push_back(PropertyInfo(Variant::STRING_NAME, "method"));
		ClassDB::bind_vararg_method(METHOD_FLAGS_DEFAULT, "add_undo_method", &EditorUndoRedoManager::_add_undo_method, mi, varray(), false);
	}
	ClassDB::bind_method(D_METHOD("add_do_property", "object", "property", "value"), &EditorUndoRedoManager::add_do_property);
	ClassDB::bind_method(D_METHOD("add_undo_property", "object", "property", "value"), &EditorUndoRedoManager::add_undo_property);
	ClassDB::bind_method(D_METHOD("add_do_reference", "object"), &EditorUndoRedoManager::add_do_reference);
	ClassDB::bind_method(D_METHOD("add_undo_reference", "object"), &EditorUndoRedoManager::add_undo_reference);
	ClassDB::bind_method(D_METHOD("get_object_history_id", "object"), &EditorUndoRedoManager::get_history_id_for_object);
	ClassDB::bind_method(D_METHOD("get_history_undo_redo", "id"), &EditorUndoRedoManager::get_history_undo_redo);
	ADD_SIGNAL(MethodInfo("history_changed"));
	ADD_SIGNAL(MethodInfo("version_changed"));
	BIND_ENUM_CONSTANT(GLOBAL_HISTORY);
	BIND_ENUM_CONSTANT(REMOTE_HISTORY);
	BIND_ENUM_CONSTANT(INVALID_HISTORY);
}
EditorUndoRedoManager *EditorUndoRedoManager::get_singleton() {