UITabBarControllerSidebarDelegate

Trait UITabBarControllerSidebarDelegate 

Source
pub unsafe trait UITabBarControllerSidebarDelegate: NSObjectProtocol + MainThreadOnly {
    // Provided methods
    fn tabBarController_sidebarVisibilityWillChange_animator(
        &self,
        tab_bar_controller: &UITabBarController,
        sidebar: &UITabBarControllerSidebar,
        animator: &ProtocolObject<dyn UITabBarControllerSidebarAnimating>,
    )
       where Self: Sized + Message { ... }
    fn tabBarController_sidebar_itemForRequest(
        &self,
        tab_bar_controller: &UITabBarController,
        sidebar: &UITabBarControllerSidebar,
        request: &UITabSidebarItemRequest,
    ) -> Retained<UITabSidebarItem>
       where Self: Sized + Message { ... }
    fn tabBarController_sidebar_updateItem(
        &self,
        tab_bar_controller: &UITabBarController,
        sidebar: &UITabBarControllerSidebar,
        item: &UITabSidebarItem,
    )
       where Self: Sized + Message { ... }
    fn tabBarController_sidebar_willBeginDisplayingTab(
        &self,
        tab_bar_controller: &UITabBarController,
        sidebar: &UITabBarControllerSidebar,
        tab: &UITab,
    )
       where Self: Sized + Message { ... }
    fn tabBarController_sidebar_didEndDisplayingTab(
        &self,
        tab_bar_controller: &UITabBarController,
        sidebar: &UITabBarControllerSidebar,
        tab: &UITab,
    )
       where Self: Sized + Message { ... }
    fn tabBarController_sidebar_leadingSwipeActionsConfigurationForTab(
        &self,
        tab_bar_controller: &UITabBarController,
        sidebar: &UITabBarControllerSidebar,
        tab: &UITab,
    ) -> Option<Retained<UISwipeActionsConfiguration>>
       where Self: Sized + Message { ... }
    fn tabBarController_sidebar_trailingSwipeActionsConfigurationForTab(
        &self,
        tab_bar_controller: &UITabBarController,
        sidebar: &UITabBarControllerSidebar,
        tab: &UITab,
    ) -> Option<Retained<UISwipeActionsConfiguration>>
       where Self: Sized + Message { ... }
    fn tabBarController_sidebar_contextMenuConfigurationForTab(
        &self,
        tab_bar_controller: &UITabBarController,
        sidebar: &UITabBarControllerSidebar,
        tab: &UITab,
    ) -> Option<Retained<UIContextMenuConfiguration>>
       where Self: Sized + Message { ... }
    fn tabBarController_sidebar_itemsForBeginningDragSession_tab(
        &self,
        tab_bar_controller: &UITabBarController,
        sidebar: &UITabBarControllerSidebar,
        drag_session: &ProtocolObject<dyn UIDragSession>,
        tab: &UITab,
    ) -> Retained<NSArray<UIDragItem>>
       where Self: Sized + Message { ... }
    fn tabBarController_sidebar_itemsForAddingToDragSession_tab(
        &self,
        tab_bar_controller: &UITabBarController,
        sidebar: &UITabBarControllerSidebar,
        drag_session: &ProtocolObject<dyn UIDragSession>,
        tab: &UITab,
    ) -> Retained<NSArray<UIDragItem>>
       where Self: Sized + Message { ... }
    fn tabBarController_sidebar_sidebarAction_group_operationForAcceptingItemsFromDropSession(
        &self,
        tab_bar_controller: &UITabBarController,
        sidebar: &UITabBarControllerSidebar,
        sidebar_action: &UIAction,
        group: &UITabGroup,
        session: &ProtocolObject<dyn UIDropSession>,
    ) -> UIDropOperation
       where Self: Sized + Message { ... }
    fn tabBarController_sidebar_sidebarAction_group_acceptItemsFromDropSession(
        &self,
        tab_bar_controller: &UITabBarController,
        sidebar: &UITabBarControllerSidebar,
        sidebar_action: &UIAction,
        group: &UITabGroup,
        session: &ProtocolObject<dyn UIDropSession>,
    )
       where Self: Sized + Message { ... }
}
Available on crate feature UITabBarControllerSidebar only.
Expand description

Provided Methods§

Source

fn tabBarController_sidebarVisibilityWillChange_animator( &self, tab_bar_controller: &UITabBarController, sidebar: &UITabBarControllerSidebar, animator: &ProtocolObject<dyn UITabBarControllerSidebarAnimating>, )
where Self: Sized + Message,

Available on crate features UIResponder and UITabBarController and UIViewController only.

Notifies the delegate when the visibility of the sidebar is about to change when sidebar.isHidden changes. Add animations to the animator to run alongside the visibility update. Alongside animations and completions will run immediately if the sidebar visibility is changed without animation.

Source

fn tabBarController_sidebar_itemForRequest( &self, tab_bar_controller: &UITabBarController, sidebar: &UITabBarControllerSidebar, request: &UITabSidebarItemRequest, ) -> Retained<UITabSidebarItem>
where Self: Sized + Message,

Available on crate features UIResponder and UITabBarController and UITabSidebarItem and UIViewController only.

Return a UITabSidebarItem for the specified item request. When created, the item will be preconfigured to the appropriate defaults for its given content. If this method is not implemented, a default sidebar item will be provided for the request.

Source

fn tabBarController_sidebar_updateItem( &self, tab_bar_controller: &UITabBarController, sidebar: &UITabBarControllerSidebar, item: &UITabSidebarItem, )
where Self: Sized + Message,

Available on crate features UIResponder and UITabBarController and UITabSidebarItem and UIViewController only.

Called whenever the sidebar item’s configurationState changes or the item is reconfigured. The passed in item will accrue all modifications until the delegate requests for a new sidebar item from the delegate method tabBarController:sidebar:itemForRequest:

Source

fn tabBarController_sidebar_willBeginDisplayingTab( &self, tab_bar_controller: &UITabBarController, sidebar: &UITabBarControllerSidebar, tab: &UITab, )
where Self: Sized + Message,

Available on crate features UIResponder and UITab and UITabBarController and UIViewController only.

Notifies the delegate when the sidebar is about to display the row representing the specified tab

Source

fn tabBarController_sidebar_didEndDisplayingTab( &self, tab_bar_controller: &UITabBarController, sidebar: &UITabBarControllerSidebar, tab: &UITab, )
where Self: Sized + Message,

Available on crate features UIResponder and UITab and UITabBarController and UIViewController only.

Notifies the delegate when the sidebar has finished displaying the row representing the specified tab

Source

fn tabBarController_sidebar_leadingSwipeActionsConfigurationForTab( &self, tab_bar_controller: &UITabBarController, sidebar: &UITabBarControllerSidebar, tab: &UITab, ) -> Option<Retained<UISwipeActionsConfiguration>>
where Self: Sized + Message,

Available on crate features UIResponder and UISwipeActionsConfiguration and UITab and UITabBarController and UIViewController only.

Called when the sidebar is about to show leading swipe actions for the specified tab. Return either a concrete UISwipeActionsConfiguration or nil if the tab does not show swipe actions.

Source

fn tabBarController_sidebar_trailingSwipeActionsConfigurationForTab( &self, tab_bar_controller: &UITabBarController, sidebar: &UITabBarControllerSidebar, tab: &UITab, ) -> Option<Retained<UISwipeActionsConfiguration>>
where Self: Sized + Message,

Available on crate features UIResponder and UISwipeActionsConfiguration and UITab and UITabBarController and UIViewController only.

Called when the sidebar is about to show trailing swipe actions for a particular tab. Return either a UISwipeActionsConfiguration object or nil if this tab does not show swipe actions.

Source

fn tabBarController_sidebar_contextMenuConfigurationForTab( &self, tab_bar_controller: &UITabBarController, sidebar: &UITabBarControllerSidebar, tab: &UITab, ) -> Option<Retained<UIContextMenuConfiguration>>
where Self: Sized + Message,

Available on crate features UIContextMenuConfiguration and UIResponder and UITab and UITabBarController and UIViewController only.

Called when the sidebar is about to display a context menu for the specified tab. Return either a concrete UIContextMenuConfiguration or nil if the tab does not show context menus.

Source

fn tabBarController_sidebar_itemsForBeginningDragSession_tab( &self, tab_bar_controller: &UITabBarController, sidebar: &UITabBarControllerSidebar, drag_session: &ProtocolObject<dyn UIDragSession>, tab: &UITab, ) -> Retained<NSArray<UIDragItem>>
where Self: Sized + Message,

Available on crate features UIDragItem and UIDragSession and UIResponder and UITab and UITabBarController and UIViewController only.

Called when a new drag session has begun in the sidebar from the specified tab. Return drag items if the specified tab can be dragged, or an empty array if no drags should begin. Note that if drag items are returned on tabs in groups that allow reordering, then tab reordering is disabled when the sidebar is not in editing.

Source

fn tabBarController_sidebar_itemsForAddingToDragSession_tab( &self, tab_bar_controller: &UITabBarController, sidebar: &UITabBarControllerSidebar, drag_session: &ProtocolObject<dyn UIDragSession>, tab: &UITab, ) -> Retained<NSArray<UIDragItem>>
where Self: Sized + Message,

Available on crate features UIDragItem and UIDragSession and UIResponder and UITab and UITabBarController and UIViewController only.

Called when a new drag session is requesting items to add to the existing drag session in the sidebar from the specified tab. Return items if the specified tab can add to the drag session, or an empty array if nothing should be added.

Source

fn tabBarController_sidebar_sidebarAction_group_operationForAcceptingItemsFromDropSession( &self, tab_bar_controller: &UITabBarController, sidebar: &UITabBarControllerSidebar, sidebar_action: &UIAction, group: &UITabGroup, session: &ProtocolObject<dyn UIDropSession>, ) -> UIDropOperation
where Self: Sized + Message,

Available on crate features UIAction and UIDragSession and UIDropInteraction and UIMenuElement and UIResponder and UITab and UITabBarController and UITabGroup and UIViewController only.

Determines if items from the specified drop session can be dropped into the specified sidebarAction. If the operation is either a .move or .copy, then the drop will proceed and tabBarController:sidebar:sidebarAction:acceptItemsFromDropSession: is called. By default, the drop will be treated as a cancel operation if this is not implemented.

Source

fn tabBarController_sidebar_sidebarAction_group_acceptItemsFromDropSession( &self, tab_bar_controller: &UITabBarController, sidebar: &UITabBarControllerSidebar, sidebar_action: &UIAction, group: &UITabGroup, session: &ProtocolObject<dyn UIDropSession>, )
where Self: Sized + Message,

Available on crate features UIAction and UIDragSession and UIMenuElement and UIResponder and UITab and UITabBarController and UITabGroup and UIViewController only.

Receive the drop from into the sidebarAction using the specified session. This is only called if the drop operation returned from tabBarController:sidebar:sidebarAction:operationForAcceptingItemsFromDropSession is valid for a drop.

Trait Implementations§

Source§

impl ProtocolType for dyn UITabBarControllerSidebarDelegate

Source§

const NAME: &'static str = "UITabBarControllerSidebarDelegate"

The name of the Objective-C protocol that this type represents. Read more
Source§

fn protocol() -> Option<&'static AnyProtocol>

Get a reference to the Objective-C protocol object that this type represents. Read more
Source§

impl<T> ImplementedBy<T> for dyn UITabBarControllerSidebarDelegate

Implementations on Foreign Types§

Source§

impl<T> UITabBarControllerSidebarDelegate for ProtocolObject<T>

Implementors§