Enum Event

Source
#[repr(usize)]
pub enum Event {
Show 78 variants Unknown, OnMousePress(MousePressEvent), OnMouseMove, OnMouseWheel, OnContextMenu, OnInit, OnPaint, OnChar, OnKeyPress, OnKeyRelease, OnSysKeyPress, OnSysKeyRelease, OnKeyEnter, OnKeyEsc, OnMinMaxInfo, OnResize, OnResizeBegin, OnResizeEnd, OnWindowMaximize, OnWindowMinimize, OnMove, OnVerticalScroll, OnHorizontalScroll, OnFileDrop, OnButtonClick, OnButtonDoubleClick, OnLabelClick, OnLabelDoubleClick, OnImageFrameClick, OnImageFrameDoubleClick, OnTextInput, OnComboBoxClosed, OnComboBoxDropdown, OnComboxBoxSelection, OnDatePickerDropdown, OnDatePickerClosed, OnDatePickerChanged, OnListBoxDoubleClick, OnListBoxSelect, TabsContainerChanged, TabsContainerChanging, TrackBarUpdated, OnMenuOpen, OnMenuEnter, OnMenuExit, OnMenuHover, OnMenuItemSelected, OnTooltipText, OnTreeViewClick, OnTreeViewDoubleClick, OnTreeViewRightClick, OnTreeViewBeginItemEdit, OnTreeViewEndItemEdit, OnTreeFocusLost, OnTreeFocus, OnTreeItemDelete, OnTreeItemExpanded, OnTreeItemChanged, OnTreeItemSelectionChanged, OnListViewClear, OnListViewItemRemoved, OnListViewItemInsert, OnListViewItemActivated, OnListViewClick, OnListViewRightClick, OnListViewDoubleClick, OnListViewColumnClick, OnListViewItemChanged, OnListViewFocus, OnListViewFocusLost, OnTrayNotificationShow, OnTrayNotificationHide, OnTrayNotificationTimeout, OnTrayNotificationUserClose, OnTimerTick, OnTimerStop, OnNotice, OnWindowClose,
}
Expand description

Events are identifiers that are sent by controls on user interaction Some events also have data that can be further processed by the event loop. See EventData

Variants§

§

Unknown

Undefined / not implemented event. This can be dispatched by the bigger controls such as ListView and TreeView

§

OnMousePress(MousePressEvent)

Generic mouse press events that can be generated by most window controls

§

OnMouseMove

Generic mouse move event that can be generated by most window controls

§

OnMouseWheel

Generic mouse wheel event that can be generated by most window controls Read the delta value with EventData::OnMouseWheel to check which key.

§

OnContextMenu

Generic window event when the user right clicks a window

§

OnInit

When a top level window control is created.

§

OnPaint

When a control needs to be redrawn

§

OnChar

When a key is pressed on a keyboard. Unlike OnKeyDown, this returns a char (ex: ‘c’) in a EventData::OnChar.

§

OnKeyPress

When a key is pressed on a keyboard. Use EventData::OnKey to check which key.

§

OnKeyRelease

When a key is released on a keyboard. Use EventData::OnKey to check which key.

§

OnSysKeyPress

When a system key is pressed on a keyboard. Use EventData::OnKey to check which key.

§

OnSysKeyRelease

When a system key is released on a keyboard. Use EventData::OnKey to check which key.

§

OnKeyEnter

When Enter is pressed.

§

OnKeyEsc

When Esc key is pressed.

§

OnMinMaxInfo

Sent to a window when the size or position of the window is about to change. An application can use the event data EventData::OnMinMaxInfo to override the minimum or maximum size.

§

OnResize

When a control is resized by the user. This is typically applied to top level windows but it also applies to children when layouts are used.

§

OnResizeBegin

When a control is about to be resized by the user. This does not trigger on maximize

§

OnResizeEnd

When a control stops being resized This does not trigger on maximize

§

OnWindowMaximize

§

OnWindowMinimize

§

OnMove

When a control is moved by the user. This is typically applied to top level windows. This is typically applied to top level windows but it also applies to children when layouts are used.

§

OnVerticalScroll

When a bar-like control value is changed.

§

OnHorizontalScroll

When a bar-like control value is changed.

§

OnFileDrop

When a file is dropped into a control

§

OnButtonClick

When a button is clicked. Similar to a MouseUp event, but only for button control

§

OnButtonDoubleClick

When a button is clicked twice rapidly

§

OnLabelClick

When a label is clicked

§

OnLabelDoubleClick

When a label is clicked twice rapidly

§

OnImageFrameClick

When an ImageFrame is clicked

§

OnImageFrameDoubleClick

When an ImageFrame is clicked twice rapidly

§

OnTextInput

When TextInput value is changed

§

OnComboBoxClosed

When the list of a combobox is closed

§

OnComboBoxDropdown

When the list of a combobox is about to be visible

§

OnComboxBoxSelection

When the current selection of the combobox was changed

§

OnDatePickerDropdown

When the date select dropdown is expanded

§

OnDatePickerClosed

When the date select dropdown is closed

§

OnDatePickerChanged

When the value of the date select is changed

§

OnListBoxDoubleClick

When an item on a list box is clicked twice

§

OnListBoxSelect

When an item on a list box is selected

§

TabsContainerChanged

The selected tab of a TabsContainer changed

§

TabsContainerChanging

The selected tab of a TabsContainer is about to be changed

§

TrackBarUpdated

When the trackbar thumb is released by the user

§

OnMenuOpen

When a menu control is opened

§

OnMenuEnter

When the user enters the menu modal loop

§

OnMenuExit

When the user exits the menu modal loop

§

OnMenuHover

When a menu is hovered (either through mouse or keyboard)

§

OnMenuItemSelected

When the user selects on a menu item

§

OnTooltipText

When the user hovers over a callback tooltip The callback will also receive a EventData::OnTooltipText

§

OnTreeViewClick

When the user has clicked the left mouse button within the control.

§

OnTreeViewDoubleClick

When the user has clicked the left mouse button within the control twice rapidly.

§

OnTreeViewRightClick

When the user has clicked the right mouse button within the control.

§

OnTreeViewBeginItemEdit

When begins in-place editing of the specified item’s text.

§

OnTreeViewEndItemEdit

When ends the editing of a treeview item’s label.

§

OnTreeFocusLost

When the control has lost the input focus

§

OnTreeFocus

When the control has acquired the input focus

§

OnTreeItemDelete

When an item is removed from the treeview. The item being deleted is passed in EventData::OnTreeItemDelete

§

OnTreeItemExpanded

When an item is expanded. Generates a EventData::OnTreeItemDelete

§

OnTreeItemChanged

When the state of a tree item is changed.

§

OnTreeItemSelectionChanged

When the selected tree item is changed.

§

OnListViewClear

When all the items in a list view are destroyed Do not add, delete, or rearrange items in the list view while processing this notification code.

§

OnListViewItemRemoved

When an item is about to be removed from the list view Do not add, delete, or rearrange items in the list view while processing this notification code. Generates an EventData::ListViewItemIndex

§

OnListViewItemInsert

When a new item is inserted in the list view This is only triggered when an ietm is added to a new ROW

§

OnListViewItemActivated

When an item in the list view is activated by the user An item is activated when the user clicks it twice Generates an EventData::ListViewItemIndex

§

OnListViewClick

When the user has clicked the left mouse button within the control Generates an EventData::ListViewItemIndex

§

OnListViewRightClick

When the user has clicked the right mouse button within the control Generates an EventData::ListViewItemIndex

§

OnListViewDoubleClick

When the user has clicked the left mouse button within the control twice rapidly Generates an EventData::ListViewItemIndex

§

OnListViewColumnClick

When the user has clicked the left mouse button on ListView header column Generates an EventData::ListViewItemIndex

§

OnListViewItemChanged

When an item is selected/unselected in the listview See EventData::OnListViewItemChanged to differentiate the two

§

OnListViewFocus

When the control has acquired the input focus

§

OnListViewFocusLost

When the control has lost the input focus

§

OnTrayNotificationShow

When a TrayNotification info popup (not the tooltip) is shown

§

OnTrayNotificationHide

When a TrayNotification info popup (not the tooltip) is hidden

§

OnTrayNotificationTimeout

When a TrayNotification is closed due to a timeout

§

OnTrayNotificationUserClose

When a TrayNotification is closed due to a user click

§

OnTimerTick

When a timer delay is elapsed

§

OnTimerStop

When a timer end condition is reached

§

OnNotice

When a notice is… noticed

§

OnWindowClose

When a user clicks on the X button of a window

Trait Implementations§

Source§

impl Clone for Event

Source§

fn clone(&self) -> Event

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 Event

Source§

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

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

impl PartialEq for Event

Source§

fn eq(&self, other: &Event) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Copy for Event

Source§

impl Eq for Event

Source§

impl StructuralPartialEq for Event

Auto Trait Implementations§

§

impl Freeze for Event

§

impl RefUnwindSafe for Event

§

impl Send for Event

§

impl Sync for Event

§

impl Unpin for Event

§

impl UnwindSafe for Event

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.