home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Kyūkyoku!! X68000 Emulator
/
X68000Book.dat
/
mac
/
OLS
/
X68000
/
Ko-Window
/
kow142s.lzh
/
wsrv
/
window.h
< prev
next >
Wrap
C/C++ Source or Header
|
1995-09-08
|
4KB
|
154 lines
#define WindowType 0
#define WindowAttrTra 1 /* ôºû╛æ«É½ */
#define WindowAttrInvisible 2 /* òsë┬Äïæ«É½ */
#define WindowAttrGraphic 4 /* âOâëâtâBâbâNÄgùpæ«É½ */
/* âOâëâtâBâbâNâéü[âh */
#define WindowAttrGraphic16 4
#define WindowAttrGraphic256 8
#define WindowAttrGraphic65536 12
#define WindowAttrGraphicUse 28
/*
* âCâxâôâgÅεò±
*/
#define EventAttrDefault ( EventOpenON | EventRedrawON | EventCloseON | \
EventResizeON | EventIconifyON | EventZoomON | \
EventMouseSwitchON | EventMouseEnterON | \
EventMouseOutON | EventKeyON )
#define EventOpenON (1<<EventOpen)
#define EventRedrawON (1<<EventRedraw)
#define EventCloseON (1<<EventClose)
#define EventPopON (1<<EventPop)
#define EventPushON (1<<EventPush)
#define EventMoveON (1<<EventMove)
#define EventResizeON (1<<EventResize)
#define EventIconifyON (1<<EventIconify)
#define EventZoomON (1<<EventZoom)
#define EventScrollON (1<<EventScroll)
#define EventMouseSwitchON (1<<EventMouseSwitch)
#define EventMouseMoveON (1<<EventMouseMove)
#define EventMouseEnterON (1<<EventMouseEnter)
#define EventMouseOutON (1<<EventMouseOut)
#define EventKeyON (1<<EventKey)
#define EventIntervalON (1<<EventInterval)
#define EventNonON (1<<EventNon)
#define EventUserON (1<<EventUser)
#define EventGraphicON (1<<EventGraphic)
typedef enum {
EventOpen,
EventRedraw,
EventClose,
EventPop,
EventPush,
EventMove,
EventResize,
EventIconify,
EventZoom,
EventScroll,
EventMouseSwitch,
EventMouseMove,
EventMouseEnter,
EventMouseOut,
EventKey,
EventInterval,
EventNon,
EventUser,
EventGraphic,
}
EventOption ;
typedef struct {
EventOption option ;
int x, y, h, v ;
int RightStat, LeftStat ;
int LeftON, LeftOFF ;
int RightON, RightOFF ;
int MoveFlag ;
int KeyCode ;
int ShiftStat ;
int Counter ;
int ComData ;
void *ComBuffer ;
}
EventInfo ;
/*
* âEâCâôâhâEì\æóæ╠
*/
typedef struct {
int type ;
int check ;
int client ;
void *clientp ;
int ownerid ;
int attr ;
int eventattr ;
ClipClass curclip ;
int hx, hy ;
void *parent ;
void *last, *next ;
void *childtop, *childbottom ;
int id ;
int (*event)();
}
WindowPart ;
typedef struct {
ClipPart clip ;
WindowPart window ;
}
WindowClass ;
#if !defined(_K_WINDOW)
extern int (*SendEventExec)();
extern void (*WindowError)();
#endif
/*
proto -e window.c > temp
*/
extern void WindowSet( WindowClass*, int, int, int, int, WindowClass*, int, int(*)() );
extern void WindowClose( WindowClass* );
extern void WindowSetClientData( WindowClass*, int, void* );
extern void WindowSetAttr( WindowClass*, int );
extern void WindowSetEventAttr( WindowClass*, int );
extern void WindowPop( WindowClass* );
extern void WindowPush( WindowClass* );
extern void WindowRedraw( WindowClass* );
extern void WindowMove( WindowClass*, int, int );
extern void WindowResize( WindowClass*, int, int, int, int );
extern void WindowSetHome( WindowClass*, int, int );
extern void WindowScroll( WindowClass*, int, int );
extern void WindowDrawAbs( WindowClass*, DrawBuf*, int );
extern void WindowDraw( WindowClass*, DrawBuf*, int );
extern int WindowGetEventAttr( WindowClass* );
extern int WindowGetClientData( WindowClass* );
extern void *WindowGetClientPointer( WindowClass* );
extern void WindowGetPosition( WindowClass*, int*, int* );
extern void WindowGetViewPosition( WindowClass*, int*, int* );
extern void WindowGetScreenPosition( WindowClass*, int*, int* );
extern void WindowGetViewSize( WindowClass*, int*, int* );
extern void WindowGetHome( WindowClass*, int*, int* );
extern WindowClass *WindowGetParent( WindowClass* );
extern WindowClass *WindowGetNext( WindowClass* );
extern WindowClass *WindowGetLast( WindowClass* );
extern WindowClass *WindowGetChildTop( WindowClass* );
extern WindowClass *WindowGetChildBottom( WindowClass* );
extern WindowClass *WindowGetChild( WindowClass*, EventInfo* );
extern int SendEvent( int, int(*)(), WindowClass*, EventInfo* );
extern int WindowSendEvent( WindowClass*, EventInfo* );
extern int WindowSendEventAll( int, EventInfo* );
/* 1991 COR. */
/*extern void ErrorCheck( int,char* );*/
#define ErrorCheck( flag, mes ) (!(flag)? _ErrorCheck(mes) : 0)
extern void _ErrorCheck( char* );