#include <stdio.h>
#include <stdlib.h>
#include <winb.h>
#include <te.h>
#include <fntb.h>
#include <gui.h>

extern int	backHyper1 ;
extern int	MJ_BASEOBJ ;
extern int	baseWin ;
extern int	baseWinFunc() ;
extern int	cntrlDlg ;
extern int	playBtn ;
extern int	BtnFunc() ;
extern int	fileBtn ;
extern int	cntrlBar ;
extern int	cntrlBarFunc() ;
extern int	pageMsg ;
extern int	waitNumbox ;
extern int	waitNumboxFunc() ;
extern int	helWin ;
extern int	helWinFunc() ;
extern int	backHyper2 ;

#define ALIGN	4
#define OFFSET(type) (sizeof(MMIPACKET) + (sizeof(type)+ALIGN-1)/ALIGN*ALIGN)

/*	MMI_init 用データ	*/

/*	ヘッダ	*/

MMIINIT	initDataBASE = { "MmiInit",  10, 0 } ;

/* backHyper1 */

static MMIPACKET d001 = {	&backHyper1,
							&MJ_BASEOBJ,
							&MJ_HYPER,
							OFFSET(HYPER),
							MS_NONE
						} ;
static HYPER	d001d = {	MS_NONEL40,
							 295,   1, 322,  28, 0, 0, 0,
							MS_NONEL40,
						} ;

/* baseWin */

static MMIPACKET d002 = {	&baseWin,
							&backHyper1,
							&MJ_WINDOWL40,
							OFFSET(WINDOWL40),
							MS_NONE
						} ;
static WINDOWL40	d002d = {	MS_BTLEFTL40 | MS_EVMOSONL40 | MS_TITLEL40 | MS_CLOSEL40,
							   0,   0, 169, 209, 8,15, 9,
							MS_SRECTL40 | MS_FRAMEL40,
							NULL,   0,   0,
							   1,  17,   0,   0,
							 128,  96, 640, 480,
							baseWinFunc,
							"GHEL v1.2",
						} ;

/* cntrlDlg */

static MMIPACKET d003 = {	&cntrlDlg,
							&baseWin,
							&MJ_DIALOGL40,
							OFFSET(DIALOGL40),
							MS_NONE
						} ;
static DIALOGL40	d003d = {	MS_BTLEFTL40 | MS_EVMOSONL40 | MS_FIXEDL40,
							   3, 143, 164, 204, 8, 4, 0,
							MS_BFRAMEL40 | MS_FRAMEL40,
							NULL,   0,   0
						} ;

/* playBtn */

static MMIPACKET d004 = {	&playBtn,
							&cntrlDlg,
							&MJ_ICONL40,
							OFFSET(ICONL40),
							MS_NONE
						} ;
static ICONL40	d004d = 	{	MS_BTLEFTL40 | MS_EVMOSOFFL40 | MS_EVKEYONL40 | MS_LEFTL40,
							  60, 151,  82, 174, 8, 4, 8,
							MS_PANELL40 | MS_FRAMEL40,
							BtnFunc,
							0x8012, 257
						} ;

/* fileBtn */

static MMIPACKET d005 = {	&fileBtn,
							&cntrlDlg,
							&MJ_ICONL40,
							OFFSET(ICONL40),
							MS_NONE
						} ;
static ICONL40	d005d = 	{	MS_BTLEFTL40 | MS_EVMOSOFFL40 | MS_EVKEYONL40 | MS_LEFTL40,
							  86, 151, 108, 174, 8, 4, 8,
							MS_PANELL40 | MS_FRAMEL40,
							BtnFunc,
							0x000c, 293
						} ;

/* cntrlBar */

static MMIPACKET d006 = {	&cntrlBar,
							&cntrlDlg,
							&MJ_SCRLL40,
							OFFSET(SCRLL40),
							MS_NONE
						} ;
static SCRLL40	d006d = 	{	MS_BTLEFTL40 | MS_REPEATL40 | MS_EVMOSONL40 | MS_HORIL40,
							   8, 183, 158, 198, 8, 4, 7,
							MS_PANELL40 | MS_FRAMEL40,
							cntrlBarFunc,
							   0,   0, 255, 255,  16,
							 265, 266
						} ;

/* pageMsg */

static MMIPACKET d007 = {	&pageMsg,
							&cntrlDlg,
							&MJ_MSGL40,
							OFFSET(MSGL40),
							MS_NONE
						} ;
static MSGL40	d007d = 	{	MS_CENTERL40 | MS_DSPONLYL40,
							   9, 156,  56, 169, 8, 4, 8,
							MS_OPAQUEL40,
							"0/0",
							   1,  12,  12,
							MS_NONEL40,
							   0,   0
						} ;

/* waitNumbox */

static MMIPACKET d008 = {	&waitNumbox,
							&cntrlDlg,
							&MJ_NUMBOXL40,
							OFFSET(NUMBOXL40),
							MS_NONE
						} ;
static NUMBOXL40	d008d = 	{	MS_BTLEFTL40 | MS_REPEATL40 | MS_EVMOSONL40 | MS_EVKEYONL40 | MS_RIGHTL40,
							 113, 151, 160, 174, 8, 4, 8,
							MS_PANELL40 | MS_FRAMEL40,
							waitNumboxFunc,
							   1,  12,  12,
							MS_NONEL40,
							   0,   0,
							   0,   0, 255,   1,   0,
							 263, 264
						} ;

/* helWin */

static MMIPACKET d009 = {	&helWin,
							&baseWin,
							&MJ_WINDOWL40,
							OFFSET(WINDOWL40),
							MS_NONE
						} ;
static WINDOWL40	d009d = {	MS_BTLEFTL40 | MS_EVMOSONL40 | MS_HIDEL40 | MS_FIXEDL40,
							   3,  19, 164, 140, 0,15, 9,
							MS_FRAMEL40,
							NULL,   0,   0,
							   1,   1, 160, 120,
							 128,  96, 640, 480,
							helWinFunc,
							NULL,
						} ;

/* backHyper2 */

static MMIPACKET d010 = {	&backHyper2,
							&MJ_BASEOBJ,
							&MJ_HYPER,
							0,
							MS_NONE
						} ;
static HYPER	d010d = {	MS_NONEL40,
							 202,   0, 229,  27, 0, 0, 0,
							MS_NONEL40,
						} ;

