⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 report.cpp

📁 Windows 图形编程 书籍
💻 CPP
字号:
//-----------------------------------------------------------------------------------//
//              Windows Graphics Programming: Win32 GDI and DirectDraw               //
//                             ISBN  0-13-086985-6                                   //
//                                                                                   //
//  Written            by  Yuan, Feng                             www.fengyuan.com   //
//  Copyright (c) 2000 by  Hewlett-Packard Company                www.hp.com         //
//  Published          by  Prentice Hall PTR, Prentice-Hall, Inc. www.phptr.com      //
//                                                                                   //
//  FileName   : report.cpp				                                             //
//  Description: Send report to spy control program                                  //
//  Version    : 1.00.000, May 31, 2000                                              //
//-----------------------------------------------------------------------------------//

#define NOCRYPT

#include <windows.h>
#include <tchar.h>

#include "Report.h"

// Report to Client

extern HWND h_Controller;

LRESULT Send(unsigned id, unsigned para, unsigned time, const TCHAR *messtext)
{
    COPYDATASTRUCT cds;
    ReportMessage  rpt;

    memset(& rpt, 0, sizeof(rpt));

    rpt.m_para = para;
    rpt.m_time = time;
    rpt.m_tick = GetTickCount();

    if ( messtext )
        _tcsncpy(rpt.m_text, messtext, sizeof(rpt.m_text)/sizeof(TCHAR)-1);

    cds.dwData = id;
    cds.cbData = sizeof(rpt);
    cds.lpData = (void *) & rpt;

    return SendMessage(h_Controller, WM_COPYDATA, NULL, (LPARAM) & cds);
}

⌨️ 快捷键说明

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