Trait MSStickerBrowserViewDataSource

Source
pub unsafe trait MSStickerBrowserViewDataSource: NSObjectProtocol {
    // Provided methods
    unsafe fn numberOfStickersInStickerBrowserView(
        &self,
        sticker_browser_view: &MSStickerBrowserView,
    ) -> NSInteger
       where Self: Sized + Message { ... }
    unsafe fn stickerBrowserView_stickerAtIndex(
        &self,
        sticker_browser_view: &MSStickerBrowserView,
        index: NSInteger,
    ) -> Retained<MSSticker>
       where Self: Sized + Message { ... }
}
Available on crate feature MSStickerBrowserViewDataSource only.
Expand description

The MSStickerBrowserViewDataSource protocol declares the methods that the Sticker Browser View uses to access the contents of its data source object.

See also Apple’s documentation

Provided Methods§

Source

unsafe fn numberOfStickersInStickerBrowserView( &self, sticker_browser_view: &MSStickerBrowserView, ) -> NSInteger
where Self: Sized + Message,

Available on crate features MSStickerBrowserView and objc2-ui-kit only.

Returns the number of Stickers that the sticker browser should show.

Parameter stickerBrowserView: The sticker browser view .

Returns: The number of stickers.

Source

unsafe fn stickerBrowserView_stickerAtIndex( &self, sticker_browser_view: &MSStickerBrowserView, index: NSInteger, ) -> Retained<MSSticker>
where Self: Sized + Message,

Available on crate features MSSticker and MSStickerBrowserView and objc2-ui-kit only.

Returns the sticker that the sticker browser should show in the browser.

Parameter stickerBrowserView: The sticker browser view.

Parameter index: The index of the sticker to show.

Returns: A MSSticker object.

Trait Implementations§

Source§

impl ProtocolType for dyn MSStickerBrowserViewDataSource

Source§

const NAME: &'static str = "MSStickerBrowserViewDataSource"

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 MSStickerBrowserViewDataSource

Implementations on Foreign Types§

Source§

impl<T> MSStickerBrowserViewDataSource for ProtocolObject<T>

Implementors§

Source§

impl MSStickerBrowserViewDataSource for MSStickerBrowserViewController

Available on crate feature MSStickerBrowserViewController only.