|
XenevaOS
|
#include <stdlib.h>#include <string.h>#include "events/mouse_event.h"#include "core/document.h"#include "utils/utils.h"
| dom_exception _dom_mouse_event_create | ( | struct dom_mouse_event ** | evt | ) |
| void _dom_mouse_event_destroy | ( | struct dom_mouse_event * | evt | ) |
| dom_exception _dom_mouse_event_get_alt_key | ( | dom_mouse_event * | evt, |
| bool * | key | ||
| ) |
Get the alt key state
| evt | The Event object |
| key | Whether the Alt key is pressed down |
| dom_exception _dom_mouse_event_get_button | ( | dom_mouse_event * | evt, |
| unsigned short * | button | ||
| ) |
Get the button which get pressed
| evt | The Event object |
| button | The pressed mouse button |
| dom_exception _dom_mouse_event_get_client_x | ( | dom_mouse_event * | evt, |
| int32_t * | x | ||
| ) |
Get clientX
| evt | The Event object |
| x | The returned clientX |
| dom_exception _dom_mouse_event_get_client_y | ( | dom_mouse_event * | evt, |
| int32_t * | y | ||
| ) |
Get clientY
| evt | The Event object |
| y | The returned clientY |
| dom_exception _dom_mouse_event_get_ctrl_key | ( | dom_mouse_event * | evt, |
| bool * | key | ||
| ) |
Get the ctrl key state
| evt | The Event object |
| key | Whether the Control key is pressed down |
| dom_exception _dom_mouse_event_get_meta_key | ( | dom_mouse_event * | evt, |
| bool * | key | ||
| ) |
Get the meta key state
| evt | The Event object |
| key | Whether the Meta key is pressed down |
| dom_exception _dom_mouse_event_get_modifier_state | ( | dom_mouse_event * | evt, |
| dom_string * | m, | ||
| bool * | state | ||
| ) |
Query the state of a modifier using a key identifier
| evt | The event object |
| ml | The modifier identifier, such as "Alt", "Control", "Meta", "AltGraph", "CapsLock", "NumLock", "Scroll", "Shift". |
| state | Whether the modifier key is pressed |
| dom_exception _dom_mouse_event_get_related_target | ( | dom_mouse_event * | evt, |
| dom_event_target ** | et | ||
| ) |
Get the related target
| evt | The Event object |
| et | The related EventTarget |
| dom_exception _dom_mouse_event_get_screen_x | ( | dom_mouse_event * | evt, |
| int32_t * | x | ||
| ) |
Get screenX
| evt | The Event object |
| x | The returned screenX |
| dom_exception _dom_mouse_event_get_screen_y | ( | dom_mouse_event * | evt, |
| int32_t * | y | ||
| ) |
Get screenY
| evt | The Event object |
| y | The returned screenY |
| dom_exception _dom_mouse_event_get_shift_key | ( | dom_mouse_event * | evt, |
| bool * | key | ||
| ) |
Get the shift key state
| evt | The Event object |
| key | Whether the Shift key is pressed down |
| dom_exception _dom_mouse_event_init | ( | dom_mouse_event * | evt, |
| dom_string * | type, | ||
| bool | bubble, | ||
| bool | cancelable, | ||
| struct dom_abstract_view * | view, | ||
| int32_t | detail, | ||
| int32_t | screen_x, | ||
| int32_t | screen_y, | ||
| int32_t | client_x, | ||
| int32_t | client_y, | ||
| bool | ctrl, | ||
| bool | alt, | ||
| bool | shift, | ||
| bool | meta, | ||
| unsigned short | button, | ||
| dom_event_target * | et | ||
| ) |
Initialise this mouse event
| evt | The Event object |
| type | The event's type |
| bubble | Whether this is a bubbling event |
| cancelable | Whether this is a cancelable event |
| view | The AbstractView associated with this event |
| detail | The detail information of this mouse event |
| screen_x | The x position of the mouse pointer in screen |
| screen_y | The y position of the mouse pointer in screen |
| client_x | The x position of the mouse pointer in client window |
| client_y | The y position of the mouse pointer in client window |
| alt | The state of Alt key, true for pressed, false otherwise |
| shift | The state of Shift key, true for pressed, false otherwise |
| mata | The state of Meta key, true for pressed, false otherwise |
| button | The mouse button pressed |
| et | The related target of this event, may be NULL |
| dom_exception _dom_mouse_event_init_ns | ( | dom_mouse_event * | evt, |
| dom_string * | namespace, | ||
| dom_string * | type, | ||
| bool | bubble, | ||
| bool | cancelable, | ||
| struct dom_abstract_view * | view, | ||
| int32_t | detail, | ||
| int32_t | screen_x, | ||
| int32_t | screen_y, | ||
| int32_t | client_x, | ||
| int32_t | client_y, | ||
| bool | ctrl, | ||
| bool | alt, | ||
| bool | shift, | ||
| bool | meta, | ||
| unsigned short | button, | ||
| dom_event_target * | et | ||
| ) |
Initialise the event with namespace
| evt | The Event object |
| namespace | The namespace of this event |
| type | The event's type |
| bubble | Whether this is a bubbling event |
| cancelable | Whether this is a cancelable event |
| view | The AbstractView associated with this event |
| detail | The detail information of this mouse event |
| screen_x | The x position of the mouse pointer in screen |
| screen_y | The y position of the mouse pointer in screen |
| client_x | The x position of the mouse pointer in client window |
| client_y | The y position of the mouse pointer in client window |
| alt | The state of Alt key, true for pressed, false otherwise |
| shift | The state of Shift key, true for pressed, false otherwise |
| mata | The state of Meta key, true for pressed, false otherwise |
| button | The mouse button pressed |
| et | The related target of this event, may be NULL |
| dom_exception _dom_mouse_event_initialise | ( | struct dom_mouse_event * | evt | ) |