[−][src]Struct winflip::WFApp
Basic application context, should be toplevel type where state lives.
This is _sapp_state
, give or take some.
Basically all the window state that isn't part of a particular backend.
Fields
window_width: u32
window_height: u32
framebuffer_width: u32
framebuffer_height: u32
sample_count: u32
swap_interval: u32
dpi_scale: f32
quit_requested: bool
quit_ordered: bool
event_consumed: bool
window_title: String
frame_count: u64
mouse_x: f32
mouse_y: f32
win32_mouse_tracked: bool
onscreen_keyboard_shown: bool
event: Event
desc: Desc
keycodes: [Keycode; 512]
clipboard_enabled: bool
clipboard_size: usize
clipboard: Vec<u8>
Methods
impl WFApp
[src]
Most of the _sapp_*
functions live here
pub fn call_event(&mut self, e: &Event) -> bool
[src]
pub fn new(desc: &Desc) -> Self
[src]
pub fn discard_state(&mut self)
[src]
TODO: This is basically just Drop
pub fn new_event(&self, typ: EventType) -> Event
[src]
pub fn events_enabled(&self) -> bool
[src]
pub fn translate_key(&self, scancode: usize) -> Option<Keycode>
[src]
TODO: Just use TryFrom?
pub fn frame(&mut self)
[src]
Auto Trait Implementations
impl RefUnwindSafe for WFApp
impl Send for WFApp
impl Sync for WFApp
impl Unpin for WFApp
impl UnwindSafe for WFApp
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,