Trait webview2_sys::ICoreWebView2ScriptDialogOpeningEventArgs[][src]

pub trait ICoreWebView2ScriptDialogOpeningEventArgs: IUnknown {
    unsafe fn get_uri(&self, uri: *mut LPWSTR) -> HRESULT;
unsafe fn get_kind(&self, kind: *mut ScriptDialogKind) -> HRESULT;
unsafe fn get_message(&self, message: *mut LPWSTR) -> HRESULT;
unsafe fn accept(&self) -> HRESULT;
unsafe fn get_default_text(&self, default_text: *mut LPWSTR) -> HRESULT;
unsafe fn get_result_text(&self, result_text: *mut LPWSTR) -> HRESULT;
unsafe fn put_result_text(&self, result_text: LPCWSTR) -> HRESULT;
unsafe fn get_deferral(
        &self,
        deferral: *mut *mut *mut ICoreWebView2DeferralVTable
    ) -> HRESULT; }

Event args for the ScriptDialogOpening event.

Required methods

unsafe fn get_uri(&self, uri: *mut LPWSTR) -> HRESULT[src]

The URI of the page that requested the dialog box.

unsafe fn get_kind(&self, kind: *mut ScriptDialogKind) -> HRESULT[src]

The kind of JavaScript dialog box. alert, confirm, prompt, or beforeunload.

unsafe fn get_message(&self, message: *mut LPWSTR) -> HRESULT[src]

The message of the dialog box. From JavaScript this is the first parameter passed to alert, confirm, and prompt and is empty for beforeunload.

unsafe fn accept(&self) -> HRESULT[src]

The host may run this to respond with OK to confirm, prompt, and beforeunload dialogs. Do not run this method to indicate cancel. From JavaScript, this means that the confirm and beforeunload function returns TRUE if Accept is run. And for the prompt function it returns the value of ResultText if Accept is run and otherwise returns FALSE.

unsafe fn get_default_text(&self, default_text: *mut LPWSTR) -> HRESULT[src]

The second parameter passed to the JavaScript prompt dialog. The result of the prompt JavaScript function uses this value as the default value.

unsafe fn get_result_text(&self, result_text: *mut LPWSTR) -> HRESULT[src]

The return value from the JavaScript prompt function if Accept is run. This value is ignored for dialog kinds other than prompt. If Accept is not run, this value is ignored and FALSE is returned from prompt.

unsafe fn put_result_text(&self, result_text: LPCWSTR) -> HRESULT[src]

Sets the ResultText property.

unsafe fn get_deferral(
    &self,
    deferral: *mut *mut *mut ICoreWebView2DeferralVTable
) -> HRESULT
[src]

Returns an ICoreWebView2Deferral object. Use this operation to complete the event at a later time.

Loading content...

Trait Implementations

impl ComInterface for dyn ICoreWebView2ScriptDialogOpeningEventArgs[src]

type VTable = ICoreWebView2ScriptDialogOpeningEventArgsVTable

A COM compatible V-Table

type Super = dyn IUnknown

The interface that this interface inherits from

impl<C: ICoreWebView2ScriptDialogOpeningEventArgs> ProductionComInterface<C> for dyn ICoreWebView2ScriptDialogOpeningEventArgs[src]

Implementations on Foreign Types

impl<T: ICoreWebView2ScriptDialogOpeningEventArgs + ComInterface + ?Sized> ICoreWebView2ScriptDialogOpeningEventArgs for ComRc<T>[src]

impl<T: ICoreWebView2ScriptDialogOpeningEventArgs + ComInterface + ?Sized> ICoreWebView2ScriptDialogOpeningEventArgs for ComPtr<T>[src]

Loading content...

Implementors

Loading content...