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

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

?? tapicomm.c

?? 一份有用的TAPI編程源碼
?? C
字號:
// THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF 
// ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO 
// THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A 
// PARTICULAR PURPOSE.
//
// Copyright 1995 - 1998 Microsoft Corporation.  All Rights Reserved.
//
//  MODULE: TapiComm.c
//
//  PURPOSE: Handles general routines for the TapiComm sample.
//
//  FUNCTIONS:
//    WndProc     - Processes messages for the main window.
//    MsgCommand  - Handle the WM_COMMAND messages for the main window.
//    MsgCreate   - Handle the WM_CREATE messages for the main window.
//    MsgSize     - Handles the WM_SIZE message by calling SendMessage() to
//                  pass the WM_SIZE message onto the status bar and tool bar
//                  controls. 
//    MsgDestroy  - Handles the WM_DESTROY message by calling 
//                  PostQuitMessage().
//    CmdExit     - Handles the file exit command by calling destroy 
//                  window on the main window.
//
//  COMMENTS:
//    Message dispatch table -
//      For every message to be handled by the main window procedure
//      place the message number and handler function pointer in
//      rgmsd (the message dispatch table).  Place the prototype
//      for the function in globals.h and the definition of the
//      function in the appropriate module.
//    Command dispatch table -
//      For every command to be handled by the main window procedure
//      place the command number and handler function pointer in
//      rgcmd (the command dispatch table).  Place the prototype
//      for the function in globals.h and the definition of the
//      function in the appropriate module.
//    Globals.h Contains the definitions of the structures and dispatch.c
//      contains the functions that use these structures.
//



#include <windows.h>            // required for all Windows applications
#include <windowsx.h>
#include <commctrl.h>           // prototypes and defs for common controls
#include "globals.h"            // prototypes specific to this application
#include "statbar.h"            // prototypes specific to statbar.c
#include "toolbar.h"            // prototypes specific to toolbar.c
#include "EditCtls.h"
#include "TapiCode.h"
#include "resource.h"

LRESULT CmdCreateFile1(HWND hWnd, WORD wCommand, WORD wNotify, HWND hwndCtrl);
LRESULT CmdCreateFile2(HWND hWnd, WORD wCommand, WORD wNotify, HWND hwndCtrl);


// Main window message table definition.
MSD rgmsd[] =
{
    {WM_COMMAND,    MsgCommand   },
    {WM_MENUSELECT, MsgMenuSelect},
    {WM_SIZE,       MsgSize      },
    {WM_NOTIFY,     MsgNotify    },
    {WM_CLOSE,      MsgClose     },
    {WM_CREATE,     MsgCreate    },
    {WM_SETFOCUS,   MsgSetFocus  },
    //{WM_PAINT,      MsgPaint     },
    {WM_DESTROY,    MsgDestroy   }
};

MSDI msdiMain =
{
    sizeof(rgmsd) / sizeof(MSD),
    rgmsd,
    edwpWindow
};


// Main window command table definition.
CMD rgcmd[] =
{
    {IDM_MAKECALL,    CmdMakeCall},
    {IDM_HANGUPCALL,  CmdHangupCall},
    {IDM_EXIT,        CmdExit},

    {IDM_EDITUNDO,    CmdStub},
    {IDM_EDITCUT,     CmdStub},
    {IDM_EDITCOPY,    CmdStub},
    {IDM_EDITPASTE,   CmdStub},
    {IDM_EDITCLEAR,   CmdStub},

    {IDM_ABOUT,       CmdAbout},
};

CMDI cmdiMain =
{
    sizeof(rgcmd) / sizeof(CMD),
    rgcmd,
    edwpWindow
};


//
//  FUNCTION: WndProc(HWND, UINT, WPARAM, LPARAM)
//
//  PURPOSE:  Processes messages for the main window.
//
//  PARAMETERS:
//    hwnd     - window handle
//    uMessage - message number
//    wparam   - additional information (dependant on message number)
//    lparam   - additional information (dependant on message number)
//
//  RETURN VALUE:
//    The return value depends on the message number.  If the message
//    is implemented in the message dispatch table, the return value is
//    the value returned by the message handling function.  Otherwise,
//    the return value is the value returned by the default window procedure.
//
//  COMMENTS:
//    Call the DispMessage() function with the main window's message dispatch
//    information (msdiMain) and the message specific information.
//

LRESULT CALLBACK WndProc(HWND   hwnd, 
                         UINT   uMessage, 
                         WPARAM wparam, 
                         LPARAM lparam)
{
    return DispMessage(&msdiMain, hwnd, uMessage, wparam, lparam);
}


//
//  FUNCTION: MsgCommand(HWND, UINT, WPARAM, LPARAM)
//
//  PURPOSE: Handle the WM_COMMAND messages for the main window.
//
//  PARAMETERS:
//    hwnd     - window handle
//    uMessage - WM_COMMAND (Unused)
//    GET_WM_COMMAND_ID(wparam, lparam)   - Command identifier
//    GET_WM_COMMAND_HWND(wparam, lparam) - Control handle
//
//  RETURN VALUE:
//    The return value depends on the message number.  If the message
//    is implemented in the message dispatch table, the return value is
//    the value returned by the message handling function.  Otherwise,
//    the return value is the value returned by the default window procedure.
//
//  COMMENTS:
//    Call the DispCommand() function with the main window's command dispatch
//    information (cmdiMain) and the command specific information.
//

LRESULT MsgCommand(HWND hwnd, UINT uMessage, WPARAM wparam, LPARAM lparam)
{
    return DispCommand(&cmdiMain, hwnd, wparam, lparam);
}


//
//  FUNCTION: MsgCreate(HWND, UINT, WPARAM, LPARAM)
//
//  PURPOSE: Handle the WM_CREATE messages for the main window.
//           and call InitCommonControls() API to initialize the
//           common control library. 
//
//  PARAMETERS:
//    hwnd     - window handle
//
//  RETURN VALUE:
//    Return 0 if the StatusBar and ToolBar Windows could be created
//    successfully. Otherwise, returns -1 to abort the main window
//    creation.
//
//  COMMENTS:
//    Call the CreateTSBars function with the main window's window handle
//    information (msdiMain). 
//
//    Must also initialize TAPI.
//

LRESULT MsgCreate(HWND hwnd, UINT uMessage, WPARAM wparam, LPARAM lparam)
{
    InitCommonControls() ; // Initialize the common control library.

    if (InitEditCtls(hwnd) == FALSE)
        return -1;

    InitializeTAPI(hwnd);

    if(!(CreateTBar(hwnd) && CreateSBar(hwnd)))
        return -1;   // Tool and status bars were not created, so return -1.

    UpdateStatusBar("Ready to make a call.",1,0);

    EnableMakeCall(hwnd, TRUE);
    EnableHangupCall(hwnd, FALSE);
    return 0;
}


//
//  FUNCTION: MsgSize(HWND, UINT, WPARAM, LPARAM)
//
//  PURPOSE:  This function resizes the toolbar and statusbar controls. 
//
//
//  PARAMETERS:
//
//    hwnd      - Window handle  (Used)
//    uMessage  - Message number (Used)
//    wparam    - Extra data     (Used)
//    lparam    - Extra data     (Used)
//
//  RETURN VALUE:
//
//    Always returns 0 - Message handled
//
//  COMMENTS:
//
//    When the window procdure that has the status and tool bar controls
//    receive the WM_SIZE message, it has to pass the message on to these 
//    controls so that these controls can adjust their size accordingly. 
//   
//    It also has to resize the edit controls that are the UI for TAPI.
//
//

LRESULT MsgSize(HWND hwnd, UINT uMessage, WPARAM wparam, LPARAM lparam) 
{
    SendMessage(hWndStatusbar,  uMessage, wparam, lparam);
    SendMessage(hWndToolbar, uMessage, wparam, lparam);

    // Re-position the panes in the status bar
    InitializeStatusBar(hwnd);

    SizeEditCtls();

    return 0 ;
}


//
//  FUNCTION: MsgSetFocus(HWND, UINT, WPARAM, LPARAM)
//
//  PURPOSE:  This function puts the focus where is should be.
//
//
//  PARAMETERS:
//
//    hwnd      - Window handle  (Used)
//    uMessage  - Identifies window that lost focus (Used)
//    wparam    - Extra data     (Used)
//    lparam    - Extra data     (Used)
//
//  RETURN VALUE:
//
//    Always returns 0 - Message handled
//
//  COMMENTS:
//
//    Just signal the edit controls to set the focus where it belongs.
//
//

LRESULT MsgSetFocus(HWND hwnd, UINT uMessage, WPARAM wparam, LPARAM lparam) 
{
    SetFocusEditCtls();

    return 0 ;
}


//
//  FUNCTION: MsgDestroy(HWND, UINT, WPARAM, LPARAM)
//
//  PURPOSE: Calls PostQuitMessage().
//
//  PARAMETERS:
//
//    hwnd      - Window handle  (Unused)
//    uMessage  - Message number (Unused)
//    wparam    - Extra data     (Unused)
//    lparam    - Extra data     (Unused)
//
//  RETURN VALUE:
//
//    Always returns 0 - Message handled
//
//  COMMENTS:
//
//

LRESULT MsgDestroy(HWND hwnd, UINT uMessage, WPARAM wparam, LPARAM lparam)
{
    PostQuitMessage(0);
    return 0;
}


//
//  FUNCTION: MsgClose(HWND, UINT, WPARAM, LPARAM)
//
//  PURPOSE: Exits the application.
//
//  PARAMETERS:
//
//    hwnd      - The window.
//    uMessage  - Message number (Unused)
//    wparam    - Extra data     (Unused)
//    lparam    - Extra data     (Unused)
//
//  RETURN VALUE:
//
//    Always returns 0 - Message handled
//
//  COMMENTS:
//    
//    Make sure TAPI is stopped before exiting.
//
//

LRESULT MsgClose(HWND hwnd, UINT uMessage, WPARAM wparam, LPARAM lparam)
{
    ShutdownTAPI();

    DestroyWindow(hwnd);
    return 0;
}


//
//  FUNCTION: MsgPaint(HWND, UINT, WPARAM, LPARAM)
//
//  PURPOSE: Paints the client area of the window.
//
//  PARAMETERS:
//
//    hwnd      - The window.
//    uMessage  - Message number (Unused)
//    wparam    - Extra data     (Unused)
//    lparam    - Extra data     (Unused)
//
//  RETURN VALUE:
//
//    Always returns 0 - Message handled
//
//  COMMENTS:
//    
//    Not sure what needs to be painted, maybe text
//    labeling the edit controls?
//
//

LRESULT MsgPaint(HWND hwnd, UINT uMessage, WPARAM wparam, LPARAM lparam)
{
    HDC hdc;
    PAINTSTRUCT ps;

    hdc = BeginPaint(hwnd, &ps);

    EndPaint(hwnd, &ps);
    return 0;
}


//
//  FUNCTION: CmdExit(HWND, WORD, WORD, HWND)
//
//  PURPOSE: Exit the application.
//
//  PARAMETERS:
//    hwnd     - The window.
//    wCommand - IDM_EXIT (unused)
//    wNotify  - Notification number (unused)
//    hwndCtrl - NULL (unused)
//
//  RETURN VALUE:
//    Always returns 0 - command handled.
//
//  COMMENTS:
//
//    Make sure TAPI is stopped before exiting.
//
//

LRESULT CmdExit(HWND hwnd, WORD wCommand, WORD wNotify, HWND hwndCtrl)
{
    char szBuffer[50];   
    int  cbWritten = 0;

    ShutdownTAPI();

    cbWritten = LoadString(hInst, wCommand, szBuffer, sizeof(szBuffer)); 
    if(cbWritten == 0) 
        lstrcpy(szBuffer, "Unknown Command");

    UpdateStatusBar(szBuffer, 0, 0);
 
    DestroyWindow(hwnd);
    return 0;
}


//
//  FUNCTION: CmdHangupCall(HWND, WORD, WORD, HWND)
//
//  PURPOSE: Stops TAPI
//
//  PARAMETERS:
//    hwnd     - The window.
//    wCommand - IDM_HANGUPCALL (unused)
//    wNotify  - Notification number (unused)
//    hwndCtrl - NULL (unused)
//
//  RETURN VALUE:
//    Always returns 0 - command handled.
//
//  COMMENTS:
//
//    Tells TAPI to close any opened lines.
//
//


LRESULT CmdHangupCall(HWND hWnd, WORD wCommand, WORD wNotify, HWND hwndCtrl)
{
    HangupCall();
    return 0;
}


//
//  FUNCTION: CmdMakeCall(HWND, WORD, WORD, HWND)
//
//  PURPOSE: Starts TAPI
//
//  PARAMETERS:
//    hwnd     - The window.
//    wCommand - IDM_MAKECALL (unused)
//    wNotify  - Notification number (unused)
//    hwndCtrl - NULL (unused)
//
//  RETURN VALUE:
//    Always returns 0 - command handled.
//
//  COMMENTS:
//
//    Starts TAPI by calling the Dialing Dialog box.
//    Code for this dialog is with the rest of the TAPI code.
//
//

LRESULT CmdMakeCall(HWND hWnd, WORD wCommand, WORD wNotify, HWND hwndCtrl)
{
    DialCall();
    return 0;
}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
www.亚洲国产| 亚洲成人精品影院| 亚洲精品国产成人久久av盗摄| 一区二区三区精品| 同产精品九九九| 另类的小说在线视频另类成人小视频在线| 韩国av一区二区| 92国产精品观看| 欧美精品久久99| 欧美国产乱子伦| 亚洲一区二区3| 国产精品18久久久久久久久| 91免费版在线看| 日韩视频一区二区在线观看| 国产欧美精品一区二区色综合朱莉| 亚洲精品成人悠悠色影视| 青娱乐精品视频| 不卡的av电影| 欧美α欧美αv大片| 国产精品久久一卡二卡| 午夜国产精品影院在线观看| 国产精品1区2区| 欧美日韩一区二区欧美激情| 亚洲精品一区二区精华| 亚洲一区二区三区免费视频| 九九九精品视频| 在线免费观看日本一区| 久久香蕉国产线看观看99| 一二三区精品视频| 激情图片小说一区| 欧洲一区二区三区在线| 久久久久99精品国产片| 午夜精品久久久久久久99水蜜桃| 国产精品456| 欧美一卡二卡在线| 亚洲精选一二三| 国产精品白丝jk黑袜喷水| 91麻豆精品国产91久久久久久久久 | 777午夜精品免费视频| 欧美韩国日本一区| 日本va欧美va精品| 欧美午夜精品一区| 国产亚洲午夜高清国产拍精品| 亚洲国产精品影院| jizzjizzjizz欧美| 国产亚洲精品aa| 日本美女视频一区二区| 色菇凉天天综合网| 国产精品日韩成人| 国产精品亚洲一区二区三区妖精| 欧美一区二区三区视频在线观看| 亚洲另类色综合网站| 国产电影一区二区三区| 精品国产伦一区二区三区观看体验| 亚洲一区精品在线| 日本久久一区二区| 亚洲图片激情小说| 福利91精品一区二区三区| 日韩你懂的在线观看| 日韩精品亚洲专区| 91国产精品成人| 国产精品护士白丝一区av| 国产另类ts人妖一区二区| 日韩久久免费av| 人人超碰91尤物精品国产| 欧美色中文字幕| 一区二区三区美女| 色8久久精品久久久久久蜜| 综合久久综合久久| 91在线视频18| 国产精品另类一区| 丁香五精品蜜臀久久久久99网站| 久久综合网色—综合色88| 美女脱光内衣内裤视频久久网站| 欧美久久久久免费| 图片区小说区区亚洲影院| 欧美高清视频www夜色资源网| 亚洲美女屁股眼交| 在线视频国内自拍亚洲视频| 亚洲色图丝袜美腿| 日本高清免费不卡视频| 亚洲精品国产一区二区精华液| av网站免费线看精品| 一区在线观看免费| 91九色最新地址| 污片在线观看一区二区| 717成人午夜免费福利电影| 日韩电影在线看| 日韩欧美国产一区在线观看| 精品一区二区综合| 国产欧美精品一区aⅴ影院 | 亚洲欧美在线观看| 色偷偷成人一区二区三区91| 亚洲激情图片一区| 欧美日韩国产乱码电影| 视频一区二区三区中文字幕| 欧美一级片在线观看| 久久99久久99小草精品免视看| 26uuu国产在线精品一区二区| 国产一区二区三区蝌蚪| 国产精品色噜噜| 在线亚洲一区二区| 日本中文字幕一区二区视频| 精品久久久久久久久久久久久久久久久 | 99久久精品情趣| 亚洲专区一二三| 欧美一区二区大片| 成人动漫一区二区在线| 一区二区欧美国产| 91精品国产色综合久久不卡电影| 国产在线播放一区| **欧美大码日韩| 91精品国产91热久久久做人人| 国产一区视频网站| 亚洲女女做受ⅹxx高潮| 91精品在线一区二区| 国产精品羞羞答答xxdd| 亚洲尤物在线视频观看| 欧美xxxxx裸体时装秀| 成人黄色在线视频| 五月婷婷激情综合| 欧美激情中文字幕一区二区| 欧美午夜不卡视频| 国产精品亚洲午夜一区二区三区| 夜夜爽夜夜爽精品视频| 久久亚洲精华国产精华液| 在线视频综合导航| 国产成人鲁色资源国产91色综| 亚洲精品一二三| 久久天天做天天爱综合色| 色综合中文综合网| 一区二区三区免费| 精品国产91九色蝌蚪| 99久久伊人网影院| 男女性色大片免费观看一区二区 | 99久久精品国产导航| 亚洲成av人片www| 久久精品网站免费观看| 日韩免费看网站| 日本道免费精品一区二区三区| 麻豆免费精品视频| 伊人开心综合网| 国产日韩欧美精品综合| 日韩一区二区视频在线观看| 在线观看亚洲一区| 粉嫩在线一区二区三区视频| 免费成人av在线| 亚洲成人激情自拍| 亚洲女人****多毛耸耸8| 欧美韩日一区二区三区四区| 日韩美女主播在线视频一区二区三区| 色天使久久综合网天天| 高清免费成人av| 国产一区二区三区电影在线观看| 日韩av电影天堂| 亚洲成年人网站在线观看| 亚洲欧美精品午睡沙发| 国产精品久久久久久久午夜片 | 国产成人啪免费观看软件| 日韩av一区二区在线影视| 亚洲一区二区黄色| 亚洲精品亚洲人成人网在线播放| 国产精品久久久久四虎| 久久精品一区八戒影视| 精品久久一区二区| 日韩你懂的在线观看| 欧美一区二区高清| 91精品国产综合久久婷婷香蕉| 欧美日韩精品免费观看视频| 日本丶国产丶欧美色综合| 91色porny| 97超碰欧美中文字幕| 成人av电影在线| 成人国产精品视频| 成人aa视频在线观看| 不卡的电视剧免费网站有什么| 成人app网站| 成人av免费在线播放| caoporn国产精品| 99久久99久久免费精品蜜臀| 91在线精品秘密一区二区| 99久免费精品视频在线观看 | 亚洲愉拍自拍另类高清精品| 亚洲精品国产第一综合99久久 | 欧美人伦禁忌dvd放荡欲情| 欧美无乱码久久久免费午夜一区| 在线视频欧美区| 欧美亚洲高清一区| 欧美色老头old∨ideo| 欧美另类高清zo欧美| 日韩限制级电影在线观看| 欧美成人一区二区三区| wwwwxxxxx欧美| 国产情人综合久久777777| 中文成人av在线| 亚洲三级电影网站| 亚洲精品中文在线观看| 亚洲电影你懂得| 日韩电影在线观看一区| 久久se这里有精品|