Skip to main content

INSMenuItem

Trait INSMenuItem 

Source
pub trait INSMenuItem: PNSObject {
Show 15 methods // Provided methods fn p_is_enabled(&self) -> bool { ... } fn p_set_enabled(&mut self, enabled: bool) { ... } fn p_is_hidden(&self) -> bool { ... } fn p_set_hidden(&mut self, hidden: bool) { ... } fn p_is_hidden_or_has_hidden_ancestor(&self) -> bool { ... } fn p_target(&self) -> id { ... } fn p_set_target(&mut self, target: id) { ... } fn p_action(&self) -> Sel { ... } fn p_set_action(&mut self, action: Sel) { ... } fn p_title(&self) -> NSString { ... } fn p_set_title(&mut self, title: NSString) { ... } fn p_submenu(&self) -> NSMenu { ... } fn p_set_submenu(&mut self, submenu: NSMenu) { ... } fn p_has_submenu(&self) -> bool { ... } fn p_parent_item(&self) -> Option<NSMenuItem> { ... }
}
Expand description

A trait containing all the methods for NSMenuItem

Provided Methods§

Source

fn p_is_enabled(&self) -> bool

A Boolean value that indicates whether the menu item is enabled.

Source

fn p_set_enabled(&mut self, enabled: bool)

Sets whether the menu item is enabled.

Source

fn p_is_hidden(&self) -> bool

A Boolean value that indicates whether the menu item is hidden.

Source

fn p_set_hidden(&mut self, hidden: bool)

Sets whether the menu item is hidden.

Source

fn p_is_hidden_or_has_hidden_ancestor(&self) -> bool

A Boolean value that indicates whether the menu item or any of its superitems is hidden.

Source

fn p_target(&self) -> id

The menu item’s target.

Source

fn p_set_target(&mut self, target: id)

Sets the menu item’s target.

Source

fn p_action(&self) -> Sel

The menu item’s action-method selector.

Source

fn p_set_action(&mut self, action: Sel)

Sets the menu item’s action-method selector.

Source

fn p_title(&self) -> NSString

The menu item’s title.

Source

fn p_set_title(&mut self, title: NSString)

Sets the menu item’s title.

Source

fn p_submenu(&self) -> NSMenu

The submenu of the menu item.

Source

fn p_set_submenu(&mut self, submenu: NSMenu)

Sets the submenu of the menu item.

Source

fn p_has_submenu(&self) -> bool

A Boolean value that indicates whether the menu item has a submenu.

Source

fn p_parent_item(&self) -> Option<NSMenuItem>

The menu item whose submenu contains the receiver.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§