_cef_context_menu_params_t

Struct _cef_context_menu_params_t 

Source
#[repr(C)]
pub struct _cef_context_menu_params_t {
Show 21 fields pub base: cef_base_ref_counted_t, pub get_xcoord: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> c_int>, pub get_ycoord: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> c_int>, pub get_type_flags: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_context_menu_type_flags_t>, pub get_link_url: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>, pub get_unfiltered_link_url: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>, pub get_source_url: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>, pub has_image_contents: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> c_int>, pub get_title_text: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>, pub get_page_url: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>, pub get_frame_url: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>, pub get_frame_charset: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>, pub get_media_type: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_context_menu_media_type_t>, pub get_media_state_flags: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_context_menu_media_state_flags_t>, pub get_selection_text: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>, pub get_misspelled_word: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>, pub get_dictionary_suggestions: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t, suggestions: cef_string_list_t) -> c_int>, pub is_editable: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> c_int>, pub is_spell_check_enabled: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> c_int>, pub get_edit_state_flags: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_context_menu_edit_state_flags_t>, pub is_custom_menu: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> c_int>,
}
Expand description

Provides information about the context menu state. The functions of this structure can only be accessed on browser process the UI thread.

NOTE: This struct is allocated DLL-side.

Fields§

§base: cef_base_ref_counted_t

Base structure.

§get_xcoord: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> c_int>

Returns the X coordinate of the mouse where the context menu was invoked. Coords are relative to the associated RenderView’s origin.

§get_ycoord: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> c_int>

Returns the Y coordinate of the mouse where the context menu was invoked. Coords are relative to the associated RenderView’s origin.

§get_type_flags: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_context_menu_type_flags_t>

Returns flags representing the type of node that the context menu was invoked on.

§get_link_url: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>

Returns the URL of the link, if any, that encloses the node that the context menu was invoked on.

§get_unfiltered_link_url: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>

Returns the link URL, if any, to be used ONLY for “copy link address”. We don’t validate this field in the frontend process.

§get_source_url: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>

Returns the source URL, if any, for the element that the context menu was invoked on. Example of elements with source URLs are img, audio, and video.

§has_image_contents: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> c_int>

Returns true (1) if the context menu was invoked on an image which has non-NULL contents.

§get_title_text: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>

Returns the title text or the alt text if the context menu was invoked on an image.

§get_page_url: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>

Returns the URL of the top level page that the context menu was invoked on.

§get_frame_url: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>

Returns the URL of the subframe that the context menu was invoked on.

§get_frame_charset: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>

Returns the character encoding of the subframe that the context menu was invoked on.

§get_media_type: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_context_menu_media_type_t>

Returns the type of context node that the context menu was invoked on.

§get_media_state_flags: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_context_menu_media_state_flags_t>

Returns flags representing the actions supported by the media element, if any, that the context menu was invoked on.

§get_selection_text: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>

Returns the text of the selection, if any, that the context menu was invoked on.

§get_misspelled_word: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_string_userfree_t>

Returns the text of the misspelled word, if any, that the context menu was invoked on.

§get_dictionary_suggestions: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t, suggestions: cef_string_list_t) -> c_int>

Returns true (1) if suggestions exist, false (0) otherwise. Fills in |suggestions| from the spell check service for the misspelled word if there is one.

§is_editable: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> c_int>

Returns true (1) if the context menu was invoked on an editable node.

§is_spell_check_enabled: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> c_int>

Returns true (1) if the context menu was invoked on an editable node where spell-check is enabled.

§get_edit_state_flags: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> cef_context_menu_edit_state_flags_t>

Returns flags representing the actions supported by the editable node, if any, that the context menu was invoked on.

§is_custom_menu: Option<unsafe extern "C" fn(self_: *mut _cef_context_menu_params_t) -> c_int>

Returns true (1) if the context menu contains items specified by the renderer process.

Trait Implementations§

Source§

impl Clone for _cef_context_menu_params_t

Source§

fn clone(&self) -> _cef_context_menu_params_t

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for _cef_context_menu_params_t

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Copy for _cef_context_menu_params_t

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.