12 2011 档案

摘要:发现个开源很好的C++框架库,共享一下网址:http://www.codeproject.com/KB/cpp/SystemFramework.aspx介绍: IntroductionStandard native C++ does not have a true object-oriented garbage collector, object-oriented function pointers (delegates), truly object-oriented exception handling, and object-oriented multithreading system. 阅读全文
posted @ 2011-12-30 11:53 kenter 阅读(522) 评论(0) 推荐(0)
摘要://Hex转BCD码#defineHEX2BCD(x)(((x)%10)+((((x)/10)%10)<<4))/*20->20H*///按照LSB格式把两个字节转化为一个word#defineFLIPW(ray)((((word)(ray)[0])*256)+(ray)[1])//按照LSB格式把一个word转化为两个字节#defineFLOPW(ray,val)(ray)[0]=((val)/256);\(ray)[1]=((val)&0xFF)//得到一个字的高位和低位字节#defineWORD_LO(xxx)((byte)((word)(var)&25 阅读全文
posted @ 2011-12-21 13:48 kenter 阅读(372) 评论(0) 推荐(0)
摘要:#pragmaonce//锁接口classILock{public:virtual~ILock(){}virtualvoidLock()=0;virtualvoidUnlock()=0;};/************************************************************************//*CRITICAL_SECTION*//************************************************************************/classCriticalSectionLocker:ILock{publ 阅读全文
posted @ 2011-12-21 13:44 kenter 阅读(250) 评论(0) 推荐(0)
摘要:HANDLEhandle;//processhandleHWNDapphwnd=NULL;//windowhandleBOOLfind=FALSE;/*************Globalfunctionsforhosting******************///Functiontoenumerateallwindows.intCALLBACKEnumWindowsProc(HWNDhwnd,LPARAMparam){DWORDpID;DWORDTpID=GetWindowThreadProcessId(hwnd,&pID);//getprocessidif(TpID==(DWOR 阅读全文
posted @ 2011-12-17 11:16 kenter 阅读(753) 评论(0) 推荐(0)