From 5693fbcce3ca04aa7a26920add40ea770419f3ea Mon Sep 17 00:00:00 2001 From: Glenn Watson Date: Fri, 24 Oct 2014 15:20:25 +1000 Subject: Add accessor for underlying display handle on Linux. Although unimplemented on other platforms, this applies to at least android as well. --- src/x11/window/mod.rs | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/x11/window') diff --git a/src/x11/window/mod.rs b/src/x11/window/mod.rs index cb73958..3d69a3e 100644 --- a/src/x11/window/mod.rs +++ b/src/x11/window/mod.rs @@ -469,6 +469,10 @@ impl Window { pub fn swap_buffers(&self) { unsafe { ffi::glx::SwapBuffers(self.display, self.window) } } + + pub fn platform_display(&self) -> *mut libc::c_void { + self.display as *mut libc::c_void + } } impl Drop for Window { -- cgit v1.2.3