├── .gitignore ├── main.m ├── UIGestureExamples_Prefix.pch ├── UIGestureExamples-Info.plist ├── Classes ├── ExampleController.h ├── DiscreteGestures.h ├── RootViewController.h ├── ExampleController.m ├── GestureInteraction.h ├── ContinuousGestures.h ├── DetailViewController.h ├── UIGestureExamplesAppDelegate.h ├── UIGestureExamplesAppDelegate.m ├── RootViewController.m ├── DetailViewController.m ├── DiscreteGestures.m ├── GestureInteraction.m ├── ContinuousGestures.m ├── DiscreteGestures.xib ├── ContinuousGestures.xib └── GestureInteraction.xib ├── UIGestureExamples.xcodeproj └── project.pbxproj ├── DetailView.xib └── MainWindow.xib /.gitignore: -------------------------------------------------------------------------------- 1 | build 2 | *.mode1v3 3 | *.pbxuser 4 | *.perspectivev3 5 | -------------------------------------------------------------------------------- /main.m: -------------------------------------------------------------------------------- 1 | // 2 | // main.m 3 | // UIGestureExamples 4 | // 5 | // Created by Nathan Eror on 11/6/10. 6 | // Copyright 2010 Free Time Studios. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | int main(int argc, char *argv[]) { 12 | NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init]; 13 | int retVal = UIApplicationMain(argc, argv, nil, nil); 14 | [pool release]; 15 | return retVal; 16 | } 17 | -------------------------------------------------------------------------------- /UIGestureExamples_Prefix.pch: -------------------------------------------------------------------------------- 1 | // 2 | // Prefix header for all source files of the 'UIGestureExamples' target in the 'UIGestureExamples' project 3 | // 4 | #import 5 | 6 | #ifndef __IPHONE_4_0 7 | #warning "This project uses features only available in iPhone SDK 4.0 and later." 8 | #endif 9 | 10 | 11 | #ifdef __OBJC__ 12 | #import 13 | #import 14 | #import 15 | #endif 16 | -------------------------------------------------------------------------------- /UIGestureExamples-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | English 7 | CFBundleDisplayName 8 | ${PRODUCT_NAME} 9 | CFBundleExecutable 10 | ${EXECUTABLE_NAME} 11 | CFBundleIconFile 12 | 13 | CFBundleIdentifier 14 | com.yourcompany.${PRODUCT_NAME:rfc1034identifier} 15 | CFBundleInfoDictionaryVersion 16 | 6.0 17 | CFBundleName 18 | ${PRODUCT_NAME} 19 | CFBundlePackageType 20 | APPL 21 | CFBundleSignature 22 | ???? 23 | CFBundleVersion 24 | 1.0 25 | LSRequiresIPhoneOS 26 | 27 | NSMainNibFile 28 | MainWindow 29 | UISupportedInterfaceOrientations 30 | 31 | UIInterfaceOrientationPortrait 32 | UIInterfaceOrientationPortraitUpsideDown 33 | UIInterfaceOrientationLandscapeLeft 34 | UIInterfaceOrientationLandscapeRight 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /Classes/ExampleController.h: -------------------------------------------------------------------------------- 1 | /* 2 | The MIT License 3 | 4 | Copyright (c) 2010 Free Time Studios and Nathan Eror 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in 14 | all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 | THE SOFTWARE. 23 | */ 24 | 25 | #import 26 | 27 | 28 | @interface ExampleController : UIViewController { 29 | 30 | } 31 | 32 | + (NSString *)friendlyName; 33 | - (void)resetExample; 34 | 35 | @end 36 | -------------------------------------------------------------------------------- /Classes/DiscreteGestures.h: -------------------------------------------------------------------------------- 1 | /* 2 | The MIT License 3 | 4 | Copyright (c) 2010 Free Time Studios and Nathan Eror 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in 14 | all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 | THE SOFTWARE. 23 | */ 24 | 25 | #import 26 | #import "ExampleController.h" 27 | 28 | @interface DiscreteGestures : ExampleController { 29 | } 30 | 31 | @property (nonatomic,retain) IBOutlet UILabel *eventTypeLabel; 32 | 33 | @end 34 | -------------------------------------------------------------------------------- /Classes/RootViewController.h: -------------------------------------------------------------------------------- 1 | /* 2 | The MIT License 3 | 4 | Copyright (c) 2010 Free Time Studios and Nathan Eror 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in 14 | all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 | THE SOFTWARE. 23 | */ 24 | 25 | #import 26 | 27 | @class DetailViewController; 28 | 29 | @interface RootViewController : UITableViewController { 30 | } 31 | 32 | @property (nonatomic, retain) IBOutlet DetailViewController *detailViewController; 33 | 34 | @end 35 | -------------------------------------------------------------------------------- /Classes/ExampleController.m: -------------------------------------------------------------------------------- 1 | /* 2 | The MIT License 3 | 4 | Copyright (c) 2010 Free Time Studios and Nathan Eror 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in 14 | all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 | THE SOFTWARE. 23 | */ 24 | 25 | #import "ExampleController.h" 26 | 27 | 28 | @implementation ExampleController 29 | 30 | + (NSString *)friendlyName { 31 | return @"An Example"; 32 | } 33 | 34 | - (void)resetExample { 35 | 36 | } 37 | 38 | - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)orientation { 39 | return YES; 40 | } 41 | 42 | @end 43 | -------------------------------------------------------------------------------- /Classes/GestureInteraction.h: -------------------------------------------------------------------------------- 1 | /* 2 | The MIT License 3 | 4 | Copyright (c) 2010 Free Time Studios and Nathan Eror 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in 14 | all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 | THE SOFTWARE. 23 | */ 24 | 25 | #import 26 | #import 27 | #import "ExampleController.h" 28 | 29 | 30 | @interface GestureInteraction : ExampleController { 31 | } 32 | 33 | @property (nonatomic, retain) IBOutlet UIView *containerView; 34 | @property (nonatomic, retain) IBOutlet UILabel *tapLabel; 35 | @property (nonatomic, retain) IBOutlet UILabel *swipeLabel; 36 | 37 | @end 38 | -------------------------------------------------------------------------------- /Classes/ContinuousGestures.h: -------------------------------------------------------------------------------- 1 | /* 2 | The MIT License 3 | 4 | Copyright (c) 2010 Free Time Studios and Nathan Eror 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in 14 | all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 | THE SOFTWARE. 23 | */ 24 | 25 | #import 26 | #import "ExampleController.h" 27 | 28 | @interface ContinuousGestures : ExampleController { 29 | } 30 | 31 | @property (nonatomic, retain) IBOutlet UIView *redView; 32 | @property (nonatomic, retain) IBOutlet UIView *greenView; 33 | @property (nonatomic, retain) IBOutlet UIView *blueView; 34 | @property (nonatomic, retain) IBOutlet UIView *orangeView; 35 | 36 | @end 37 | -------------------------------------------------------------------------------- /Classes/DetailViewController.h: -------------------------------------------------------------------------------- 1 | /* 2 | The MIT License 3 | 4 | Copyright (c) 2010 Free Time Studios and Nathan Eror 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in 14 | all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 | THE SOFTWARE. 23 | */ 24 | 25 | #import 26 | #import "ExampleController.h" 27 | 28 | @interface DetailViewController : UIViewController { 29 | 30 | } 31 | 32 | @property (nonatomic, retain) IBOutlet UIToolbar *toolbar; 33 | @property (nonatomic, retain) ExampleController *exampleController; 34 | @property (nonatomic, retain) IBOutlet UIView *contentView; 35 | @property (nonatomic, retain) IBOutlet UILabel *titleLabel; 36 | 37 | @end 38 | 39 | @interface DetailView : UIView 40 | 41 | @end 42 | -------------------------------------------------------------------------------- /Classes/UIGestureExamplesAppDelegate.h: -------------------------------------------------------------------------------- 1 | /* 2 | The MIT License 3 | 4 | Copyright (c) 2010 Free Time Studios and Nathan Eror 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in 14 | all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 | THE SOFTWARE. 23 | */ 24 | 25 | #import 26 | 27 | @class RootViewController; 28 | @class DetailViewController; 29 | 30 | @interface UIGestureExamplesAppDelegate : NSObject { 31 | } 32 | 33 | @property (nonatomic, retain) IBOutlet UIWindow *window; 34 | @property (nonatomic, retain) IBOutlet UISplitViewController *splitViewController; 35 | @property (nonatomic, retain) IBOutlet RootViewController *rootViewController; 36 | @property (nonatomic, retain) IBOutlet DetailViewController *detailViewController; 37 | 38 | @end 39 | -------------------------------------------------------------------------------- /Classes/UIGestureExamplesAppDelegate.m: -------------------------------------------------------------------------------- 1 | /* 2 | The MIT License 3 | 4 | Copyright (c) 2010 Free Time Studios and Nathan Eror 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in 14 | all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 | THE SOFTWARE. 23 | */ 24 | 25 | #import "UIGestureExamplesAppDelegate.h" 26 | #import "RootViewController.h" 27 | #import "DetailViewController.h" 28 | 29 | 30 | @implementation UIGestureExamplesAppDelegate 31 | 32 | @synthesize window = window_; 33 | @synthesize splitViewController = splitViewController_; 34 | @synthesize rootViewController = rootViewController_; 35 | @synthesize detailViewController = detailViewController_; 36 | 37 | #pragma mark - 38 | #pragma mark Application lifecycle 39 | 40 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { 41 | [self.window addSubview:self.splitViewController.view]; 42 | [self.window makeKeyAndVisible]; 43 | return YES; 44 | } 45 | 46 | - (void)dealloc { 47 | [splitViewController_ release], splitViewController_ = nil; 48 | [rootViewController_ release], rootViewController_ = nil; 49 | [detailViewController_ release], detailViewController_ = nil; 50 | [window_ release], window_ = nil; 51 | [super dealloc]; 52 | } 53 | 54 | 55 | @end 56 | 57 | -------------------------------------------------------------------------------- /Classes/RootViewController.m: -------------------------------------------------------------------------------- 1 | /* 2 | The MIT License 3 | 4 | Copyright (c) 2010 Free Time Studios and Nathan Eror 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in 14 | all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 | THE SOFTWARE. 23 | */ 24 | 25 | #import "RootViewController.h" 26 | #import "DetailViewController.h" 27 | #import "ExampleController.h" 28 | #import "GestureInteraction.h" 29 | #import "DiscreteGestures.h" 30 | #import "ContinuousGestures.h" 31 | 32 | @interface RootViewController() 33 | 34 | @property (copy) NSArray *examples; 35 | 36 | @end 37 | 38 | @implementation RootViewController 39 | 40 | @synthesize detailViewController = detailViewController_; 41 | @synthesize examples = examples_; 42 | 43 | #pragma mark - 44 | #pragma mark View lifecycle 45 | 46 | - (void)viewDidLoad { 47 | [super viewDidLoad]; 48 | self.clearsSelectionOnViewWillAppear = NO; 49 | self.contentSizeForViewInPopover = CGSizeMake(320.0, 600.0); 50 | 51 | self.examples = [NSArray arrayWithObjects:[DiscreteGestures class], [ContinuousGestures class], [GestureInteraction class], nil]; 52 | } 53 | 54 | - (void)dealloc { 55 | [detailViewController_ release], detailViewController_ = nil; 56 | [examples_ release], examples_ = nil; 57 | [super dealloc]; 58 | } 59 | 60 | 61 | - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)orientation { 62 | return YES; 63 | } 64 | 65 | #pragma mark - 66 | #pragma mark Table view data source 67 | 68 | - (NSInteger)numberOfSectionsInTableView:(UITableView *)aTableView { 69 | return 1; 70 | } 71 | 72 | - (NSInteger)tableView:(UITableView *)aTableView numberOfRowsInSection:(NSInteger)section { 73 | return [self.examples count]; 74 | } 75 | 76 | 77 | - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { 78 | 79 | static NSString *CellIdentifier = @"CellIdentifier"; 80 | 81 | UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier]; 82 | if (cell == nil) { 83 | cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] autorelease]; 84 | cell.accessoryType = UITableViewCellAccessoryNone; 85 | } 86 | 87 | Class example = [self.examples objectAtIndex:indexPath.row]; 88 | 89 | cell.textLabel.text = [example friendlyName]; 90 | return cell; 91 | } 92 | 93 | #pragma mark - 94 | #pragma mark Table view delegate 95 | 96 | - (void)tableView:(UITableView *)aTableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath { 97 | Class exampleClass = [self.examples objectAtIndex:indexPath.row]; 98 | ExampleController *example = [[exampleClass alloc] initWithNibName:nil bundle:nil]; 99 | self.detailViewController.exampleController = example; 100 | [example release]; 101 | } 102 | 103 | @end 104 | -------------------------------------------------------------------------------- /Classes/DetailViewController.m: -------------------------------------------------------------------------------- 1 | /* 2 | The MIT License 3 | 4 | Copyright (c) 2010 Free Time Studios and Nathan Eror 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in 14 | all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 | THE SOFTWARE. 23 | */ 24 | 25 | #import "DetailViewController.h" 26 | #import "RootViewController.h" 27 | 28 | @interface DetailViewController() { 29 | } 30 | 31 | @property (nonatomic, retain) UIPopoverController *popoverController; 32 | 33 | - (void)handleLongPress:(UILongPressGestureRecognizer *)recognizer; 34 | - (void)resetCurrentExample; 35 | 36 | @end 37 | 38 | @implementation DetailViewController 39 | 40 | @synthesize toolbar = toolbar_; 41 | @synthesize popoverController = popoverController_; 42 | @synthesize exampleController = exampleController_; 43 | @synthesize contentView = contentView_; 44 | @synthesize titleLabel = titleLabel_; 45 | 46 | - (void)viewDidLoad { 47 | UILongPressGestureRecognizer *longPress = [[UILongPressGestureRecognizer alloc] initWithTarget:self action:@selector(handleLongPress:)]; 48 | [self.view addGestureRecognizer:longPress]; 49 | [longPress release]; 50 | } 51 | 52 | - (void)viewDidUnload { 53 | self.popoverController = nil; 54 | } 55 | 56 | - (void)dealloc { 57 | [popoverController_ release], popoverController_ = nil; 58 | [toolbar_ release], toolbar_ = nil; 59 | [exampleController_ release], exampleController_ = nil; 60 | [contentView_ release], contentView_ = nil; 61 | [titleLabel_ release], titleLabel_ = nil; 62 | [super dealloc]; 63 | } 64 | 65 | #pragma mark - 66 | #pragma mark Touch Gesture Handling 67 | 68 | - (void)handleLongPress:(UILongPressGestureRecognizer *)recognizer { 69 | if([recognizer state] == UIGestureRecognizerStateBegan) { 70 | UIMenuController *menuController = [UIMenuController sharedMenuController]; 71 | UIMenuItem *resetMenuItem = [[UIMenuItem alloc] initWithTitle:@"Reset Example" action:@selector(resetCurrentExample)]; 72 | CGPoint location = [recognizer locationInView:[recognizer view]]; 73 | 74 | [self.view becomeFirstResponder]; 75 | [menuController setMenuItems:[NSArray arrayWithObject:resetMenuItem]]; 76 | [menuController setTargetRect:CGRectMake(location.x, location.y, 0, 0) inView:[recognizer view]]; 77 | [menuController setMenuVisible:YES animated:YES]; 78 | [resetMenuItem release]; 79 | } 80 | } 81 | 82 | - (void)resetCurrentExample { 83 | [self.exampleController resetExample]; 84 | } 85 | 86 | #pragma mark - 87 | #pragma mark Managing the detail item 88 | 89 | - (void)setExampleController:(ExampleController *)newExample { 90 | if(exampleController_ != newExample) { 91 | [exampleController_ viewWillDisappear:YES]; 92 | [newExample viewWillAppear:YES]; 93 | 94 | ExampleController *currentController = exampleController_; 95 | 96 | newExample.view.alpha = 0.f; 97 | [UIView animateWithDuration:.25f animations:^{ 98 | [self.contentView insertSubview:newExample.view belowSubview:self.toolbar]; 99 | [self.titleLabel setText:[[newExample class] friendlyName]]; 100 | newExample.view.alpha = 1.f; 101 | currentController.view.alpha = 0.f; 102 | } completion:^(BOOL finished) { 103 | [currentController.view removeFromSuperview]; 104 | [currentController viewDidDisappear:YES]; 105 | [newExample viewDidAppear:YES]; 106 | }]; 107 | 108 | [exampleController_ release]; 109 | exampleController_ = [newExample retain]; 110 | } 111 | if (self.popoverController != nil) { 112 | [self.popoverController dismissPopoverAnimated:YES]; 113 | } 114 | } 115 | 116 | #pragma mark - 117 | #pragma mark Split view support 118 | 119 | - (void)splitViewController:(UISplitViewController*)svc 120 | willHideViewController:(UIViewController *)aViewController 121 | withBarButtonItem:(UIBarButtonItem*)barButtonItem 122 | forPopoverController:(UIPopoverController*)pc 123 | { 124 | 125 | barButtonItem.title = @"Gesture Examples"; 126 | NSMutableArray *items = [[self.toolbar items] mutableCopy]; 127 | [items insertObject:barButtonItem atIndex:0]; 128 | [self.toolbar setItems:items animated:YES]; 129 | [items release]; 130 | self.popoverController = pc; 131 | } 132 | 133 | - (void)splitViewController: (UISplitViewController*)svc 134 | willShowViewController:(UIViewController *)aViewController 135 | invalidatingBarButtonItem:(UIBarButtonItem *)barButtonItem 136 | { 137 | NSMutableArray *items = [[self.toolbar items] mutableCopy]; 138 | [items removeObjectAtIndex:0]; 139 | [self.toolbar setItems:items animated:YES]; 140 | [items release]; 141 | self.popoverController = nil; 142 | } 143 | 144 | 145 | #pragma mark - 146 | #pragma mark Rotation support 147 | 148 | - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)orientation { 149 | return YES; 150 | } 151 | 152 | @end 153 | 154 | @implementation DetailView 155 | 156 | - (BOOL)canBecomeFirstResponder { 157 | return YES; 158 | } 159 | 160 | @end 161 | -------------------------------------------------------------------------------- /Classes/DiscreteGestures.m: -------------------------------------------------------------------------------- 1 | /* 2 | The MIT License 3 | 4 | Copyright (c) 2010 Free Time Studios and Nathan Eror 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in 14 | all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 | THE SOFTWARE. 23 | */ 24 | 25 | #import "DiscreteGestures.h" 26 | 27 | @interface DiscreteGestures() { 28 | CAShapeLayer *eventIndicator_; 29 | } 30 | 31 | @property (readonly) CALayer *eventIndicator; 32 | 33 | - (void)handleSingleTap:(UITapGestureRecognizer *)recognizer; 34 | - (void)handleTwoFingerDoubleTap:(UITapGestureRecognizer *)recognizer; 35 | - (void)handleSwipeUpDown:(UISwipeGestureRecognizer *)recognizer; 36 | - (void)handleThreeFingerSwipe:(UISwipeGestureRecognizer *)recognizer; 37 | 38 | @end 39 | 40 | @implementation DiscreteGestures 41 | 42 | @synthesize eventTypeLabel = eventTypeLabel_; 43 | 44 | + (NSString *)friendlyName { 45 | return @"Discrete Gestures"; 46 | } 47 | 48 | - (void)dealloc { 49 | [eventIndicator_ release], eventIndicator_ = nil; 50 | [eventTypeLabel_ release], eventTypeLabel_ = nil; 51 | [super dealloc]; 52 | } 53 | 54 | - (CALayer *)eventIndicator { 55 | if(!eventIndicator_) { 56 | CGRect indicatorBounds = CGRectMake(0.f, 0.f, 50.f, 50.f); 57 | eventIndicator_ = [[CAShapeLayer alloc] init]; 58 | eventIndicator_.bounds = indicatorBounds; 59 | eventIndicator_.fillColor = [[UIColor orangeColor] CGColor]; 60 | eventIndicator_.lineWidth = 0.f; 61 | eventIndicator_.opacity = 0.f; 62 | CGMutablePathRef circle = CGPathCreateMutable(); 63 | CGPathAddEllipseInRect(circle, NULL, indicatorBounds); 64 | eventIndicator_.path = circle; 65 | CGPathRelease(circle); 66 | eventIndicator_.shouldRasterize = YES; 67 | } 68 | return eventIndicator_; 69 | } 70 | 71 | - (void)showEventIndicatorAtPoint:(CGPoint)point { 72 | [self.eventIndicator removeAllAnimations]; 73 | [CATransaction begin]; 74 | [CATransaction setAnimationDuration:.4f]; 75 | [CATransaction setDisableActions:YES]; 76 | 77 | self.eventIndicator.position = point; 78 | 79 | CABasicAnimation *scale = [CABasicAnimation animationWithKeyPath:@"transform.scale"]; 80 | scale.toValue = [NSNumber numberWithFloat:2.f]; 81 | [self.eventIndicator addAnimation:scale forKey:@"scale"]; 82 | 83 | CABasicAnimation *fade = [CABasicAnimation animationWithKeyPath:@"opacity"]; 84 | fade.fromValue = [NSNumber numberWithFloat:1.f]; 85 | [self.eventIndicator addAnimation:fade forKey:@"fade"]; 86 | 87 | [CATransaction commit]; 88 | } 89 | 90 | - (void)viewDidLoad { 91 | [super viewDidLoad]; 92 | [self.view.layer addSublayer:self.eventIndicator]; 93 | 94 | UITapGestureRecognizer *singleFingerTap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(handleSingleTap:)]; 95 | [self.view addGestureRecognizer:singleFingerTap]; 96 | [singleFingerTap release]; 97 | 98 | UITapGestureRecognizer *twoFingerDoubleTap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(handleTwoFingerDoubleTap:)]; 99 | twoFingerDoubleTap.numberOfTouchesRequired = 2; 100 | twoFingerDoubleTap.numberOfTapsRequired = 2; 101 | [self.view addGestureRecognizer:twoFingerDoubleTap]; 102 | [twoFingerDoubleTap release]; 103 | 104 | 105 | UISwipeGestureRecognizer *swipeUpDown = [[UISwipeGestureRecognizer alloc] initWithTarget:self action:@selector(handleSwipeUpDown:)]; 106 | swipeUpDown.direction = UISwipeGestureRecognizerDirectionUp | UISwipeGestureRecognizerDirectionDown; 107 | [self.view addGestureRecognizer:swipeUpDown]; 108 | [swipeUpDown release]; 109 | 110 | UISwipeGestureRecognizer *threeFingerSwipe = [[UISwipeGestureRecognizer alloc] initWithTarget:self action:@selector(handleThreeFingerSwipe:)]; 111 | threeFingerSwipe.direction = UISwipeGestureRecognizerDirectionLeft | UISwipeGestureRecognizerDirectionRight; 112 | threeFingerSwipe.numberOfTouchesRequired = 3; 113 | [self.view addGestureRecognizer:threeFingerSwipe]; 114 | [threeFingerSwipe release]; 115 | 116 | } 117 | 118 | #pragma mark - 119 | #pragma mark Gesture handlers 120 | 121 | - (void)handleSingleTap:(UITapGestureRecognizer *)recognizer { 122 | CGPoint location = [recognizer locationInView:[self.eventTypeLabel superview]]; 123 | self.eventTypeLabel.text = @"Single Finger Tap"; 124 | [self showEventIndicatorAtPoint:location]; 125 | } 126 | 127 | - (void)handleTwoFingerDoubleTap:(UITapGestureRecognizer *)recognizer { 128 | CGPoint location = [recognizer locationInView:[self.eventTypeLabel superview]]; 129 | self.eventTypeLabel.text = @"Two Finger Double Tap"; 130 | [self showEventIndicatorAtPoint:location]; 131 | } 132 | 133 | - (void)handleSwipeUpDown:(UISwipeGestureRecognizer *)recognizer { 134 | CGPoint location = [recognizer locationInView:[self.eventTypeLabel superview]]; 135 | self.eventTypeLabel.text = @"Swipe up or down"; 136 | [self showEventIndicatorAtPoint:location]; 137 | } 138 | 139 | 140 | - (void)handleThreeFingerSwipe:(UISwipeGestureRecognizer *)recognizer { 141 | CGPoint location = [recognizer locationInView:[self.eventTypeLabel superview]]; 142 | self.eventTypeLabel.text = @"Swipe left or right (3 fingers)"; 143 | [self showEventIndicatorAtPoint:location]; 144 | } 145 | 146 | @end 147 | -------------------------------------------------------------------------------- /Classes/GestureInteraction.m: -------------------------------------------------------------------------------- 1 | /* 2 | The MIT License 3 | 4 | Copyright (c) 2010 Free Time Studios and Nathan Eror 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in 14 | all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 | THE SOFTWARE. 23 | */ 24 | 25 | #import "GestureInteraction.h" 26 | 27 | @interface GestureInteraction() { 28 | NSDictionary *stateColorMap_; 29 | } 30 | 31 | @property (nonatomic, retain) CAShapeLayer *centroidLayer; 32 | 33 | - (void)handleTap:(UITapGestureRecognizer *)recognizer; 34 | - (void)handleSwipe:(UISwipeGestureRecognizer *)recognizer; 35 | - (void)handlePinch:(UIPinchGestureRecognizer *)recognizer; 36 | - (void)handlePan:(UIPanGestureRecognizer *)recognizer; 37 | 38 | @end 39 | 40 | @implementation GestureInteraction 41 | 42 | @synthesize tapLabel = tapLabel_; 43 | @synthesize swipeLabel = swipeLabel_; 44 | @synthesize containerView = containerView_; 45 | @synthesize centroidLayer = centroidLayer_; 46 | 47 | + (NSString *)friendlyName { 48 | return @"Gesture Interaction"; 49 | } 50 | 51 | - (void)dealloc { 52 | [tapLabel_ release], tapLabel_ = nil; 53 | [swipeLabel_ release], swipeLabel_ = nil; 54 | [stateColorMap_ release], stateColorMap_ = nil; 55 | [containerView_ release], containerView_ = nil; 56 | [centroidLayer_ release], centroidLayer_ = nil; 57 | [super dealloc]; 58 | } 59 | 60 | - (void)setupUI { 61 | [self.tapLabel.layer setBorderColor:[[UIColor blueColor] CGColor]]; 62 | [self.tapLabel.layer setBorderWidth:2.f]; 63 | 64 | [self.swipeLabel.layer setBorderColor:[[UIColor blueColor] CGColor]]; 65 | [self.swipeLabel.layer setBorderWidth:2.f]; 66 | 67 | CGRect centriodMarkerBounds = CGRectMake(0.f, 0.f, 40.f, 40.f); 68 | self.centroidLayer = [CAShapeLayer layer]; 69 | self.centroidLayer.bounds = centriodMarkerBounds; 70 | self.centroidLayer.fillColor = [[UIColor orangeColor] CGColor]; 71 | self.centroidLayer.lineWidth = 0.f; 72 | CGMutablePathRef circle = CGPathCreateMutable(); 73 | CGPathAddEllipseInRect(circle, NULL, centriodMarkerBounds); 74 | self.centroidLayer.path = circle; 75 | CGPathRelease(circle); 76 | self.centroidLayer.shouldRasterize = YES; 77 | } 78 | 79 | - (void)viewDidLoad { 80 | [super viewDidLoad]; 81 | 82 | stateColorMap_ = [[NSDictionary alloc] initWithObjectsAndKeys: 83 | [UIColor greenColor], [NSNumber numberWithInt:UIGestureRecognizerStateRecognized], 84 | [UIColor blueColor], [NSNumber numberWithInt:UIGestureRecognizerStateBegan], 85 | [UIColor blueColor], [NSNumber numberWithInt:UIGestureRecognizerStateChanged], 86 | [UIColor blackColor], [NSNumber numberWithInt:UIGestureRecognizerStateEnded], 87 | [UIColor redColor], [NSNumber numberWithInt:UIGestureRecognizerStateCancelled], 88 | nil]; 89 | 90 | [self setupUI]; 91 | 92 | UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(handleTap:)]; 93 | [self.tapLabel addGestureRecognizer:tap]; 94 | [tap release]; 95 | 96 | UISwipeGestureRecognizer *swipe = [[UISwipeGestureRecognizer alloc] initWithTarget:self action:@selector(handleSwipe:)]; 97 | [swipe setDirection:UISwipeGestureRecognizerDirectionRight | UISwipeGestureRecognizerDirectionLeft]; 98 | [self.swipeLabel addGestureRecognizer:swipe]; 99 | [swipe release]; 100 | 101 | UIPinchGestureRecognizer *pinch = [[UIPinchGestureRecognizer alloc] initWithTarget:self action:@selector(handlePinch:)]; 102 | pinch.delegate = self; 103 | [self.containerView addGestureRecognizer:pinch]; 104 | [pinch release]; 105 | 106 | UIPanGestureRecognizer *panContainerView = [[UIPanGestureRecognizer alloc] initWithTarget:self action:@selector(handlePan:)]; 107 | panContainerView.delegate = self; 108 | [panContainerView requireGestureRecognizerToFail:swipe]; 109 | [self.containerView addGestureRecognizer:panContainerView]; 110 | [panContainerView release]; 111 | 112 | 113 | UIPanGestureRecognizer *panMainView = [[UIPanGestureRecognizer alloc] initWithTarget:self action:@selector(handlePan:)]; 114 | [self.view addGestureRecognizer:panMainView]; 115 | [panMainView release]; 116 | 117 | 118 | } 119 | 120 | - (void)viewDidUnload { 121 | self.centroidLayer = nil; 122 | [super viewDidUnload]; 123 | } 124 | 125 | 126 | - (void)resetExample { 127 | self.tapLabel.backgroundColor = [UIColor blackColor]; 128 | self.swipeLabel.backgroundColor = [UIColor blackColor]; 129 | self.containerView.backgroundColor = [UIColor blackColor]; 130 | self.containerView.transform = CGAffineTransformIdentity; 131 | self.view.backgroundColor = [UIColor whiteColor]; 132 | } 133 | 134 | #pragma mark - 135 | #pragma mark Tap 136 | 137 | - (void)handleTap:(UITapGestureRecognizer *)recognizer { 138 | [[recognizer view] setBackgroundColor:[stateColorMap_ objectForKey:[NSNumber numberWithInt:[recognizer state]]]]; 139 | } 140 | 141 | - (void)handleSwipe:(UISwipeGestureRecognizer *)recognizer { 142 | [[recognizer view] setBackgroundColor:[stateColorMap_ objectForKey:[NSNumber numberWithInt:[recognizer state]]]]; 143 | } 144 | 145 | - (void)handlePinch:(UIPinchGestureRecognizer *)recognizer { 146 | [[recognizer view] setBackgroundColor:[stateColorMap_ objectForKey:[NSNumber numberWithInt:[recognizer state]]]]; 147 | if([recognizer state] == UIGestureRecognizerStateBegan || [recognizer state] == UIGestureRecognizerStateChanged) { 148 | [recognizer view].transform = CGAffineTransformScale([[recognizer view] transform], [recognizer scale], [recognizer scale]); 149 | [recognizer setScale:1]; 150 | } 151 | } 152 | 153 | - (void)handlePan:(UIPanGestureRecognizer *)recognizer { 154 | [[recognizer view] setBackgroundColor:[stateColorMap_ objectForKey:[NSNumber numberWithInt:[recognizer state]]]]; 155 | if([recognizer state] == UIGestureRecognizerStateBegan) { 156 | [self.view.layer addSublayer:self.centroidLayer]; 157 | } 158 | if([recognizer state] == UIGestureRecognizerStateChanged || [recognizer state] == UIGestureRecognizerStateBegan) { 159 | [CATransaction begin]; 160 | [CATransaction setDisableActions:YES]; 161 | self.centroidLayer.position = [recognizer locationInView:self.view]; 162 | [CATransaction commit]; 163 | } 164 | if([recognizer state] == UIGestureRecognizerStateEnded) { 165 | [self.centroidLayer removeFromSuperlayer]; 166 | } 167 | } 168 | 169 | #pragma mark - 170 | #pragma mark Gesture Recognizer delegate 171 | 172 | - (BOOL)gestureRecognizer:(UIGestureRecognizer *)recognizer shouldRecognizeSimultaneouslyWithGestureRecognizer:(UIGestureRecognizer *)other { 173 | return ([recognizer view] == [other view]); 174 | } 175 | 176 | @end 177 | -------------------------------------------------------------------------------- /Classes/ContinuousGestures.m: -------------------------------------------------------------------------------- 1 | /* 2 | The MIT License 3 | 4 | Copyright (c) 2010 Free Time Studios and Nathan Eror 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in 14 | all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 | THE SOFTWARE. 23 | */ 24 | 25 | #import "ContinuousGestures.h" 26 | 27 | @interface ContinuousGestures() 28 | 29 | - (void)addGestureRecognizersToView:(UIView *)theView; 30 | - (void)adjustAnchorPointForGestureRecognizer:(UIGestureRecognizer *)recognizer; 31 | - (void)handlePan:(UIPanGestureRecognizer *)recognizer; 32 | - (void)handleRotate:(UIRotationGestureRecognizer *)recognizer; 33 | - (void)handleScale:(UIPinchGestureRecognizer *)recognizer; 34 | - (void)handleDoubleTap:(UITapGestureRecognizer *)recognizer; 35 | - (void)handleTwoFingerTap:(UITapGestureRecognizer *)recognizer; 36 | 37 | @end 38 | 39 | 40 | @implementation ContinuousGestures 41 | 42 | @synthesize redView = redView_; 43 | @synthesize greenView = greenView_; 44 | @synthesize blueView = blueView_; 45 | @synthesize orangeView = orangeView_; 46 | 47 | + (NSString *)friendlyName { 48 | return @"Continuous Gestures"; 49 | } 50 | 51 | - (void)viewDidLoad { 52 | [super viewDidLoad]; 53 | [self addGestureRecognizersToView:self.redView]; 54 | [self addGestureRecognizersToView:self.greenView]; 55 | [self addGestureRecognizersToView:self.blueView]; 56 | [self addGestureRecognizersToView:self.orangeView]; 57 | 58 | UITapGestureRecognizer *doubleTap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(handleDoubleTap:)]; 59 | doubleTap.numberOfTapsRequired = 2; 60 | [self.view addGestureRecognizer:doubleTap]; 61 | [doubleTap release]; 62 | 63 | 64 | UITapGestureRecognizer *twoFingerTap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(handleTwoFingerTap:)]; 65 | twoFingerTap.numberOfTouchesRequired = 2; 66 | [self.view addGestureRecognizer:twoFingerTap]; 67 | [twoFingerTap release]; 68 | 69 | } 70 | 71 | - (void)dealloc { 72 | [redView_ release], redView_ = nil; 73 | [greenView_ release], greenView_ = nil; 74 | [blueView_ release], blueView_ = nil; 75 | [orangeView_ release], orangeView_ = nil; 76 | [super dealloc]; 77 | } 78 | 79 | - (void)resetExample { 80 | CGPoint defaultAnchorPoint = CGPointMake(.5f, .5f); 81 | NSArray *views = [NSArray arrayWithObjects:self.redView, self.greenView, self.blueView, self.orangeView, nil]; 82 | [UIView animateWithDuration:.3f animations:^{ 83 | self.view.transform = CGAffineTransformIdentity; 84 | [views enumerateObjectsUsingBlock:^(id obj, NSUInteger idx, BOOL *stop) { 85 | UIView *theView = (UIView *)obj; 86 | theView.transform = CGAffineTransformIdentity; 87 | theView.layer.anchorPoint = defaultAnchorPoint; 88 | NSValue *originalCenter = [theView.layer valueForKey:@"originalCenter"]; 89 | if(originalCenter) { 90 | theView.center = [originalCenter CGPointValue]; 91 | } 92 | }]; 93 | }]; 94 | } 95 | 96 | - (void)adjustAnchorPointForGestureRecognizer:(UIGestureRecognizer *)recognizer { 97 | if (recognizer.state == UIGestureRecognizerStateBegan) { 98 | CGPoint locationInView = [recognizer locationInView:recognizer.view]; 99 | CGPoint locationInSuperview = [recognizer locationInView:recognizer.view.superview]; 100 | CGSize viewSize = recognizer.view.bounds.size; 101 | 102 | recognizer.view.layer.anchorPoint = CGPointMake(locationInView.x / viewSize.width, locationInView.y / viewSize.height); 103 | recognizer.view.layer.position = locationInSuperview; 104 | } 105 | } 106 | 107 | 108 | - (void)addGestureRecognizersToView:(UIView *)theView { 109 | 110 | UIRotationGestureRecognizer *rotationGesture = [[UIRotationGestureRecognizer alloc] initWithTarget:self action:@selector(handleRotate:)]; 111 | rotationGesture.delegate = self; 112 | [theView addGestureRecognizer:rotationGesture]; 113 | [rotationGesture release]; 114 | 115 | UIPinchGestureRecognizer *pinchGesture = [[UIPinchGestureRecognizer alloc] initWithTarget:self action:@selector(handleScale:)]; 116 | pinchGesture.delegate = self; 117 | [theView addGestureRecognizer:pinchGesture]; 118 | [pinchGesture release]; 119 | 120 | UIPanGestureRecognizer *panGesture = [[UIPanGestureRecognizer alloc] initWithTarget:self action:@selector(handlePan:)]; 121 | [panGesture setMaximumNumberOfTouches:2]; 122 | panGesture.delegate = self; 123 | [theView addGestureRecognizer:panGesture]; 124 | [panGesture release]; 125 | [theView.layer setValue:[NSValue valueWithCGPoint:theView.center] forKey:@"originalCenter"]; 126 | } 127 | 128 | - (void)handlePan:(UIPanGestureRecognizer *)recognizer { 129 | if(recognizer.state == UIGestureRecognizerStateBegan || 130 | recognizer.state == UIGestureRecognizerStateChanged) { 131 | CGPoint translation = [recognizer translationInView:recognizer.view.superview]; 132 | 133 | recognizer.view.center = 134 | CGPointMake(recognizer.view.center.x + translation.x, 135 | recognizer.view.center.y + translation.y); 136 | [recognizer setTranslation:CGPointZero inView:recognizer.view.superview]; 137 | } 138 | } 139 | 140 | 141 | - (void)handleRotate:(UIRotationGestureRecognizer *)recognizer { 142 | [self adjustAnchorPointForGestureRecognizer:recognizer]; 143 | if(recognizer.state == UIGestureRecognizerStateBegan || 144 | recognizer.state == UIGestureRecognizerStateChanged) { 145 | recognizer.view.transform = CGAffineTransformRotate(recognizer.view.transform, recognizer.rotation); 146 | [recognizer setRotation:0]; 147 | } 148 | } 149 | 150 | - (void)handleScale:(UIPinchGestureRecognizer *)recognizer { 151 | [self adjustAnchorPointForGestureRecognizer:recognizer]; 152 | if ([recognizer state] == UIGestureRecognizerStateBegan || 153 | [recognizer state] == UIGestureRecognizerStateChanged) { 154 | recognizer.view.transform = CGAffineTransformScale(recognizer.view.transform, recognizer.scale, recognizer.scale); 155 | [recognizer setScale:1]; 156 | } 157 | 158 | } 159 | 160 | - (void)handleDoubleTap:(UITapGestureRecognizer *)recognizer { 161 | [self adjustAnchorPointForGestureRecognizer:recognizer]; 162 | [UIView animateWithDuration:.2f animations:^{ 163 | recognizer.view.transform = CGAffineTransformScale(self.view.transform, 1.5f, 1.5f); 164 | }]; 165 | } 166 | 167 | 168 | - (void)handleTwoFingerTap:(UITapGestureRecognizer *)recognizer { 169 | recognizer.view.layer.anchorPoint = CGPointMake(.5f, .5f); 170 | [UIView animateWithDuration:.2f animations:^{ 171 | recognizer.view.transform = CGAffineTransformIdentity; 172 | }]; 173 | } 174 | 175 | 176 | - (BOOL)gestureRecognizer:(UIGestureRecognizer *)recognizer shouldRecognizeSimultaneouslyWithGestureRecognizer:(UIGestureRecognizer *)other { 177 | return YES; 178 | } 179 | 180 | @end -------------------------------------------------------------------------------- /UIGestureExamples.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 1D3623260D0F684500981E51 /* UIGestureExamplesAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 1D3623250D0F684500981E51 /* UIGestureExamplesAppDelegate.m */; }; 11 | 1D60589B0D05DD56006BFB54 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 29B97316FDCFA39411CA2CEA /* main.m */; }; 12 | 1D60589F0D05DD5A006BFB54 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1D30AB110D05D00D00671497 /* Foundation.framework */; }; 13 | 1DF5F4E00D08C38300B7A737 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1DF5F4DF0D08C38300B7A737 /* UIKit.framework */; }; 14 | 2804200B108E984D000629CD /* RootViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 28042008108E984D000629CD /* RootViewController.m */; }; 15 | 2804200C108E984D000629CD /* DetailViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2804200A108E984D000629CD /* DetailViewController.m */; }; 16 | 2804203C108E9BAB000629CD /* DetailView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 2804203B108E9BAB000629CD /* DetailView.xib */; }; 17 | 2892E4100DC94CBA00A64D0F /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2892E40F0DC94CBA00A64D0F /* CoreGraphics.framework */; }; 18 | 28AD73600D9D9599002E5188 /* MainWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = 28AD735F0D9D9599002E5188 /* MainWindow.xib */; }; 19 | DF5A11B71285B61B0034A491 /* ExampleController.m in Sources */ = {isa = PBXBuildFile; fileRef = DF5A11B61285B61B0034A491 /* ExampleController.m */; }; 20 | DF5A11CF1285B8250034A491 /* GestureInteraction.m in Sources */ = {isa = PBXBuildFile; fileRef = DF5A11CD1285B8250034A491 /* GestureInteraction.m */; }; 21 | DF5A11D01285B8250034A491 /* GestureInteraction.xib in Resources */ = {isa = PBXBuildFile; fileRef = DF5A11CE1285B8250034A491 /* GestureInteraction.xib */; }; 22 | DF5A127F1285C6FA0034A491 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DF5A127E1285C6FA0034A491 /* QuartzCore.framework */; }; 23 | DF6DD39512872D3500158FB2 /* DiscreteGestures.m in Sources */ = {isa = PBXBuildFile; fileRef = DF6DD39312872D3500158FB2 /* DiscreteGestures.m */; }; 24 | DF6DD39612872D3500158FB2 /* DiscreteGestures.xib in Resources */ = {isa = PBXBuildFile; fileRef = DF6DD39412872D3500158FB2 /* DiscreteGestures.xib */; }; 25 | DF6DD4EF12874F5600158FB2 /* ContinuousGestures.m in Sources */ = {isa = PBXBuildFile; fileRef = DF6DD4ED12874F5600158FB2 /* ContinuousGestures.m */; }; 26 | DF6DD4F012874F5600158FB2 /* ContinuousGestures.xib in Resources */ = {isa = PBXBuildFile; fileRef = DF6DD4EE12874F5600158FB2 /* ContinuousGestures.xib */; }; 27 | /* End PBXBuildFile section */ 28 | 29 | /* Begin PBXFileReference section */ 30 | 1D30AB110D05D00D00671497 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; }; 31 | 1D3623240D0F684500981E51 /* UIGestureExamplesAppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIGestureExamplesAppDelegate.h; sourceTree = ""; }; 32 | 1D3623250D0F684500981E51 /* UIGestureExamplesAppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UIGestureExamplesAppDelegate.m; sourceTree = ""; }; 33 | 1D6058910D05DD3D006BFB54 /* UIGestureExamples.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = UIGestureExamples.app; sourceTree = BUILT_PRODUCTS_DIR; }; 34 | 1DF5F4DF0D08C38300B7A737 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; }; 35 | 28042007108E984D000629CD /* RootViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RootViewController.h; sourceTree = ""; }; 36 | 28042008108E984D000629CD /* RootViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RootViewController.m; sourceTree = ""; }; 37 | 28042009108E984D000629CD /* DetailViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DetailViewController.h; sourceTree = ""; }; 38 | 2804200A108E984D000629CD /* DetailViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = DetailViewController.m; sourceTree = ""; }; 39 | 2804203B108E9BAB000629CD /* DetailView.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = DetailView.xib; sourceTree = ""; }; 40 | 2892E40F0DC94CBA00A64D0F /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; }; 41 | 28A0AAE50D9B0CCF005BE974 /* UIGestureExamples_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIGestureExamples_Prefix.pch; sourceTree = ""; }; 42 | 28AD735F0D9D9599002E5188 /* MainWindow.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = MainWindow.xib; sourceTree = ""; }; 43 | 29B97316FDCFA39411CA2CEA /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; 44 | 8D1107310486CEB800E47090 /* UIGestureExamples-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "UIGestureExamples-Info.plist"; plistStructureDefinitionIdentifier = "com.apple.xcode.plist.structure-definition.iphone.info-plist"; sourceTree = ""; }; 45 | DF5A11B51285B61B0034A491 /* ExampleController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ExampleController.h; sourceTree = ""; }; 46 | DF5A11B61285B61B0034A491 /* ExampleController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ExampleController.m; sourceTree = ""; }; 47 | DF5A11CC1285B8250034A491 /* GestureInteraction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GestureInteraction.h; path = Classes/GestureInteraction.h; sourceTree = ""; }; 48 | DF5A11CD1285B8250034A491 /* GestureInteraction.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = GestureInteraction.m; path = Classes/GestureInteraction.m; sourceTree = ""; }; 49 | DF5A11CE1285B8250034A491 /* GestureInteraction.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = GestureInteraction.xib; path = Classes/GestureInteraction.xib; sourceTree = ""; }; 50 | DF5A127E1285C6FA0034A491 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; 51 | DF6DD39212872D3500158FB2 /* DiscreteGestures.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DiscreteGestures.h; path = Classes/DiscreteGestures.h; sourceTree = ""; }; 52 | DF6DD39312872D3500158FB2 /* DiscreteGestures.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = DiscreteGestures.m; path = Classes/DiscreteGestures.m; sourceTree = ""; }; 53 | DF6DD39412872D3500158FB2 /* DiscreteGestures.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = DiscreteGestures.xib; path = Classes/DiscreteGestures.xib; sourceTree = ""; }; 54 | DF6DD4EC12874F5600158FB2 /* ContinuousGestures.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ContinuousGestures.h; path = Classes/ContinuousGestures.h; sourceTree = ""; }; 55 | DF6DD4ED12874F5600158FB2 /* ContinuousGestures.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = ContinuousGestures.m; path = Classes/ContinuousGestures.m; sourceTree = ""; }; 56 | DF6DD4EE12874F5600158FB2 /* ContinuousGestures.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = ContinuousGestures.xib; path = Classes/ContinuousGestures.xib; sourceTree = ""; }; 57 | /* End PBXFileReference section */ 58 | 59 | /* Begin PBXFrameworksBuildPhase section */ 60 | 1D60588F0D05DD3D006BFB54 /* Frameworks */ = { 61 | isa = PBXFrameworksBuildPhase; 62 | buildActionMask = 2147483647; 63 | files = ( 64 | 1D60589F0D05DD5A006BFB54 /* Foundation.framework in Frameworks */, 65 | 1DF5F4E00D08C38300B7A737 /* UIKit.framework in Frameworks */, 66 | 2892E4100DC94CBA00A64D0F /* CoreGraphics.framework in Frameworks */, 67 | DF5A127F1285C6FA0034A491 /* QuartzCore.framework in Frameworks */, 68 | ); 69 | runOnlyForDeploymentPostprocessing = 0; 70 | }; 71 | /* End PBXFrameworksBuildPhase section */ 72 | 73 | /* Begin PBXGroup section */ 74 | 080E96DDFE201D6D7F000001 /* Classes */ = { 75 | isa = PBXGroup; 76 | children = ( 77 | 1D3623240D0F684500981E51 /* UIGestureExamplesAppDelegate.h */, 78 | 1D3623250D0F684500981E51 /* UIGestureExamplesAppDelegate.m */, 79 | 28042007108E984D000629CD /* RootViewController.h */, 80 | 28042008108E984D000629CD /* RootViewController.m */, 81 | 28042009108E984D000629CD /* DetailViewController.h */, 82 | 2804200A108E984D000629CD /* DetailViewController.m */, 83 | DF5A11B51285B61B0034A491 /* ExampleController.h */, 84 | DF5A11B61285B61B0034A491 /* ExampleController.m */, 85 | ); 86 | path = Classes; 87 | sourceTree = ""; 88 | }; 89 | 19C28FACFE9D520D11CA2CBB /* Products */ = { 90 | isa = PBXGroup; 91 | children = ( 92 | 1D6058910D05DD3D006BFB54 /* UIGestureExamples.app */, 93 | ); 94 | name = Products; 95 | sourceTree = ""; 96 | }; 97 | 29B97314FDCFA39411CA2CEA /* CustomTemplate */ = { 98 | isa = PBXGroup; 99 | children = ( 100 | DF8C2C5E1285AA1F00061AC4 /* Examples */, 101 | 080E96DDFE201D6D7F000001 /* Classes */, 102 | 29B97315FDCFA39411CA2CEA /* Other Sources */, 103 | 29B97317FDCFA39411CA2CEA /* Resources */, 104 | 29B97323FDCFA39411CA2CEA /* Frameworks */, 105 | 19C28FACFE9D520D11CA2CBB /* Products */, 106 | ); 107 | name = CustomTemplate; 108 | sourceTree = ""; 109 | }; 110 | 29B97315FDCFA39411CA2CEA /* Other Sources */ = { 111 | isa = PBXGroup; 112 | children = ( 113 | 28A0AAE50D9B0CCF005BE974 /* UIGestureExamples_Prefix.pch */, 114 | 29B97316FDCFA39411CA2CEA /* main.m */, 115 | ); 116 | name = "Other Sources"; 117 | sourceTree = ""; 118 | }; 119 | 29B97317FDCFA39411CA2CEA /* Resources */ = { 120 | isa = PBXGroup; 121 | children = ( 122 | 28AD735F0D9D9599002E5188 /* MainWindow.xib */, 123 | 2804203B108E9BAB000629CD /* DetailView.xib */, 124 | 8D1107310486CEB800E47090 /* UIGestureExamples-Info.plist */, 125 | ); 126 | name = Resources; 127 | sourceTree = ""; 128 | }; 129 | 29B97323FDCFA39411CA2CEA /* Frameworks */ = { 130 | isa = PBXGroup; 131 | children = ( 132 | DF5A127E1285C6FA0034A491 /* QuartzCore.framework */, 133 | 1DF5F4DF0D08C38300B7A737 /* UIKit.framework */, 134 | 1D30AB110D05D00D00671497 /* Foundation.framework */, 135 | 2892E40F0DC94CBA00A64D0F /* CoreGraphics.framework */, 136 | ); 137 | name = Frameworks; 138 | sourceTree = ""; 139 | }; 140 | DF6DD38B12872CBE00158FB2 /* Basic Gestures */ = { 141 | isa = PBXGroup; 142 | children = ( 143 | DF6DD39212872D3500158FB2 /* DiscreteGestures.h */, 144 | DF6DD39312872D3500158FB2 /* DiscreteGestures.m */, 145 | DF6DD39412872D3500158FB2 /* DiscreteGestures.xib */, 146 | DF6DD4EC12874F5600158FB2 /* ContinuousGestures.h */, 147 | DF6DD4ED12874F5600158FB2 /* ContinuousGestures.m */, 148 | DF6DD4EE12874F5600158FB2 /* ContinuousGestures.xib */, 149 | ); 150 | name = "Basic Gestures"; 151 | sourceTree = ""; 152 | }; 153 | DF6DD38C12872CC800158FB2 /* Gesture Interaction */ = { 154 | isa = PBXGroup; 155 | children = ( 156 | DF5A11CC1285B8250034A491 /* GestureInteraction.h */, 157 | DF5A11CD1285B8250034A491 /* GestureInteraction.m */, 158 | DF5A11CE1285B8250034A491 /* GestureInteraction.xib */, 159 | ); 160 | name = "Gesture Interaction"; 161 | sourceTree = ""; 162 | }; 163 | DF8C2C5E1285AA1F00061AC4 /* Examples */ = { 164 | isa = PBXGroup; 165 | children = ( 166 | DF6DD38B12872CBE00158FB2 /* Basic Gestures */, 167 | DF6DD38C12872CC800158FB2 /* Gesture Interaction */, 168 | ); 169 | name = Examples; 170 | sourceTree = ""; 171 | }; 172 | /* End PBXGroup section */ 173 | 174 | /* Begin PBXNativeTarget section */ 175 | 1D6058900D05DD3D006BFB54 /* UIGestureExamples */ = { 176 | isa = PBXNativeTarget; 177 | buildConfigurationList = 1D6058960D05DD3E006BFB54 /* Build configuration list for PBXNativeTarget "UIGestureExamples" */; 178 | buildPhases = ( 179 | 1D60588D0D05DD3D006BFB54 /* Resources */, 180 | 1D60588E0D05DD3D006BFB54 /* Sources */, 181 | 1D60588F0D05DD3D006BFB54 /* Frameworks */, 182 | ); 183 | buildRules = ( 184 | ); 185 | dependencies = ( 186 | ); 187 | name = UIGestureExamples; 188 | productName = UIGestureExamples; 189 | productReference = 1D6058910D05DD3D006BFB54 /* UIGestureExamples.app */; 190 | productType = "com.apple.product-type.application"; 191 | }; 192 | /* End PBXNativeTarget section */ 193 | 194 | /* Begin PBXProject section */ 195 | 29B97313FDCFA39411CA2CEA /* Project object */ = { 196 | isa = PBXProject; 197 | buildConfigurationList = C01FCF4E08A954540054247B /* Build configuration list for PBXProject "UIGestureExamples" */; 198 | compatibilityVersion = "Xcode 3.2"; 199 | developmentRegion = English; 200 | hasScannedForEncodings = 1; 201 | knownRegions = ( 202 | English, 203 | Japanese, 204 | French, 205 | German, 206 | en, 207 | ); 208 | mainGroup = 29B97314FDCFA39411CA2CEA /* CustomTemplate */; 209 | projectDirPath = ""; 210 | projectRoot = ""; 211 | targets = ( 212 | 1D6058900D05DD3D006BFB54 /* UIGestureExamples */, 213 | ); 214 | }; 215 | /* End PBXProject section */ 216 | 217 | /* Begin PBXResourcesBuildPhase section */ 218 | 1D60588D0D05DD3D006BFB54 /* Resources */ = { 219 | isa = PBXResourcesBuildPhase; 220 | buildActionMask = 2147483647; 221 | files = ( 222 | 28AD73600D9D9599002E5188 /* MainWindow.xib in Resources */, 223 | 2804203C108E9BAB000629CD /* DetailView.xib in Resources */, 224 | DF5A11D01285B8250034A491 /* GestureInteraction.xib in Resources */, 225 | DF6DD39612872D3500158FB2 /* DiscreteGestures.xib in Resources */, 226 | DF6DD4F012874F5600158FB2 /* ContinuousGestures.xib in Resources */, 227 | ); 228 | runOnlyForDeploymentPostprocessing = 0; 229 | }; 230 | /* End PBXResourcesBuildPhase section */ 231 | 232 | /* Begin PBXSourcesBuildPhase section */ 233 | 1D60588E0D05DD3D006BFB54 /* Sources */ = { 234 | isa = PBXSourcesBuildPhase; 235 | buildActionMask = 2147483647; 236 | files = ( 237 | 1D60589B0D05DD56006BFB54 /* main.m in Sources */, 238 | 1D3623260D0F684500981E51 /* UIGestureExamplesAppDelegate.m in Sources */, 239 | 2804200B108E984D000629CD /* RootViewController.m in Sources */, 240 | 2804200C108E984D000629CD /* DetailViewController.m in Sources */, 241 | DF5A11B71285B61B0034A491 /* ExampleController.m in Sources */, 242 | DF5A11CF1285B8250034A491 /* GestureInteraction.m in Sources */, 243 | DF6DD39512872D3500158FB2 /* DiscreteGestures.m in Sources */, 244 | DF6DD4EF12874F5600158FB2 /* ContinuousGestures.m in Sources */, 245 | ); 246 | runOnlyForDeploymentPostprocessing = 0; 247 | }; 248 | /* End PBXSourcesBuildPhase section */ 249 | 250 | /* Begin XCBuildConfiguration section */ 251 | 1D6058940D05DD3E006BFB54 /* Debug */ = { 252 | isa = XCBuildConfiguration; 253 | buildSettings = { 254 | ALWAYS_SEARCH_USER_PATHS = NO; 255 | COPY_PHASE_STRIP = NO; 256 | GCC_DYNAMIC_NO_PIC = NO; 257 | GCC_OPTIMIZATION_LEVEL = 0; 258 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 259 | GCC_PREFIX_HEADER = UIGestureExamples_Prefix.pch; 260 | GCC_VERSION = com.apple.compilers.llvm.clang.1_0; 261 | INFOPLIST_FILE = "UIGestureExamples-Info.plist"; 262 | PRODUCT_NAME = UIGestureExamples; 263 | RUN_CLANG_STATIC_ANALYZER = YES; 264 | }; 265 | name = Debug; 266 | }; 267 | 1D6058950D05DD3E006BFB54 /* Release */ = { 268 | isa = XCBuildConfiguration; 269 | buildSettings = { 270 | ALWAYS_SEARCH_USER_PATHS = NO; 271 | COPY_PHASE_STRIP = YES; 272 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 273 | GCC_PREFIX_HEADER = UIGestureExamples_Prefix.pch; 274 | GCC_VERSION = com.apple.compilers.llvm.clang.1_0; 275 | INFOPLIST_FILE = "UIGestureExamples-Info.plist"; 276 | PRODUCT_NAME = UIGestureExamples; 277 | RUN_CLANG_STATIC_ANALYZER = YES; 278 | VALIDATE_PRODUCT = YES; 279 | }; 280 | name = Release; 281 | }; 282 | C01FCF4F08A954540054247B /* Debug */ = { 283 | isa = XCBuildConfiguration; 284 | buildSettings = { 285 | ARCHS = "$(ARCHS_UNIVERSAL_IPHONE_OS)"; 286 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 287 | GCC_C_LANGUAGE_STANDARD = c99; 288 | GCC_VERSION = com.apple.compilers.llvm.clang.1_0; 289 | GCC_WARN_ABOUT_RETURN_TYPE = YES; 290 | GCC_WARN_UNUSED_VARIABLE = YES; 291 | PREBINDING = NO; 292 | RUN_CLANG_STATIC_ANALYZER = YES; 293 | SDKROOT = iphoneos; 294 | TARGETED_DEVICE_FAMILY = 2; 295 | }; 296 | name = Debug; 297 | }; 298 | C01FCF5008A954540054247B /* Release */ = { 299 | isa = XCBuildConfiguration; 300 | buildSettings = { 301 | ARCHS = "$(ARCHS_UNIVERSAL_IPHONE_OS)"; 302 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 303 | GCC_C_LANGUAGE_STANDARD = c99; 304 | GCC_VERSION = com.apple.compilers.llvm.clang.1_0; 305 | GCC_WARN_ABOUT_RETURN_TYPE = YES; 306 | GCC_WARN_UNUSED_VARIABLE = YES; 307 | OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1"; 308 | PREBINDING = NO; 309 | RUN_CLANG_STATIC_ANALYZER = YES; 310 | SDKROOT = iphoneos; 311 | TARGETED_DEVICE_FAMILY = 2; 312 | }; 313 | name = Release; 314 | }; 315 | /* End XCBuildConfiguration section */ 316 | 317 | /* Begin XCConfigurationList section */ 318 | 1D6058960D05DD3E006BFB54 /* Build configuration list for PBXNativeTarget "UIGestureExamples" */ = { 319 | isa = XCConfigurationList; 320 | buildConfigurations = ( 321 | 1D6058940D05DD3E006BFB54 /* Debug */, 322 | 1D6058950D05DD3E006BFB54 /* Release */, 323 | ); 324 | defaultConfigurationIsVisible = 0; 325 | defaultConfigurationName = Release; 326 | }; 327 | C01FCF4E08A954540054247B /* Build configuration list for PBXProject "UIGestureExamples" */ = { 328 | isa = XCConfigurationList; 329 | buildConfigurations = ( 330 | C01FCF4F08A954540054247B /* Debug */, 331 | C01FCF5008A954540054247B /* Release */, 332 | ); 333 | defaultConfigurationIsVisible = 0; 334 | defaultConfigurationName = Release; 335 | }; 336 | /* End XCConfigurationList section */ 337 | }; 338 | rootObject = 29B97313FDCFA39411CA2CEA /* Project object */; 339 | } 340 | -------------------------------------------------------------------------------- /Classes/DiscreteGestures.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1056 5 | 10J567 6 | 844 7 | 1038.35 8 | 462.00 9 | 10 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 11 | 141 12 | 13 | 14 | YES 15 | 16 | 17 | YES 18 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 19 | 20 | 21 | YES 22 | 23 | YES 24 | 25 | 26 | YES 27 | 28 | 29 | 30 | YES 31 | 32 | IBFilesOwner 33 | IBIPadFramework 34 | 35 | 36 | IBFirstResponder 37 | IBIPadFramework 38 | 39 | 40 | 41 | 292 42 | 43 | YES 44 | 45 | 46 | 290 47 | {{20, 20}, {728, 30}} 48 | 49 | NO 50 | YES 51 | 7 52 | NO 53 | IBIPadFramework 54 | 55 | 56 | Helvetica-Bold 57 | 24 58 | 16 59 | 60 | 61 | 1 62 | MCAwIDAAA 63 | 64 | 65 | 3 66 | MQA 67 | 68 | 1 69 | 10 70 | 1 71 | 72 | 73 | {768, 1004} 74 | 75 | 3 76 | MQA 77 | 78 | 2 79 | 80 | 81 | NO 82 | 83 | 2 84 | 85 | 86 | IBUISplitViewController 87 | 88 | IBUISplitViewControllerContentSizeLocation 89 | IBUISplitViewControllerContentSizeLocationDetail 90 | 91 | IBIPadFramework 92 | Detail 93 | 94 | IBIPadFramework 95 | 96 | 97 | 98 | 99 | YES 100 | 101 | 102 | view 103 | 104 | 105 | 106 | 3 107 | 108 | 109 | 110 | eventTypeLabel_ 111 | 112 | 113 | 114 | 14 115 | 116 | 117 | 118 | 119 | YES 120 | 121 | 0 122 | 123 | 124 | 125 | 126 | 127 | -1 128 | 129 | 130 | File's Owner 131 | 132 | 133 | -2 134 | 135 | 136 | 137 | 138 | 2 139 | 140 | 141 | YES 142 | 143 | 144 | 145 | 146 | 147 | 12 148 | 149 | 150 | 151 | 152 | 153 | 154 | YES 155 | 156 | YES 157 | -1.CustomClassName 158 | -2.CustomClassName 159 | 12.IBEditorWindowLastContentRect 160 | 12.IBPluginDependency 161 | 12.IBViewBoundsToFrameTransform 162 | 2.IBEditorWindowLastContentRect 163 | 2.IBPluginDependency 164 | 165 | 166 | YES 167 | DiscreteGestures 168 | UIResponder 169 | {{0, 935}, {300, 60}} 170 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 171 | 172 | P4AAAL+AAABCqAAAw/oAAA 173 | 174 | {{285, 4}, {783, 1002}} 175 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 176 | 177 | 178 | 179 | YES 180 | 181 | 182 | YES 183 | 184 | 185 | 186 | 187 | YES 188 | 189 | 190 | YES 191 | 192 | 193 | 194 | 14 195 | 196 | 197 | 198 | YES 199 | 200 | DiscreteGestures 201 | ExampleController 202 | 203 | eventTypeLabel_ 204 | UILabel 205 | 206 | 207 | eventTypeLabel_ 208 | 209 | eventTypeLabel_ 210 | UILabel 211 | 212 | 213 | 214 | IBProjectSource 215 | Classes/DiscreteGestures.h 216 | 217 | 218 | 219 | DiscreteGestures 220 | ExampleController 221 | 222 | IBUserSource 223 | 224 | 225 | 226 | 227 | ExampleController 228 | UIViewController 229 | 230 | IBProjectSource 231 | Classes/ExampleController.h 232 | 233 | 234 | 235 | 236 | YES 237 | 238 | NSObject 239 | 240 | IBFrameworkSource 241 | Foundation.framework/Headers/NSError.h 242 | 243 | 244 | 245 | NSObject 246 | 247 | IBFrameworkSource 248 | Foundation.framework/Headers/NSFileManager.h 249 | 250 | 251 | 252 | NSObject 253 | 254 | IBFrameworkSource 255 | Foundation.framework/Headers/NSKeyValueCoding.h 256 | 257 | 258 | 259 | NSObject 260 | 261 | IBFrameworkSource 262 | Foundation.framework/Headers/NSKeyValueObserving.h 263 | 264 | 265 | 266 | NSObject 267 | 268 | IBFrameworkSource 269 | Foundation.framework/Headers/NSKeyedArchiver.h 270 | 271 | 272 | 273 | NSObject 274 | 275 | IBFrameworkSource 276 | Foundation.framework/Headers/NSObject.h 277 | 278 | 279 | 280 | NSObject 281 | 282 | IBFrameworkSource 283 | Foundation.framework/Headers/NSRunLoop.h 284 | 285 | 286 | 287 | NSObject 288 | 289 | IBFrameworkSource 290 | Foundation.framework/Headers/NSThread.h 291 | 292 | 293 | 294 | NSObject 295 | 296 | IBFrameworkSource 297 | Foundation.framework/Headers/NSURL.h 298 | 299 | 300 | 301 | NSObject 302 | 303 | IBFrameworkSource 304 | Foundation.framework/Headers/NSURLConnection.h 305 | 306 | 307 | 308 | NSObject 309 | 310 | IBFrameworkSource 311 | QuartzCore.framework/Headers/CAAnimation.h 312 | 313 | 314 | 315 | NSObject 316 | 317 | IBFrameworkSource 318 | QuartzCore.framework/Headers/CALayer.h 319 | 320 | 321 | 322 | NSObject 323 | 324 | IBFrameworkSource 325 | UIKit.framework/Headers/UIAccessibility.h 326 | 327 | 328 | 329 | NSObject 330 | 331 | IBFrameworkSource 332 | UIKit.framework/Headers/UINibLoading.h 333 | 334 | 335 | 336 | NSObject 337 | 338 | IBFrameworkSource 339 | UIKit.framework/Headers/UIResponder.h 340 | 341 | 342 | 343 | UILabel 344 | UIView 345 | 346 | IBFrameworkSource 347 | UIKit.framework/Headers/UILabel.h 348 | 349 | 350 | 351 | UIResponder 352 | NSObject 353 | 354 | 355 | 356 | UISearchBar 357 | UIView 358 | 359 | IBFrameworkSource 360 | UIKit.framework/Headers/UISearchBar.h 361 | 362 | 363 | 364 | UISearchDisplayController 365 | NSObject 366 | 367 | IBFrameworkSource 368 | UIKit.framework/Headers/UISearchDisplayController.h 369 | 370 | 371 | 372 | UIView 373 | 374 | IBFrameworkSource 375 | UIKit.framework/Headers/UIPrintFormatter.h 376 | 377 | 378 | 379 | UIView 380 | 381 | IBFrameworkSource 382 | UIKit.framework/Headers/UITextField.h 383 | 384 | 385 | 386 | UIView 387 | UIResponder 388 | 389 | IBFrameworkSource 390 | UIKit.framework/Headers/UIView.h 391 | 392 | 393 | 394 | UIViewController 395 | 396 | IBFrameworkSource 397 | UIKit.framework/Headers/UINavigationController.h 398 | 399 | 400 | 401 | UIViewController 402 | 403 | IBFrameworkSource 404 | UIKit.framework/Headers/UIPopoverController.h 405 | 406 | 407 | 408 | UIViewController 409 | 410 | IBFrameworkSource 411 | UIKit.framework/Headers/UISplitViewController.h 412 | 413 | 414 | 415 | UIViewController 416 | 417 | IBFrameworkSource 418 | UIKit.framework/Headers/UITabBarController.h 419 | 420 | 421 | 422 | UIViewController 423 | UIResponder 424 | 425 | IBFrameworkSource 426 | UIKit.framework/Headers/UIViewController.h 427 | 428 | 429 | 430 | 431 | 0 432 | IBIPadFramework 433 | 434 | com.apple.InterfaceBuilder.CocoaTouchPlugin.iPhoneOS 435 | 436 | 437 | 438 | com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3 439 | 440 | 441 | YES 442 | ../UIGestureExamples.xcodeproj 443 | 3 444 | 141 445 | 446 | 447 | -------------------------------------------------------------------------------- /DetailView.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1056 5 | 10F569 6 | 823 7 | 1038.29 8 | 461.00 9 | 10 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 11 | 132 12 | 13 | 14 | YES 15 | 16 | 17 | 18 | YES 19 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 20 | 21 | 22 | YES 23 | 24 | YES 25 | 26 | 27 | YES 28 | 29 | 30 | 31 | YES 32 | 33 | IBFilesOwner 34 | IBIPadFramework 35 | 36 | 37 | IBFirstResponder 38 | IBIPadFramework 39 | 40 | 41 | 42 | 310 43 | 44 | YES 45 | 46 | 47 | 290 48 | {768, 44} 49 | 50 | NO 51 | NO 52 | IBIPadFramework 53 | 54 | YES 55 | 56 | 57 | 58 | 59 | 310 60 | {{0, 44}, {768, 960}} 61 | 62 | 63 | 3 64 | MQA 65 | 66 | 2 67 | 68 | 69 | IBIPadFramework 70 | 71 | 72 | 73 | 290 74 | {{193, 7}, {382, 29}} 75 | 76 | NO 77 | YES 78 | 7 79 | NO 80 | IBIPadFramework 81 | 82 | 83 | Helvetica-Bold 84 | 18 85 | 16 86 | 87 | 88 | 1 89 | MC40MDAwMDAwMDYgMC40MDAwMDAwMDYgMC40MDAwMDAwMDYAA 90 | 91 | 92 | 3 93 | MQA 94 | 95 | 96 | 1 97 | MC45MDE5NjA3OTAyIDAuOTAxOTYwNzkwMiAwLjkwMTk2MDc5MDIAA 98 | 99 | {0, 1} 100 | 1 101 | 10 102 | 1 103 | 104 | 105 | {768, 1004} 106 | 107 | 108 | NO 109 | 110 | 2 111 | 112 | IBIPadFramework 113 | 114 | 115 | 116 | 117 | YES 118 | 119 | 120 | view 121 | 122 | 123 | 124 | 12 125 | 126 | 127 | 128 | toolbar 129 | 130 | 131 | 132 | 65 133 | 134 | 135 | 136 | contentView 137 | 138 | 139 | 140 | 68 141 | 142 | 143 | 144 | titleLabel 145 | 146 | 147 | 148 | 71 149 | 150 | 151 | 152 | 153 | YES 154 | 155 | 0 156 | 157 | 158 | 159 | 160 | 161 | -1 162 | 163 | 164 | File's Owner 165 | 166 | 167 | -2 168 | 169 | 170 | 171 | 172 | 8 173 | 174 | 175 | YES 176 | 177 | 178 | 179 | 180 | 181 | 182 | 183 | 63 184 | 185 | 186 | YES 187 | 188 | 189 | 190 | 191 | 67 192 | 193 | 194 | 195 | 196 | 70 197 | 198 | 199 | 200 | 201 | 202 | 203 | YES 204 | 205 | YES 206 | -1.CustomClassName 207 | -2.CustomClassName 208 | 63.IBPluginDependency 209 | 67.IBPluginDependency 210 | 67.IBViewBoundsToFrameTransform 211 | 70.IBPluginDependency 212 | 70.IBViewBoundsToFrameTransform 213 | 8.CustomClassName 214 | 8.IBEditorWindowLastContentRect 215 | 8.IBPluginDependency 216 | 217 | 218 | YES 219 | DetailViewController 220 | UIResponder 221 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 222 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 223 | 224 | AQAAAABCMAAAA 225 | 226 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 227 | 228 | P4AAAL+AAABDQQAAwhgAAA 229 | 230 | DetailView 231 | {{194, 4}, {783, 1002}} 232 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 233 | 234 | 235 | 236 | YES 237 | 238 | 239 | YES 240 | 241 | 242 | 243 | 244 | YES 245 | 246 | 247 | YES 248 | 249 | 250 | 251 | 71 252 | 253 | 254 | 255 | YES 256 | 257 | DetailView 258 | UIView 259 | 260 | IBProjectSource 261 | Classes/DetailViewController.h 262 | 263 | 264 | 265 | DetailViewController 266 | UIViewController 267 | 268 | YES 269 | 270 | YES 271 | contentView 272 | titleLabel 273 | toolbar 274 | 275 | 276 | YES 277 | UIView 278 | UILabel 279 | UIToolbar 280 | 281 | 282 | 283 | YES 284 | 285 | YES 286 | contentView 287 | titleLabel 288 | toolbar 289 | 290 | 291 | YES 292 | 293 | contentView 294 | UIView 295 | 296 | 297 | titleLabel 298 | UILabel 299 | 300 | 301 | toolbar 302 | UIToolbar 303 | 304 | 305 | 306 | 307 | 308 | 309 | 310 | YES 311 | 312 | NSObject 313 | 314 | IBFrameworkSource 315 | Foundation.framework/Headers/NSError.h 316 | 317 | 318 | 319 | NSObject 320 | 321 | IBFrameworkSource 322 | Foundation.framework/Headers/NSFileManager.h 323 | 324 | 325 | 326 | NSObject 327 | 328 | IBFrameworkSource 329 | Foundation.framework/Headers/NSKeyValueCoding.h 330 | 331 | 332 | 333 | NSObject 334 | 335 | IBFrameworkSource 336 | Foundation.framework/Headers/NSKeyValueObserving.h 337 | 338 | 339 | 340 | NSObject 341 | 342 | IBFrameworkSource 343 | Foundation.framework/Headers/NSKeyedArchiver.h 344 | 345 | 346 | 347 | NSObject 348 | 349 | IBFrameworkSource 350 | Foundation.framework/Headers/NSObject.h 351 | 352 | 353 | 354 | NSObject 355 | 356 | IBFrameworkSource 357 | Foundation.framework/Headers/NSRunLoop.h 358 | 359 | 360 | 361 | NSObject 362 | 363 | IBFrameworkSource 364 | Foundation.framework/Headers/NSThread.h 365 | 366 | 367 | 368 | NSObject 369 | 370 | IBFrameworkSource 371 | Foundation.framework/Headers/NSURL.h 372 | 373 | 374 | 375 | NSObject 376 | 377 | IBFrameworkSource 378 | Foundation.framework/Headers/NSURLConnection.h 379 | 380 | 381 | 382 | NSObject 383 | 384 | IBFrameworkSource 385 | QuartzCore.framework/Headers/CAAnimation.h 386 | 387 | 388 | 389 | NSObject 390 | 391 | IBFrameworkSource 392 | QuartzCore.framework/Headers/CALayer.h 393 | 394 | 395 | 396 | NSObject 397 | 398 | IBFrameworkSource 399 | UIKit.framework/Headers/UIAccessibility.h 400 | 401 | 402 | 403 | NSObject 404 | 405 | IBFrameworkSource 406 | UIKit.framework/Headers/UINibLoading.h 407 | 408 | 409 | 410 | NSObject 411 | 412 | IBFrameworkSource 413 | UIKit.framework/Headers/UIResponder.h 414 | 415 | 416 | 417 | UILabel 418 | UIView 419 | 420 | IBFrameworkSource 421 | UIKit.framework/Headers/UILabel.h 422 | 423 | 424 | 425 | UIResponder 426 | NSObject 427 | 428 | 429 | 430 | UISearchBar 431 | UIView 432 | 433 | IBFrameworkSource 434 | UIKit.framework/Headers/UISearchBar.h 435 | 436 | 437 | 438 | UISearchDisplayController 439 | NSObject 440 | 441 | IBFrameworkSource 442 | UIKit.framework/Headers/UISearchDisplayController.h 443 | 444 | 445 | 446 | UIToolbar 447 | UIView 448 | 449 | IBFrameworkSource 450 | UIKit.framework/Headers/UIToolbar.h 451 | 452 | 453 | 454 | UIView 455 | 456 | IBFrameworkSource 457 | UIKit.framework/Headers/UIPrintFormatter.h 458 | 459 | 460 | 461 | UIView 462 | 463 | IBFrameworkSource 464 | UIKit.framework/Headers/UITextField.h 465 | 466 | 467 | 468 | UIView 469 | UIResponder 470 | 471 | IBFrameworkSource 472 | UIKit.framework/Headers/UIView.h 473 | 474 | 475 | 476 | UIViewController 477 | 478 | IBFrameworkSource 479 | UIKit.framework/Headers/UINavigationController.h 480 | 481 | 482 | 483 | UIViewController 484 | 485 | IBFrameworkSource 486 | UIKit.framework/Headers/UIPopoverController.h 487 | 488 | 489 | 490 | UIViewController 491 | 492 | IBFrameworkSource 493 | UIKit.framework/Headers/UISplitViewController.h 494 | 495 | 496 | 497 | UIViewController 498 | 499 | IBFrameworkSource 500 | UIKit.framework/Headers/UITabBarController.h 501 | 502 | 503 | 504 | UIViewController 505 | UIResponder 506 | 507 | IBFrameworkSource 508 | UIKit.framework/Headers/UIViewController.h 509 | 510 | 511 | 512 | 513 | 0 514 | IBIPadFramework 515 | 516 | com.apple.InterfaceBuilder.CocoaTouchPlugin.iPhoneOS 517 | 518 | 519 | 520 | com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3 521 | 522 | 523 | YES 524 | UIGestureExamples.xcodeproj 525 | 3 526 | 132 527 | 528 | 529 | -------------------------------------------------------------------------------- /Classes/ContinuousGestures.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1056 5 | 10F569 6 | 823 7 | 1038.29 8 | 461.00 9 | 10 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 11 | 132 12 | 13 | 14 | YES 15 | 16 | 17 | 18 | YES 19 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 20 | 21 | 22 | YES 23 | 24 | YES 25 | 26 | 27 | YES 28 | 29 | 30 | 31 | YES 32 | 33 | IBFilesOwner 34 | IBIPadFramework 35 | 36 | 37 | IBFirstResponder 38 | IBIPadFramework 39 | 40 | 41 | 42 | 292 43 | 44 | YES 45 | 46 | 47 | 274 48 | {{111, 249}, {200, 200}} 49 | 50 | 51 | 1 52 | MC41MDE5NjA4MTQgMCAwAA 53 | 54 | IBIPadFramework 55 | 56 | 57 | 58 | 274 59 | {{456, 249}, {200, 200}} 60 | 61 | 62 | 1 63 | MCAwLjUwMTk2MDgxNCAwAA 64 | 65 | IBIPadFramework 66 | 67 | 68 | 69 | 274 70 | {{111, 555}, {200, 200}} 71 | 72 | 73 | 1 74 | MCAwLjI1MDk4MDQwNyAwLjUwMTk2MDgxNAA 75 | 76 | IBIPadFramework 77 | 78 | 79 | 80 | 274 81 | {{456, 555}, {200, 200}} 82 | 83 | 84 | 1 85 | MSAwLjUwMTk2MDgxNCAwAA 86 | 87 | IBIPadFramework 88 | 89 | 90 | {768, 1004} 91 | 92 | 93 | 3 94 | MQA 95 | 96 | NO 97 | 98 | 2 99 | 100 | IBIPadFramework 101 | 102 | 103 | 104 | 105 | YES 106 | 107 | 108 | view 109 | 110 | 111 | 112 | 3 113 | 114 | 115 | 116 | redView 117 | 118 | 119 | 120 | 8 121 | 122 | 123 | 124 | greenView 125 | 126 | 127 | 128 | 9 129 | 130 | 131 | 132 | orangeView 133 | 134 | 135 | 136 | 10 137 | 138 | 139 | 140 | blueView 141 | 142 | 143 | 144 | 11 145 | 146 | 147 | 148 | 149 | YES 150 | 151 | 0 152 | 153 | 154 | 155 | 156 | 157 | -1 158 | 159 | 160 | File's Owner 161 | 162 | 163 | -2 164 | 165 | 166 | 167 | 168 | 2 169 | 170 | 171 | YES 172 | 173 | 174 | 175 | 176 | 177 | 178 | 179 | 180 | 4 181 | 182 | 183 | Red View 184 | 185 | 186 | 5 187 | 188 | 189 | Green View 190 | 191 | 192 | 6 193 | 194 | 195 | Blue View 196 | 197 | 198 | 7 199 | 200 | 201 | Orange View 202 | 203 | 204 | 205 | 206 | YES 207 | 208 | YES 209 | -1.CustomClassName 210 | -2.CustomClassName 211 | 2.IBEditorWindowLastContentRect 212 | 2.IBPluginDependency 213 | 4.IBPluginDependency 214 | 4.IBViewBoundsToFrameTransform 215 | 5.IBPluginDependency 216 | 5.IBViewBoundsToFrameTransform 217 | 6.IBPluginDependency 218 | 6.IBViewBoundsToFrameTransform 219 | 7.IBPluginDependency 220 | 7.IBViewBoundsToFrameTransform 221 | 222 | 223 | YES 224 | ContinuousGestures 225 | UIResponder 226 | {{259, 4}, {783, 1002}} 227 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 228 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 229 | 230 | P4AAAL+AAABCLAAAw44AAA 231 | 232 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 233 | 234 | P4AAAL+AAABDwQAAw4oAAA 235 | 236 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 237 | 238 | P4AAAL+AAABCZAAAxCmAAA 239 | 240 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 241 | 242 | P4AAAL+AAABD2YAAxCVAAA 243 | 244 | 245 | 246 | 247 | YES 248 | 249 | 250 | YES 251 | 252 | 253 | 254 | 255 | YES 256 | 257 | 258 | YES 259 | 260 | 261 | 262 | 11 263 | 264 | 265 | 266 | YES 267 | 268 | ContinuousGestures 269 | ExampleController 270 | 271 | YES 272 | 273 | YES 274 | blueView 275 | greenView 276 | orangeView 277 | redView 278 | 279 | 280 | YES 281 | UIView 282 | UIView 283 | UIView 284 | UIView 285 | 286 | 287 | 288 | YES 289 | 290 | YES 291 | blueView 292 | greenView 293 | orangeView 294 | redView 295 | 296 | 297 | YES 298 | 299 | blueView 300 | UIView 301 | 302 | 303 | greenView 304 | UIView 305 | 306 | 307 | orangeView 308 | UIView 309 | 310 | 311 | redView 312 | UIView 313 | 314 | 315 | 316 | 317 | IBProjectSource 318 | Classes/ContinuousGestures.h 319 | 320 | 321 | 322 | ExampleController 323 | UIViewController 324 | 325 | IBProjectSource 326 | Classes/ExampleController.h 327 | 328 | 329 | 330 | 331 | YES 332 | 333 | NSObject 334 | 335 | IBFrameworkSource 336 | Foundation.framework/Headers/NSError.h 337 | 338 | 339 | 340 | NSObject 341 | 342 | IBFrameworkSource 343 | Foundation.framework/Headers/NSFileManager.h 344 | 345 | 346 | 347 | NSObject 348 | 349 | IBFrameworkSource 350 | Foundation.framework/Headers/NSKeyValueCoding.h 351 | 352 | 353 | 354 | NSObject 355 | 356 | IBFrameworkSource 357 | Foundation.framework/Headers/NSKeyValueObserving.h 358 | 359 | 360 | 361 | NSObject 362 | 363 | IBFrameworkSource 364 | Foundation.framework/Headers/NSKeyedArchiver.h 365 | 366 | 367 | 368 | NSObject 369 | 370 | IBFrameworkSource 371 | Foundation.framework/Headers/NSObject.h 372 | 373 | 374 | 375 | NSObject 376 | 377 | IBFrameworkSource 378 | Foundation.framework/Headers/NSRunLoop.h 379 | 380 | 381 | 382 | NSObject 383 | 384 | IBFrameworkSource 385 | Foundation.framework/Headers/NSThread.h 386 | 387 | 388 | 389 | NSObject 390 | 391 | IBFrameworkSource 392 | Foundation.framework/Headers/NSURL.h 393 | 394 | 395 | 396 | NSObject 397 | 398 | IBFrameworkSource 399 | Foundation.framework/Headers/NSURLConnection.h 400 | 401 | 402 | 403 | NSObject 404 | 405 | IBFrameworkSource 406 | QuartzCore.framework/Headers/CAAnimation.h 407 | 408 | 409 | 410 | NSObject 411 | 412 | IBFrameworkSource 413 | QuartzCore.framework/Headers/CALayer.h 414 | 415 | 416 | 417 | NSObject 418 | 419 | IBFrameworkSource 420 | UIKit.framework/Headers/UIAccessibility.h 421 | 422 | 423 | 424 | NSObject 425 | 426 | IBFrameworkSource 427 | UIKit.framework/Headers/UINibLoading.h 428 | 429 | 430 | 431 | NSObject 432 | 433 | IBFrameworkSource 434 | UIKit.framework/Headers/UIResponder.h 435 | 436 | 437 | 438 | UIResponder 439 | NSObject 440 | 441 | 442 | 443 | UISearchBar 444 | UIView 445 | 446 | IBFrameworkSource 447 | UIKit.framework/Headers/UISearchBar.h 448 | 449 | 450 | 451 | UISearchDisplayController 452 | NSObject 453 | 454 | IBFrameworkSource 455 | UIKit.framework/Headers/UISearchDisplayController.h 456 | 457 | 458 | 459 | UIView 460 | 461 | IBFrameworkSource 462 | UIKit.framework/Headers/UIPrintFormatter.h 463 | 464 | 465 | 466 | UIView 467 | 468 | IBFrameworkSource 469 | UIKit.framework/Headers/UITextField.h 470 | 471 | 472 | 473 | UIView 474 | UIResponder 475 | 476 | IBFrameworkSource 477 | UIKit.framework/Headers/UIView.h 478 | 479 | 480 | 481 | UIViewController 482 | 483 | IBFrameworkSource 484 | UIKit.framework/Headers/UINavigationController.h 485 | 486 | 487 | 488 | UIViewController 489 | 490 | IBFrameworkSource 491 | UIKit.framework/Headers/UIPopoverController.h 492 | 493 | 494 | 495 | UIViewController 496 | 497 | IBFrameworkSource 498 | UIKit.framework/Headers/UISplitViewController.h 499 | 500 | 501 | 502 | UIViewController 503 | 504 | IBFrameworkSource 505 | UIKit.framework/Headers/UITabBarController.h 506 | 507 | 508 | 509 | UIViewController 510 | UIResponder 511 | 512 | IBFrameworkSource 513 | UIKit.framework/Headers/UIViewController.h 514 | 515 | 516 | 517 | 518 | 0 519 | IBIPadFramework 520 | 521 | com.apple.InterfaceBuilder.CocoaTouchPlugin.iPhoneOS 522 | 523 | 524 | 525 | com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3 526 | 527 | 528 | YES 529 | ../UIGestureExamples.xcodeproj 530 | 3 531 | 132 532 | 533 | 534 | -------------------------------------------------------------------------------- /Classes/GestureInteraction.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1056 5 | 10F569 6 | 823 7 | 1038.29 8 | 461.00 9 | 10 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 11 | 132 12 | 13 | 14 | YES 15 | 16 | 17 | YES 18 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 19 | 20 | 21 | YES 22 | 23 | YES 24 | 25 | 26 | YES 27 | 28 | 29 | 30 | YES 31 | 32 | IBFilesOwner 33 | IBIPadFramework 34 | 35 | 36 | IBFirstResponder 37 | IBIPadFramework 38 | 39 | 40 | 41 | 292 42 | 43 | YES 44 | 45 | 46 | 310 47 | 48 | YES 49 | 50 | 51 | 290 52 | {{0, 20}, {728, 30}} 53 | 54 | NO 55 | YES 56 | 7 57 | NO 58 | IBIPadFramework 59 | Pinch 60 | 61 | Helvetica 62 | 18 63 | 16 64 | 65 | 66 | 1 67 | MSAxIDEAA 68 | 69 | 70 | 3 71 | MQA 72 | 73 | 1 74 | 10 75 | 1 76 | 77 | 78 | 79 | 274 80 | {{20, 105}, {300, 300}} 81 | 82 | 83 | 1 84 | MCAwIDAAA 85 | 86 | NO 87 | YES 88 | 7 89 | IBIPadFramework 90 | Tap 91 | 92 | Helvetica 93 | 24 94 | 16 95 | 96 | 97 | 98 | 1 99 | 10 100 | 1 101 | 102 | 103 | 104 | 274 105 | {{408, 105}, {300, 300}} 106 | 107 | 108 | NO 109 | YES 110 | 7 111 | IBIPadFramework 112 | Swipe 113 | 114 | 115 | 116 | 1 117 | 10 118 | 1 119 | 120 | 121 | {{20, 73}, {728, 459}} 122 | 123 | 124 | IBIPadFramework 125 | 126 | 127 | 128 | 290 129 | {{20, 20}, {728, 22}} 130 | 131 | NO 132 | YES 133 | 7 134 | NO 135 | IBIPadFramework 136 | Pan 137 | 138 | 139 | 140 | 1 141 | 10 142 | 1 143 | 144 | 145 | {768, 980} 146 | 147 | NO 148 | NO 149 | 150 | NO 151 | 152 | 153 | IBUISplitViewController 154 | 155 | IBUISplitViewControllerContentSizeLocation 156 | IBUISplitViewControllerContentSizeLocationDetail 157 | 158 | IBIPadFramework 159 | Detail 160 | 161 | IBIPadFramework 162 | 163 | 164 | 165 | 166 | YES 167 | 168 | 169 | view 170 | 171 | 172 | 173 | 4 174 | 175 | 176 | 177 | tapLabel 178 | 179 | 180 | 181 | 25 182 | 183 | 184 | 185 | swipeLabel 186 | 187 | 188 | 189 | 26 190 | 191 | 192 | 193 | containerView 194 | 195 | 196 | 197 | 30 198 | 199 | 200 | 201 | 202 | YES 203 | 204 | 0 205 | 206 | 207 | 208 | 209 | 210 | -1 211 | 212 | 213 | File's Owner 214 | 215 | 216 | -2 217 | 218 | 219 | 220 | 221 | 2 222 | 223 | 224 | YES 225 | 226 | 227 | 228 | 229 | 230 | 231 | 28 232 | 233 | 234 | YES 235 | 236 | 237 | 238 | 239 | 240 | Container View 241 | 242 | 243 | 20 244 | 245 | 246 | Tap View 247 | 248 | 249 | 23 250 | 251 | 252 | Swipe View 253 | 254 | 255 | 29 256 | 257 | 258 | 259 | 260 | 31 261 | 262 | 263 | 264 | 265 | 266 | 267 | YES 268 | 269 | YES 270 | -1.CustomClassName 271 | -2.CustomClassName 272 | 2.IBEditorWindowLastContentRect 273 | 2.IBPluginDependency 274 | 2.IBViewEditorWindowController.showingLayoutRectangles 275 | 20.IBPluginDependency 276 | 20.IBViewBoundsToFrameTransform 277 | 23.IBPluginDependency 278 | 23.IBViewBoundsToFrameTransform 279 | 28.IBPluginDependency 280 | 28.IBViewBoundsToFrameTransform 281 | 29.IBPluginDependency 282 | 29.IBViewBoundsToFrameTransform 283 | 31.IBPluginDependency 284 | 285 | 286 | YES 287 | GestureInteraction 288 | UIResponder 289 | {{247, 4}, {783, 1002}} 290 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 291 | 292 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 293 | 294 | P4AAAL+AAABCFAAAw8mAAA 295 | 296 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 297 | 298 | P4AAAL+AAABD0IAAw8cAAA 299 | 300 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 301 | 302 | P4AAAL+AAAAAAAAAxARAAA 303 | 304 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 305 | 306 | P4AAAL+AAABDhoAAwjQAAA 307 | 308 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 309 | 310 | 311 | 312 | YES 313 | 314 | 315 | YES 316 | 317 | 318 | 319 | 320 | YES 321 | 322 | 323 | YES 324 | 325 | 326 | 327 | 31 328 | 329 | 330 | 331 | YES 332 | 333 | ExampleController 334 | UIViewController 335 | 336 | IBProjectSource 337 | Classes/ExampleController.h 338 | 339 | 340 | 341 | GestureInteraction 342 | ExampleController 343 | 344 | YES 345 | 346 | YES 347 | containerView 348 | swipeLabel 349 | tapLabel 350 | 351 | 352 | YES 353 | UIView 354 | UILabel 355 | UILabel 356 | 357 | 358 | 359 | YES 360 | 361 | YES 362 | containerView 363 | swipeLabel 364 | tapLabel 365 | 366 | 367 | YES 368 | 369 | containerView 370 | UIView 371 | 372 | 373 | swipeLabel 374 | UILabel 375 | 376 | 377 | tapLabel 378 | UILabel 379 | 380 | 381 | 382 | 383 | IBUserSource 384 | 385 | 386 | 387 | 388 | 389 | YES 390 | 391 | NSObject 392 | 393 | IBFrameworkSource 394 | Foundation.framework/Headers/NSError.h 395 | 396 | 397 | 398 | NSObject 399 | 400 | IBFrameworkSource 401 | Foundation.framework/Headers/NSFileManager.h 402 | 403 | 404 | 405 | NSObject 406 | 407 | IBFrameworkSource 408 | Foundation.framework/Headers/NSKeyValueCoding.h 409 | 410 | 411 | 412 | NSObject 413 | 414 | IBFrameworkSource 415 | Foundation.framework/Headers/NSKeyValueObserving.h 416 | 417 | 418 | 419 | NSObject 420 | 421 | IBFrameworkSource 422 | Foundation.framework/Headers/NSKeyedArchiver.h 423 | 424 | 425 | 426 | NSObject 427 | 428 | IBFrameworkSource 429 | Foundation.framework/Headers/NSObject.h 430 | 431 | 432 | 433 | NSObject 434 | 435 | IBFrameworkSource 436 | Foundation.framework/Headers/NSRunLoop.h 437 | 438 | 439 | 440 | NSObject 441 | 442 | IBFrameworkSource 443 | Foundation.framework/Headers/NSThread.h 444 | 445 | 446 | 447 | NSObject 448 | 449 | IBFrameworkSource 450 | Foundation.framework/Headers/NSURL.h 451 | 452 | 453 | 454 | NSObject 455 | 456 | IBFrameworkSource 457 | Foundation.framework/Headers/NSURLConnection.h 458 | 459 | 460 | 461 | NSObject 462 | 463 | IBFrameworkSource 464 | QuartzCore.framework/Headers/CAAnimation.h 465 | 466 | 467 | 468 | NSObject 469 | 470 | IBFrameworkSource 471 | QuartzCore.framework/Headers/CALayer.h 472 | 473 | 474 | 475 | NSObject 476 | 477 | IBFrameworkSource 478 | UIKit.framework/Headers/UIAccessibility.h 479 | 480 | 481 | 482 | NSObject 483 | 484 | IBFrameworkSource 485 | UIKit.framework/Headers/UINibLoading.h 486 | 487 | 488 | 489 | NSObject 490 | 491 | IBFrameworkSource 492 | UIKit.framework/Headers/UIResponder.h 493 | 494 | 495 | 496 | UILabel 497 | UIView 498 | 499 | IBFrameworkSource 500 | UIKit.framework/Headers/UILabel.h 501 | 502 | 503 | 504 | UIResponder 505 | NSObject 506 | 507 | 508 | 509 | UISearchBar 510 | UIView 511 | 512 | IBFrameworkSource 513 | UIKit.framework/Headers/UISearchBar.h 514 | 515 | 516 | 517 | UISearchDisplayController 518 | NSObject 519 | 520 | IBFrameworkSource 521 | UIKit.framework/Headers/UISearchDisplayController.h 522 | 523 | 524 | 525 | UIView 526 | 527 | IBFrameworkSource 528 | UIKit.framework/Headers/UIPrintFormatter.h 529 | 530 | 531 | 532 | UIView 533 | 534 | IBFrameworkSource 535 | UIKit.framework/Headers/UITextField.h 536 | 537 | 538 | 539 | UIView 540 | UIResponder 541 | 542 | IBFrameworkSource 543 | UIKit.framework/Headers/UIView.h 544 | 545 | 546 | 547 | UIViewController 548 | 549 | IBFrameworkSource 550 | UIKit.framework/Headers/UINavigationController.h 551 | 552 | 553 | 554 | UIViewController 555 | 556 | IBFrameworkSource 557 | UIKit.framework/Headers/UIPopoverController.h 558 | 559 | 560 | 561 | UIViewController 562 | 563 | IBFrameworkSource 564 | UIKit.framework/Headers/UISplitViewController.h 565 | 566 | 567 | 568 | UIViewController 569 | 570 | IBFrameworkSource 571 | UIKit.framework/Headers/UITabBarController.h 572 | 573 | 574 | 575 | UIViewController 576 | UIResponder 577 | 578 | IBFrameworkSource 579 | UIKit.framework/Headers/UIViewController.h 580 | 581 | 582 | 583 | 584 | 0 585 | IBIPadFramework 586 | 587 | com.apple.InterfaceBuilder.CocoaTouchPlugin.iPhoneOS 588 | 589 | 590 | 591 | com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3 592 | 593 | 594 | YES 595 | ../UIGestureExamples.xcodeproj 596 | 3 597 | 132 598 | 599 | 600 | -------------------------------------------------------------------------------- /MainWindow.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1056 5 | 10F569 6 | 823 7 | 1038.29 8 | 461.00 9 | 10 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 11 | 132 12 | 13 | 14 | 15 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 16 | 17 | 18 | 19 | 20 | IBFilesOwner 21 | IBIPadFramework 22 | 23 | 24 | IBFirstResponder 25 | IBIPadFramework 26 | 27 | 28 | 29 | 292 30 | {768, 1024} 31 | 32 | 1 33 | MSAxIDEAA 34 | 35 | NO 36 | 37 | 2 38 | 39 | IBIPadFramework 40 | YES 41 | 42 | 43 | IBIPadFramework 44 | 45 | 46 | 47 | 48 | 2 49 | 50 | 51 | 3 52 | 53 | IBIPadFramework 54 | YES 55 | 56 | 57 | 58 | 2 59 | 60 | 61 | 1 62 | 63 | IBIPadFramework 64 | NO 65 | 66 | 67 | 256 68 | {0, 0} 69 | YES 70 | YES 71 | IBIPadFramework 72 | 73 | 74 | 75 | 76 | Gesture Examples 77 | IBIPadFramework 78 | 79 | 80 | 81 | 2 82 | 83 | 84 | 1 85 | 86 | IBIPadFramework 87 | NO 88 | 89 | 90 | 91 | 92 | 93 | 94 | DetailView 95 | 96 | 1 97 | 98 | IBIPadFramework 99 | NO 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | window 108 | 109 | 110 | 111 | 4 112 | 113 | 114 | 115 | delegate 116 | 117 | 118 | 119 | 17 120 | 121 | 122 | 123 | splitViewController 124 | 125 | 126 | 127 | 43 128 | 129 | 130 | 131 | rootViewController 132 | 133 | 134 | 135 | 44 136 | 137 | 138 | 139 | detailViewController 140 | 141 | 142 | 143 | 45 144 | 145 | 146 | 147 | detailViewController 148 | 149 | 150 | 151 | 46 152 | 153 | 154 | 155 | delegate 156 | 157 | 158 | 159 | 49 160 | 161 | 162 | 163 | 164 | 165 | 0 166 | 167 | 168 | 169 | 170 | 171 | -1 172 | 173 | 174 | File's Owner 175 | 176 | 177 | -2 178 | 179 | 180 | 181 | 182 | 2 183 | 184 | 185 | 186 | 187 | 3 188 | 189 | 190 | 191 | 192 | 37 193 | 194 | 195 | 196 | 197 | 198 | 199 | 200 | 201 | 38 202 | 203 | 204 | 205 | 206 | 207 | 208 | 209 | 210 | 39 211 | 212 | 213 | 214 | 215 | 40 216 | 217 | 218 | 219 | 220 | 221 | 222 | 223 | 41 224 | 225 | 226 | 227 | 228 | 42 229 | 230 | 231 | 232 | 233 | 234 | 235 | UIApplication 236 | UIResponder 237 | {{190, 57}, {783, 799}} 238 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 239 | UIGestureExamplesAppDelegate 240 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 241 | {{37, 238}, {1024, 768}} 242 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 243 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 244 | DetailViewController 245 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 246 | RootViewController 247 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 248 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 249 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 250 | 251 | 252 | 253 | 254 | 255 | 49 256 | 257 | 258 | 259 | 260 | DetailViewController 261 | UIViewController 262 | 263 | UIView 264 | UILabel 265 | UIToolbar 266 | 267 | 268 | 269 | contentView 270 | UIView 271 | 272 | 273 | titleLabel 274 | UILabel 275 | 276 | 277 | toolbar 278 | UIToolbar 279 | 280 | 281 | 282 | IBProjectSource 283 | Classes/DetailViewController.h 284 | 285 | 286 | 287 | RootViewController 288 | UITableViewController 289 | 290 | detailViewController 291 | DetailViewController 292 | 293 | 294 | detailViewController 295 | 296 | detailViewController 297 | DetailViewController 298 | 299 | 300 | 301 | IBProjectSource 302 | Classes/RootViewController.h 303 | 304 | 305 | 306 | RootViewController 307 | UITableViewController 308 | 309 | IBUserSource 310 | 311 | 312 | 313 | 314 | UIGestureExamplesAppDelegate 315 | NSObject 316 | 317 | DetailViewController 318 | RootViewController 319 | UISplitViewController 320 | UIWindow 321 | 322 | 323 | 324 | detailViewController 325 | DetailViewController 326 | 327 | 328 | rootViewController 329 | RootViewController 330 | 331 | 332 | splitViewController 333 | UISplitViewController 334 | 335 | 336 | window 337 | UIWindow 338 | 339 | 340 | 341 | IBProjectSource 342 | Classes/UIGestureExamplesAppDelegate.h 343 | 344 | 345 | 346 | 347 | 348 | NSObject 349 | 350 | IBFrameworkSource 351 | Foundation.framework/Headers/NSError.h 352 | 353 | 354 | 355 | NSObject 356 | 357 | IBFrameworkSource 358 | Foundation.framework/Headers/NSFileManager.h 359 | 360 | 361 | 362 | NSObject 363 | 364 | IBFrameworkSource 365 | Foundation.framework/Headers/NSKeyValueCoding.h 366 | 367 | 368 | 369 | NSObject 370 | 371 | IBFrameworkSource 372 | Foundation.framework/Headers/NSKeyValueObserving.h 373 | 374 | 375 | 376 | NSObject 377 | 378 | IBFrameworkSource 379 | Foundation.framework/Headers/NSKeyedArchiver.h 380 | 381 | 382 | 383 | NSObject 384 | 385 | IBFrameworkSource 386 | Foundation.framework/Headers/NSObject.h 387 | 388 | 389 | 390 | NSObject 391 | 392 | IBFrameworkSource 393 | Foundation.framework/Headers/NSRunLoop.h 394 | 395 | 396 | 397 | NSObject 398 | 399 | IBFrameworkSource 400 | Foundation.framework/Headers/NSThread.h 401 | 402 | 403 | 404 | NSObject 405 | 406 | IBFrameworkSource 407 | Foundation.framework/Headers/NSURL.h 408 | 409 | 410 | 411 | NSObject 412 | 413 | IBFrameworkSource 414 | Foundation.framework/Headers/NSURLConnection.h 415 | 416 | 417 | 418 | NSObject 419 | 420 | IBFrameworkSource 421 | QuartzCore.framework/Headers/CAAnimation.h 422 | 423 | 424 | 425 | NSObject 426 | 427 | IBFrameworkSource 428 | QuartzCore.framework/Headers/CALayer.h 429 | 430 | 431 | 432 | NSObject 433 | 434 | IBFrameworkSource 435 | UIKit.framework/Headers/UIAccessibility.h 436 | 437 | 438 | 439 | NSObject 440 | 441 | IBFrameworkSource 442 | UIKit.framework/Headers/UINibLoading.h 443 | 444 | 445 | 446 | NSObject 447 | 448 | IBFrameworkSource 449 | UIKit.framework/Headers/UIResponder.h 450 | 451 | 452 | 453 | UIApplication 454 | UIResponder 455 | 456 | IBFrameworkSource 457 | UIKit.framework/Headers/UIApplication.h 458 | 459 | 460 | 461 | UIBarButtonItem 462 | UIBarItem 463 | 464 | IBFrameworkSource 465 | UIKit.framework/Headers/UIBarButtonItem.h 466 | 467 | 468 | 469 | UIBarItem 470 | NSObject 471 | 472 | IBFrameworkSource 473 | UIKit.framework/Headers/UIBarItem.h 474 | 475 | 476 | 477 | UILabel 478 | UIView 479 | 480 | IBFrameworkSource 481 | UIKit.framework/Headers/UILabel.h 482 | 483 | 484 | 485 | UINavigationBar 486 | UIView 487 | 488 | IBFrameworkSource 489 | UIKit.framework/Headers/UINavigationBar.h 490 | 491 | 492 | 493 | UINavigationController 494 | UIViewController 495 | 496 | IBFrameworkSource 497 | UIKit.framework/Headers/UINavigationController.h 498 | 499 | 500 | 501 | UINavigationItem 502 | NSObject 503 | 504 | 505 | 506 | UIResponder 507 | NSObject 508 | 509 | 510 | 511 | UISearchBar 512 | UIView 513 | 514 | IBFrameworkSource 515 | UIKit.framework/Headers/UISearchBar.h 516 | 517 | 518 | 519 | UISearchDisplayController 520 | NSObject 521 | 522 | IBFrameworkSource 523 | UIKit.framework/Headers/UISearchDisplayController.h 524 | 525 | 526 | 527 | UISplitViewController 528 | UIViewController 529 | 530 | IBFrameworkSource 531 | UIKit.framework/Headers/UISplitViewController.h 532 | 533 | 534 | 535 | UITableViewController 536 | UIViewController 537 | 538 | IBFrameworkSource 539 | UIKit.framework/Headers/UITableViewController.h 540 | 541 | 542 | 543 | UIToolbar 544 | UIView 545 | 546 | IBFrameworkSource 547 | UIKit.framework/Headers/UIToolbar.h 548 | 549 | 550 | 551 | UIView 552 | 553 | IBFrameworkSource 554 | UIKit.framework/Headers/UIPrintFormatter.h 555 | 556 | 557 | 558 | UIView 559 | 560 | IBFrameworkSource 561 | UIKit.framework/Headers/UITextField.h 562 | 563 | 564 | 565 | UIView 566 | UIResponder 567 | 568 | IBFrameworkSource 569 | UIKit.framework/Headers/UIView.h 570 | 571 | 572 | 573 | UIViewController 574 | 575 | 576 | 577 | UIViewController 578 | 579 | IBFrameworkSource 580 | UIKit.framework/Headers/UIPopoverController.h 581 | 582 | 583 | 584 | UIViewController 585 | 586 | 587 | 588 | UIViewController 589 | 590 | IBFrameworkSource 591 | UIKit.framework/Headers/UITabBarController.h 592 | 593 | 594 | 595 | UIViewController 596 | UIResponder 597 | 598 | IBFrameworkSource 599 | UIKit.framework/Headers/UIViewController.h 600 | 601 | 602 | 603 | UIWindow 604 | UIView 605 | 606 | IBFrameworkSource 607 | UIKit.framework/Headers/UIWindow.h 608 | 609 | 610 | 611 | 612 | 0 613 | IBIPadFramework 614 | 615 | com.apple.InterfaceBuilder.CocoaTouchPlugin.iPhoneOS 616 | 617 | 618 | 619 | com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3 620 | 621 | 622 | YES 623 | UIGestureExamples.xcodeproj 624 | 3 625 | 132 626 | 627 | 628 | --------------------------------------------------------------------------------