git-svn-id: http://svn2.nishi.boats/svn/milsko/trunk@400 b9cfdab3-6d41-4d17-bbe4-086880011989
This commit is contained in:
NishiOwO
2025-10-17 19:11:32 +00:00
parent 7a531de084
commit 599b1ee0c8
11 changed files with 214 additions and 3 deletions

View File

@@ -237,6 +237,25 @@ MWDECL void MwForceRender2(MwWidget handle, void* ptr);
*/
MWDECL void MwAddTickList(MwWidget handle);
/*!
* %brief Focus the widget
* %param handle Widget
*/
MWDECL void MwFocus(MwWidget handle);
/*!
* %brief Grabs the pointer
* %param handle Widget
* %param toggle Toggle
*/
MWDECL void MwGrabPointer(MwWidget handle, int toggle);
/*!
* %brief Hides the cursor
* %param handle Widget
*/
MWDECL void MwHideCursor(MwWidget handle);
#ifdef __cplusplus
}
#endif

View File

@@ -44,6 +44,16 @@ MWDECL MwCursor MwCursorText;
*/
MWDECL MwCursor MwCursorTextMask;
/*!
* %brief Hidden cursor
*/
MWDECL MwCursor MwCursorHidden;
/*!
* %brief Hidden cursor mask
*/
MWDECL MwCursor MwCursorHiddenMask;
#ifdef __cplusplus
}
#endif

View File

@@ -42,7 +42,9 @@ enum MwLLKeyEnum {
MwLLKeyLeft,
MwLLKeyRight,
MwLLKeyUp,
MwLLKeyDown
MwLLKeyDown,
MwLLKeyEnter,
MwLLKeyEscape
};
enum MwLLMouseEnum {
@@ -67,6 +69,8 @@ struct _MwLLHandler {
void (*move)(MwLL handle, void* data);
void (*key)(MwLL handle, void* data);
void (*key_released)(MwLL handle, void* data);
void (*focus_in)(MwLL handle, void* data);
void (*focus_out)(MwLL handle, void* data);
};
#ifdef __cplusplus
@@ -117,6 +121,9 @@ MWDECL long MwLLGetTick(void);
MWDECL void MwLLSetBackground(MwLL handle, MwLLColor color);
MWDECL void MwLLFocus(MwLL handle);
MWDECL void MwLLGrabPointer(MwLL handle, int toggle);
#ifdef __cplusplus
}
#endif

View File

@@ -45,5 +45,7 @@
#define MwNkeyHandler "Ckey" /* int* (MwLLKeyEnum or character code) */
#define MwNkeyReleaseHandler "CkeyRelease" /* same as MwNkeyHandler */
#define MwNcloseHandler "Cclose" /* NULL */
#define MwNfocusInHandler "CfocusIn" /* NULL */
#define MwNfocusOutHandler "CfocusOut" /* NULL */
#endif