Update bitflags to 2.0

Co-authored-by: dAxpeDDa <daxpedda@gmail.com>
This commit is contained in:
George Burton 2023-06-02 15:44:36 +01:00 committed by GitHub
parent d273518ce9
commit 31ebc5caf4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
14 changed files with 27 additions and 14 deletions

View file

@ -109,6 +109,7 @@ unsafe impl Encode for NSApplicationActivationPolicy {
}
bitflags! {
#[derive(Debug, Clone, Copy)]
pub struct NSApplicationPresentationOptions: NSUInteger {
const NSApplicationPresentationDefault = 0;
const NSApplicationPresentationAutoHideDock = 1 << 0;

View file

@ -194,6 +194,7 @@ const NX_DEVICERALTKEYMASK: u32 = 0x00000040;
const NX_DEVICERCTLKEYMASK: u32 = 0x00002000;
bitflags! {
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
pub struct NSEventModifierFlags: NSUInteger {
const NSAlphaShiftKeyMask = 1 << 16;
const NSShiftKeyMask = 1 << 17;
@ -212,6 +213,7 @@ unsafe impl Encode for NSEventModifierFlags {
}
bitflags! {
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
pub struct NSEventPhase: NSUInteger {
const NSEventPhaseNone = 0;
const NSEventPhaseBegan = 0x1 << 0;

View file

@ -336,6 +336,7 @@ unsafe impl Encode for NSWindowLevel {
}
bitflags! {
#[derive(Clone, Copy)]
pub struct NSWindowOcclusionState: NSUInteger {
const NSWindowOcclusionStateVisible = 1 << 1;
}
@ -346,6 +347,7 @@ unsafe impl Encode for NSWindowOcclusionState {
}
bitflags! {
#[derive(Debug, Clone, Copy)]
pub struct NSWindowStyleMask: NSUInteger {
const NSBorderlessWindowMask = 0;
const NSTitledWindowMask = 1 << 0;

View file

@ -71,6 +71,7 @@ enum ImeState {
}
bitflags! {
#[derive(Debug, Clone, Copy, PartialEq)]
struct ModLocationMask: u8 {
const LEFT = 1;
const RIGHT = 2;