Trait objc2_web_kit::WKUIDelegate
source · pub unsafe trait WKUIDelegate: NSObjectProtocol {
// Provided methods
unsafe fn webView_createWebViewWithConfiguration_forNavigationAction_windowFeatures(
&self,
web_view: &WKWebView,
configuration: &WKWebViewConfiguration,
navigation_action: &WKNavigationAction,
window_features: &WKWindowFeatures
) -> Option<Retained<WKWebView>>
where Self: Sized + Message { ... }
unsafe fn webViewDidClose(&self, web_view: &WKWebView)
where Self: Sized + Message { ... }
unsafe fn webView_runJavaScriptAlertPanelWithMessage_initiatedByFrame_completionHandler(
&self,
web_view: &WKWebView,
message: &NSString,
frame: &WKFrameInfo,
completion_handler: &Block<dyn Fn()>
)
where Self: Sized + Message { ... }
unsafe fn webView_runJavaScriptConfirmPanelWithMessage_initiatedByFrame_completionHandler(
&self,
web_view: &WKWebView,
message: &NSString,
frame: &WKFrameInfo,
completion_handler: &Block<dyn Fn(Bool)>
)
where Self: Sized + Message { ... }
unsafe fn webView_runJavaScriptTextInputPanelWithPrompt_defaultText_initiatedByFrame_completionHandler(
&self,
web_view: &WKWebView,
prompt: &NSString,
default_text: Option<&NSString>,
frame: &WKFrameInfo,
completion_handler: &Block<dyn Fn(*mut NSString)>
)
where Self: Sized + Message { ... }
unsafe fn webView_requestMediaCapturePermissionForOrigin_initiatedByFrame_type_decisionHandler(
&self,
web_view: &WKWebView,
origin: &WKSecurityOrigin,
frame: &WKFrameInfo,
type: WKMediaCaptureType,
decision_handler: &Block<dyn Fn(WKPermissionDecision)>
)
where Self: Sized + Message { ... }
unsafe fn webView_requestDeviceOrientationAndMotionPermissionForOrigin_initiatedByFrame_decisionHandler(
&self,
web_view: &WKWebView,
origin: &WKSecurityOrigin,
frame: &WKFrameInfo,
decision_handler: &Block<dyn Fn(WKPermissionDecision)>
)
where Self: Sized + Message { ... }
unsafe fn webView_runOpenPanelWithParameters_initiatedByFrame_completionHandler(
&self,
web_view: &WKWebView,
parameters: &WKOpenPanelParameters,
frame: &WKFrameInfo,
completion_handler: &Block<dyn Fn(*mut NSArray<NSURL>)>
)
where Self: Sized + Message { ... }
}
Available on crate feature
WKUIDelegate
only.Provided Methods§
Available on crate feature
WKNavigationAction
and crate feature WKWebView
and crate feature WKWebViewConfiguration
and crate feature WKWindowFeatures
and crate feature objc2-app-kit
and macOS only.unsafe fn webViewDidClose(&self, web_view: &WKWebView)
Available on crate feature
WKWebView
and crate feature objc2-app-kit
and macOS only.unsafe fn webView_runJavaScriptAlertPanelWithMessage_initiatedByFrame_completionHandler( &self, web_view: &WKWebView, message: &NSString, frame: &WKFrameInfo, completion_handler: &Block<dyn Fn()> )
Available on crate feature
WKFrameInfo
and crate feature WKWebView
and crate feature block2
and crate feature objc2-app-kit
and macOS only.unsafe fn webView_runJavaScriptConfirmPanelWithMessage_initiatedByFrame_completionHandler( &self, web_view: &WKWebView, message: &NSString, frame: &WKFrameInfo, completion_handler: &Block<dyn Fn(Bool)> )
Available on crate feature
WKFrameInfo
and crate feature WKWebView
and crate feature block2
and crate feature objc2-app-kit
and macOS only.unsafe fn webView_runJavaScriptTextInputPanelWithPrompt_defaultText_initiatedByFrame_completionHandler( &self, web_view: &WKWebView, prompt: &NSString, default_text: Option<&NSString>, frame: &WKFrameInfo, completion_handler: &Block<dyn Fn(*mut NSString)> )
Available on crate feature
WKFrameInfo
and crate feature WKWebView
and crate feature block2
and crate feature objc2-app-kit
and macOS only.unsafe fn webView_requestMediaCapturePermissionForOrigin_initiatedByFrame_type_decisionHandler( &self, web_view: &WKWebView, origin: &WKSecurityOrigin, frame: &WKFrameInfo, type: WKMediaCaptureType, decision_handler: &Block<dyn Fn(WKPermissionDecision)> )
Available on crate feature
WKFrameInfo
and crate feature WKSecurityOrigin
and crate feature WKWebView
and crate feature block2
and crate feature objc2-app-kit
and macOS only.unsafe fn webView_requestDeviceOrientationAndMotionPermissionForOrigin_initiatedByFrame_decisionHandler( &self, web_view: &WKWebView, origin: &WKSecurityOrigin, frame: &WKFrameInfo, decision_handler: &Block<dyn Fn(WKPermissionDecision)> )
Available on crate feature
WKFrameInfo
and crate feature WKSecurityOrigin
and crate feature WKWebView
and crate feature block2
and crate feature objc2-app-kit
and macOS only.unsafe fn webView_runOpenPanelWithParameters_initiatedByFrame_completionHandler( &self, web_view: &WKWebView, parameters: &WKOpenPanelParameters, frame: &WKFrameInfo, completion_handler: &Block<dyn Fn(*mut NSArray<NSURL>)> )
Available on crate feature
WKFrameInfo
and crate feature WKOpenPanelParameters
and crate feature WKWebView
and crate feature block2
and crate feature objc2-app-kit
and macOS only.