### Godot version

 Latest 4.0.dev (a3a42159e31db27f8ae7c1ecad6a9ed417cb05de)

### System information

Ubuntu 22.04.1 LTS

### Issue description

![image](https://user-images.githubusercontent.com/85438892/214476911-0ce83a43-b959-4b13-88fd-d6b9af0cd63a.png)

### Steps to reproduce

Open any script

### Minimal reproduction project

N/A
XFlush(x11_display);
	
	XEvent ev = {};
	while (XCheckIfEvent(x11_display, &ev, _predicate_all_events, nullptr)) {
		
		if (XFilterEvent(&ev, None)) {
			
			
			continue;
		}
		
		
		
		if (ev.type == SelectionRequest) {
			_handle_selection_request_event(&(ev.xselectionrequest));
			continue;
		}
		r_events.push_back(ev);
	}
}
DisplayServer::WindowID DisplayServerX11::window_get_active_popup() const {