diff options
Diffstat (limited to 'src/api/x11')
-rw-r--r-- | src/api/x11/window.rs | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/api/x11/window.rs b/src/api/x11/window.rs index ba0fe52..c0c5917 100644 --- a/src/api/x11/window.rs +++ b/src/api/x11/window.rs @@ -9,6 +9,7 @@ use std::collections::VecDeque; use std::sync::{Arc, Mutex}; use Api; +use ContextError; use CursorState; use GlContext; use GlRequest; @@ -800,11 +801,11 @@ impl Window { } impl GlContext for Window { - unsafe fn make_current(&self) { + unsafe fn make_current(&self) -> Result<(), ContextError> { match self.x.context { Context::Glx(ref ctxt) => ctxt.make_current(), Context::Egl(ref ctxt) => ctxt.make_current(), - Context::None => {} + Context::None => Ok(()) } } @@ -824,11 +825,11 @@ impl GlContext for Window { } } - fn swap_buffers(&self) { + fn swap_buffers(&self) -> Result<(), ContextError> { match self.x.context { Context::Glx(ref ctxt) => ctxt.swap_buffers(), Context::Egl(ref ctxt) => ctxt.swap_buffers(), - Context::None => {} + Context::None => Ok(()) } } |