guistyle_item_buttonwin.c

来自「IT projecotr reference design.」· C语言 代码 · 共 34 行

C
34
字号
/*****************************************************************************
**             TEXAS INSTRUMENTS PROPRIETARY INFORMATION
**
**  (c) Copyright, Texas Instruments Incorporated, 2006.
**      All Rights Reserved.
**
**  Property of Texas Instruments Incorporated. Restricted Rights -
**  Use, duplication, or disclosure is subject to restrictions set
**  forth in TI's program license agreement and associated documentation.
******************************************************************************/

#include "common.h"
#include "osd.h"
#include "guiStyle.h"

/* This item style requires a 3d styled window.  List index 0 = undepressed. 
 * List index 1 = depressed */
int08 guiStyle_item_ButtonWin_SetListIndex( int16 itemId, uint08 index )
{
    uint08 winNum;
       
    /* get the first window in the item */
    if( OSD_GetItemFirstWinNum( itemId, &winNum ) != PASS )
        return FAIL;
    
    /* Set the index value */
    if( index == 0 )
        OSD_SetWinDepressed( winNum, 0 );   /* undepressed */
    else
        OSD_SetWinDepressed( winNum, 1 );   /* depressed */   

    return PASS;
}

⌨️ 快捷键说明

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