aboutsummaryrefslogtreecommitdiffstats
path: root/src/x11
diff options
context:
space:
mode:
authorPierre Krieger <pierre.krieger1708@gmail.com>2014-11-18 17:55:26 +0100
committerPierre Krieger <pierre.krieger1708@gmail.com>2014-12-07 13:52:08 +0100
commitc893e4faec212953174c12c68538d55929c90ad3 (patch)
treebb5ed569b0f5042c00e1c454452fdc9e108cd424 /src/x11
parent2320c2bc974fcc655553e678c457230f3e97de68 (diff)
downloadglutin-c893e4faec212953174c12c68538d55929c90ad3.tar.gz
glutin-c893e4faec212953174c12c68538d55929c90ad3.zip
Add get_api() function
Diffstat (limited to 'src/x11')
-rw-r--r--src/x11/headless.rs5
-rw-r--r--src/x11/window/mod.rs5
2 files changed, 10 insertions, 0 deletions
diff --git a/src/x11/headless.rs b/src/x11/headless.rs
index e6479d6..78fb985 100644
--- a/src/x11/headless.rs
+++ b/src/x11/headless.rs
@@ -47,6 +47,11 @@ impl HeadlessContext {
})
}
}
+
+ /// See the docs in the crate root file.
+ pub fn get_api(&self) -> ::Api {
+ ::Api::OpenGl
+ }
}
impl Drop for HeadlessContext {
diff --git a/src/x11/window/mod.rs b/src/x11/window/mod.rs
index 7bce19f..f22d1f8 100644
--- a/src/x11/window/mod.rs
+++ b/src/x11/window/mod.rs
@@ -535,6 +535,11 @@ impl Window {
pub fn platform_display(&self) -> *mut libc::c_void {
self.display as *mut libc::c_void
}
+
+ /// See the docs in the crate root file.
+ pub fn get_api(&self) -> ::Api {
+ ::Api::OpenGl
+ }
}
impl Drop for Window {