亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? mdichild.c

?? ICon文件格式
?? C
?? 第 1 頁 / 共 4 頁
字號:
\****************************************************************************/
BOOL CreateChildren( HWND hWnd )
{
    RECT                ClientRect, TempRect;
    LPCHILDWINDOWDATA	lpcwd;
    HDC                	hDC;
    SIZE                size;

    // Get the data associated with this window
    if( (lpcwd = (LPCHILDWINDOWDATA)GetWindowLong( hWnd, GWL_USERDATA )) == NULL )
        return FALSE;
    // Just how big is this window?
    GetClientRect( hWnd, &ClientRect );
    // Calculate listbox size and position
    SetRect( &(lpcwd->BoxRect), 10, ClientRect.bottom-30, (MAX_ICON_WIDTH*2)+14, ClientRect.bottom+50 );
    // Create the listbox
    if((lpcwd->hWndFormatListBox=CreateChildListBox( hWnd, ID_FORMAT_BOX, &(lpcwd->BoxRect) )) == NULL )
        return FALSE;
    // If we have an icon resource
    if( lpcwd->lpIR != NULL )
    {
        UINT    i, nIndex;
        TCHAR	szBuffer[256];

        // For each image in the resoure
        for(i=0;i<lpcwd->lpIR->nNumImages;i++)
        {
            // Add the type of the image to the listbox
            wsprintf( szBuffer, "%dx%d, %d Bit Color", lpcwd->lpIR->IconImages[i].Width, 
                        lpcwd->lpIR->IconImages[i].Height, lpcwd->lpIR->IconImages[i].Colors );
            nIndex = SendMessage( lpcwd->hWndFormatListBox, CB_ADDSTRING, 0, (LPARAM)szBuffer );
        }
        // Select the first entry
        SendMessage( lpcwd->hWndFormatListBox, 	CB_SETCURSEL, (WPARAM)0, (LPARAM)0 );
    }
    // Adjust the box size based on the listbox's real size
    GetClientRect( lpcwd->hWndFormatListBox, &TempRect );
    lpcwd->BoxRect.bottom = lpcwd->BoxRect.top + TempRect.bottom;

    // How big is text these days?
    hDC = GetDC( hWnd );
    GetTextExtentPoint32( hDC, "Icon on Black", 13, &size );
    ReleaseDC( hWnd, hDC );

    // Set the rectangles for the various squares to be drawn later
#define DIVIDER 5
    SetRect( &(lpcwd->DrawingRect), 10, 10, (MAX_ICON_WIDTH*2)+14, 20 + (MAX_ICON_HEIGHT*2) + (TempRect.bottom*2) );
    SetRect( &(lpcwd->BlackRect), lpcwd->DrawingRect.left, lpcwd->DrawingRect.top, lpcwd->DrawingRect.left + MAX_ICON_WIDTH + 1, lpcwd->DrawingRect.top + MAX_ICON_HEIGHT + 1 );
    SetRect( &(lpcwd->BlackTextRect), lpcwd->BlackRect.left, lpcwd->BlackRect.bottom+1, lpcwd->BlackRect.right, lpcwd->BlackRect.bottom + TempRect.bottom + 1 );
    SetRect( &(lpcwd->WhiteRect), lpcwd->BlackRect.right+1, lpcwd->BlackRect.top, lpcwd->DrawingRect.right, lpcwd->BlackRect.bottom );
    SetRect( &(lpcwd->WhiteTextRect), lpcwd->WhiteRect.left, lpcwd->WhiteRect.bottom+1, lpcwd->WhiteRect.right, lpcwd->WhiteRect.bottom + TempRect.bottom + 1 );
    SetRect( &(lpcwd->XORRect),	lpcwd->BlackTextRect.left, lpcwd->BlackTextRect.bottom + 1 + DIVIDER, lpcwd->BlackRect.right, lpcwd->BlackTextRect.bottom + 2 + DIVIDER + MAX_ICON_HEIGHT ); 
    SetRect( &(lpcwd->XORTextRect),	lpcwd->XORRect.left, lpcwd->XORRect.bottom + 1, lpcwd->XORRect.right, lpcwd->DrawingRect.bottom ); 
    SetRect( &(lpcwd->ANDRect),	lpcwd->WhiteTextRect.left, lpcwd->WhiteTextRect.bottom + 1 + DIVIDER, lpcwd->WhiteRect.right, lpcwd->WhiteTextRect.bottom + 2 + DIVIDER + MAX_ICON_HEIGHT ); 
    SetRect( &(lpcwd->ANDTextRect),	lpcwd->ANDRect.left, lpcwd->ANDRect.bottom + 1, lpcwd->ANDRect.right, lpcwd->DrawingRect.bottom ); 
#undef DIVIDER

    return TRUE;
}
/* End CreateChildren() ****************************************************/




/****************************************************************************
*
*     FUNCTION: CreateChildListBox
*
*     PURPOSE:  Creates a listbox and shows it
*
*     PARAMS:   HWND   hWndParent - The MDI window to be a parent
*               UINT   ID         - the ID of the new listbox
*               LPRECT lpRect     - the RECT for the listbox
*
*     RETURNS:  HWND - handle to listbox window, NULL for failure
*
* History:
*                July '95 - Created
*
\****************************************************************************/
HWND CreateChildListBox( HWND hWndParent, UINT ID, LPRECT lpRect )
{
    HWND hWnd;

    hWnd = CreateWindow( "COMBOBOX", "", CBS_DROPDOWNLIST | CBS_DISABLENOSCROLL | WS_CHILD | WS_VSCROLL,
                        lpRect->left, lpRect->top, 
                        lpRect->right - lpRect->left + 1, lpRect->bottom - lpRect->top + 1,
                        hWndParent, (HMENU)ID, hInst, 0 );
    if( hWnd != NULL )
        ShowWindow( hWnd, SW_SHOW );
    return hWnd;
}
/* End CreateChildListBox() ************************************************/




/****************************************************************************
*
*     FUNCTION: AddFormatDlgProc
*
*     PURPOSE:  Dialog Procedure for "Add Format" dialog
*
*     PARAMS:   HWND hWnd     - This dialog's window handle
*               UINT Msg      - Which Message?
*               WPARAM wParam - message parameter
*               LPARAM lParam - message parameter
*
*     RETURNS:  BOOL - TRUE for OK, FALSE for Cancel
*
* History:
*                July '95 - Created
*
\****************************************************************************/
BOOL CALLBACK AddFormatDlgProc( HWND hWnd, UINT Msg, WPARAM wParam, LPARAM lParam )
{
    // Support all DIB color formats known at this time
    #define MAX_COLOR_FORMAT    5
    TCHAR	ColorFormats[MAX_COLOR_FORMAT+1][20] = { "Monochrome (1bpp)", "16 Color (4bpp)", "256 Color (8bpp)",
                                    "16 Bit Color", "24 Bit Color", "32 Bit Color" };
    UINT    Bits[MAX_COLOR_FORMAT+1] = { 1, 4, 8, 16, 24, 32 };
    static	bSquareOnly = TRUE;
    static	LPARAM lInitParam;


    switch( Msg )
    {
        // Dialog is being initialized
        case WM_INITDIALOG:
        {
            TCHAR	szBuffer[100];

            // We are passed a pointer to a LPICONIMAGE in lParam, save it
            lInitParam = lParam;
            // Set the range and position of the sliders
            SendDlgItemMessage( hWnd, ID_WIDTHSLIDER, TBM_SETRANGE, (WPARAM)TRUE, (LPARAM)MAKELONG(MIN_ICON_WIDTH,MAX_ICON_WIDTH) );
            SendDlgItemMessage( hWnd, ID_WIDTHSLIDER, TBM_SETPOS, (WPARAM)TRUE, (LPARAM)MIN_ICON_WIDTH );
            wsprintf( szBuffer, "%d Width", MIN_ICON_WIDTH );
            SetDlgItemText( hWnd, ID_WIDTHTEXT, szBuffer );
            SendDlgItemMessage( hWnd, ID_HEIGHTSLIDER, TBM_SETRANGE, (WPARAM)TRUE, (LPARAM)MAKELONG(MIN_ICON_HEIGHT,MAX_ICON_HEIGHT) );
            SendDlgItemMessage( hWnd, ID_HEIGHTSLIDER, TBM_SETPOS, (WPARAM)TRUE, (LPARAM)MIN_ICON_HEIGHT );
            wsprintf( szBuffer, "%d Height", MIN_ICON_HEIGHT );
            SetDlgItemText( hWnd, ID_HEIGHTTEXT, szBuffer );
            SendDlgItemMessage( hWnd, ID_COLORSLIDER, TBM_SETRANGE, (WPARAM)TRUE, (LPARAM)MAKELONG(0,MAX_COLOR_FORMAT) );
            SendDlgItemMessage( hWnd, ID_COLORSLIDER, TBM_SETPOS, (WPARAM)TRUE, (LPARAM)2);
            SetDlgItemText( hWnd, ID_COLORTEXT, ColorFormats[2] );
            CheckDlgButton( hWnd, IDC_SQUAREONLY, bSquareOnly );
        }
        break; // End WM_INITDIALOG

        // Scroll message from the sliders
        case WM_HSCROLL:
        {
            int	nPos;
            TCHAR	szBuffer[100];

            // Get the current position
            if( ( LOWORD(wParam) == TB_THUMBPOSITION ) || ( LOWORD(wParam) == TB_THUMBTRACK ) )
                nPos = HIWORD( wParam );
            else
                nPos = SendMessage( (HWND)lParam, TBM_GETPOS, 0, 0 );
            // Was it the width slider?
            if( (HWND)lParam == GetDlgItem( hWnd, ID_WIDTHSLIDER) )
            {
                // Update the text
                wsprintf( szBuffer, "%d Width", nPos );
                SetDlgItemText( hWnd, ID_WIDTHTEXT, szBuffer );
                // If dealing with width=height, adjust height too
                if( bSquareOnly )
                {
                    SendDlgItemMessage( hWnd, ID_HEIGHTSLIDER, TBM_SETPOS, (WPARAM)TRUE, (LPARAM)nPos );
                    wsprintf( szBuffer, "%d Height", nPos );
                    SetDlgItemText( hWnd, ID_HEIGHTTEXT, szBuffer );
                }
            }
            else
            {
                // Was it the height slider?
                if( (HWND)lParam == GetDlgItem( hWnd, ID_HEIGHTSLIDER) )
                {
                    // Update the text
                    wsprintf( szBuffer, "%d Height", nPos );
                    SetDlgItemText( hWnd, ID_HEIGHTTEXT, szBuffer );
                    // If dealing with width=height, adjust width too
                    if( bSquareOnly )
                    {
                        SendDlgItemMessage( hWnd, ID_WIDTHSLIDER, TBM_SETPOS, (WPARAM)TRUE, (LPARAM)nPos );
                        wsprintf( szBuffer, "%d Width", nPos );
                        SetDlgItemText( hWnd, ID_WIDTHTEXT, szBuffer );
                    }
                }
                else
                {
                    // Was it the color slider?
                    if( (HWND)lParam == GetDlgItem( hWnd, ID_COLORSLIDER) )
                    {
                        // Update the text
                        SetDlgItemText( hWnd, ID_COLORTEXT, ColorFormats[nPos] );
                    }
                }
            }
        }
        break; // End WM_HSCROLL

        // Time to say 'goodbye'
        case WM_CLOSE:
            PostMessage( hWnd, WM_COMMAND, IDCANCEL, 0l );
        break; // End WM_CLOSE


        // Messages from user items - checkboxes etc
        case WM_COMMAND:
            switch( LOWORD(wParam) )
            {
                // Checkbox for width=height restriction
                case IDC_SQUAREONLY:
                    // Is it checked now?
                    bSquareOnly = IsDlgButtonChecked( hWnd, IDC_SQUAREONLY );
                    // If it is, set height equal to width
                    if( bSquareOnly )
                    {
                        int nPos;
                        TCHAR	szBuffer[100];

                        nPos = SendDlgItemMessage( hWnd, ID_WIDTHSLIDER, TBM_GETPOS, 0, 0 );
                        SendDlgItemMessage( hWnd, ID_HEIGHTSLIDER, TBM_SETPOS, (WPARAM)TRUE, (LPARAM)nPos );
                        wsprintf( szBuffer, "%d Height", nPos );
                        SetDlgItemText( hWnd, ID_HEIGHTTEXT, szBuffer );
                    }
                break; // End IDC_SQUAREONLY

                // Add Format button has been pressed
                case IDOK:
                {
                    LPICONIMAGE	lpii;

                    // Were we passed a valid LPICONIMAGE pointer?
                    if( ((LPICONIMAGE)lInitParam) != NULL )
                    {
                        // allocate the new ICONIMAGE
                        if( (lpii = malloc( sizeof( ICONIMAGE ) )) == FALSE )
                            EndDialog( hWnd, FALSE );
                        else
                        {
                            // initialize it
                            ZeroMemory( lpii, sizeof( ICONIMAGE ) );
                            lpii->Width = SendDlgItemMessage( hWnd, ID_WIDTHSLIDER, TBM_GETPOS, 0, 0 );
                            lpii->Height = SendDlgItemMessage( hWnd, ID_HEIGHTSLIDER, TBM_GETPOS, 0, 0 );
                            lpii->Colors = Bits[SendDlgItemMessage( hWnd, ID_COLORSLIDER, TBM_GETPOS, 0, 0 )];
                            // update the pointer that we were passed
                            *(LPICONIMAGE *)lInitParam = lpii;
                            // bail
                            EndDialog( hWnd, TRUE );
                        }
                    }
                    else
                    {
                        // bail
                        EndDialog( hWnd, FALSE );
                    }
                }
                break; // End IDOK

                // Time to cancel
                case IDCANCEL:
                    EndDialog( hWnd, FALSE );
                break; // End IDCANCEL

            }
        break;
        default:
            return FALSE;
        break;
    }
    return TRUE;
    #undef MAX_COLOR_FORMAT
}
/* End AddFormatDlgProc() ************************************************/

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
精品影院一区二区久久久| 国产精品亲子伦对白| 精品不卡在线视频| 欧美激情艳妇裸体舞| 亚洲最新在线观看| 久久精品99国产精品日本| 福利一区福利二区| 99国产精品久久久久久久久久| 在线一区二区三区四区五区| 日韩限制级电影在线观看| 中文字幕的久久| 五月天亚洲婷婷| 欧美日韩免费不卡视频一区二区三区| 欧美一区午夜视频在线观看| 欧美极品美女视频| 婷婷中文字幕综合| 国产91精品一区二区麻豆网站| 欧美性猛交一区二区三区精品| 精品国产免费视频| 一区二区三区中文字幕电影| 激情图片小说一区| 在线视频欧美精品| 欧美国产禁国产网站cc| 日本欧美一区二区| 97se亚洲国产综合自在线| 欧美成人精品二区三区99精品| 亚洲女子a中天字幕| 国产一区二区伦理片| 在线免费观看日本一区| 中文字幕欧美国产| 日韩vs国产vs欧美| 在线观看视频一区二区| 国产调教视频一区| 麻豆91免费观看| 色噜噜偷拍精品综合在线| 久久久久久久av麻豆果冻| 午夜精品久久久久久久久久久| 91亚洲男人天堂| 国产夜色精品一区二区av| 日欧美一区二区| 日本韩国欧美三级| 国产精品久久久久久久久久久免费看| 久久99热这里只有精品| 欧美美女bb生活片| 亚洲一区二区视频在线观看| 成人高清伦理免费影院在线观看| 日韩精品在线看片z| 三级亚洲高清视频| 欧洲一区二区av| 《视频一区视频二区| 国产精品亚洲а∨天堂免在线| 欧美一区二区三区婷婷月色 | 精品一区二区免费看| 欧美亚洲动漫另类| 亚洲视频在线一区观看| 国产麻豆欧美日韩一区| 日韩欧美二区三区| 久色婷婷小香蕉久久| 4438x成人网最大色成网站| 亚洲国产精品嫩草影院| 色综合久久久网| 亚洲色图欧洲色图婷婷| zzijzzij亚洲日本少妇熟睡| 欧美极品xxx| 高清在线成人网| 精品一区二区三区久久| 亚洲欧洲av在线| 国产成人日日夜夜| 久久精品一区二区三区不卡牛牛| 美国欧美日韩国产在线播放| 欧美一区二区久久久| 视频一区二区三区在线| 欧美日韩国产天堂| 天天影视色香欲综合网老头| 欧美疯狂做受xxxx富婆| 亚洲国产欧美在线| 欧美日韩国产精品成人| 日本午夜精品视频在线观看| 91精品国产一区二区人妖| 日本亚洲视频在线| 欧美videos大乳护士334| 久久超碰97中文字幕| 久久精品亚洲麻豆av一区二区| 国产精品综合久久| 国产精品视频一二| 91免费观看视频| 亚洲黄色录像片| 欧美午夜一区二区三区免费大片| 亚洲一区影音先锋| 欧美理论在线播放| 久久激情综合网| 精品国产免费久久| 成人永久免费视频| 综合网在线视频| 欧美日韩精品一区二区三区蜜桃 | 欧美日韩色一区| 青青青爽久久午夜综合久久午夜| 日韩欧美亚洲一区二区| 黑人精品欧美一区二区蜜桃 | 9久草视频在线视频精品| 亚洲日本在线天堂| 7777精品伊人久久久大香线蕉完整版 | 国产精品一区二区男女羞羞无遮挡| 久久午夜羞羞影院免费观看| 99精品久久只有精品| 亚洲 欧美综合在线网络| 精品日韩99亚洲| www.成人网.com| 午夜一区二区三区视频| 久久新电视剧免费观看| 91亚洲永久精品| 日韩国产成人精品| 国产精品久久久一本精品| 欧洲中文字幕精品| 国产在线看一区| 亚洲精品高清在线观看| 精品久久久久久久久久久久久久久久久 | 成人精品一区二区三区中文字幕| 亚洲国产aⅴ成人精品无吗| 精品日产卡一卡二卡麻豆| 9色porny自拍视频一区二区| 日韩精品高清不卡| 国产精品国产成人国产三级| 欧美精品久久一区| 成人免费看的视频| 美女看a上一区| 亚洲人成网站在线| 精品国产3级a| 日本韩国欧美三级| 国产成人精品综合在线观看| 香蕉成人伊视频在线观看| 国产精品久久免费看| 日韩一区二区三区高清免费看看| 99久久免费精品| 激情久久久久久久久久久久久久久久| 亚洲啪啪综合av一区二区三区| 精品黑人一区二区三区久久| 色一区在线观看| 国产成人av一区二区三区在线观看| 亚洲国产精品一区二区尤物区| 亚洲国产高清在线观看视频| 69堂成人精品免费视频| 91丨porny丨蝌蚪视频| 国模少妇一区二区三区| 亚洲自拍偷拍综合| 国产精品麻豆欧美日韩ww| 日韩视频国产视频| 欧美三级视频在线| 91色九色蝌蚪| 国产**成人网毛片九色| 另类小说一区二区三区| 亚洲成人午夜影院| 亚洲蜜臀av乱码久久精品蜜桃| 国产午夜亚洲精品午夜鲁丝片| 欧美一级高清大全免费观看| 在线观看国产一区二区| hitomi一区二区三区精品| 国产精品资源在线看| 久久精品99国产国产精| 视频一区中文字幕| 亚洲成人av一区二区三区| 亚洲男人的天堂一区二区 | 99国内精品久久| 粉嫩av一区二区三区| 国产在线精品一区二区不卡了 | 欧美一级欧美一级在线播放| 欧美私模裸体表演在线观看| 99精品热视频| 99精品视频在线播放观看| av激情成人网| 成年人国产精品| 成人涩涩免费视频| 国产91在线看| 国产成人鲁色资源国产91色综| 国产一区二区不卡老阿姨| 狠狠色丁香久久婷婷综合_中| 美日韩一级片在线观看| 免费观看久久久4p| 美国av一区二区| 麻豆久久一区二区| 久久丁香综合五月国产三级网站| 麻豆精品视频在线| 麻豆一区二区在线| 国精品**一区二区三区在线蜜桃| 国内精品国产成人国产三级粉色 | 久久久久久久久一| 国产午夜一区二区三区| 欧美国产一区二区在线观看| 国产女人18毛片水真多成人如厕 | 成人午夜精品一区二区三区| 国产成a人亚洲| 不卡一区在线观看| 色狠狠色狠狠综合| 欧美三级日韩在线| 日韩欧美中文字幕公布| 精品嫩草影院久久| 国产午夜精品久久| 日韩伦理免费电影| 亚洲一区二区三区四区中文字幕| 婷婷成人激情在线网|