1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
use crate::X11Surface;
#[cfg(not(feature = "xlib"))]
use crate::XWindow;
use glib::translate::*;
#[cfg(any(feature = "xlib", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "xlib")))]
use x11::xlib::Window as XWindow;
impl X11Surface {
#[doc(alias = "gdk_x11_surface_get_xid")]
#[doc(alias = "get_xid")]
pub fn xid(&self) -> XWindow {
unsafe { ffi::gdk_x11_surface_get_xid(self.to_glib_none().0) }
}
#[doc(alias = "gdk_x11_surface_lookup_for_display")]
pub fn lookup_for_display(display: &crate::X11Display, window: XWindow) -> Option<X11Surface> {
skip_assert_initialized!();
unsafe {
from_glib_none(ffi::gdk_x11_surface_lookup_for_display(
display.to_glib_none().0,
window,
))
}
}
}