### Godot version

v4.0.beta15.mono.official [4fa6edc88]

### System information

Linux, Xorg

### Issue description

The entire window loses focus if you ungrab focus from a Control. 
This doesn't seem to happen in Beta 14 and older betas.

### Steps to reproduce

1. Create a Control that can grab focus (tested with LineEdit and TextEdit)
2. Grab focus
3. Release focus via release_focus() or hiding the node

### Minimal reproduction project

[FocusMinimal.zip](https://github.com/godotengine/godot/files/10498175/FocusMinimal.zip)

"row_resize",
			"col_resize",
			"question_arrow"
		};
		img[i] = XcursorLibraryLoadImage(cursor_file[i], cursor_theme, cursor_size);
		if (!img[i]) {
			const char *fallback = nullptr;
			switch (i) {
				case CURSOR_POINTING_HAND:
					fallback = "pointer";
					break;
				case CURSOR_CROSS:
					fallback = "crosshair";
					break;
				case CURSOR_WAIT:
					fallback = "wait";
					break;
				case CURSOR_BUSY:
					fallback = "progress";
					break;
				case CURSOR_DRAG:
					fallback = "grabbing";
					break;
				case CURSOR_CAN_DROP:
					fallback = "hand1";
					break;
				case CURSOR_FORBIDDEN:
					fallback = "forbidden";
					break;
				case CURSOR_VSIZE: