### Godot version

4.0

### System information

Windows 11

### Issue description

So on my monitor with 2560x1440 resolution retrieved by the `DisplayServer.get_window_size` method shows 2562x1442, which I think is incorrect. A similar result returned by `get_viewport().size`. But it's become correct if the `Resizable` property is turned on.

![image](https://user-images.githubusercontent.com/3036176/212492776-5c09b12e-d25a-4951-8392-54f5a5e3bece.png)


### Steps to reproduce

Create the project, add a label to observe the resolution text, set the full-screen mode in the project settings, toggle off the `Resizable` property, and run the project.

### Minimal reproduction project

[TestResolution.zip](https://github.com/godotengine/godot/files/10418682/TestResolution.zip)

_send_window_event(windows[window_id], WINDOW_EVENT_MOUSE_EXIT);
			} else if (window_mouseover_id != INVALID_WINDOW_ID && windows.has(window_mouseover_id)) {
				
				
				track_mouse_leave_event(windows[window_mouseover_id].hWnd);
			}
		} break;
		case WM_INPUT: {
			if (mouse_mode != MOUSE_MODE_CAPTURED || !use_raw_input) {
				break;
			}
			UINT dwSize;
			GetRawInputData((HRAWINPUT)lParam, RID_INPUT, nullptr, &dwSize, sizeof(RAWINPUTHEADER));
			LPBYTE lpb = new BYTE[dwSize];
			if (lpb == nullptr) {
				return 0;
			}
			if (GetRawInputData((HRAWINPUT)lParam, RID_INPUT, lpb, &dwSize, sizeof(RAWINPUTHEADER)) != dwSize) {
				OutputDebugString(TEXT("GetRawInputData does not return correct size !\n"));
			}
			RAWINPUT *raw = (RAWINPUT *)lpb;
			if (raw->header.dwType == RIM_TYPEMOUSE) {
				Ref<InputEventMouseMotion> mm;
				mm.instantiate();
				mm->set_window_id(window_id);
				mm->set_ctrl_pressed(control_mem);
				mm->set_shift_pressed(shift_mem);
				mm->set_alt_pressed(alt_mem);
				mm->set_pressure((raw->data.mouse.ulButtons & RI_MOUSE_LEFT_BUTTON_DOWN) ? 1.0f : 0.0f);
				mm->set_button_mask(last_button_state);