use crate::common::*;
use crate::AppKit::*;
use crate::CoreData::*;
use crate::Foundation::*;
extern_class!(
#[derive(Debug, PartialEq, Eq, Hash)]
pub struct NSCursor;
unsafe impl ClassType for NSCursor {
type Super = NSObject;
}
);
extern_methods!(
unsafe impl NSCursor {
#[method_id(@__retain_semantics Other currentCursor)]
pub unsafe fn currentCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other currentSystemCursor)]
pub unsafe fn currentSystemCursor() -> Option<Id<NSCursor, Shared>>;
#[method_id(@__retain_semantics Other arrowCursor)]
pub unsafe fn arrowCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other IBeamCursor)]
pub unsafe fn IBeamCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other pointingHandCursor)]
pub unsafe fn pointingHandCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other closedHandCursor)]
pub unsafe fn closedHandCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other openHandCursor)]
pub unsafe fn openHandCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other resizeLeftCursor)]
pub unsafe fn resizeLeftCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other resizeRightCursor)]
pub unsafe fn resizeRightCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other resizeLeftRightCursor)]
pub unsafe fn resizeLeftRightCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other resizeUpCursor)]
pub unsafe fn resizeUpCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other resizeDownCursor)]
pub unsafe fn resizeDownCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other resizeUpDownCursor)]
pub unsafe fn resizeUpDownCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other crosshairCursor)]
pub unsafe fn crosshairCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other disappearingItemCursor)]
pub unsafe fn disappearingItemCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other operationNotAllowedCursor)]
pub unsafe fn operationNotAllowedCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other dragLinkCursor)]
pub unsafe fn dragLinkCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other dragCopyCursor)]
pub unsafe fn dragCopyCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other contextualMenuCursor)]
pub unsafe fn contextualMenuCursor() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Other IBeamCursorForVerticalLayout)]
pub unsafe fn IBeamCursorForVerticalLayout() -> Id<NSCursor, Shared>;
#[method_id(@__retain_semantics Init initWithImage:hotSpot:)]
pub unsafe fn initWithImage_hotSpot(
this: Option<Allocated<Self>>,
newImage: &NSImage,
point: NSPoint,
) -> Id<Self, Shared>;
#[method_id(@__retain_semantics Init initWithCoder:)]
pub unsafe fn initWithCoder(
this: Option<Allocated<Self>>,
coder: &NSCoder,
) -> Id<Self, Shared>;
#[method(hide)]
pub unsafe fn hide();
#[method(unhide)]
pub unsafe fn unhide();
#[method(setHiddenUntilMouseMoves:)]
pub unsafe fn setHiddenUntilMouseMoves(flag: bool);
#[method_id(@__retain_semantics Other image)]
pub unsafe fn image(&self) -> Id<NSImage, Shared>;
#[method(hotSpot)]
pub unsafe fn hotSpot(&self) -> NSPoint;
#[method(push)]
pub unsafe fn push(&self);
#[method(set)]
pub unsafe fn set(&self);
}
);
extern_static!(NSAppKitVersionNumberWithCursorSizeSupport: NSAppKitVersion = 682.0);
extern_methods!(
unsafe impl NSCursor {
#[method_id(@__retain_semantics Init initWithImage:foregroundColorHint:backgroundColorHint:hotSpot:)]
pub unsafe fn initWithImage_foregroundColorHint_backgroundColorHint_hotSpot(
this: Option<Allocated<Self>>,
newImage: &NSImage,
fg: Option<&NSColor>,
bg: Option<&NSColor>,
hotSpot: NSPoint,
) -> Id<Self, Shared>;
#[method(setOnMouseExited:)]
pub unsafe fn setOnMouseExited(&self, flag: bool);
#[method(setOnMouseEntered:)]
pub unsafe fn setOnMouseEntered(&self, flag: bool);
#[method(isSetOnMouseExited)]
pub unsafe fn isSetOnMouseExited(&self) -> bool;
#[method(isSetOnMouseEntered)]
pub unsafe fn isSetOnMouseEntered(&self) -> bool;
#[method(mouseEntered:)]
pub unsafe fn mouseEntered(&self, event: &NSEvent);
#[method(mouseExited:)]
pub unsafe fn mouseExited(&self, event: &NSEvent);
}
);