glbfun.cpp
来自「超声影像工作站系统可与各种型号的B超、彩超连接」· C++ 代码 · 共 39 行
CPP
39 行
// glbfun.cpp
#include "glbfun.h"
#include "stdafx.h"
DWORD CALLBACK EditStreamCallBack(DWORD dwCookie, LPBYTE pbBuff, LONG cb, LONG *pcb)
{
CString *pstr = (CString *)dwCookie;
if( pstr->GetLength() < cb )
{
*pcb = pstr->GetLength();
memcpy(pbBuff, (LPCSTR)*pstr, *pcb );
pstr->Empty();
}
else
{
*pcb = cb;
memcpy(pbBuff, (LPCSTR)*pstr, *pcb );
*pstr = pstr->Right( pstr->GetLength() - cb );
}
return 0;
}
DWORD CALLBACK EditStreamCallBackW(DWORD dwCookie, LPBYTE pbBuff, LONG cb, LONG *pcb)
{
CString *psEntry = (CString*) dwCookie;
CString tmpEntry = "";
tmpEntry = (CString) pbBuff;
// And write it!!!
*psEntry += tmpEntry.Left(cb);
return 0;
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?