摘要:数值NSMutableArray* arr = [NSMutableArrayarrayWithObjects: [NSNumber numberWithInt:0], [NSNumber numberWithInt:3], [NSNumber numberWithInt:2], [NSNumber numberWithInt:1], [...
阅读全文
摘要:UIScreen* screen =[UIScreenmainScreen];UIDevice* device = [UIDevicecurrentDevice];UIScreenMode* screenMode = [screen currentMode];
阅读全文
摘要:声明NSInvocation* m_touchDown;赋值-(void) setTouchMoveCallback:(id) target sel:(SEL) sel { if (m_touchMove) { [m_touchMove release]; m_touchMove = nil; } NSMethodSignature *sig= [target methodSignatureForSelector:sel]; NSAssert(sig, @""); m_touchMove = [NSInvocation invocati...
阅读全文
摘要:libevent和libcurl的一些学习原文libcurl是一个用于传递数据的库;libevent则是提供服务器相应操作的库。网上关于libcurl的介绍很多,主要介绍了如何用它下载网页等功能,另外网上也有许多相关php代码的实例。libevent的相关资源比较少。一下是我实现的两个简单的小例子,一个利用libcurl发送数据,一个利用libevent去接收。libcurl.c 发送数据?1 #include2 #include3intmain(void){4char*url="http://127.0.0.1:8080/test";5charmypost[]="
阅读全文