pub unsafe trait IKSlideshowDataSource {
// Provided methods
unsafe fn numberOfSlideshowItems(&self) -> NSUInteger
where Self: Sized + Message { ... }
unsafe fn slideshowItemAtIndex(
&self,
index: NSUInteger,
) -> Option<Retained<AnyObject>>
where Self: Sized + Message { ... }
unsafe fn nameOfSlideshowItemAtIndex(
&self,
index: NSUInteger,
) -> Option<Retained<NSString>>
where Self: Sized + Message { ... }
unsafe fn canExportSlideshowItemAtIndex_toApplication(
&self,
index: NSUInteger,
application_bundle_identifier: Option<&NSString>,
) -> bool
where Self: Sized + Message { ... }
unsafe fn slideshowWillStart(&self)
where Self: Sized + Message { ... }
unsafe fn slideshowDidStop(&self)
where Self: Sized + Message { ... }
unsafe fn slideshowDidChangeCurrentIndex(&self, new_index: NSUInteger)
where Self: Sized + Message { ... }
}Available on crate features
IKSlideshow and ImageKit only.Expand description
The data source of IKSlideshow must conform to IKSlideshowDataSource protocol.
The data source methods may be called one a non-main thread.
See also Apple’s documentation
Provided Methods§
Sourceunsafe fn numberOfSlideshowItems(&self) -> NSUInteger
unsafe fn numberOfSlideshowItems(&self) -> NSUInteger
return number of items in Slideshow.
Sourceunsafe fn slideshowItemAtIndex(
&self,
index: NSUInteger,
) -> Option<Retained<AnyObject>>
unsafe fn slideshowItemAtIndex( &self, index: NSUInteger, ) -> Option<Retained<AnyObject>>
return the item for a given index.
The item can be either: NSImage, NSString, NSURL, CGImageRef, or PDFPage. Note: when using ‘IKSlideshowModeOther’ as slideshowMode, the item has to be a NSURL.
Sourceunsafe fn nameOfSlideshowItemAtIndex(
&self,
index: NSUInteger,
) -> Option<Retained<NSString>>
unsafe fn nameOfSlideshowItemAtIndex( &self, index: NSUInteger, ) -> Option<Retained<NSString>>
Display name for item at index.
Sourceunsafe fn canExportSlideshowItemAtIndex_toApplication(
&self,
index: NSUInteger,
application_bundle_identifier: Option<&NSString>,
) -> bool
unsafe fn canExportSlideshowItemAtIndex_toApplication( &self, index: NSUInteger, application_bundle_identifier: Option<&NSString>, ) -> bool
should the export button be enabled for a given item at index?
Sourceunsafe fn slideshowWillStart(&self)
unsafe fn slideshowWillStart(&self)
Slideshow will start.
Sourceunsafe fn slideshowDidStop(&self)
unsafe fn slideshowDidStop(&self)
Slideshow did stop.
Sourceunsafe fn slideshowDidChangeCurrentIndex(&self, new_index: NSUInteger)
unsafe fn slideshowDidChangeCurrentIndex(&self, new_index: NSUInteger)
Slideshow did change current item index.