Enum egui::os::OperatingSystem
source · pub enum OperatingSystem {
Unknown,
Android,
IOS,
Nix,
Mac,
Windows,
}
Expand description
An enum
of common operating systems.
Variants§
Unknown
Unknown OS - could be wasm
Android
Android OS.
IOS
Apple iPhone OS.
Nix
Linux or Unix other than Android.
Mac
MacOS.
Windows
Windows.
Implementations§
source§impl OperatingSystem
impl OperatingSystem
sourcepub const fn from_target_os() -> Self
pub const fn from_target_os() -> Self
Uses the compile-time target_arch
to identify the OS.
sourcepub fn from_user_agent(user_agent: &str) -> Self
pub fn from_user_agent(user_agent: &str) -> Self
Helper: try to guess from the user-agent of a browser.
Trait Implementations§
source§impl Clone for OperatingSystem
impl Clone for OperatingSystem
source§fn clone(&self) -> OperatingSystem
fn clone(&self) -> OperatingSystem
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for OperatingSystem
impl Debug for OperatingSystem
source§impl Default for OperatingSystem
impl Default for OperatingSystem
source§impl Hash for OperatingSystem
impl Hash for OperatingSystem
source§impl PartialEq for OperatingSystem
impl PartialEq for OperatingSystem
source§fn eq(&self, other: &OperatingSystem) -> bool
fn eq(&self, other: &OperatingSystem) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Copy for OperatingSystem
impl Eq for OperatingSystem
impl StructuralEq for OperatingSystem
impl StructuralPartialEq for OperatingSystem
Auto Trait Implementations§
impl RefUnwindSafe for OperatingSystem
impl Send for OperatingSystem
impl Sync for OperatingSystem
impl Unpin for OperatingSystem
impl UnwindSafe for OperatingSystem
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