?? o_device_switch_config.c
字號:
/* **************************************************************************************
* Copyright (c) 2004 ZORAN Corporation, All Rights Reserved
* THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF ZORAN CORPORATION
*
* File: o_device_switch_config.c
*
* Description:
* ========
*
****************************************************************************************/
/***************************************************************************************
* Objects definition
****************************************************************************************/
#ifndef D_CUSTOM_oDiscBtnBMPSet
static CONST MS_BITMAP_SET oDiscBtnBMPSet = {
BMP_DISC,
NULL,
NULL,
NULL,
};
#endif // D_CUSTOM
#ifndef D_CUSTOM_oUSBBtnBMPSet
static CONST MS_BITMAP_SET oUSBBtnBMPSet = {
BMP_USB,
NULL,
NULL,
NULL,
};
#endif // D_CUSTOM
#ifdef FTA_SUPPORT
#ifndef D_CUSTOM_oFTABtnBMPSet
static CONST MS_BITMAP_SET oFTABtnBMPSet = {
BMP_FTA_DEVICE,
NULL,
NULL,
NULL,
};
#endif // D_CUSTOM
#endif
#ifndef D_CUSTOM_oCardBtnBMPSet
static CONST MS_BITMAP_SET oCardBtnBMPSet = {
BMP_FCU,
NULL,
NULL,
NULL,
};
#endif // D_CUSTOM
/*static CONST MS_BITMAP_SET oBtnBgBMPSet = {
BMP_BG_2,
BMP_FG_FOCUS,
BMP_BG_2,
BMP_FG_FOCUS,//BMP_BG_2
};*/
#ifndef D_CUSTOM_oButtonTextAlign
static CONST MS_X_Y_ALIGN oButtonTextAlign =
{
0,//30,
0,
ALIGN_H_CENTER_TO_CONTAINER,//ALIGN_H_LEFT_TO_CONTAINER,
ALIGN_V_CENTER_TO_CONTAINER
};
#endif // D_CUSTOM
#ifndef D_CUSTOM_oButtonIconAlign
static CONST MS_X_Y_ALIGN oButtonIconAlign =
{
8,// 4,
0,
ALIGN_H_LEFT_TO_CONTAINER,
ALIGN_V_CENTER_TO_CONTAINER
};
#endif // D_CUSTOM
#ifndef D_CUSTOM_oDiscText
static CONST OSD_TEXT oDiscText = {
OSDR_GetFormUniStr_OsdMessage,
S_DISC
};
#endif // D_CUSTOM
#ifndef D_CUSTOM_oSDText
static CONST OSD_TEXT oSDText = {
OSDR_GetFormUniStr_OsdMessage,
S_CARD_SD
};
#endif // D_CUSTOM
#ifndef D_CUSTOM_oMMCText
static CONST OSD_TEXT oMMCText = {
OSDR_GetFormUniStr_OsdMessage,
S_CARD_MMC
};
#endif // D_CUSTOM
#ifndef D_CUSTOM_oMSText
static CONST OSD_TEXT oMSText = {
OSDR_GetFormUniStr_OsdMessage,
S_CARD_MS
};
#endif // D_CUSTOM
#ifndef D_CUSTOM_oCFText
static CONST OSD_TEXT oCFText = {
OSDR_GetFormUniStr_OsdMessage,
S_CARD_CF
};
#endif // D_CUSTOM
#ifndef D_CUSTOM_oSMText
static CONST OSD_TEXT oSMText = {
OSDR_GetFormUniStr_OsdMessage,
S_CARD_SM
};
#endif // D_CUSTOM
#ifndef D_CUSTOM_oXDText
static CONST OSD_TEXT oXDText = {
OSDR_GetFormUniStr_OsdMessage,
S_CARD_XD
};
#endif // D_CUSTOM
#ifndef D_CUSTOM_oUSBText
static CONST OSD_TEXT oUSBText = {
OSDR_GetFormUniStr_OsdMessage,
S_USB
};
#endif // D_CUSTOM
#ifdef FTA_SUPPORT
#ifndef D_CUSTOM_oFTAText
static CONST OSD_TEXT oFTAText = {
OSDR_GetFormUniStr_OsdMessage,
S_FTA
};
#endif // D_CUSTOM
#endif // FTA_SUPPORT
/***************************************************************************************
* Descriptor : oDescriptorDiscBtn
*
* Purpose :
****************************************************************************************/
#ifndef D_CUSTOM_oDescriptorDiscBtn
static CONST MS_DESCRIPTOR_DEVICE_BUTTON oDescriptorDiscBtn =
{
//text descriptor
{
{
sizeof(MSO_DEVICE_BUTTON),
MS_NAV_TO_ALGINED_Y | MS_NAV_DISABLE_LR,
MS_ATTR_FOCUSABLE | MS_ATTR_OSD_LAYER_0,
{
AREA_DEVICE_BUTTON_X, 0, AREA_DEVICE_BUTTON_W, AREA_DEVICE_BUTTON_H
},
_ButtonOperation,
_ButtonFillOSDSeg,
mpParamNull
},
(MS_X_Y_ALIGN *)&oButtonTextAlign,
(MS_COLOR_SET *)&oButtonTextColorSet,
(MS_BITMAP_SET *)&oButtonBitmapSet,
(OSD_TEXT *) &oDiscText,
FONT_0,
(MS_BITMAP_SET *)&oDiscBtnBMPSet,
(MS_X_Y_ALIGN *)&oButtonIconAlign
},
//ms_op
MS_OP_MENU_SELECT_DEVICE
};
#endif // D_CUSTOM
/***************************************************************************************
* Descriptor : oDescriptorFTABtn
*
* Purpose :
****************************************************************************************/
#ifdef FTA_SUPPORT
#ifndef D_CUSTOM_oDescriptorFTABtn
static CONST MS_DESCRIPTOR_DEVICE_BUTTON oDescriptorFTABtn =
{
//text descriptor
{
{
sizeof(MSO_DEVICE_BUTTON),
MS_NAV_TO_ALGINED_Y | MS_NAV_DISABLE_LR,
MS_ATTR_FOCUSABLE | MS_ATTR_OSD_LAYER_0,
{
AREA_DEVICE_BUTTON_X, 0, AREA_DEVICE_BUTTON_W, AREA_DEVICE_BUTTON_H
},
_ButtonOperation,
_ButtonFillOSDSeg,
mpParamNull
},
(MS_X_Y_ALIGN *)&oButtonTextAlign,
(MS_COLOR_SET *)&oButtonTextColorSet,
(MS_BITMAP_SET *)&oButtonBitmapSet,
(OSD_TEXT *) &oFTAText,
FONT_0,
(MS_BITMAP_SET *)&oFTABtnBMPSet,
(MS_X_Y_ALIGN *)&oButtonIconAlign
},
//ms_op
MS_OP_MENU_SELECT_DEVICE
};
#endif // D_CUSTOM
#endif // FTA_SUPPORT
/***************************************************************************************
* Descriptor : oDescriptorUSBBtn
*
* Purpose :
****************************************************************************************/
#ifndef D_CUSTOM_oDescriptorUSBBtn
static CONST MS_DESCRIPTOR_DEVICE_BUTTON oDescriptorUSBBtn =
{
//text descriptor
{
{
sizeof(MSO_DEVICE_BUTTON),
MS_NAV_TO_ALGINED_Y | MS_NAV_DISABLE_LR,
MS_ATTR_FOCUSABLE | MS_ATTR_OSD_LAYER_0,
{
AREA_DEVICE_BUTTON_X, 0, AREA_DEVICE_BUTTON_W, AREA_DEVICE_BUTTON_H
},
_ButtonOperation,
_ButtonFillOSDSeg,
mpParamNull
},
(MS_X_Y_ALIGN *)&oButtonTextAlign,
(MS_COLOR_SET *)&oButtonTextColorSet,
(MS_BITMAP_SET *)&oButtonBitmapSet,
(OSD_TEXT *) &oUSBText,
FONT_0,
(MS_BITMAP_SET *)&oUSBBtnBMPSet,
(MS_X_Y_ALIGN *)&oButtonIconAlign
},
//ms_op
MS_OP_MENU_SELECT_DEVICE
};
#endif // D_CUSTOM
/***************************************************************************************
* Descriptor : oDescriptorCardBtn
*
* Purpose :
****************************************************************************************/
#ifndef D_CUSTOM_oDescriptorMSBtn
static CONST MS_DESCRIPTOR_DEVICE_BUTTON oDescriptorMSBtn =
{
//text descriptor
{
{
sizeof(MSO_DEVICE_BUTTON),
MS_NAV_TO_ALGINED_Y | MS_NAV_DISABLE_LR,
MS_ATTR_FOCUSABLE | MS_ATTR_OSD_LAYER_0,
{
AREA_DEVICE_BUTTON_X, 0, AREA_DEVICE_BUTTON_W, AREA_DEVICE_BUTTON_H
},
_ButtonOperation,
_ButtonFillOSDSeg,
mpParamNull
},
(MS_X_Y_ALIGN *)&oButtonTextAlign,
(MS_COLOR_SET *)&oButtonTextColorSet,
(MS_BITMAP_SET *)&oButtonBitmapSet,
(OSD_TEXT *) &oMSText,
FONT_0,
(MS_BITMAP_SET *)&oCardBtnBMPSet,
(MS_X_Y_ALIGN *)&oButtonIconAlign
},
//ms_op
MS_OP_MENU_SELECT_DEVICE
};
#endif D_CUSTOM
/***************************************************************************************
* Descriptor : oDescriptorCardBtn
*
* Purpose :
****************************************************************************************/
#ifndef D_CUSTOM_oDescriptorCardBtn
static CONST MS_DESCRIPTOR_DEVICE_BUTTON oDescriptorSDBtn =
{
//text descriptor
{
{
sizeof(MSO_DEVICE_BUTTON),
MS_NAV_TO_ALGINED_Y | MS_NAV_DISABLE_LR,
MS_ATTR_FOCUSABLE | MS_ATTR_OSD_LAYER_0,
{
AREA_DEVICE_BUTTON_X, 0, AREA_DEVICE_BUTTON_W, AREA_DEVICE_BUTTON_H
},
_ButtonOperation,
_ButtonFillOSDSeg,
mpParamNull
},
(MS_X_Y_ALIGN *)&oButtonTextAlign,
(MS_COLOR_SET *)&oButtonTextColorSet,
(MS_BITMAP_SET *)&oButtonBitmapSet,
(OSD_TEXT *) &oSDText,
FONT_0,
(MS_BITMAP_SET *)&oCardBtnBMPSet,
(MS_X_Y_ALIGN *)&oButtonIconAlign
},
//ms_op
MS_OP_MENU_SELECT_DEVICE
};
#endif D_CUSTOM
/***************************************************************************************
* Descriptor : oDescriptorCardBtn
*
* Purpose :
****************************************************************************************/
#ifndef D_CUSTOM_oDescriptorCardBtn
static CONST MS_DESCRIPTOR_DEVICE_BUTTON oDescriptorMMCBtn =
{
//text descriptor
{
{
sizeof(MSO_DEVICE_BUTTON),
MS_NAV_TO_ALGINED_Y | MS_NAV_DISABLE_LR,
MS_ATTR_FOCUSABLE | MS_ATTR_OSD_LAYER_0,
{
AREA_DEVICE_BUTTON_X, 0, AREA_DEVICE_BUTTON_W, AREA_DEVICE_BUTTON_H
},
_ButtonOperation,
_ButtonFillOSDSeg,
mpParamNull
},
(MS_X_Y_ALIGN *)&oButtonTextAlign,
(MS_COLOR_SET *)&oButtonTextColorSet,
(MS_BITMAP_SET *)&oButtonBitmapSet,
(OSD_TEXT *) &oMMCText,
FONT_0,
(MS_BITMAP_SET *)&oCardBtnBMPSet,
(MS_X_Y_ALIGN *)&oButtonIconAlign
},
//ms_op
MS_OP_MENU_SELECT_DEVICE
};
#endif D_CUSTOM
/***************************************************************************************
* Descriptor : oDescriptorCardBtn
*
* Purpose :
****************************************************************************************/
#ifndef D_CUSTOM_oDescriptorCFBtn
static CONST MS_DESCRIPTOR_DEVICE_BUTTON oDescriptorCFBtn =
{
//text descriptor
{
{
sizeof(MSO_DEVICE_BUTTON),
MS_NAV_TO_ALGINED_Y | MS_NAV_DISABLE_LR,
MS_ATTR_FOCUSABLE | MS_ATTR_OSD_LAYER_0,
{
AREA_DEVICE_BUTTON_X, 0, AREA_DEVICE_BUTTON_W, AREA_DEVICE_BUTTON_H
},
_ButtonOperation,
_ButtonFillOSDSeg,
mpParamNull
},
(MS_X_Y_ALIGN *)&oButtonTextAlign,
(MS_COLOR_SET *)&oButtonTextColorSet,
(MS_BITMAP_SET *)&oButtonBitmapSet,
(OSD_TEXT *) &oCFText,
FONT_0,
(MS_BITMAP_SET *)&oCardBtnBMPSet,
(MS_X_Y_ALIGN *)&oButtonIconAlign
},
//ms_op
MS_OP_MENU_SELECT_DEVICE
};
#endif D_CUSTOM
/***************************************************************************************
* Descriptor : oDescriptorCardBtn
*
* Purpose :
****************************************************************************************/
#ifndef D_CUSTOM_oDescriptorSMBtn
static CONST MS_DESCRIPTOR_DEVICE_BUTTON oDescriptorSMBtn =
{
//text descriptor
{
{
sizeof(MSO_DEVICE_BUTTON),
MS_NAV_TO_ALGINED_Y | MS_NAV_DISABLE_LR,
MS_ATTR_FOCUSABLE | MS_ATTR_OSD_LAYER_0,
{
AREA_DEVICE_BUTTON_X, 0, AREA_DEVICE_BUTTON_W, AREA_DEVICE_BUTTON_H
},
_ButtonOperation,
_ButtonFillOSDSeg,
mpParamNull
},
(MS_X_Y_ALIGN *)&oButtonTextAlign,
(MS_COLOR_SET *)&oButtonTextColorSet,
(MS_BITMAP_SET *)&oButtonBitmapSet,
(OSD_TEXT *) &oSMText,
FONT_0,
(MS_BITMAP_SET *)&oCardBtnBMPSet,
(MS_X_Y_ALIGN *)&oButtonIconAlign
},
//ms_op
MS_OP_MENU_SELECT_DEVICE
};
#endif D_CUSTOM
/***************************************************************************************
* Descriptor : oDescriptorCardBtn
*
* Purpose :
****************************************************************************************/
#ifndef D_CUSTOM_oDescriptorXDBtn
static CONST MS_DESCRIPTOR_DEVICE_BUTTON oDescriptorXDBtn =
{
//text descriptor
{
{
sizeof(MSO_DEVICE_BUTTON),
MS_NAV_TO_ALGINED_Y | MS_NAV_DISABLE_LR,
MS_ATTR_FOCUSABLE | MS_ATTR_OSD_LAYER_0,
{
AREA_DEVICE_BUTTON_X, 0, AREA_DEVICE_BUTTON_W, AREA_DEVICE_BUTTON_H
},
_ButtonOperation,
_ButtonFillOSDSeg,
mpParamNull
},
(MS_X_Y_ALIGN *)&oButtonTextAlign,
(MS_COLOR_SET *)&oButtonTextColorSet,
(MS_BITMAP_SET *)&oButtonBitmapSet,
(OSD_TEXT *) &oXDText,
FONT_0,
(MS_BITMAP_SET *)&oCardBtnBMPSet,
(MS_X_Y_ALIGN *)&oButtonIconAlign
},
//ms_op
MS_OP_MENU_SELECT_DEVICE
};
#endif D_CUSTOM
/***************************************************************************************
* Descriptor : oDescriptorDeviceList
*
* Purpose :
****************************************************************************************/
#ifndef D_CUSTOM_oDescriptorDeviceList
static CONST MS_DESCRIPTOR_VLIST oDescriptorDeviceList =
{
{
sizeof(MSO_VLIST),
MS_NAV_DISABLE_LR|MS_NAV_DISABLE_UD,//MS_NAV_TO_ALGINED_Y| MS_NAV_DISABLE_LR,
MS_ATTR_CONTAINER|MS_ATTR_FOCUSABLE | MS_ATTR_OSD_LAYER_0,
{
// This object is resized by it parent, so we don't care defining its position and dimensions
0, 0, 0, 0
},
_VListOperation,
mpfFillOsdSegNull,
mpParamNull
},
maContentsNull,
mwNbrContentsNull
};
#endif // D_CUSTOM
/***************************************************************************************
* Descriptor : oDescriptorDeviceScrollList
*
* Purpose :
****************************************************************************************/
#ifndef D_CUSTOM_oDescriptorDeviceScrollList
static CONST MS_DESCRIPTOR_VSCROLL_LIST oDescriptorDeviceScrollList =
{
{//descriptor container
{
sizeof(MSO_VSCROLL_LIST),
MS_NAV_NULL,
MS_ATTR_CONTAINER|MS_ATTR_VSLIST_SCROLL_ARROW|MS_ATTR_VSLIST_DISPLAY_BG_BMP
|MS_ATTR_FOCUSABLE | MS_ATTR_OSD_LAYER_0,
{
AREA_VSCROLL_LIST_X, AREA_VSCROLL_LIST_Y,
AREA_VSCROLL_LIST_W, AREA_VSCROLL_LIST_H
},
_VScrollListOperation,
VScrollListFillOSDSeg,
mpParamNull
},
maContentsNull,
mwNbrContentsNull
},
(MS_DESCRIPTOR_VLIST*)&oDescriptorDeviceList,
VSCROLL_LIST_XPADDING,
VSCROLL_LIST_YPADDING,
CIDX_8, // Text color
BMP_BG_2, // Background bitmap
NULL,//BMP_BG_PUSHED_1, // Scrollbar background bitmap
NULL,//BMP_BG_3 // Scrollbar bitmap
};
#endif // D_CUSTOM
/***************************************************************************************
* Descriptor : oDescriptorDeviceSwitch
*
* Purpose :
****************************************************************************************/
#ifndef D_CUSTOM_oDescriptorDeviceSwitch
CONST MS_DESCRIPTOR_COMPONENT oDescriptorDeviceSwitch =
{
//descriptor container
{
{
sizeof(MSO_COMPONENT),
MS_NAV_NULL,//MS_NAV_TO_ALGINED_Y| MS_NAV_DISABLE_LR,
MS_ATTR_CONTAINER|MS_ATTR_FOCUSABLE | MS_ATTR_OSD_LAYER_0,
{
// Position decided by its parent
0, 0, AREA_DEVICE_SWITCH_W, AREA_DEVICE_SWITCH_H
},
_ComponentOperation,
NULL,
mpParamNull
},
maContentsNull,//(CONST MS_DESCRIPTOR**)apDSContents,
mwNbrContentsNull//NBR_DS_CONTENTS
},
//focus descriptor
(MS_DESCRIPTOR *)&oDescriptorDeviceScrollList,
};
#endif // D_CUSTOM
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -