pub unsafe trait UIFocusItemScrollableContainer: UIFocusItemContainer + MainThreadOnly {
// Provided methods
unsafe fn contentOffset(&self) -> CGPoint
where Self: Sized + Message { ... }
unsafe fn setContentOffset(&self, content_offset: CGPoint)
where Self: Sized + Message { ... }
unsafe fn contentSize(&self) -> CGSize
where Self: Sized + Message { ... }
unsafe fn visibleSize(&self) -> CGSize
where Self: Sized + Message { ... }
}
Available on crate feature
UIFocus
only.Expand description
Objects conforming to UIFocusItemScrollableContainer are updated accordingly to ensure the focused item remains visible on the screen.
See also Apple’s documentation
Provided Methods§
Sourceunsafe fn contentOffset(&self) -> CGPoint
Available on crate feature objc2-core-foundation
only.
unsafe fn contentOffset(&self) -> CGPoint
objc2-core-foundation
only.The current content offset of this scrollable container. If the scrollable container has a bounds
property, bounds.origin
must be equal to contentOffset
.
Sourceunsafe fn setContentOffset(&self, content_offset: CGPoint)
Available on crate feature objc2-core-foundation
only.
unsafe fn setContentOffset(&self, content_offset: CGPoint)
objc2-core-foundation
only.Setter for contentOffset
.
Sourceunsafe fn contentSize(&self) -> CGSize
Available on crate feature objc2-core-foundation
only.
unsafe fn contentSize(&self) -> CGSize
objc2-core-foundation
only.The total size of the content contained by this container. If this size exceeds the size of this container’s visible size, then scrolling is possible.
Sourceunsafe fn visibleSize(&self) -> CGSize
Available on crate feature objc2-core-foundation
only.
unsafe fn visibleSize(&self) -> CGSize
objc2-core-foundation
only.The visible size of this scrollable container.
Trait Implementations§
Source§impl ProtocolType for dyn UIFocusItemScrollableContainer
impl ProtocolType for dyn UIFocusItemScrollableContainer
impl<T> ImplementedBy<T> for dyn UIFocusItemScrollableContainer
Implementations on Foreign Types§
impl<T> UIFocusItemScrollableContainer for ProtocolObject<T>where
T: ?Sized + UIFocusItemScrollableContainer,
Implementors§
impl UIFocusItemScrollableContainer for UICollectionView
Available on crate feature
UICollectionView
only.impl UIFocusItemScrollableContainer for UIScrollView
Available on crate feature
UIScrollView
only.impl UIFocusItemScrollableContainer for UITableView
Available on crate feature
UITableView
only.impl UIFocusItemScrollableContainer for UITextView
Available on crate feature
UITextView
only.