⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 fsgui1.h

📁 Sunplus 8202S source code.
💻 H
📖 第 1 页 / 共 2 页
字号:
//
// fsGUI.h
//
//      fs9660-GUI module internal include
//
// notes:
//
// history:
//  2002/02/26  : create
//

#ifndef __FS_GUI1_H
#define __FS_GUI1_H

//module global variables for internal reference
UINT16  Hl_x;
UINT16  Hl_y;
UINT16  Hl_len;
UINT16  Hl_high;
UINT16  Hl_x_btn;
UINT16  Hl_y_btn;
UINT16  Hl_len_btn;
UINT16  old_file_page;	        // index of current page
UINT16  old_dir_page;
UINT16  refresh_file_page;
UINT16  refresh_dir_page;
UINT16  refresh_dir_icon;

#ifdef FS_BMP_GUI
#define PER_PAGE                        8
#else
#define	PER_PAGE                        10
#endif

//wanghaoying marked for no used, 2004-5-11 16:52
//#ifdef NEW_MP3_GUI
//#define  SLOT_Y                         0x91
//#define  SLOT_CRCB                      0x429d
//#endif

//black color
#define BLACK_Y                         0x20
#define BLACK_CRCB                      0x8080

//white color
#define WHITE_Y                         0xc0
#define WHITE_CRCB                      0x8080



//background clolr
#if defined(BLUE_MP3_BK_GROUND)
   #define BK_GROUNDY                     0x18     //blue corlor
   #define BK_GROUNDCRCB                 0x6bb5  

#elif defined(MP3_BK_GROUND_GREEN) //li mao add 2004/4/27 
   #define BK_GROUNDY                      0x40     //green corlor
   #define BK_GROUNDCRCB                   0x5050

#elif defined(MP3_BK_GROUND_BLACK)              
   #define BK_GROUNDY                      0x20     //black corlor.
   #define BK_GROUNDCRCB                   0x8080

#elif defined(MP3_BK_GROUND_AQUA)   
   #define BK_GROUNDY                      0x60     // aqua corlor
   #define BK_GROUNDCRCB                   0x7070

#elif defined(NEW_MP3_GUI)
    #define BK_GROUNDY                  RGB2Y(108, 172, 206)
    #define BK_GROUNDCRCB               (RGB2Cr(108, 172, 206)<<8)|(RGB2Cb(108, 172, 206))
//	#define BUTTON_Y                    RGB2Y(108, 172, 206)
//	#define BUTTON_CRCB                 (RGB2Cr(108, 172, 206)<<8)|(RGB2Cb(108, 172, 206))

#elif defined(THUMBNAIL_BMP_GUI)
	#define BK_GROUNDY				0x8f// RGB2Y(125, 147, 169)
	#define BK_GROUNDCRCB             0x738f//  (RGB2Cr(125, 147, 169)<<8)|(RGB2Cb(125, 147, 169))
#else         
    #define BK_GROUNDY                    0x80
    #define BK_GROUNDCRCB                 0x7a85

#endif

#ifndef NEW_MP3_GUI
//high line color
 	#ifdef BLUE_MP3_BK_GROUND
 		#define HL_Y                    0x18
 		#define HL_CRCB                 0x6bb5
	#elif defined FS_BMP_GUI
	    #define HL_Y                    RGB2Y(253, 220, 7)
	    #define HL_CRCB                 (RGB2Cr( 253, 220, 7)<<8)|(RGB2Cb(253, 220, 7))
	    #define HL_SIDE_Y               RGB2Y(186, 160, 0)
	    #define HL_SIDE_CRCB            (RGB2Cr(186, 160, 0)<<8)|(RGB2Cb(186, 160, 0))
	#else
		#define HL_Y                    0x90
		#define HL_CRCB                 0x7090
	#endif
#else
	#define HL_Y                        0xa1//0x80
	#define HL_CRCB                     0xb266//0xbe59
#endif

#ifdef THUMBNAIL_BMP_GUI
	#define THUMBNAIL_BG_Y			0x7d//RGB2Y(106, 130, 150)
	#define THUMBNAIL_BG_CRCB		0x728e//(RGB2Cr( 106, 130, 150)<<8)|(RGB2Cb(106, 130, 150))

	#define THUMBNAIL_OUTER_FRAME_Y	0x9c//RGB2Y(189, 169, 0)
	#define THUMBNAIL_OUTER_FRAME_CRCB	0x9828//(RGB2Cr( 189, 169, 0)<<8)|(RGB2Cb(189, 169, 0))

	#define THUMBNAIL_MID_FRAME_Y		0xd0//RGB2Y(251, 226, 0)
	#define THUMBNAIL_MID_FRAME_CRCB	0x9f0b//(RGB2Cr( 251, 226, 0)<<8)|(RGB2Cb(251, 226, 0))

	#define THUMBNAIL_INNER_FRAME_Y	0x9c//RGB2Y(189, 169, 0)
	#define THUMBNAIL_INNER_FRAME_CRCB	0x9828//(RGB2Cr( 189, 169, 0)<<8)|(RGB2Cb(189, 169, 0))
#endif

//yellow
#define YELLOW_Y                        0xd0
#define YELLOW_CRCB                     0x9050

//red
#define RED_Y                           0x41
#define RED_CRCB                        0xd464


//define FONT color


#define FS_FONTCOLOR_FILE_Y1             0xea
#define FS_FONTCOLOR_FILE_CrCb1          0x8278

#ifdef THUMBNAIL_BMP_GUI
#define FS_FONTCOLOR_FILE_Y             0xde
#define FS_FONTCOLOR_FILE_CrCb          0x8080
#define FS_FONTCOLOR_THUMBNAIL_TITLE_Y 	0x3b//RGB2Y(49, 62, 68)
#define FS_FONTCOLOR_THUMBNAIL_TITLE_CrCb 	0x7985//(RGB2Cr( 49, 62, 68)<<8)|(RGB2Cb(49, 62, 68))

#else
#define FS_FONTCOLOR_FILE_Y             0xea
#define FS_FONTCOLOR_FILE_CrCb          0x8278
#endif

#ifdef FS_BMP_GUI
#define FS_FONTCOLOR_PATH_Y             0xbd
#define FS_FONTCOLOR_PATH_CrCb          0xae15
#define FS_FONTCOLOR_TITLE_Y		    0x08
#define FS_FONTCOLOR_TITLE_CrCb	        0x7aa3
#endif

#define FS_FONTCOLOR_PAGE_UY            0x24
#define FS_FONTCOLOR_PAGE_UCrCb         0x7ba6
#define FS_FONTCOLOR_PAGE_DY            0x29
#define FS_FONTCOLOR_PAGE_DCrCb         0xaf7c

///////////////////////////////////////////////////////////////////
//define main menu look-and-feel style
//Notes : to avoid blinking (when white/black line displaying in n/n+1 line, with interlace mode)
//        SHADOW_WID , LIGHT_WID should >=2
//        X1, Y1, Y3 should be 2*n
#define SHADOW_WID                      2
#define LIGHT_WID                       2

#if defined(FS_BMP_GUI)

#define	X1                              170
#define	Y1                              60
#define	Y3                              232
#define FS_FILEICON_XSTART				437            //file ICON start-x
#define FS_FILEICON_ySTART				437            //file ICON start-x
#define	FS_FILELIST_XSTART				130             //file string start-x
#define	FS_FILELIST_YSTART				150              //file string start-y
#define	FS_DIRLIST_XSTART				130             //dir string start-x
#define	FS_DIRLIST_YSTART				150              //dir string start-y

#define FS_FILELIST_YSTEP				32              //file(dir) list item height

#define	FS_DIRICON_XLEN                 35
#define	FS_FILEICON_XLEN                FS_DIRICON_XLEN
#define	FS_DIRITEM_XLEN                 252+2 //199+40//190
#define	FS_FILEITEM_XLEN                FS_DIRITEM_XLEN

#define	FS_DIRSCROLLLEN_XSTART          329//65+264
#define	FS_DIESCROLLLEN_YSTART          171  
#define	FS_DIRSCROLLLEN_XSIZE           22
#define	FS_DIRSCROLLLEN_YSIZE           211//382-171

#elif defined(MP3_LARGE_GUI)

#define X1                             320
#define Y1                              90
#define Y3                              232
#define FS_DIRLIST_YSTART               100              //dir string start-y
#define FS_DIRLIST_XSTART               120              //dir string start-x
#define FS_FILELIST_YSTEP               28             //file(dir) list item height
#define FS_FILEICON_XSTART              380             //file ICON start-x

#else

#define	X1                              170
#define	Y1                              60
#define	Y3                              232
#define	FS_DIRLIST_YSTART				70              //dir string start-y
#define	FS_DIRLIST_XSTART				60              //dir string start-x
#define FS_FILELIST_YSTEP				16              //file(dir) list item height
#define FS_FILEICON_XSTART				180             //file ICON start-x

#if defined(FAT_FILE_MODE) || defined(FILE_MODE_WRITE)//liweihua 2004-10-9 22:28//sunzhh 2004-12-25
#define	FS_DIRSCROLLLEN_XSTART          329//65+264
#define	FS_DIESCROLLLEN_YSTART          171  
#define	FS_DIRSCROLLLEN_XSIZE           22
#define	FS_DIRSCROLLLEN_YSIZE           211//382-171
#endif//#ifdef FAT_FILE_MODE

#endif//#if defined(FS_BMP_GUI)


#if defined(SUPPORT_NESGAME)||defined(SUPPORT_SPG_GAME)//defintion of gamepad buttons
#define FS_GAMEPAD_RIGHT                0x0001
#define FS_GAMEPAD_LEFT                 0x0002
#define FS_GAMEPAD_DOWN                 0x0004
#define FS_GAMEPAD_UP                   0x0008
#define FS_GAMEPAD_START                0x0010
#define FS_GAMEPAD_SELECT               0x0020
#endif

enum
{
	CNT_AREA_FILE 		= 0,
	CNT_AREA_DIR		= 1,
	CNT_AREA_MP3BUTTON	= 2,
	CNT_AREA_JPEGBUTTON	= 3,
#if defined(SUPPORT_NESGAME)||defined(SUPPORT_SPG_GAME)
	CNT_AREA_GAMEBUTTON,
#endif
#ifdef SUPPORT_FILE_SYSTEM_MODE
	CNT_AREA_OTHERBUTTON,
#endif
#ifdef SUPPORT_MIDI
	CNT_AREA_MIDIBUTTON,
#endif
#ifdef SUPPORT_MULTI_PARTITION
    CNT_AREA_MULTI_PART,
    #ifdef FAT_FILE_MODE
    CNT_AREA_DISK,
    CNT_AREA_CARD,
    CNT_AREA_WARNING,
    #endif
#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -