UIView触摸事件touchBegin等一系列方法 1)手指按下 - (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event; 2)按下并移动 - (void)touchesMoved:(NSSet *)...
分类:
其他好文 时间:
2015-09-21 10:20:58
阅读次数:
145
5。触摸事件 touchBegin 等一系列方法 1)手指按下 - (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event; 2)按下并移动 - (void)touchesMoved:(NSSet *)to...
分类:
其他好文 时间:
2015-09-21 08:03:56
阅读次数:
150
方法一:点击屏幕背景,键盘下落//触摸背景键盘下落-(void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event{ [self.view endEditing:YES];}View Code方法二:点击return键键盘下落[_t...
分类:
其他好文 时间:
2015-09-14 22:23:04
阅读次数:
235
// --- 裁剪圆形图片-画带边框的圆形头像 - (void)touchesBegan:(NSSet*)touches withEvent:(UIEvent*)event { // -1.获取图片 UIImage* image = [UIImage imageNamed:@"me"...
分类:
其他好文 时间:
2015-09-14 00:17:53
阅读次数:
241
NSMapTable、NSHashTable与NSPointerArray的封装说明NSMapTable对应NSDictionary;NSHashTable对应NSSet;NSPointerArray对应NSArray,本人通过装饰设计模式对他们的使用进行了封装。源码https://github.c...
分类:
其他好文 时间:
2015-09-12 18:54:23
阅读次数:
255
*********// 2D绘图 Quartz2D// 合并图片 -- 水印- (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event{ // 1.队列组 dispatch_group_t group = dispa...
分类:
移动开发 时间:
2015-09-09 17:18:51
阅读次数:
158
公司项目中需要为一个view添加手势,短按则消失,长按就保存到相册,为了在touchesEnded中区分长按和短按开始了google和百度,百度中有人说可以通过以下方式来实现:-(void)touchesEnded:(NSSet*)toucheswithEvent:(UIEvent*)event
{
UITouch*aTouch=[touchesanyObject];
for(i..
分类:
其他好文 时间:
2015-09-09 14:51:39
阅读次数:
235
一、Foundation框架中一些常用的类字符串型:NSString:不可变字符串NSMutableString:可变字符串集合型:1)NSArray:OC不可变数组NSMutableArray:可变数组2)NSSet:NSMutableSet:3)NSDictioraryNSMutableDict...
分类:
其他好文 时间:
2015-09-08 23:31:04
阅读次数:
244
让键盘下去总的来说就是结束编辑或让键盘失去第一响应,我一般用这3种方法:第一种:点击屏幕让键盘结束编辑。-(void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event{ [self.view endEditing:YES];}第二...
分类:
移动开发 时间:
2015-09-08 12:21:30
阅读次数:
403
****动画效果- (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event{ [UIView animateWithDuration:1 animations:^{ // 旋转// ...
分类:
移动开发 时间:
2015-09-06 17:57:41
阅读次数:
547