#[repr(transparent)]pub struct NSPasteboardAccessBehavior(pub NSInteger);
NSPasteboard
only.Expand description
A value indicating pasteboard access behavior.
See also Apple’s documentation
Tuple Fields§
§0: NSInteger
Implementations§
Source§impl NSPasteboardAccessBehavior
impl NSPasteboardAccessBehavior
Sourcepub const Default: Self
pub const Default: Self
The default behavior for the General pasteboard is to ask upon programmatic access. All other pasteboards default to always allow access.
If an app has never triggered a pasteboard access alert, its General pasteboard will report .default
behavior. Such an app is not shown in the corresponding System Settings pane.
Once programmatic pasteboard access triggers the first pasteboard access alert, the state automatically changes to .ask
. At this point the app starts being shown in System Settings, where the user can toggle the behavior between .ask
, .alwaysAllow
, and .alwaysDeny
.
Sourcepub const Ask: Self
pub const Ask: Self
The system will notify the user and ask for permission before granting pasteboard access. However, access that is both user originated and paste related will always be allowed, and will not result in a notification. The app is listed in the corresponding System Settings pane.
Sourcepub const AlwaysAllow: Self
pub const AlwaysAllow: Self
The system will automatically allow all pasteboard access, without notifying the user. The app is listed in the corresponding System Settings pane.
Sourcepub const AlwaysDeny: Self
pub const AlwaysDeny: Self
The system will automatically deny all pasteboard access, without notifying the user. However, access that is both user originated and paste related will always be allowed, and will not result in a notification. The app is listed in the corresponding System Settings pane.
Trait Implementations§
Source§impl Clone for NSPasteboardAccessBehavior
impl Clone for NSPasteboardAccessBehavior
Source§fn clone(&self) -> NSPasteboardAccessBehavior
fn clone(&self) -> NSPasteboardAccessBehavior
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more