pub enum CandlCurrentWrapper {
PossiblyCurrent(WindowedContext<PossiblyCurrent>),
NotCurrent(WindowedContext<NotCurrent>),
}Expand description
Tracking the context status
When working with OpenGL context it’s important to know if the context you
working with is the current one or not. If you’re using only one window,
it’s ok to avoid this enum and only use PossiblyCurrent, because the
context status will never change. But if you need multiple windows, you
need to know if the context you want to work with is the current one, and
if not you need to change that. The CandlManager is here to do that for
you, and use CandlCurrentWrapper to do so.
Variants§
PossiblyCurrent(WindowedContext<PossiblyCurrent>)
OpenGL context is probably current
NotCurrent(WindowedContext<NotCurrent>)
OpenGL context is not current
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for CandlCurrentWrapper
impl !RefUnwindSafe for CandlCurrentWrapper
impl !Send for CandlCurrentWrapper
impl !Sync for CandlCurrentWrapper
impl Unpin for CandlCurrentWrapper
impl UnsafeUnpin for CandlCurrentWrapper
impl !UnwindSafe for CandlCurrentWrapper
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more