?? guitypes.h
字號(hào):
#ifndef _GUI_TYPES_H_
#define _GUI_TYPES_H_
#include "rmgfx_library/include/rmguiobjects.h"
#ifdef GUI_REFID_2
class CommandMetaData;
#endif
#define MAX_GUI_PAGES 7 // per session
#define MAX_GUI_EVENTS 32 // per object
#define MAX_GUI_BITMAPS 15 // per page
#define MAX_GUI_COMMANDS 256 // per session
#define MAX_GUI_MENUS 5 // per page
#define MAX_GUI_MENUITEMS 10 // per menu
#define MAX_GUI_POPUPS 32 // per session
#define MAX_GUI_STRINGS 32 // per page
#define MAX_GUI_STRINGITEMS 64 // per object
#define MAX_GUI_ICONS 30 // per session
#define MAX_GUI_LISTS 10 // per object
#define MAX_GUI_LISTITEMS 128 // per list
#define MAX_GUI_EVENTBITMAPS 80 // per session
#define MAX_GUI_SLIDERS 8 // per session
#define MAX_GUI_TEXTTABLES 15 // per session
#define MAX_GUI_TEXTITEMS 32 // per object
#define MAX_GUI_MEDIA 80 // per session
#define MAX_GUI_CHAPTERS 40 // per media
#ifdef GUI_REFID_2
#define MAX_LANGUAGE_STRINGS 1024 // per page
#define MAX_LANGUAGE_PAGES 1 // per session
#define MAX_GUI_BUTTONS 64 // per page / menu item
#else
#define MAX_GUI_BUTTONS 15 // per page / menu item
#endif
// object ID masks
#define SLIDER_IDMASK 0x00000100
#define MENU_IDMASK 0x00000200
#define SUBMENUBUTTON_IDMASK 0x00000400
#define TEXTTABLE_IDMASK 0x00000800
#define TEXTITEM_IDMASK 0x00001000
#define LIST_IDMASK 0x00002000
#define STRING_IDMASK 0x00004000
#define EVENT_IDMASK 0x00008000
#define POPUP_IDMASK 0x00010000
#define BUTTON_IDMASK 0x00020000
#define BITMAP_IDMASK 0x00040000
#define MEDIA_IDMASK 0x00080000
#define CHAPTER_IDMASK 0x00100000
// object id check-up macros
#define ISSLIDER(x) (((x) & SLIDER_IDMASK) && !((x) >> 9))
#define ISMENU(x) (((x) & MENU_IDMASK) && !((x) >> 10))
#define ISSUBMENUBUTTON(x) (((x) & SUBMENUBUTTON_IDMASK) && !((x) >> 11))
#define ISTEXTTABLE(x) (((x) & TEXTTABLE_IDMASK) && !((x) >> 12))
#define ISTEXTITEM(x) (((x) & TEXTITEM_IDMASK) && !((x) >> 13))
#define ISLIST(x) (((x) & LIST_IDMASK) && !((x) >> 14))
#define ISSTRING(x) (((x) & STRING_IDMASK) && !((x) >> 15))
#define ISEVENT(x) (((x) & EVENT_IDMASK) && !((x) >> 16))
#define ISPOPUP(x) (((x) & POPUP_IDMASK) && !((x) >> 17))
#define ISBUTTON(x) (((x) & BUTTON_IDMASK) && !((x) >> 18))
#define ISBITMAP(x) (((x) & BITMAP_IDMASK) && !((x) >> 19))
#define ISMEDIA(x) (((x) & MEDIA_IDMASK) && !((x) >> 20))
#define ISCHAPTER(x) (((x) & CHAPTER_IDMASK) && !((x) >> 21))
// sliders
#define VOLUME_CONTROL SLIDER_IDMASK
#define BRIGHTNESS_CONTROL (SLIDER_IDMASK | 1)
#define CONTRAST_CONTROL (SLIDER_IDMASK | 2)
#define SATURATION_CONTROL (SLIDER_IDMASK | 3)
#define PROGRESS_CONTROL (SLIDER_IDMASK | 4)
#define TEMPERATURE_CONTROL (SLIDER_IDMASK | 5)
#define GUI_PASSWORD_DISPLAY_STR "####"
#define GUI_DEFAULT_PASSWORD_STR "0000"
#define GUI_PASSWORD_STR_LENGTH 5
#define GUI_TIMEHMS_DISPLAY_STR "00:00:00"
#define GUI_TRACK_DISPLAY_STR "000"
#define GUI_FIELD_STR_LENGTH 32
#define GUI_MAX_PASSW_STR 32
#define GUI_DEFAULT_VOLUME 0x6597FA9
#define GUI_DEFAULT_BRIGHTNESS 0
#define GUI_DEFAULT_CONTRAST 128
#define GUI_DEFAULT_SATURATION 128
#define GUI_DEFAULT_DVDREGION 1
#define GUI_DEFAULT_MACROVISION 1
#define REPEAT_OFF_STR "OFF"
#define REPEAT_A_STR "A-"
#define REPEAT_AB_STR "A-B"
#define REPEAT_RANDOM_STR "RANDOM"
#define REPEAT_DISC_STR "DISC"
#define REPEAT_TRACK_STR "TRACK"
#define REPEAT_CHAPTER_STR "CHAPTER"
#define REPEAT_TITLE_STR "TITLE"
#define REPEAT_TRACKS_STR "TRACKS"
#define PLAY_STR "PLAY"
#define PAUSE_STR "PAUSE"
#define STOP_STR "STOP"
#define STEP_STR "STEP"
#define NEXT_STR "NEXT"
#define PREVIOUS_STR "PREVIOUS"
#define CLOSE_STR "CLOSE"
#define EJECT_STR "EJECT"
#define INVALIDOP_STR "N/A"
#define PBC_ON_STR "PBC ON"
#define PBC_OFF_STR "PBC OFF"
#define MUTE_STR "MUTE"
#define SHUFFLE_STR "SHUFFLE"
#define WAIT_STR "PLEASE WAIT"
#define OFF_STR "OFF"
#define ON_STR "ON"
#define STEREO_STR "STEREO"
#define RIGHT_STR "RIGHT"
#define LEFT_STR "LEFT"
#define OPEN_STR "OPEN"
#define SETUP_STR "SETUP"
#define JPEG_STR "JPEG"
#define ISO_STR "ISO"
#define LOADING_STR "LOADING"
#define DETECT_STR "DETECT"
#define NODISC_STR "NO DISC"
#define FOLDER_STR "FOLDER"
#define UNKNOWN_STR "UNKNOWN"
#define RESUME_STR "RESUME"
#define FILE_ERROR_STR "FILE ERROR"
#define DISC_ERR_FP_STR "FileErr"
#define DRIVE_REGION_STR "RPC2 RGN"
#define DVIHDMI_STR "VIDEO CHG"
#define FATALRESET_STR "ERR RESET"
#define DISC_BLANK_STR "BLANK"
#ifdef GUI_REFID_2
#define DVD_STR "DVD"
#define VCD_STR "VIDEO CD"
#define CDDA_STR "AUDIO CD"
#else
#define DVD_STR "DVD-V"
#define VCD_STR "VCD"
#define CDDA_STR "CDDA"
#endif
typedef enum
{
FILETYPE_UNKNOWN = 0,
FILETYPE_VIDEO = 1,
FILETYPE_AUDIO = 2,
FILETYPE_PICTURE = 4, /* any pictures other than jpeg */
FILETYPE_JPEG = 8,
FILETYPE_PICTURES = 12,
FILETYPE_DIRECTORY = 16,
FILETYPE_HOST = 32
} RMguiFileType;
typedef enum
{
EOF_GUI_EVENT=549,
DETECTING_GUI_EVENT,
} RMguiEvent;
typedef enum
{
LISTTYPE_STRING = 0,
LISTTYPE_FILE,
LISTTYPE_HOST,
LISTTYPE_LIST,
LISTTYPE_BILLING //the list is like LISTTYPE_STRING, except no picture for selected item is used
// element 0 is header of the table, text of items is delimited with "|" which means new column
// add columnWidth propertie
} RMguiListType;
typedef enum
{
TIMER_NONE = 0, // no timeout
TIMER_EVENT,
TIMER_SLIDER,
TIMER_SLIDESHOW,
TIMER_ERRORMESSAGE,
TIMER_PICTUREERRORMESSAGE,
TIMER_RESUMEMOVIE,
TIMER_MEDIA,
TIMER_VIDEOOUTCHANGE,
TIMER_OSDFADE,
TIMER_KML1,
TIMER_KML2,
TIMER_SAVESETTINGS,
TIMER_WAIT_ANIMATION,
TIMER_LOAD_ANIMATION,
TIMER_PLAYER_NUMERIC_INPUT,
TIMER_REMOVEPOPUP,
TIMER_GENERIC // multiple use timeout
} RMguiTimerType; // no more than MAX_GUI_TIMERS supported
typedef enum
{
REPEAT_OFF = 0,
REPEAT_TRACK,
REPEAT_CHAPTER,
REPEAT_TITLE,
REPEAT_A_SET,
REPEAT_AB_SET,
REPEAT_TRACKS
} RMguiRepeatMode;
typedef struct
{
RMuint32 id;
RMuint32 linkId;
RMbool validLink;
union{
RMascii *value;
RMuint32 nValue;
};
#ifdef GUI_REFID_2
CommandMetaData* pMetaData;
#endif
}typeCommandInfo;
typedef struct
{
RMuint32 volume;
RMint8 brightness;
RMuint8 contrast;
RMuint8 saturation;
RMuint32 audioOut;
RMuint32 hdDVIOut; // DVI
RMuint32 hdYbPrOut; // Component
RMuint32 tvOut; // SD including CScart
RMuint32 vcdPBC;
RMuint32 tvType;
RMuint8 dvdParentalLevel;
RMascii dvdParentalPassw[GUI_PASSWORD_STR_LENGTH];
RMuint8 dvdRegion;
RMbool macrovisionOn;
RMuint32 hdDVIHdmi; // HDMI resolutions
RMbool validBookmark;
RMuint32 bookmarkCRC;
RMuint8 bookmark[BOOKMARK_SIZE];
RMuint32 crc;
RMuint32 tvStandard;
RMuint32 activeVideoOutput;
RMuint32 scart; // Scart RGB
RMbool forceNoHDMI;
RMuint8 dvdRegionCounter; // [0..5]
RMuint32 audioChannels;
RMuint32 screenSaverDelay;
#ifdef GUI_REFID_2
RMuint32 dhcp;
RMuint32 ip;
RMuint32 subnet;
RMuint32 gateway;
RMuint32 dns;
RMuint32 dnsAlt;
RMuint32 networkConfig;
RMuint8 quickSetupStatus;
RMuint32 audioMixMode;
RMuint16 country;
RMint8 timezone;
RMuint16 menuLanguage;
RMuint16 dvdMenuLanguage;
RMuint16 dvdSubtitleLanguage;
RMuint16 dvdSpokenLanguage;
RMascii myKmlPage[128];
RMascii prefferedPcLinkServer[22]; //ip and port ("iii.iii.iii.iii:pppp")
#ifdef GUI_REFID_3
RMuint8 sview;
RMascii accessCodePassw[9];
RMbool accessCode;
#endif
#endif
RMuint32 warningMode; // ref3
/* RMascii lastKnownHdmiMonitorId[16]; // wait for new module to get this */
} guiPlayerSettingsType;
typedef struct
{
RMascii* mainPage;
RMascii* messagePopup;
} guiPlayerParams;
typedef struct
{
RMuint16 width;
RMuint16 height;
RMbool isDefault;
} guiScreenFormatType;
typedef struct
{
RMascii* name;
RMascii* command;
RMascii* link;
RMascii* value; // parameter affecting command
#ifdef GUI_REFID_2
CommandMetaData* pMetaData;
#endif
} guiEventType;
typedef struct
{
RMascii* name;
RMuint32 id;
} guiCommandType;
typedef struct
{
RMascii* name;
RMascii* translations[10]; //max 10 languages for now
}guiTranslation;
typedef struct
{
RMascii* name;
RMuint32 id;
RMStringObject object;
RMascii* keyleft;
RMascii* keyup;
RMascii* keyright;
RMascii* keydown;
RMuint8 minLength;
RMuint8 maxLength;
guiEventType *events[MAX_GUI_EVENTS];
RMuint16 nbEvents;
guiTranslation *item;
} guiStringType;
//typedef struct
//{
// RMListItemObject object;
// guiEventType *events[MAX_GUI_EVENTS];
// RMuint16 nbEvents;
//} guiListItemType;
typedef struct
{
RMascii* name;
RMTextItemObject object;
} guiTextItemType;
typedef struct
{
RMascii* name;
RMuint32 id;
RMuint32 startTime; // in secs comes from xml
RMuint32 seekTime; // in secs. specifies I-frame position at or before given startTime. initialized as startTime and updated when seeking performed.
} guiChapterType;
typedef struct
{
RMascii* name;
RMuint32 id;
RMascii* file;
RMuint32 duration; // in secs
RMbool canSkip;
RMascii* whenDone;
guiChapterType *chapters[MAX_GUI_CHAPTERS];
RMuint16 nbChapters;
RMuint32 audioStream; // default audio stream
RMbool isPicture;
} guiMediaType;
typedef struct
{
RMascii* name;
RMuint32 id;
RMButtonObject object;
RMascii* keyleft;
RMascii* keyup;
RMascii* keyright;
RMascii* keydown;
guiEventType *events[MAX_GUI_EVENTS];
RMuint16 nbEvents;
} guiButtonType;
typedef struct
{
RMascii* name;
RMuint32 id;
RMTextTableObject object;
guiTextItemType* items[MAX_GUI_TEXTITEMS];
RMuint16 nbItems;
} guiTextTableType;
typedef struct tagListItem guiListItemType;
typedef struct
{
RMascii* name;
RMuint32 id;
RMListObject object;
RMascii* keyleft;
RMascii* keyright;
RMascii* prevPage;
RMguiListType type;
guiListItemType* items[MAX_GUI_LISTITEMS]; // to keep displayable and loaded from xml items
guiEventType* events[MAX_GUI_EVENTS];
guiTextTableType *info;
RMuint16 nbItems;
RMuint16 nbEvents;
RMuint16 nbItemsDisplayed;
} guiListType;
typedef struct
{
guiTranslation* translations[128];
RMuint8 nbNumItems;
}guiLangTranslations;
typedef struct tagListItem
{
RMListItemObject object;
guiEventType *events[MAX_GUI_EVENTS];
RMuint16 nbEvents;
guiListType* list;
guiTranslation *item;
} guiListItemType;
typedef struct
{
RMascii* name;
RMuint32 id;
RMascii* selectedObject;
RMBitmapObject object;
guiStringType* strings[MAX_GUI_STRINGS];
guiEventType* events[MAX_GUI_EVENTS];
guiButtonType* buttons[MAX_GUI_BUTTONS];
RMuint16 nbStrings;
RMuint16 nbEvents;
RMuint16 nbButtons;
guiListType* lists[MAX_GUI_LISTS];
RMuint16 nbLists;
} guiPopupType;
typedef struct
{
RMascii* name;
RMuint32 id;
RMascii* event; // used if part of event bitmap list
RMBitmapObject object;
RMascii* displayParameter; // if displayParameter (objectname.param) == displayCondition,
RMuint16 displayCondition; // bitmap is visible otherwise is not
#ifdef GUI_REFID_2
RMascii* szGroupName; ///< Used when bitmap is part of a group see also SHOW_BITMAP_IN_GROUP command
#endif
} guiBitmapType;
typedef struct
{
RMascii* name;
RMuint32 id;
RMIconObject object;
} guiIconType;
typedef struct
{
RMascii* name;
RMuint8 index;
RMMenuItemObject object;
RMascii* keyleft;
RMascii* keyright;
guiEventType* events[MAX_GUI_EVENTS];
guiButtonType* buttons[MAX_GUI_BUTTONS];
RMuint16 nbEvents;
RMuint16 nbButtons;
} guiMenuItemType;
typedef struct
{
RMascii* name;
RMuint32 id;
RMMenuObject object;
RMascii* keyleft;
RMascii* keyright;
guiMenuItemType *items[MAX_GUI_MENUITEMS];
guiEventType *events[MAX_GUI_EVENTS];
RMuint16 nbItems;
RMuint16 nbEvents;
} guiMenuType;
typedef struct
{
RMascii* name;
RMuint32 id;
RMuint32 min;
RMuint32 max;
RMuint32 value;
RMSliderObject object;
guiBitmapType* bitmaps[MAX_GUI_BITMAPS];
guiEventType* events[MAX_GUI_SLIDERS];
RMuint16 nbBitmaps;
RMuint16 nbEvents;
} guiSliderType;
typedef struct
{
RMascii* name;
RMPanelObject object;
guiSliderType* slider;
guiButtonType* buttons[MAX_GUI_BUTTONS];
RMuint16 nbButtons;
}guiPanelType;
typedef struct
{
RMascii* file;
RMuint16 x;
RMuint16 y;
guiPanelType* panels[3]; //hardcoded to 3 left, right, bottom
}guiMediaControls;
typedef struct
{
RMascii* name;
RMAnimationObject object;
}guiAnimationItem;
typedef struct
{
RMascii* name;
guiAnimationItem* item;
RMuint16 nbAnimations;
}guiAnimationType;
typedef struct
{
RMascii* name;
RMuint32 id;
RMascii* selectedObject;
RMPageObject object;
guiEventType* events[MAX_GUI_EVENTS];
guiButtonType* buttons[MAX_GUI_BUTTONS];
guiBitmapType* bitmaps[MAX_GUI_BITMAPS];
guiMenuType* menus[MAX_GUI_MENUS];
guiListType* lists[MAX_GUI_LISTS];
guiStringType* strings[MAX_GUI_STRINGS];
guiSliderType* temp; //only one slider is allowed per page only needed in temp peage so ...
RMuint16 nbEvents;
RMuint16 nbButtons;
RMuint16 nbBitmaps;
RMuint16 nbMenus;
RMuint16 nbLists;
RMuint16 nbStrings;
} guiOsdPageType;
#ifdef GUI_REFID_2
typedef struct
{
RMascii* name;
RMuint32 id;
RMPageObject object;
guiStringType* strings[MAX_LANGUAGE_STRINGS];
RMuint16 nbStrings;
} guiLanguagePageType;
typedef struct{
char* name;
char* host;
int port;
} hostList;
#endif
#endif //_GUI_TYPES_H_
?? 快捷鍵說(shuō)明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -