### 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)

KeySym keysym_keycode = 0; 
	KeySym keysym_unicode = 0; 
	
	char str[256] = {};
	XKeyEvent xkeyevent_no_mod = *xkeyevent;
	xkeyevent_no_mod.state &= ~ShiftMask;
	xkeyevent_no_mod.state &= ~ControlMask;
	XLookupString(xkeyevent, str, 255, &keysym_unicode, nullptr);
	XLookupString(&xkeyevent_no_mod, nullptr, 0, &keysym_keycode, nullptr);
	String keysym;
	if (xkb_keysym_to_utf32 && xkb_keysym_to_upper) {
		KeySym keysym_unicode_nm = 0; 
		XLookupString(&xkeyevent_no_mod, nullptr, 0, &keysym_unicode_nm, nullptr);
		keysym = String::chr(xkb_keysym_to_utf32(xkb_keysym_to_upper(keysym_unicode_nm)));
	}
	
	if (!xmbstring) {
		
		xmbstring = (char *)memalloc(sizeof(char) * 8);
		xmblen = 8;