pub unsafe trait WebDocumentView: NSObjectProtocol {
// Provided methods
unsafe fn setDataSource(&self, data_source: Option<&WebDataSource>)
where Self: Sized + Message { ... }
unsafe fn dataSourceUpdated(&self, data_source: Option<&WebDataSource>)
where Self: Sized + Message { ... }
unsafe fn setNeedsLayout(&self, flag: bool)
where Self: Sized + Message { ... }
unsafe fn layout(&self)
where Self: Sized + Message { ... }
unsafe fn viewDidMoveToHostWindow(&self)
where Self: Sized + Message { ... }
}
👎Deprecated
Available on crate feature
WebDocument
only.Expand description
Protocol implemented by the document view of WebFrameView
See also Apple’s documentation
Provided Methods§
Sourceunsafe fn setDataSource(&self, data_source: Option<&WebDataSource>)
👎DeprecatedAvailable on crate feature WebDataSource
only.
unsafe fn setDataSource(&self, data_source: Option<&WebDataSource>)
WebDataSource
only.Called when the corresponding data source has been created.
Parameter dataSource
: The corresponding data source.
Sourceunsafe fn dataSourceUpdated(&self, data_source: Option<&WebDataSource>)
👎DeprecatedAvailable on crate feature WebDataSource
only.
unsafe fn dataSourceUpdated(&self, data_source: Option<&WebDataSource>)
WebDataSource
only.Called when the corresponding data source has received data.
Parameter dataSource
: The corresponding data source.
Sourceunsafe fn setNeedsLayout(&self, flag: bool)
👎Deprecated
unsafe fn setNeedsLayout(&self, flag: bool)
Called when WebKit has determined that the document view needs to layout. This method should simply set a flag and call layout from drawRect if the flag is YES.
Parameter flag
: YES to cause a layout, no to not cause a layout.
Sourceunsafe fn layout(&self)
👎Deprecated
unsafe fn layout(&self)
Called when the document view must immediately layout. For simple views, setting the frame is a sufficient implementation of this method.
Sourceunsafe fn viewDidMoveToHostWindow(&self)
👎Deprecated
unsafe fn viewDidMoveToHostWindow(&self)
Called after the host window is set on the parent web view.