[go: up one dir, main page]

Trait NSEvent

Source
pub trait NSEvent: Sized {
Show 71 methods // Required methods unsafe fn keyEventWithType_location_modifierFlags_timestamp_windowNumber_context_characters_charactersIgnoringModifiers_isARepeat_keyCode_( _: Self, eventType: NSEventType, location: NSPoint, modifierFlags: NSEventModifierFlags, timestamp: NSTimeInterval, windowNumber: NSInteger, context: id, characters: id, unmodCharacters: id, repeatKey: BOOL, code: c_ushort, ) -> id; unsafe fn mouseEventWithType_location_modifierFlags_timestamp_windowNumber_context_eventNumber_clickCount_pressure_( _: Self, eventType: NSEventType, location: NSPoint, modifierFlags: NSEventModifierFlags, timestamp: NSTimeInterval, windowNumber: NSInteger, context: id, eventNumber: NSInteger, clickCount: NSInteger, pressure: c_float, ) -> id; unsafe fn enterExitEventWithType_location_modifierFlags_timestamp_windowNumber_context_eventNumber_trackingNumber_userData_( _: Self, eventType: NSEventType, location: NSPoint, modifierFlags: NSEventModifierFlags, timestamp: NSTimeInterval, windowNumber: NSInteger, context: id, eventNumber: NSInteger, trackingNumber: NSInteger, userData: *mut c_void, ) -> id; unsafe fn otherEventWithType_location_modifierFlags_timestamp_windowNumber_context_subtype_data1_data2_( _: Self, eventType: NSEventType, location: NSPoint, modifierFlags: NSEventModifierFlags, timestamp: NSTimeInterval, windowNumber: NSInteger, context: id, subtype: NSEventSubtype, data1: NSInteger, data2: NSInteger, ) -> id; unsafe fn eventWithEventRef_(_: Self, eventRef: *const c_void) -> id; unsafe fn eventWithCGEvent_(_: Self, cgEvent: *mut c_void) -> id; unsafe fn context(self) -> id; unsafe fn locationInWindow(self) -> NSPoint; unsafe fn modifierFlags(self) -> NSEventModifierFlags; unsafe fn timestamp(self) -> NSTimeInterval; unsafe fn eventType(self) -> NSEventType; unsafe fn window(self) -> id; unsafe fn windowNumber(self) -> NSInteger; unsafe fn eventRef(self) -> *const c_void; unsafe fn CGEvent(self) -> *mut c_void; unsafe fn currentModifierFlags(_: Self) -> NSEventModifierFlags; unsafe fn keyRepeatDelay(_: Self) -> NSTimeInterval; unsafe fn keyRepeatInterval(_: Self) -> NSTimeInterval; unsafe fn characters(self) -> id; unsafe fn charactersIgnoringModifiers(self) -> id; unsafe fn keyCode(self) -> c_ushort; unsafe fn isARepeat(self) -> BOOL; unsafe fn pressedMouseButtons(_: Self) -> NSUInteger; unsafe fn doubleClickInterval(_: Self) -> NSTimeInterval; unsafe fn mouseLocation(_: Self) -> NSPoint; unsafe fn buttonNumber(self) -> NSInteger; unsafe fn clickCount(self) -> NSInteger; unsafe fn pressure(self) -> c_float; unsafe fn stage(self) -> NSInteger; unsafe fn setMouseCoalescingEnabled_(_: Self, flag: BOOL); unsafe fn isMouseCoalescingEnabled(_: Self) -> BOOL; unsafe fn eventNumber(self) -> NSInteger; unsafe fn trackingNumber(self) -> NSInteger; unsafe fn trackingArea(self) -> id; unsafe fn userData(self) -> *const c_void; unsafe fn data1(self) -> NSInteger; unsafe fn data2(self) -> NSInteger; unsafe fn subtype(self) -> NSEventSubtype; unsafe fn deltaX(self) -> CGFloat; unsafe fn deltaY(self) -> CGFloat; unsafe fn deltaZ(self) -> CGFloat; unsafe fn capabilityMask(self) -> NSUInteger; unsafe fn deviceID(self) -> NSUInteger; unsafe fn pointingDeviceID(self) -> NSUInteger; unsafe fn pointingDeviceSerialNumber(self) -> NSUInteger; unsafe fn pointingDeviceType(self) -> NSPointingDeviceType; unsafe fn systemTabletID(self) -> NSUInteger; unsafe fn tabletID(self) -> NSUInteger; unsafe fn uniqueID(self) -> c_ulonglong; unsafe fn vendorID(self) -> NSUInteger; unsafe fn vendorPointingDeviceType(self) -> NSUInteger; unsafe fn absoluteX(self) -> NSInteger; unsafe fn absoluteY(self) -> NSInteger; unsafe fn absoluteZ(self) -> NSInteger; unsafe fn buttonMask(self) -> NSEventButtonMask; unsafe fn rotation(self) -> c_float; unsafe fn tangentialPressure(self) -> c_float; unsafe fn tilt(self) -> NSPoint; unsafe fn vendorDefined(self) -> id; unsafe fn startPeriodicEventsAfterDelay_withPeriod_( _: Self, delaySeconds: NSTimeInterval, periodSeconds: NSTimeInterval, ); unsafe fn stopPeriodicEvents(_: Self); unsafe fn magnification(self) -> CGFloat; unsafe fn touchesMatchingPhase_inView_( self, phase: NSTouchPhase, view: id, ) -> id; unsafe fn isSwipeTrackingFromScrollEventsEnabled(_: Self) -> BOOL; unsafe fn removeMonitor_(_: Self, eventMonitor: id); unsafe fn hasPreciseScrollingDeltas(self) -> BOOL; unsafe fn scrollingDeltaX(self) -> CGFloat; unsafe fn scrollingDeltaY(self) -> CGFloat; unsafe fn momentumPhase(self) -> NSEventPhase; unsafe fn phase(self) -> NSEventPhase; unsafe fn locationInNode_(self, node: id) -> CGPoint;
}
๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead

Required Methodsยง

Source

unsafe fn keyEventWithType_location_modifierFlags_timestamp_windowNumber_context_characters_charactersIgnoringModifiers_isARepeat_keyCode_( _: Self, eventType: NSEventType, location: NSPoint, modifierFlags: NSEventModifierFlags, timestamp: NSTimeInterval, windowNumber: NSInteger, context: id, characters: id, unmodCharacters: id, repeatKey: BOOL, code: c_ushort, ) -> id

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn mouseEventWithType_location_modifierFlags_timestamp_windowNumber_context_eventNumber_clickCount_pressure_( _: Self, eventType: NSEventType, location: NSPoint, modifierFlags: NSEventModifierFlags, timestamp: NSTimeInterval, windowNumber: NSInteger, context: id, eventNumber: NSInteger, clickCount: NSInteger, pressure: c_float, ) -> id

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn enterExitEventWithType_location_modifierFlags_timestamp_windowNumber_context_eventNumber_trackingNumber_userData_( _: Self, eventType: NSEventType, location: NSPoint, modifierFlags: NSEventModifierFlags, timestamp: NSTimeInterval, windowNumber: NSInteger, context: id, eventNumber: NSInteger, trackingNumber: NSInteger, userData: *mut c_void, ) -> id

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn otherEventWithType_location_modifierFlags_timestamp_windowNumber_context_subtype_data1_data2_( _: Self, eventType: NSEventType, location: NSPoint, modifierFlags: NSEventModifierFlags, timestamp: NSTimeInterval, windowNumber: NSInteger, context: id, subtype: NSEventSubtype, data1: NSInteger, data2: NSInteger, ) -> id

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn eventWithEventRef_(_: Self, eventRef: *const c_void) -> id

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn eventWithCGEvent_(_: Self, cgEvent: *mut c_void) -> id

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn context(self) -> id

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn locationInWindow(self) -> NSPoint

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn modifierFlags(self) -> NSEventModifierFlags

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn timestamp(self) -> NSTimeInterval

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn eventType(self) -> NSEventType

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn window(self) -> id

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn windowNumber(self) -> NSInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn eventRef(self) -> *const c_void

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn CGEvent(self) -> *mut c_void

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn currentModifierFlags(_: Self) -> NSEventModifierFlags

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn keyRepeatDelay(_: Self) -> NSTimeInterval

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn keyRepeatInterval(_: Self) -> NSTimeInterval

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn characters(self) -> id

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn charactersIgnoringModifiers(self) -> id

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn keyCode(self) -> c_ushort

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn isARepeat(self) -> BOOL

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn pressedMouseButtons(_: Self) -> NSUInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn doubleClickInterval(_: Self) -> NSTimeInterval

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn mouseLocation(_: Self) -> NSPoint

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn buttonNumber(self) -> NSInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn clickCount(self) -> NSInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn pressure(self) -> c_float

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn stage(self) -> NSInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn setMouseCoalescingEnabled_(_: Self, flag: BOOL)

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn isMouseCoalescingEnabled(_: Self) -> BOOL

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn eventNumber(self) -> NSInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn trackingNumber(self) -> NSInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn trackingArea(self) -> id

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn userData(self) -> *const c_void

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn data1(self) -> NSInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn data2(self) -> NSInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn subtype(self) -> NSEventSubtype

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn deltaX(self) -> CGFloat

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn deltaY(self) -> CGFloat

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn deltaZ(self) -> CGFloat

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn capabilityMask(self) -> NSUInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn deviceID(self) -> NSUInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn pointingDeviceID(self) -> NSUInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn pointingDeviceSerialNumber(self) -> NSUInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn pointingDeviceType(self) -> NSPointingDeviceType

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn systemTabletID(self) -> NSUInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn tabletID(self) -> NSUInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn uniqueID(self) -> c_ulonglong

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn vendorID(self) -> NSUInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn vendorPointingDeviceType(self) -> NSUInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn absoluteX(self) -> NSInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn absoluteY(self) -> NSInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn absoluteZ(self) -> NSInteger

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn buttonMask(self) -> NSEventButtonMask

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn rotation(self) -> c_float

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn tangentialPressure(self) -> c_float

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn tilt(self) -> NSPoint

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn vendorDefined(self) -> id

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn startPeriodicEventsAfterDelay_withPeriod_( _: Self, delaySeconds: NSTimeInterval, periodSeconds: NSTimeInterval, )

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn stopPeriodicEvents(_: Self)

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn magnification(self) -> CGFloat

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn touchesMatchingPhase_inView_( self, phase: NSTouchPhase, view: id, ) -> id

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn isSwipeTrackingFromScrollEventsEnabled(_: Self) -> BOOL

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn removeMonitor_(_: Self, eventMonitor: id)

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn hasPreciseScrollingDeltas(self) -> BOOL

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn scrollingDeltaX(self) -> CGFloat

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn scrollingDeltaY(self) -> CGFloat

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn momentumPhase(self) -> NSEventPhase

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn phase(self) -> NSEventPhase

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead
Source

unsafe fn locationInNode_(self, node: id) -> CGPoint

๐Ÿ‘ŽDeprecated: use the objc2-app-kit crate instead

Dyn Compatibilityยง

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementorsยง