mirror of
https://gitea.nishi.boats/pyrite-dev/milsko
synced 2025-12-31 06:30:52 +00:00
cursor
git-svn-id: http://svn2.nishi.boats/svn/milsko/trunk@180 b9cfdab3-6d41-4d17-bbe4-086880011989
This commit is contained in:
31
include/Mw/Cursor.h
Normal file
31
include/Mw/Cursor.h
Normal file
@@ -0,0 +1,31 @@
|
||||
/* $Id$ */
|
||||
/*!
|
||||
* %file Mw/Cursor.h
|
||||
* %brief Cursor externs
|
||||
*/
|
||||
|
||||
#ifndef __MW_CURSOR_H__
|
||||
#define __MW_CURSOR_H__
|
||||
|
||||
#include <Mw/MachDep.h>
|
||||
#include <Mw/TypeDefs.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*!
|
||||
* %brief Default cursor
|
||||
*/
|
||||
MWDECL MwCursor MwCursorDefault;
|
||||
|
||||
/*!
|
||||
* %brief Default cursor mask
|
||||
*/
|
||||
MWDECL MwCursor MwCursorDefaultMask;
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -9,11 +9,11 @@
|
||||
|
||||
#include <Mw/MachDep.h>
|
||||
|
||||
typedef struct _MwLLHandler *MwLLHandler, MwLLHandlerRec;
|
||||
typedef struct _MwLLHandler* MwLLHandler;
|
||||
#ifdef _MILSKO
|
||||
typedef struct _MwLL * MwLL, MwLLRec;
|
||||
typedef struct _MwLLColor * MwLLColor, MwLLColorRec;
|
||||
typedef struct _MwLLPixmap *MwLLPixmap, MwLLPixmapRec;
|
||||
typedef struct _MwLL* MwLL;
|
||||
typedef struct _MwLLColor* MwLLColor;
|
||||
typedef struct _MwLLPixmap* MwLLPixmap;
|
||||
#else
|
||||
typedef void* MwLL;
|
||||
typedef void* MwLLColor;
|
||||
@@ -76,6 +76,8 @@ MWDECL void MwLLSetIcon(MwLL handle, MwLLPixmap pixmap);
|
||||
|
||||
MWDECL void MwLLForceRender(MwLL handle);
|
||||
|
||||
MWDECL void MwLLSetCursor(MwLL handle, MwCursor* image, MwCursor* mask);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
#include <Mw/Draw.h>
|
||||
#include <Mw/Font.h>
|
||||
#include <Mw/Error.h>
|
||||
#include <Mw/Cursor.h>
|
||||
#include <Mw/Constants.h>
|
||||
|
||||
#include <Mw/Widget/Window.h>
|
||||
|
||||
@@ -16,12 +16,12 @@ typedef struct _MwTextKeyValue MwTextKeyValue;
|
||||
typedef struct _MwUserHandlerKeyValue MwUserHandlerKeyValue;
|
||||
typedef struct _MwVoidKeyValue MwVoidKeyValue;
|
||||
typedef struct _MwFont MwFont;
|
||||
typedef struct _MwMenu* MwMenu;
|
||||
typedef struct _MwCursor MwCursor;
|
||||
#ifdef _MILSKO
|
||||
typedef struct _MwWidget *MwWidget, MwWidgetRec;
|
||||
typedef struct _MwMenu * MwMenu, MwMenuRec;
|
||||
typedef struct _MwWidget* MwWidget;
|
||||
#else
|
||||
typedef void* MwWidget;
|
||||
typedef void* MwMenu;
|
||||
#endif
|
||||
typedef void (*MwHandler)(MwWidget handle);
|
||||
typedef int (*MwHandler2)(MwWidget handle);
|
||||
@@ -88,6 +88,7 @@ struct _MwWidget {
|
||||
|
||||
MwWidget* destroy_queue;
|
||||
};
|
||||
#endif
|
||||
|
||||
struct _MwMenu {
|
||||
char* name;
|
||||
@@ -95,7 +96,15 @@ struct _MwMenu {
|
||||
MwWidget wsub;
|
||||
MwMenu* sub;
|
||||
};
|
||||
#endif
|
||||
|
||||
#define MwCursorDataHeight 16
|
||||
struct _MwCursor {
|
||||
int width;
|
||||
int height;
|
||||
int x;
|
||||
int y;
|
||||
unsigned int data[MwCursorDataHeight];
|
||||
};
|
||||
|
||||
struct _MwClass {
|
||||
MwHandler2 create;
|
||||
|
||||
Reference in New Issue
Block a user