Merge pull request #551 from tomaka/android-headless

Implement headless contexts on android
This commit is contained in:
tomaka 2015-07-28 19:59:49 +02:00
commit 829d7a6afc
2 changed files with 40 additions and 33 deletions

View file

@ -1,36 +1,3 @@
#![cfg(target_os = "android")]
pub use api::android::*;
use ContextError;
pub struct HeadlessContext(i32);
impl HeadlessContext {
/// See the docs in the crate root file.
pub fn new(_builder: BuilderAttribs) -> Result<HeadlessContext, CreationError> {
unimplemented!()
}
/// See the docs in the crate root file.
pub unsafe fn make_current(&self) -> Result<(), ContextError> {
unimplemented!()
}
/// See the docs in the crate root file.
pub fn is_current(&self) -> bool {
unimplemented!()
}
/// See the docs in the crate root file.
pub fn get_proc_address(&self, _addr: &str) -> *const () {
unimplemented!()
}
pub fn get_api(&self) -> ::Api {
::Api::OpenGlEs
}
}
unsafe impl Send for HeadlessContext {}
unsafe impl Sync for HeadlessContext {}