├── .gitignore ├── AppIcons ├── 20-gear2.png ├── Default-568h@2x.png ├── Default.png ├── Default@2x.png ├── appIcon.png ├── appIcon29x29.png ├── appIcon58x58.png ├── appIcon@2x.png ├── appIcon@Retina.png └── appretina.png ├── Button Icons ├── blueButton.png ├── blueButton@2x.png ├── blueButtonHighlight.png ├── blueButtonHighlight@2x.png ├── button@2x.png ├── greenButton.png ├── greenButton@2x.png ├── greenButtonHighlight.png ├── greenButtonHighlight@2x.png ├── greyButton.png ├── greyButton@2x.png ├── redButton.png ├── redButton@2x.png ├── redButtonHighlight.png ├── redButtonHighlight@2x.png ├── whiteButton.png ├── whiteButton@2x.png ├── whiteButtonHighlight.png └── whiteButtonHighlight@2x.png ├── COPYING ├── Classes ├── AboutViewController.h ├── AboutViewController.m ├── ActivityIndicatorDelegate.h ├── CycleAtlantaAppDelegate.h ├── CycleAtlantaAppDelegate.m ├── DetailViewController.h ├── DetailViewController.m ├── ImageResize.h ├── ImageResize.m ├── LoadingView.h ├── LoadingView.m ├── MKPointAnnotation+IndegoPointAnnotation.h ├── MKPointAnnotation+IndegoPointAnnotation.m ├── MapCoord.h ├── MapCoord.m ├── MapViewController.h ├── MapViewController.m ├── NoteViewController.xib ├── PersonalInfoDelegate.h ├── PersonalInfoViewController.h ├── PersonalInfoViewController.m ├── PickerViewController.h ├── PickerViewController.m ├── RecordTripViewController.h ├── RecordTripViewController.m ├── RecordingInProgressDelegate.h ├── ReminderManager.h ├── ReminderManager.m ├── SaveRequest.h ├── SaveRequest.m ├── SavedTripsViewController.h ├── SavedTripsViewController.m ├── TookTransitViewController.h ├── TookTransitViewController.m ├── TripDetailViewController.h ├── TripDetailViewController.m ├── TripDetailViewController.xib ├── TripManager.h ├── TripManager.m ├── TripPurposeDelegate.h ├── ZipUtil.h └── ZipUtil.m ├── Coord.h ├── Coord.m ├── CustomPickerDataSource.h ├── CustomPickerDataSource.m ├── CustomView.h ├── CustomView.m ├── Cycle Atlanta.ipa ├── Cycle Philly-Info.plist ├── Cycle Philly.xcodeproj ├── project.pbxproj └── project.xcworkspace │ ├── contents.xcworkspacedata │ └── xcshareddata │ └── Cycle Philly.xccheckout ├── Cycle Philly └── Images.xcassets │ ├── AppIcon.appiconset │ ├── Contents.json │ ├── appIcon29x29.png │ ├── appIcon58x58.png │ ├── appIcon@2x.png │ ├── appIcon@Retina.png │ ├── appicon57x57.png │ └── appretina.png │ └── LaunchImage.launchimage │ ├── Contents.json │ ├── Default-568h@2x.png │ ├── Default.png │ └── Default@2x.png ├── Cycle Philly_Prefix.pch ├── CycleAtlanta.xcdatamodeld ├── .xccurrentversion ├── CycleAtlanta 2.xcdatamodel │ ├── elements │ └── layout └── CycleAtlanta.xcdatamodel │ ├── elements │ └── layout ├── Deprecated Images ├── 20-gear2.png ├── ArrowButton.png ├── ClearArrowButton.png ├── ClearArrowButtonDark.png ├── ClearArrowButtonWideDark.png ├── GreenCheckMark.png ├── GreenCheckMark2.png ├── GreenCheckMark3.png ├── LargeCounter.png ├── LockIcon.png ├── OpacityMask80.png ├── OpacityMaskWindow.png ├── SlideToUnlock.png ├── UnlockIcon.png ├── cancel_button.png ├── lock_button1.png ├── lock_button2.png ├── lock_button_fpo.png ├── orangeslide.png ├── save_button.png ├── save_button_selected.png ├── slider_ball.png ├── start_button.png ├── start_button_selected.png └── yellowslide.png ├── DetailView.xib ├── Firebase.framework ├── Firebase ├── Headers └── Versions │ ├── A │ ├── Firebase │ └── Headers │ │ ├── FAuthData.h │ │ ├── FAuthType.h │ │ ├── FDataSnapshot.h │ │ ├── FEventType.h │ │ ├── FMutableData.h │ │ ├── FQuery.h │ │ ├── FTransactionResult.h │ │ ├── Firebase.h │ │ └── FirebaseServerValue.h │ └── Current ├── Images ├── Default.png ├── Icon.png ├── appStoreIcon1024.png ├── appStoreIcon512.png └── appicon57x57.png ├── IndegoIcons ├── indegoActive.png ├── indegoActive@2x.png ├── indegoComingSoon.png ├── indegoComingSoon@2x.png ├── indegoPartialService.png ├── indegoPartialService@2x.png ├── indegoSpecialEvent.png ├── indegoSpecialEvent@2x.png ├── indegoUnavailable.png └── indegoUnavailable@2x.png ├── IndegoStationStrings.h ├── IndegoStationStrings.m ├── MainWindow.xib ├── MapViewController.xib ├── Model.xcmappingmodel └── xcmapping.xml ├── NSString+MD5Addition.h ├── NSString+MD5Addition.m ├── Note.h ├── Note.m ├── PersonalInfo.xib ├── README.md ├── RecordMap.xib ├── TabBarIcons V2 ├── tabbar_instructions.png ├── tabbar_instructions@2x.png ├── tabbar_notes.png ├── tabbar_notes@2x.png ├── tabbar_record.png ├── tabbar_record@2x.png ├── tabbar_settings.png ├── tabbar_settings@2x.png ├── tabbar_view.png └── tabbar_view@2x.png ├── TabBarIcons ├── settings_icon2.png ├── tabbar_instructions.png ├── tabbar_record.png ├── tabbar_settings.png └── tabbar_view.png ├── TookTransitViewController.xib ├── Trip.h ├── Trip.m ├── TripPurposePicker.xib ├── TripPurposePickerIcons V3 ├── commute.png ├── commute@2x.png ├── errands.png ├── errands@2x.png ├── exercise.png ├── exercise@2x.png ├── failedUpload.png ├── failedUpload@2x.png ├── noteAssetMapGlyph.png ├── noteAssetMapGlyph@2x.png ├── noteAssetPicker.png ├── noteAssetPicker@2x.png ├── noteBlankPicker.png ├── noteBlankPicker@2x.png ├── noteIssueMapGlyph.png ├── noteIssueMapGlyph@2x.png ├── noteIssuePicker.png ├── noteIssuePicker@2x.png ├── other.png ├── other@2x.png ├── school.png ├── school@2x.png ├── shopping.png ├── shopping@2x.png ├── social.png ├── social@2x.png ├── tripEnd.png ├── tripEnd@2x.png ├── tripStart.png ├── tripStart@2x.png ├── workRelated.png └── workRelated@2x.png ├── TripPurposePickerIcons v2 ├── commute.tif ├── commuter2.png ├── errands.tif ├── exercise.tif ├── other.tif ├── school.tif ├── shopping.tif ├── social.tif └── work-related.tif ├── UI Elements ├── LCD-screen-288x126.png ├── MapCoord.png ├── lcd-screen.png ├── lcd-screen@2x.png ├── lcdScreen.png ├── lcdScreen@2x copy.png ├── lcdScreen@2x.png ├── photoFrame.png ├── photoFrame@2x.png └── record-map-frame-288x141.png ├── UIDevice+IdentifierAddition.h ├── UIDevice+IdentifierAddition.m ├── UIImageViewResizable.h ├── UIImageViewResizable.m ├── User.h ├── User.m ├── bicycle-bell-normalized.aiff ├── constants.h ├── dist.plist ├── main.m └── migrate.c /.gitignore: -------------------------------------------------------------------------------- 1 | # OS generated files # 2 | ###################### 3 | .DS_Store 4 | .DS_Store? 5 | ._* 6 | .Spotlight-V100 7 | .Trashes 8 | Icon? 9 | ehthumbs.db 10 | Thumbs.db 11 | *.swp 12 | *.lock 13 | profile 14 | 15 | #### 16 | # Xcode temporary files that should never be committed 17 | # 18 | # NB: NIB/XIB files still exist even on Storyboard projects, so we want this... 19 | 20 | *~.nib 21 | 22 | 23 | #### 24 | # Xcode build files - 25 | # 26 | # NB: slash on the end, so we only remove the FOLDER, not any files that were badly named "DerivedData" 27 | 28 | DerivedData/ 29 | 30 | # NB: slash on the end, so we only remove the FOLDER, not any files that were badly named "build" 31 | 32 | build/ 33 | 34 | 35 | ##### 36 | # Xcode private settings (window sizes, bookmarks, breakpoints, custom executables, smart groups) 37 | # 38 | # This is complicated: 39 | # 40 | # SOMETIMES you need to put this file in version control. 41 | # Apple designed it poorly - if you use "custom executables", they are 42 | # saved in this file. 43 | # 99% of projects do NOT use those, so they do NOT want to version control this file. 44 | # ..but if you're in the 1%, comment out the line "*.pbxuser" 45 | 46 | *.pbxuser 47 | *.mode1v3 48 | *.mode2v3 49 | *.perspectivev3 50 | # NB: also, whitelist the default ones, some projects need to use these 51 | !default.pbxuser 52 | !default.mode1v3 53 | !default.mode2v3 54 | !default.perspectivev3 55 | 56 | 57 | #### 58 | # Xcode 4 - semi-personal settings, often included in workspaces 59 | # 60 | # You can safely ignore the xcuserdata files - but do NOT ignore the files next to them 61 | # 62 | 63 | xcuserdata 64 | 65 | 66 | #### 67 | # XCode 4 workspaces - more detailed 68 | # 69 | # Workspaces are important! They are a core feature of Xcode - don't exclude them :) 70 | # 71 | # Workspace layout is quite spammy. For reference: 72 | # 73 | # (root)/ 74 | # (project-name).xcodeproj/ 75 | # project.pbxproj 76 | # project.xcworkspace/ 77 | # contents.xcworkspacedata 78 | # xcuserdata/ 79 | # (your name)/xcuserdatad/ 80 | # xcuserdata/ 81 | # (your name)/xcuserdatad/ 82 | # 83 | # 84 | # 85 | # Xcode 4 workspaces - SHARED 86 | # 87 | # This is UNDOCUMENTED (google: "developer.apple.com xcshareddata" - 0 results 88 | # But if you're going to kill personal workspaces, at least keep the shared ones... 89 | # 90 | # 91 | !xcshareddata 92 | 93 | 94 | #### 95 | # Xcode 4 - Deprecated classes 96 | # 97 | # Allegedly, if you manually "deprecate" your classes, they get moved here. 98 | # 99 | # We're using source-control, so this is a "feature" that we do not want! 100 | 101 | *.moved-aside -------------------------------------------------------------------------------- /AppIcons/20-gear2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/AppIcons/20-gear2.png -------------------------------------------------------------------------------- /AppIcons/Default-568h@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/AppIcons/Default-568h@2x.png -------------------------------------------------------------------------------- /AppIcons/Default.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/AppIcons/Default.png -------------------------------------------------------------------------------- /AppIcons/Default@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/AppIcons/Default@2x.png -------------------------------------------------------------------------------- /AppIcons/appIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/AppIcons/appIcon.png -------------------------------------------------------------------------------- /AppIcons/appIcon29x29.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/AppIcons/appIcon29x29.png -------------------------------------------------------------------------------- /AppIcons/appIcon58x58.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/AppIcons/appIcon58x58.png -------------------------------------------------------------------------------- /AppIcons/appIcon@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/AppIcons/appIcon@2x.png -------------------------------------------------------------------------------- /AppIcons/appIcon@Retina.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/AppIcons/appIcon@Retina.png -------------------------------------------------------------------------------- /AppIcons/appretina.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/AppIcons/appretina.png -------------------------------------------------------------------------------- /Button Icons/blueButton.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/blueButton.png -------------------------------------------------------------------------------- /Button Icons/blueButton@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/blueButton@2x.png -------------------------------------------------------------------------------- /Button Icons/blueButtonHighlight.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/blueButtonHighlight.png -------------------------------------------------------------------------------- /Button Icons/blueButtonHighlight@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/blueButtonHighlight@2x.png -------------------------------------------------------------------------------- /Button Icons/button@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/button@2x.png -------------------------------------------------------------------------------- /Button Icons/greenButton.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/greenButton.png -------------------------------------------------------------------------------- /Button Icons/greenButton@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/greenButton@2x.png -------------------------------------------------------------------------------- /Button Icons/greenButtonHighlight.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/greenButtonHighlight.png -------------------------------------------------------------------------------- /Button Icons/greenButtonHighlight@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/greenButtonHighlight@2x.png -------------------------------------------------------------------------------- /Button Icons/greyButton.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/greyButton.png -------------------------------------------------------------------------------- /Button Icons/greyButton@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/greyButton@2x.png -------------------------------------------------------------------------------- /Button Icons/redButton.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/redButton.png -------------------------------------------------------------------------------- /Button Icons/redButton@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/redButton@2x.png -------------------------------------------------------------------------------- /Button Icons/redButtonHighlight.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/redButtonHighlight.png -------------------------------------------------------------------------------- /Button Icons/redButtonHighlight@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/redButtonHighlight@2x.png -------------------------------------------------------------------------------- /Button Icons/whiteButton.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/whiteButton.png -------------------------------------------------------------------------------- /Button Icons/whiteButton@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/whiteButton@2x.png -------------------------------------------------------------------------------- /Button Icons/whiteButtonHighlight.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/whiteButtonHighlight.png -------------------------------------------------------------------------------- /Button Icons/whiteButtonHighlight@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Button Icons/whiteButtonHighlight@2x.png -------------------------------------------------------------------------------- /Classes/AboutViewController.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * 12 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 13 | * Atlanta, GA. USA 14 | * 15 | * @author Christopher Le Dantec 16 | * @author Anhong Guo 17 | * 18 | * Updated/Modified for Atlanta's app deployment. Based on the 19 | * CycleTracks codebase for SFCTA. 20 | * 21 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 22 | * San Francisco, CA, USA 23 | * 24 | * @author Matt Paul 25 | * 26 | * This file is part of CycleTracks. 27 | * 28 | * CycleTracks is free software: you can redistribute it and/or modify 29 | * it under the terms of the GNU General Public License as published by 30 | * the Free Software Foundation, either version 3 of the License, or 31 | * (at your option) any later version. 32 | * 33 | * CycleTracks is distributed in the hope that it will be useful, 34 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 35 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 36 | * GNU General Public License for more details. 37 | * 38 | * You should have received a copy of the GNU General Public License 39 | * along with CycleTracks. If not, see . 40 | */ 41 | 42 | // 43 | // AboutViewController.h 44 | // CycleTracks 45 | // 46 | // Created by Matt Paul on 2/23/10. 47 | // Copyright 2010 mopimp productions. All rights reserved. 48 | // 49 | 50 | #import 51 | 52 | 53 | @interface AboutViewController : UIViewController { 54 | IBOutlet UIWebView *webView; 55 | Boolean _over18; 56 | Boolean _alreadyConsent18; 57 | } 58 | 59 | @end 60 | -------------------------------------------------------------------------------- /Classes/AboutViewController.m: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // AboutViewController.m 43 | // CycleTracks 44 | // 45 | // Created by Matt Paul on 2/23/10. 46 | // Copyright 2010 mopimp productions. All rights reserved. 47 | // 48 | 49 | #import "AboutViewController.h" 50 | #import "constants.h" 51 | 52 | 53 | @implementation AboutViewController 54 | 55 | /* 56 | // The designated initializer. Override if you create the controller programmatically and want to perform customization that is not appropriate for viewDidLoad. 57 | - (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil { 58 | if (self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]) { 59 | // Custom initialization 60 | } 61 | return self; 62 | } 63 | */ 64 | 65 | /* 66 | // Implement loadView to create a view hierarchy programmatically, without using a nib. 67 | - (void)loadView { 68 | } 69 | */ 70 | 71 | 72 | // Implement viewDidLoad to do additional setup after loading the view, typically from a nib. 73 | - (void)viewDidLoad 74 | { 75 | [super viewDidLoad]; 76 | 77 | self.navigationController.navigationBar.barStyle = UIBarStyleBlackTranslucent; 78 | NSLog(@"About viewDidLoad"); 79 | //loads the instructions page everytime the app is started. good for testing. 80 | NSURL *url = [NSURL URLWithString:kInstructionsURL]; 81 | NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:url]; 82 | [request setCachePolicy:NSURLRequestReloadIgnoringLocalCacheData]; 83 | [webView loadRequest:request]; 84 | //loads the instructions page once and saves it unless the app is deleted 85 | //[webView loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:kInstructionsURL]]]; 86 | 87 | /*_alreadyConsent18 = [[NSUserDefaults standardUserDefaults] boolForKey:@"alreadyConsent18"]; 88 | 89 | if (!_alreadyConsent18) { 90 | 91 | [[NSUserDefaults standardUserDefaults] setBool: !_alreadyConsent18 92 | forKey: @"alreadyConsent18"]; 93 | [[NSUserDefaults standardUserDefaults] synchronize]; 94 | 95 | UIAlertView* alertView = [[[UIAlertView alloc] initWithTitle: kConsentFor18Title 96 | message: kConsentFor18Message 97 | delegate: self 98 | cancelButtonTitle: @"NO" 99 | otherButtonTitles: @"YES", nil] 100 | autorelease]; 101 | [alertView show]; 102 | }*/ 103 | } 104 | 105 | 106 | /* 107 | // Override to allow orientations other than the default portrait orientation. 108 | - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation { 109 | // Return YES for supported orientations 110 | return (interfaceOrientation == UIInterfaceOrientationPortrait); 111 | } 112 | */ 113 | 114 | - (void)didReceiveMemoryWarning { 115 | // Releases the view if it doesn't have a superview. 116 | [super didReceiveMemoryWarning]; 117 | 118 | // Release any cached data, images, etc that aren't in use. 119 | } 120 | 121 | 122 | - (void)dealloc { 123 | [webView release]; 124 | [super dealloc]; 125 | } 126 | 127 | /* 128 | #pragma mark UIAlertViewDelegate methods 129 | 130 | - (void)alertView:(UIAlertView *)alertView clickedButtonAtIndex:(NSInteger)buttonIndex { 131 | _over18 = !(buttonIndex == 0); 132 | [[NSUserDefaults standardUserDefaults] setBool: _over18 forKey:@"over18"]; 133 | [[NSUserDefaults standardUserDefaults] synchronize]; 134 | 135 | NSLog(@"User's age is over 18: %d", _over18); 136 | }*/ 137 | 138 | @end 139 | -------------------------------------------------------------------------------- /Classes/ActivityIndicatorDelegate.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // ActivityIndicatorDelegate.h 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 9/25/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | 51 | @protocol ActivityIndicatorDelegate 52 | 53 | @required 54 | 55 | - (void)dismissSaving; 56 | - (void)startAnimating; 57 | - (void)stopAnimating; 58 | 59 | - (void)updateBytesWritten:(NSInteger)totalBytesWritten totalBytesExpectedToWrite:(NSInteger)totalBytesExpectedToWrite; 60 | - (void)updateSavingMessage:(NSString *)message; 61 | 62 | @end 63 | -------------------------------------------------------------------------------- /Classes/CycleAtlantaAppDelegate.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * @author Corey Acri 6 | * @author Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 11 | * Atlanta, GA. USA 12 | * 13 | * @author Christopher Le Dantec 14 | * @author Anhong Guo 15 | * 16 | * Updated/Modified for Atlanta's app deployment. Based on the 17 | * CycleTracks codebase for SFCTA. 18 | * 19 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 20 | * San Francisco, CA, USA 21 | * 22 | * @author Matt Paul 23 | * 24 | * This file is part of CycleTracks. 25 | * 26 | * CycleTracks is free software: you can redistribute it and/or modify 27 | * it under the terms of the GNU General Public License as published by 28 | * the Free Software Foundation, either version 3 of the License, or 29 | * (at your option) any later version. 30 | * 31 | * CycleTracks is distributed in the hope that it will be useful, 32 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 33 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 34 | * GNU General Public License for more details. 35 | * 36 | * You should have received a copy of the GNU General Public License 37 | * along with CycleTracks. If not, see . 38 | */ 39 | 40 | // 41 | // CycleTracksAppDelegate.h 42 | // CycleTracks 43 | // 44 | // Copyright 2009-2010 SFCTA. All rights reserved. 45 | // Written by Matt Paul on 9/21/09. 46 | // For more information on the project, 47 | // e-mail Billy Charlton at the SFCTA 48 | #import 49 | 50 | @interface CycleAtlantaAppDelegate : NSObject 51 | { 52 | NSManagedObjectModel *managedObjectModel; 53 | NSManagedObjectContext *managedObjectContext; 54 | NSPersistentStoreCoordinator *persistentStoreCoordinator; 55 | 56 | UIWindow *window; 57 | UITabBarController *tabBarController; 58 | NSString *uniqueIDHash; 59 | //UIAlertView *consentFor18; 60 | // added to handle location manager background service switching 61 | BOOL isRecording; 62 | CLLocationManager *locationManager; 63 | } 64 | 65 | @property (nonatomic, retain, readonly) NSManagedObjectModel *managedObjectModel; 66 | @property (nonatomic, retain, readonly) NSManagedObjectContext *managedObjectContext; 67 | @property (nonatomic, retain, readonly) NSPersistentStoreCoordinator *persistentStoreCoordinator; 68 | 69 | @property (nonatomic, retain) IBOutlet UIWindow *window; 70 | @property (nonatomic, retain) IBOutlet UITabBarController *tabBarController; 71 | @property (nonatomic, retain) NSString *uniqueIDHash; 72 | //@property (nonatomic, retain) UIAlertView *consentFor18; 73 | // added to handle location manager background service switching 74 | @property (nonatomic, assign) BOOL isRecording; 75 | @property (nonatomic, retain) CLLocationManager *locationManager; 76 | 77 | - (NSString *)applicationDocumentsDirectory; 78 | - (void)initUniqueIDHash; 79 | 80 | @end 81 | 82 | -------------------------------------------------------------------------------- /Classes/DetailViewController.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Cycle Atlanta is free software: you can redistribute it and/or modify 18 | * it under the terms of the GNU General Public License as published by 19 | * the Free Software Foundation, either version 3 of the License, or 20 | * (at your option) any later version. 21 | * 22 | * Cycle Atlanta is distributed in the hope that it will be useful, 23 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 24 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 25 | * GNU General Public License for more details. 26 | * 27 | * You should have received a copy of the GNU General Public License 28 | * along with Cycle Atlanta. If not, see . 29 | */ 30 | 31 | #import 32 | #import 33 | #import "TripPurposeDelegate.h" 34 | 35 | @interface DetailViewController : UIViewController{ 36 | id delegate; 37 | UITextView *detailTextView; 38 | UIButton *addPicButton; 39 | NSInteger pickerCategory; 40 | NSString *details; 41 | UIImage *image; 42 | NSData *imageData; 43 | } 44 | 45 | @property (nonatomic, retain) id delegate; 46 | 47 | @property (nonatomic, retain) IBOutlet UITextView *detailTextView; 48 | @property (nonatomic, retain) IBOutlet UIButton *addPicButton; 49 | 50 | @property (strong, nonatomic) IBOutlet UIImageView *imageView; 51 | @property (strong, nonatomic) IBOutlet UIImageView *imageFrameView; 52 | 53 | @property (strong, nonatomic) UIImage *image; 54 | @property (strong, nonatomic) UIImage *imageFrame; 55 | @property (readwrite, retain) NSData *imageData; 56 | 57 | @property (copy, nonatomic) NSString *lastChosenMediaType; 58 | 59 | - (IBAction)skip:(id)sender; 60 | - (IBAction)saveDetail:(id)sender; 61 | - (IBAction)shootPictureOrVideo:(id)sender; 62 | - (IBAction)selectExistingPictureOrVideo:(id)sender; 63 | 64 | 65 | 66 | @end 67 | -------------------------------------------------------------------------------- /Classes/ImageResize.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Cycle Atlanta is free software: you can redistribute it and/or modify 18 | * it under the terms of the GNU General Public License as published by 19 | * the Free Software Foundation, either version 3 of the License, or 20 | * (at your option) any later version. 21 | * 22 | * Cycle Atlanta is distributed in the hope that it will be useful, 23 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 24 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 25 | * GNU General Public License for more details. 26 | * 27 | * You should have received a copy of the GNU General Public License 28 | * along with Cycle Atlanta. If not, see . 29 | */ 30 | 31 | #import 32 | 33 | @interface ImageResize : NSObject 34 | 35 | + (UIImage*)imageWithImage:(UIImage*)sourceImage scaledToSizeWithSameAspectRatio:(CGSize)targetSize; 36 | + (UIImage*)imageWithImage:(UIImage*)sourceImage scaledToSize:(CGSize)targetSize; 37 | 38 | @end 39 | -------------------------------------------------------------------------------- /Classes/LoadingView.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * This file is part of CycleTracks. 24 | * 25 | * CycleTracks is free software: you can redistribute it and/or modify 26 | * it under the terms of the GNU General Public License as published by 27 | * the Free Software Foundation, either version 3 of the License, or 28 | * (at your option) any later version. 29 | * 30 | * CycleTracks is distributed in the hope that it will be useful, 31 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 32 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 33 | * GNU General Public License for more details. 34 | * 35 | * You should have received a copy of the GNU General Public License 36 | * along with CycleTracks. If not, see . 37 | */ 38 | 39 | // 40 | // LoadingView.h 41 | // LoadingView 42 | // 43 | // Created by Matt Gallagher on 12/04/09. 44 | // Copyright Matt Gallagher 2009. All rights reserved. 45 | // 46 | // Permission is given to use this source code file, free of charge, in any 47 | // project, commercial or otherwise, entirely at your risk, with the condition 48 | // that any redistribution (in part or whole) of source code must retain 49 | // this copyright and permission notice. Attribution in compiled projects is 50 | // appreciated but not required. 51 | // 52 | 53 | #import 54 | 55 | @interface LoadingView : UIView 56 | { 57 | 58 | } 59 | 60 | @property (nonatomic, retain) UILabel *loadingLabel; 61 | @property (nonatomic, retain) UIActivityIndicatorView *activityIndicatorView; 62 | 63 | + (id)loadingViewInView:(UIView *)aSuperview messageString:(NSString *)message; 64 | - (void)loadingComplete:(NSString *) completeMessage delayInterval:(NSTimeInterval)delay; 65 | - (void)removeView; 66 | 67 | @end 68 | -------------------------------------------------------------------------------- /Classes/MKPointAnnotation+IndegoPointAnnotation.h: -------------------------------------------------------------------------------- 1 | // 2 | // MKPointAnnotation+IndegoPointAnnotation.h 3 | // Cycle Philly 4 | // 5 | // Created by Kathryn Killebrew on 7/12/15. 6 | // 7 | // 8 | 9 | #import 10 | 11 | @interface MKPointAnnotation (IndegoPointAnnotation) 12 | @property NSString *stationStatus; 13 | @end 14 | -------------------------------------------------------------------------------- /Classes/MKPointAnnotation+IndegoPointAnnotation.m: -------------------------------------------------------------------------------- 1 | // 2 | // MKPointAnnotation+IndegoPointAnnotation.m 3 | // Cycle Philly 4 | // 5 | // Created by Kathryn Killebrew on 7/12/15. 6 | // 7 | // 8 | 9 | #import 10 | 11 | #import "MKPointAnnotation+IndegoPointAnnotation.h" 12 | 13 | @implementation MKPointAnnotation (IndegoPointAnnotation) 14 | @dynamic stationStatus; 15 | 16 | // associated objects icky hack required to add property for determining which marker icon to use 17 | // http://nshipster.com/associated-objects/ 18 | 19 | - (void)setStationStatus:(NSString *)stationStatus { 20 | objc_setAssociatedObject(self, @selector(stationStatus), stationStatus, OBJC_ASSOCIATION_RETAIN_NONATOMIC); 21 | } 22 | 23 | - (id)stationStatus { 24 | return objc_getAssociatedObject(self, @selector(stationStatus)); 25 | } 26 | @end 27 | -------------------------------------------------------------------------------- /Classes/MapCoord.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | * CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // MapCoord.h 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 8/8/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | #import 51 | #import 52 | #import 53 | 54 | 55 | @interface MapCoord : NSObject 56 | { 57 | CLLocationCoordinate2D coordinate; 58 | NSString *title; 59 | NSString *subtitle; 60 | 61 | BOOL first; 62 | BOOL last; 63 | } 64 | 65 | @property (nonatomic) CLLocationCoordinate2D coordinate; 66 | @property (nonatomic, copy) NSString *title; 67 | @property (nonatomic, copy) NSString *subtitle; 68 | 69 | @property (assign) BOOL first; 70 | @property (assign) BOOL last; 71 | 72 | - (void) print; 73 | 74 | @end 75 | -------------------------------------------------------------------------------- /Classes/MapCoord.m: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // MapCoord.m 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 8/8/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | #import "MapCoord.h" 51 | 52 | 53 | @implementation MapCoord 54 | 55 | @synthesize coordinate, title, subtitle, first, last; 56 | 57 | 58 | - (id) init 59 | { 60 | if ( self = [super init] ) 61 | { 62 | first = NO; 63 | last = NO; 64 | } 65 | return self; 66 | } 67 | 68 | 69 | - (void) print 70 | { 71 | NSLog(@"%f lat, %f lon", coordinate.latitude, coordinate.longitude); 72 | } 73 | 74 | - (void)dealloc 75 | { 76 | self.title = nil; 77 | self.subtitle = nil; 78 | self.first = nil; 79 | self.last = nil; 80 | 81 | [title release]; 82 | [subtitle release]; 83 | 84 | [super dealloc]; 85 | } 86 | 87 | 88 | @end 89 | -------------------------------------------------------------------------------- /Classes/MapViewController.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // MapViewController.h 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 9/28/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | #import 51 | #import 52 | #import 53 | #import "TripManager.h" 54 | #import "TripPurposeDelegate.h" 55 | 56 | 57 | @interface MapViewController : UIViewController 58 | { 59 | id delegate; 60 | IBOutlet MKMapView *mapView; 61 | Trip *trip; 62 | 63 | UIBarButtonItem *doneButton; 64 | UIBarButtonItem *flipButton; 65 | UIView *infoView; 66 | } 67 | 68 | @property (nonatomic, retain) id delegate; 69 | @property (nonatomic, retain) Trip *trip; 70 | @property (nonatomic, retain) UIBarButtonItem *doneButton; 71 | @property (nonatomic, retain) UIBarButtonItem *flipButton; 72 | @property (nonatomic, retain) UIView *infoView; 73 | @property (nonatomic, retain) MKPolyline* routeLine; 74 | 75 | - (id)initWithTrip:(Trip *)trip; 76 | 77 | 78 | @end 79 | -------------------------------------------------------------------------------- /Classes/NoteViewController.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /Classes/PersonalInfoDelegate.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // PersonalInfoDelegate.h 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 9/25/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | 51 | @protocol PersonalInfoDelegate 52 | 53 | @required 54 | - (void)setSaved:(BOOL)value; 55 | @end 56 | -------------------------------------------------------------------------------- /Classes/PersonalInfoViewController.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // PersonalInfoViewController.h 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 9/23/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | #import 51 | #import 52 | #import "PersonalInfoDelegate.h" 53 | 54 | 55 | @class User; 56 | 57 | 58 | @interface PersonalInfoViewController : UITableViewController 59 | { 60 | id delegate; 61 | NSManagedObjectContext *managedObjectContext; 62 | User *user; 63 | 64 | UITextField *age; 65 | UITextField *email; 66 | UITextField *gender; 67 | UITextField *ethnicity; 68 | UITextField *income; 69 | UITextField *homeZIP; 70 | UITextField *workZIP; 71 | UITextField *schoolZIP; 72 | UITextField *cyclingFreq; 73 | UITextField *riderType; 74 | UITextField *riderHistory; 75 | UIToolbar *doneToolbar; 76 | UIActionSheet *actionSheet; 77 | UIPickerView *pickerView; 78 | UITextField *currentTextField; 79 | 80 | NSArray *genderArray; 81 | NSArray *ageArray; 82 | NSArray *ethnicityArray; 83 | NSArray *incomeArray; 84 | NSArray *cyclingFreqArray; 85 | NSArray *riderTypeArray; 86 | NSArray *riderHistoryArray; 87 | 88 | NSInteger ageSelectedRow; 89 | NSInteger genderSelectedRow; 90 | NSInteger ethnicitySelectedRow; 91 | NSInteger incomeSelectedRow; 92 | NSInteger cyclingFreqSelectedRow; 93 | NSInteger riderTypeSelectedRow; 94 | NSInteger riderHistorySelectedRow; 95 | NSInteger selectedItem; 96 | } 97 | 98 | 99 | @property (nonatomic, retain) id delegate; 100 | @property (nonatomic, retain) NSManagedObjectContext *managedObjectContext; 101 | @property (nonatomic, retain) User *user; 102 | 103 | @property (nonatomic, retain) UITextField *age; 104 | @property (nonatomic, retain) UITextField *email; 105 | @property (nonatomic, retain) UITextField *gender; 106 | @property (nonatomic, retain) UITextField *ethnicity; 107 | @property (nonatomic, retain) UITextField *income; 108 | @property (nonatomic, retain) UITextField *homeZIP; 109 | @property (nonatomic, retain) UITextField *workZIP; 110 | @property (nonatomic, retain) UITextField *schoolZIP; 111 | 112 | @property (nonatomic, retain) UITextField *cyclingFreq; 113 | @property (nonatomic, retain) UITextField *riderType; 114 | @property (nonatomic, retain) UITextField *riderHistory; 115 | 116 | @property (nonatomic) NSInteger ageSelectedRow; 117 | @property (nonatomic) NSInteger genderSelectedRow; 118 | @property (nonatomic) NSInteger ethnicitySelectedRow; 119 | @property (nonatomic) NSInteger incomeSelectedRow; 120 | @property (nonatomic) NSInteger cyclingFreqSelectedRow; 121 | @property (nonatomic) NSInteger riderTypeSelectedRow; 122 | @property (nonatomic) NSInteger riderHistorySelectedRow; 123 | @property (nonatomic) NSInteger selectedItem; 124 | 125 | // DEPRECATED 126 | - (id)initWithManagedObjectContext:(NSManagedObjectContext*)context; 127 | 128 | - (void)done; 129 | 130 | @end 131 | -------------------------------------------------------------------------------- /Classes/PickerViewController.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // PickerViewController.h 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 9/28/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | #import 51 | #import "CustomPickerDataSource.h" 52 | #import "TripPurposeDelegate.h" 53 | #import "Note.h" 54 | #import "RecordTripViewController.h" 55 | 56 | 57 | @interface PickerViewController : UIViewController 58 | { 59 | id delegate; 60 | UIPickerView *customPickerView; 61 | CustomPickerDataSource *customPickerDataSource; 62 | 63 | UITextView *description; 64 | NSInteger pickerCategory; 65 | NSInteger pickedNotedType; 66 | IBOutlet UINavigationBar *navBarItself; 67 | UILabel *descriptionText; 68 | 69 | } 70 | 71 | 72 | @property (nonatomic, retain) id delegate; 73 | @property (nonatomic, retain) IBOutlet UIPickerView *customPickerView; 74 | @property (nonatomic, retain) CustomPickerDataSource *customPickerDataSource; 75 | 76 | @property (atomic, retain) UITextView *descriptionText; 77 | 78 | @property (nonatomic, retain) IBOutlet UILabel *descriptionLabel; 79 | 80 | - (id)initWithPurpose:(NSInteger)index; 81 | 82 | - (IBAction)cancel:(id)sender; 83 | - (IBAction)save:(id)sender; 84 | 85 | @end 86 | -------------------------------------------------------------------------------- /Classes/RecordTripViewController.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // RecordTripViewController.h 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 8/10/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | 51 | #import 52 | #import "ActivityIndicatorDelegate.h" 53 | #import 54 | #import "PersonalInfoDelegate.h" 55 | #import "RecordingInProgressDelegate.h" 56 | #import "TripPurposeDelegate.h" 57 | #import "CycleAtlantaAppDelegate.h" 58 | #import 59 | 60 | 61 | @class ReminderManager; 62 | @class TripManager; 63 | //@class CycleTracksAppDelegate; 64 | 65 | //@interface RecordTripViewController : UITableViewController 66 | @interface RecordTripViewController : UIViewController 67 | 77 | { 78 | NSManagedObjectContext *managedObjectContext; 79 | CycleAtlantaAppDelegate *appDelegate; 80 | // CLLocationManager *locationManager; 81 | /* 82 | UITableViewCell *tripPurposeCell; 83 | UITableViewCell *personalInfoCell; 84 | */ 85 | BOOL didUpdateUserLocation; 86 | IBOutlet MKMapView *mapView; 87 | 88 | IBOutlet UIButton *infoButton; 89 | IBOutlet UIButton *saveButton; 90 | IBOutlet UIButton *startButton; 91 | 92 | IBOutlet UILabel *timeCounter; 93 | IBOutlet UILabel *distCounter; 94 | IBOutlet UILabel *speedCounter; 95 | UIActionSheet *saveActionSheet; 96 | 97 | 98 | NSTimer *timer; 99 | 100 | // pointer to opacity mask, TabBar view 101 | UIView *opacityMask; 102 | UIView *parentView; 103 | 104 | BOOL recording; 105 | BOOL shouldUpdateCounter; 106 | BOOL userInfoSaved; 107 | NSInteger pickerCategory; 108 | 109 | TripManager *tripManager; 110 | 111 | CLLocation *myLocation; 112 | // ReminderManager *reminderManager; 113 | } 114 | 115 | //@property (nonatomic, retain) NSManagedObjectContext *managedObjectContext; 116 | 117 | //@property (nonatomic, retain) CLLocationManager *locationManager; 118 | /* 119 | @property (nonatomic, retain) UITableViewCell *tripPurposeCell; 120 | @property (nonatomic, retain) UITableViewCell *personalInfoCell; 121 | */ 122 | @property (nonatomic, retain) UIButton *infoButton; 123 | @property (nonatomic, retain) UIButton *saveButton; 124 | @property (nonatomic, retain) UIButton *startButton; 125 | 126 | @property (nonatomic, retain) UILabel *timeCounter; 127 | @property (nonatomic, retain) UILabel *distCounter; 128 | @property (nonatomic, retain) UIActionSheet *saveActionSheet; 129 | 130 | 131 | @property (assign) NSTimer *timer; 132 | 133 | @property (nonatomic, retain) UIView *parentView; 134 | 135 | 136 | @property (assign) BOOL recording; 137 | @property (assign) BOOL shouldUpdateCounter; 138 | @property (assign) BOOL userInfoSaved; 139 | 140 | //@property (nonatomic, retain) ReminderManager *reminderManager; 141 | @property (nonatomic, retain) TripManager *tripManager; 142 | 143 | @property (nonatomic, retain) CycleAtlantaAppDelegate *appDelegate; 144 | 145 | - (void)initTripManager:(TripManager*)manager; 146 | 147 | // DEPRECATED 148 | //- (id)initWithManagedObjectContext:(NSManagedObjectContext*)context; 149 | //- (id)initWithTripManager:(TripManager*)manager; 150 | 151 | // IBAction handlers 152 | - (IBAction)save:(UIButton *)sender; 153 | - (void)save; 154 | 155 | - (IBAction)start:(UIButton *)sender; 156 | 157 | // timer methods 158 | - (void)start:(UIButton *)sender; 159 | - (void)createCounter; 160 | - (void)resetCounter; 161 | - (void)setCounterTimeSince:(NSDate *)startDate distance:(CLLocationDistance)distance; 162 | - (void)updateCounter:(NSTimer *)theTimer; 163 | 164 | - (UIButton *)newSaveButton; 165 | - (UIButton *)createStartButton; 166 | 167 | - (void)displayUploadedTripMap; 168 | 169 | @end 170 | -------------------------------------------------------------------------------- /Classes/RecordingInProgressDelegate.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // RecordingInProgressDelegate.h 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 10/05/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | @class Trip; 51 | 52 | @protocol RecordingInProgressDelegate 53 | 54 | @required 55 | - (CLLocationManager*)getLocationManager; 56 | - (Trip*)getRecordingInProgress; 57 | @end 58 | -------------------------------------------------------------------------------- /Classes/ReminderManager.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // ReminderManager.h 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 9/30/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | #import 51 | #import 52 | #import "RecordingInProgressDelegate.h" 53 | 54 | @class Reminder; 55 | 56 | @interface ReminderManager : NSObject 57 | { 58 | NSMutableArray *reminders; 59 | } 60 | 61 | @property (nonatomic, retain) NSMutableArray *reminders; 62 | 63 | - (id)initWithRecordingInProgressDelegate:(id )delegate; 64 | - (void)enableReminders; 65 | - (void)disableReminders; 66 | 67 | @end 68 | -------------------------------------------------------------------------------- /Classes/SaveRequest.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // SaveRequest.h 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 8/25/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | #import 51 | 52 | 53 | @interface SaveRequest : NSObject 54 | { 55 | NSMutableURLRequest *request; 56 | NSString *deviceUniqueIdHash; 57 | NSMutableDictionary *postVars; 58 | } 59 | 60 | @property (nonatomic, retain) NSMutableURLRequest *request; 61 | @property (nonatomic, retain) NSMutableDictionary *postVars; 62 | @property (nonatomic, retain) NSString *deviceUniqueIdHash; 63 | 64 | - initWithPostVars:(NSDictionary *)inPostVars with:(NSInteger) type image:(NSData*) imageData; 65 | 66 | @end 67 | -------------------------------------------------------------------------------- /Classes/SavedTripsViewController.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // SavedTripsViewController.h 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 8/10/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | #import 51 | #import 52 | #import "ActivityIndicatorDelegate.h" 53 | #import "RecordingInProgressDelegate.h" 54 | 55 | // Check system version to size text labels 56 | #define IOS_6_OR_EARLIER ([[[UIDevice currentDevice] systemVersion] floatValue] < 7.0) 57 | 58 | @class LoadingView; 59 | @class MapViewController; 60 | @class Trip; 61 | @class TripManager; 62 | 63 | @interface SavedTripsViewController : UITableViewController 64 | 68 | { 69 | NSMutableArray *trips; 70 | NSManagedObjectContext *managedObjectContext; 71 | 72 | id delegate; 73 | TripManager *tripManager; 74 | Trip *selectedTrip; 75 | 76 | LoadingView *loading; 77 | 78 | NSInteger pickerCategory; 79 | } 80 | 81 | @property (nonatomic, retain) NSMutableArray *trips; 82 | @property (nonatomic, retain) NSManagedObjectContext *managedObjectContext; 83 | 84 | @property (nonatomic, retain) id delegate; 85 | @property (nonatomic, retain) TripManager *tripManager; 86 | @property (nonatomic, retain) Trip *selectedTrip; 87 | 88 | - (void)initTripManager:(TripManager*)manager; 89 | 90 | - (void)displayUploadedTripMap; 91 | // DEPRECATED 92 | - (id)initWithManagedObjectContext:(NSManagedObjectContext*)context; 93 | - (id)initWithTripManager:(TripManager*)manager; 94 | 95 | @end 96 | -------------------------------------------------------------------------------- /Classes/TookTransitViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // TookTransitViewController.h 3 | // Cycle Philly 4 | // 5 | // Created by kat on 4/19/14. 6 | // 7 | // 8 | 9 | #import 10 | #import "TripPurposeDelegate.h" 11 | 12 | @interface TookTransitViewController : UIViewController 13 | { 14 | UIView *tookTransitView; 15 | UILabel *transitText; 16 | UILabel *answerTransitYesNo; 17 | UISwitch *tookPublicTransit; 18 | UILabel *rentalText; 19 | UILabel *answerRentalYesNo; 20 | UISwitch *tookRental; 21 | 22 | 23 | id delegate; 24 | IBOutlet UINavigationBar *navBarItself; 25 | } 26 | 27 | @property (nonatomic, retain) IBOutlet UIView *tookTransitView; 28 | @property (nonatomic, retain) IBOutlet UILabel *transitText; 29 | @property (nonatomic, retain) IBOutlet UILabel * answerTransitYesNo; 30 | @property (nonatomic, retain) IBOutlet UISwitch *tookPublicTransit; 31 | @property (nonatomic, retain) IBOutlet UILabel *rentalText; 32 | @property (nonatomic, retain) IBOutlet UILabel * answerRentalYesNo; 33 | @property (nonatomic, retain) IBOutlet UISwitch *tookRental; 34 | @property (nonatomic, retain) id delegate; 35 | 36 | -(IBAction)cancel:(id)sender; 37 | -(IBAction)saveDetail:(id)sender; 38 | -(IBAction)answerChanged:(UISwitch *)sender; 39 | 40 | @end -------------------------------------------------------------------------------- /Classes/TookTransitViewController.m: -------------------------------------------------------------------------------- 1 | // 2 | // TookTransitViewController.m 3 | // Cycle Philly 4 | // 5 | // Created by kat on 4/19/14. 6 | // 7 | // 8 | 9 | #import "TookTransitViewController.h" 10 | #import "TripDetailViewController.h" 11 | 12 | @interface TookTransitViewController () 13 | @end 14 | 15 | @implementation TookTransitViewController 16 | 17 | @synthesize tookTransitView; 18 | @synthesize tookPublicTransit, transitText, answerTransitYesNo; 19 | @synthesize tookRental, rentalText, answerRentalYesNo; 20 | @synthesize delegate; 21 | 22 | - (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil 23 | { 24 | self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]; 25 | if (self) { 26 | // Custom initialization 27 | } 28 | return self; 29 | } 30 | 31 | - (void)viewDidLoad 32 | { 33 | [super viewDidLoad]; 34 | [self.view addSubview:tookTransitView]; 35 | } 36 | 37 | - (void)didReceiveMemoryWarning 38 | { 39 | [super didReceiveMemoryWarning]; 40 | // Dispose of any resources that can be recreated. 41 | } 42 | 43 | -(IBAction)answerChanged:(UISwitch *)sender { 44 | NSLog(@"Switch moved"); 45 | if (sender == self.tookPublicTransit) { 46 | if (self.tookPublicTransit.on) { 47 | self.answerTransitYesNo.text = @"Yes"; 48 | } else { 49 | self.answerTransitYesNo.text = @"No"; 50 | } 51 | } else if (sender == self.tookRental) { 52 | if (self.tookRental.on) { 53 | self.answerRentalYesNo.text = @"Yes"; 54 | } else { 55 | self.answerRentalYesNo.text = @"No"; 56 | } 57 | } else { 58 | NSLog(@"Unrecognized switch in TookTransitViewController"); 59 | } 60 | 61 | 62 | } 63 | 64 | -(IBAction)cancel:(id)sender{ 65 | NSLog(@"Cancelled"); 66 | 67 | [tookTransitView resignFirstResponder]; 68 | [delegate didCancelNote]; 69 | } 70 | 71 | -(IBAction)saveDetail:(id)sender{ 72 | NSLog(@"Save Detail"); 73 | 74 | if (self.tookPublicTransit.on) { 75 | NSLog(@"Noted took transit in TookTransitViewController"); 76 | [delegate didTakeTransit]; 77 | } 78 | 79 | if (self.tookRental.on) { 80 | NSLog(@"Noted took bike rental in TookTransitViewController"); 81 | [delegate didTakeBikeRental]; 82 | } 83 | 84 | TripDetailViewController *tripDetailViewController = [[TripDetailViewController alloc] initWithNibName:@"TripDetailViewController" bundle:nil]; 85 | tripDetailViewController.delegate = self.delegate; 86 | 87 | [self presentViewController:tripDetailViewController animated:YES completion:nil]; 88 | 89 | } 90 | 91 | - (void)dealloc { 92 | self.delegate = nil; 93 | self.tookTransitView = nil; 94 | self.tookPublicTransit = nil; 95 | self.tookRental = nil; 96 | self.transitText = nil; 97 | self.rentalText = nil; 98 | 99 | [transitText release]; 100 | [rentalText release]; 101 | [tookPublicTransit release]; 102 | [tookRental release]; 103 | [delegate release]; 104 | 105 | [navBarItself release]; 106 | 107 | [super dealloc]; 108 | } 109 | 110 | @end -------------------------------------------------------------------------------- /Classes/TripDetailViewController.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Cycle Atlanta is free software: you can redistribute it and/or modify 18 | * it under the terms of the GNU General Public License as published by 19 | * the Free Software Foundation, either version 3 of the License, or 20 | * (at your option) any later version. 21 | * 22 | * Cycle Atlanta is distributed in the hope that it will be useful, 23 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 24 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 25 | * GNU General Public License for more details. 26 | * 27 | * You should have received a copy of the GNU General Public License 28 | * along with Cycle Atlanta. If not, see . 29 | */ 30 | 31 | #import 32 | #import 33 | #import "TripPurposeDelegate.h" 34 | 35 | @interface TripDetailViewController : UIViewController 36 | { 37 | id delegate; 38 | UITextView *detailTextView; 39 | NSInteger pickerCategory; 40 | NSString *details; 41 | } 42 | 43 | @property (nonatomic, retain) id delegate; 44 | 45 | @property (nonatomic, retain) IBOutlet UITextView *detailTextView; 46 | 47 | 48 | -(IBAction)skip:(id)sender; 49 | -(IBAction)saveDetail:(id)sender; 50 | 51 | @end 52 | -------------------------------------------------------------------------------- /Classes/TripDetailViewController.m: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Cycle Atlanta is free software: you can redistribute it and/or modify 18 | * it under the terms of the GNU General Public License as published by 19 | * the Free Software Foundation, either version 3 of the License, or 20 | * (at your option) any later version. 21 | * 22 | * Cycle Atlanta is distributed in the hope that it will be useful, 23 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 24 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 25 | * GNU General Public License for more details. 26 | * 27 | * You should have received a copy of the GNU General Public License 28 | * along with Cycle Atlanta. If not, see . 29 | */ 30 | 31 | #import "TripDetailViewController.h" 32 | 33 | @interface TripDetailViewController () 34 | 35 | @end 36 | 37 | @implementation TripDetailViewController 38 | @synthesize delegate; 39 | @synthesize detailTextView; 40 | 41 | - (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil 42 | { 43 | self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]; 44 | if (self) { 45 | // Custom initialization 46 | } 47 | return self; 48 | } 49 | 50 | - (UIBarPosition)positionForBar:(id)bar { 51 | return UIBarPositionTopAttached; 52 | } 53 | 54 | - (void)viewDidLoad 55 | { 56 | [self.detailTextView becomeFirstResponder]; 57 | [super viewDidLoad]; 58 | // Do any additional setup after loading the view from its nib. 59 | detailTextView.layer.borderWidth = 1.0; 60 | detailTextView.layer.borderColor = [[UIColor blackColor] CGColor]; 61 | } 62 | 63 | -(IBAction)skip:(id)sender{ 64 | NSLog(@"Skip"); 65 | [delegate didCancelNote]; 66 | 67 | pickerCategory = [[NSUserDefaults standardUserDefaults] integerForKey:@"pickerCategory"]; 68 | [[NSUserDefaults standardUserDefaults] setInteger:0 forKey: @"pickerCategory"]; 69 | [[NSUserDefaults standardUserDefaults] synchronize]; 70 | 71 | details = @""; 72 | 73 | [delegate didEnterTripDetails:details]; 74 | [delegate saveTrip]; 75 | } 76 | 77 | -(IBAction)saveDetail:(id)sender{ 78 | NSLog(@"Save Detail"); 79 | [detailTextView resignFirstResponder]; 80 | [delegate didCancelNote]; 81 | 82 | pickerCategory = [[NSUserDefaults standardUserDefaults] integerForKey:@"pickerCategory"]; 83 | [[NSUserDefaults standardUserDefaults] setInteger:0 forKey: @"pickerCategory"]; 84 | [[NSUserDefaults standardUserDefaults] synchronize]; 85 | 86 | details = detailTextView.text; 87 | 88 | [delegate didEnterTripDetails:details]; 89 | [delegate saveTrip]; 90 | } 91 | 92 | 93 | - (void)didReceiveMemoryWarning 94 | { 95 | [super didReceiveMemoryWarning]; 96 | // Dispose of any resources that can be recreated. 97 | } 98 | 99 | - (void)dealloc { 100 | self.delegate = nil; 101 | self.detailTextView = nil; 102 | 103 | [delegate release]; 104 | [detailTextView release]; 105 | 106 | [super dealloc]; 107 | } 108 | 109 | @end 110 | -------------------------------------------------------------------------------- /Classes/TripDetailViewController.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | -------------------------------------------------------------------------------- /Classes/TripManager.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // TripManager.h 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 9/22/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | 51 | #import 52 | #import 53 | #import "ActivityIndicatorDelegate.h" 54 | #import "TripPurposeDelegate.h" 55 | #import "LoadingView.h" 56 | 57 | @class Trip; 58 | 59 | 60 | @interface TripManager : NSObject 61 | 65 | { 66 | UIAlertView *saving; 67 | UIAlertView *tripNotes; 68 | UITextView *tripNotesText; 69 | // id activityDelegate; 70 | // id alertDelegate; 71 | // UIActivityIndicatorView *activityIndicator; 72 | 73 | BOOL dirty; 74 | Trip *trip; 75 | CLLocationDistance distance; 76 | NSInteger purposeIndex; 77 | 78 | NSMutableArray *coords; 79 | NSManagedObjectContext *managedObjectContext; 80 | 81 | NSMutableData *receivedData; 82 | 83 | NSMutableArray *unSavedTrips; 84 | NSMutableArray *unSyncedTrips; 85 | NSMutableArray *zeroDistanceTrips; 86 | } 87 | 88 | @property (nonatomic, retain) id activityDelegate; 89 | @property (nonatomic, retain) id alertDelegate; 90 | 91 | @property (nonatomic, retain) UIActivityIndicatorView *activityIndicator; 92 | @property (nonatomic, retain) LoadingView *uploadingView; 93 | 94 | @property (nonatomic, retain) UIViewController *parent; 95 | 96 | @property (nonatomic, retain) UIAlertView *saving; 97 | @property (nonatomic, retain) UIAlertView *tripNotes; 98 | @property (nonatomic, retain) UITextView *tripNotesText; 99 | 100 | @property (assign) BOOL dirty; 101 | @property (nonatomic, retain) Trip *trip; 102 | 103 | @property (nonatomic, retain) NSMutableArray *coords; 104 | @property (nonatomic, retain) NSManagedObjectContext *managedObjectContext; 105 | 106 | @property (nonatomic, retain) NSMutableData *receivedData; 107 | 108 | 109 | - (id)initWithManagedObjectContext:(NSManagedObjectContext*)context; 110 | - (id)initWithTrip:(Trip*)trip; 111 | - (BOOL)loadTrip:(Trip*)trip; 112 | 113 | - (void)createTrip; 114 | - (void)createTrip:(long)index; 115 | 116 | - (CLLocationDistance)addCoord:(CLLocation*)location; 117 | - (void)saveTookTransit; 118 | - (void)saveTookBikeRental; 119 | - (void)saveNotes:(NSString*)notes; 120 | - (void)saveTrip; 121 | - (void)discardTrip; 122 | 123 | - (CLLocationDistance)getDistanceEstimate; 124 | 125 | - (NSInteger)getPurposeIndex; 126 | 127 | //- (void)promptForTripNotes; 128 | 129 | - (long)countUnSavedTrips; 130 | - (long)countUnSyncedTrips; 131 | - (long)countZeroDistanceTrips; 132 | 133 | - (BOOL)loadMostRecentUnSavedTrip; 134 | - (long)recalculateTripDistances; 135 | - (CLLocationDistance)calculateTripDistance:(Trip*)_trip; 136 | 137 | @end 138 | 139 | 140 | @interface TripPurpose : NSObject { } 141 | 142 | + (long)getPurposeIndex:(NSString*)string; 143 | + (NSString *)getPurposeString:(long)index; 144 | 145 | @end 146 | 147 | 148 | -------------------------------------------------------------------------------- /Classes/TripPurposeDelegate.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // TripPurposeDelegate.h 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 9/22/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | 51 | #define kTripPurposeCommute 0 52 | #define kTripPurposeSchool 1 53 | #define kTripPurposeWork 2 54 | #define kTripPurposeExercise 3 55 | #define kTripPurposeSocial 4 56 | #define kTripPurposeShopping 5 57 | #define kTripPurposeErrand 6 58 | #define kTripPurposeOther 7 59 | 60 | #define kTripPurposeCommuteIcon @"commute.png" 61 | #define kTripPurposeSchoolIcon @"school.png" 62 | #define kTripPurposeWorkIcon @"workRelated.png" 63 | #define kTripPurposeExerciseIcon @"exercise.png" 64 | #define kTripPurposeSocialIcon @"social.png" 65 | #define kTripPurposeShoppingIcon @"shopping.png" 66 | #define kTripPurposeErrandIcon @"errands.png" 67 | #define kTripPurposeOtherIcon @"other.png" 68 | 69 | #define kTripPurposeCommuteString @"Commute" 70 | #define kTripPurposeSchoolString @"School" 71 | #define kTripPurposeWorkString @"Work-Related" 72 | #define kTripPurposeExerciseString @"Exercise" 73 | #define kTripPurposeSocialString @"Social" 74 | #define kTripPurposeShoppingString @"Shopping" 75 | #define kTripPurposeErrandString @"Errand" 76 | #define kTripPurposeOtherString @"Other" 77 | 78 | 79 | 80 | @protocol TripPurposeDelegate 81 | 82 | @required 83 | - (NSString *)getPurposeString:(long)index; 84 | - (NSString *)setPurpose:(long)index; 85 | 86 | @optional 87 | - (void)didTakeTransit; 88 | - (void)didTakeBikeRental; 89 | - (void)didCancelPurpose; 90 | - (void)didCancelNote; 91 | - (void)didPickPurpose:(long)index; 92 | - (void)didPickNoteType:(NSNumber *)index; 93 | - (void)didEnterNoteDetails:(NSString *)details; 94 | - (void)didEnterTripDetails:(NSString *)details; 95 | - (void)didSaveImage:(NSData *)imgData; 96 | - (void)getNoteThumbnail:(NSData *)imgData; 97 | - (void)getTripThumbnail:(NSData *)imgData; 98 | - (void)saveNote; 99 | - (void)saveTrip; 100 | 101 | @end 102 | -------------------------------------------------------------------------------- /Classes/ZipUtil.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Cycle Atlanta is free software: you can redistribute it and/or modify 18 | * it under the terms of the GNU General Public License as published by 19 | * the Free Software Foundation, either version 3 of the License, or 20 | * (at your option) any later version. 21 | * 22 | * Cycle Atlanta is distributed in the hope that it will be useful, 23 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 24 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 25 | * GNU General Public License for more details. 26 | * 27 | * You should have received a copy of the GNU General Public License 28 | * along with Cycle Atlanta. If not, see . 29 | */ 30 | 31 | // 32 | // ZipUtil.h 33 | // Cycle Atlanta 34 | // 35 | // Modified from http://www.clintharris.net/2009/how-to-gzip-data-in-memory-using-objective-c/ 36 | // 37 | 38 | #import 39 | #import "zlib.h" 40 | 41 | 42 | 43 | @interface ZipUtil : NSObject 44 | 45 | +(NSData*) gzipDeflate: (NSData*)pUncompressedData ; 46 | 47 | @end 48 | -------------------------------------------------------------------------------- /Coord.h: -------------------------------------------------------------------------------- 1 | // 2 | // Coord.h 3 | // Cycle Atlanta adapted for CyclePhilly 2013, CodeforPhilly.org 4 | // 5 | // Created by Guo Anhong on 13-2-26. 6 | // 7 | // 8 | 9 | #import 10 | #import 11 | 12 | @class Trip; 13 | 14 | @interface Coord : NSManagedObject 15 | 16 | @property (nonatomic, retain) NSNumber * hAccuracy; 17 | @property (nonatomic, retain) NSNumber * longitude; 18 | @property (nonatomic, retain) NSNumber * vAccuracy; 19 | @property (nonatomic, retain) NSNumber * speed; 20 | @property (nonatomic, retain) NSNumber * latitude; 21 | @property (nonatomic, retain) NSDate * recorded; 22 | @property (nonatomic, retain) NSNumber * altitude; 23 | @property (nonatomic, retain) Trip *trip; 24 | 25 | @end 26 | -------------------------------------------------------------------------------- /Coord.m: -------------------------------------------------------------------------------- 1 | // 2 | // Coord.m 3 | // Cycle Atlanta adapted for CyclePhilly 2013, CodeforPhilly.org 4 | // 5 | // Created by Guo Anhong on 13-2-26. 6 | // 7 | // 8 | 9 | #import "Coord.h" 10 | #import "Trip.h" 11 | 12 | 13 | @implementation Coord 14 | 15 | @dynamic hAccuracy; 16 | @dynamic longitude; 17 | @dynamic vAccuracy; 18 | @dynamic speed; 19 | @dynamic latitude; 20 | @dynamic recorded; 21 | @dynamic altitude; 22 | @dynamic trip; 23 | 24 | @end 25 | -------------------------------------------------------------------------------- /CustomPickerDataSource.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // CustomPickerDataSource.h 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 9/22/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | // Check system version to support picker 51 | // picker styles for iOS >= 7.1, 52 | // 7.0, which gets its own weird style, 53 | // and 5/6 54 | #define IOS_6_OR_EARLIER ([[[UIDevice currentDevice] systemVersion] floatValue] < 7.0) 55 | 56 | // Trip Purpose descriptions 57 | #define kDescCommute @"The primary reason for this bike trip is to get between home and your primary work location." 58 | #define kDescSchool @"The primary reason for this bike trip is to go to or from school or college." 59 | #define kDescWork @"The primary reason for this bike trip is to go to or from business-related meeting, function, or work-related errand for your job." 60 | #define kDescExercise @"The primary reason for this bike trip is exercise or biking for the sake of biking." 61 | #define kDescSocial @"The primary reason for this bike trip is going to or from a social activity (e.g. at a friend's house, the park, a restaurant, the movies)." 62 | #define kDescShopping @"The primary reason for this bike trip is to purchase or bring home goods or groceries." 63 | #define kDescErrand @"The primary reason for this bike trip is to attend to personal business such as banking, doctor visit, going to the gym, etc." 64 | #define kDescOther @"If none of the other reasons apply to this trip, you can enter trip comments after saving your trip to tell us more." 65 | 66 | @interface CustomPickerDataSource : NSObject 67 | { 68 | NSArray *customPickerArray; 69 | id parent; 70 | NSInteger pickerCategory; 71 | } 72 | 73 | @property (nonatomic, retain) NSArray *customPickerArray; 74 | @property (nonatomic, retain) NSArray *pickerTitles; 75 | @property (nonatomic, retain) NSArray *pickerImages; 76 | @property (nonatomic, retain) id parent; 77 | 78 | @end 79 | -------------------------------------------------------------------------------- /CustomView.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Updated/Modified for Philadelphia's app deployment. Based on the 12 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 13 | * 14 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 15 | * Atlanta, GA. USA 16 | * 17 | * @author Christopher Le Dantec 18 | * @author Anhong Guo 19 | * 20 | * Updated/Modified for Atlanta's app deployment. Based on the 21 | * CycleTracks codebase for SFCTA. 22 | * 23 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 24 | * San Francisco, CA, USA 25 | * 26 | * @author Matt Paul 27 | * 28 | * This file is part of CycleTracks. 29 | * 30 | * CycleTracks is free software: you can redistribute it and/or modify 31 | * it under the terms of the GNU General Public License as published by 32 | * the Free Software Foundation, either version 3 of the License, or 33 | * (at your option) any later version. 34 | * 35 | * CycleTracks is distributed in the hope that it will be useful, 36 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 37 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 38 | * GNU General Public License for more details. 39 | * 40 | * You should have received a copy of the GNU General Public License 41 | * along with CycleTracks. If not, see . 42 | */ 43 | 44 | // 45 | // CustomView.h 46 | // CycleTracks 47 | // 48 | // Copyright 2009-2010 SFCTA. All rights reserved. 49 | // Written by Matt Paul on 9/22/09. 50 | // For more information on the project, 51 | // e-mail Billy Charlton at the SFCTA 52 | 53 | #import "constants.h" 54 | #import 55 | 56 | @interface CustomView : UIView 57 | { 58 | NSString *title; 59 | UIImage *image; 60 | } 61 | 62 | @property (nonatomic, copy) NSString *title; 63 | @property (nonatomic, copy) UIImage *image; 64 | 65 | + (CGFloat)viewWidth; 66 | + (CGFloat)viewHeight; 67 | 68 | @end 69 | -------------------------------------------------------------------------------- /CustomView.m: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // CustomView.m 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 9/22/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | #import "CustomView.h" 51 | 52 | @implementation CustomView 53 | 54 | @synthesize title, image; 55 | 56 | const CGFloat kViewWidth = 200; 57 | const CGFloat kViewHeight = 44; 58 | 59 | + (CGFloat)viewWidth 60 | { 61 | return kViewWidth; 62 | } 63 | 64 | + (CGFloat)viewHeight 65 | { 66 | return kViewHeight; 67 | } 68 | 69 | - (id)initWithFrame:(CGRect)frame 70 | { 71 | // use predetermined frame size 72 | if (self = [super initWithFrame:CGRectMake(0.0, 0.0, kViewWidth, kViewHeight)]) 73 | { 74 | self.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight; 75 | self.backgroundColor = [UIColor clearColor]; // make the background transparent 76 | } 77 | return self; 78 | } 79 | 80 | - (void)drawRect:(CGRect)rect 81 | { 82 | // draw the image and title using their draw methods 83 | CGFloat yCoord = (self.bounds.size.height - self.image.size.height) / 2; 84 | CGPoint point = CGPointMake(10.0, yCoord); 85 | [self.image drawAtPoint:point]; 86 | 87 | CGRect drawRect = CGRectMake(10.0 + self.image.size.width, (self.bounds.size.height - MAIN_FONT_SIZE) / 2, self.bounds.size.width, self.image.size.height); 88 | 89 | NSDictionary *textAttributes = @{NSFontAttributeName: [UIFont systemFontOfSize:MAIN_FONT_SIZE]}; 90 | 91 | // Create string drawing context 92 | NSStringDrawingContext *drawingContext = [[[NSStringDrawingContext alloc] init] autorelease]; 93 | drawingContext.minimumScaleFactor = MIN_MAIN_FONT_SIZE / MAIN_FONT_SIZE; 94 | 95 | [self.title drawWithRect:drawRect 96 | options:NSStringDrawingUsesLineFragmentOrigin 97 | attributes:textAttributes 98 | context:drawingContext]; 99 | 100 | // deprecated 101 | //[self.title drawAtPoint:point 102 | // forWidth:self.bounds.size.width 103 | // withFont:[UIFont systemFontOfSize:MAIN_FONT_SIZE] 104 | // minFontSize:MIN_MAIN_FONT_SIZE 105 | // actualFontSize:NULL 106 | // lineBreakMode:NSLineBreakByTruncatingTail 107 | // baselineAdjustment:UIBaselineAdjustmentAlignBaselines]; 108 | } 109 | 110 | - (void)dealloc 111 | { 112 | [title release]; 113 | [image release]; 114 | 115 | [super dealloc]; 116 | } 117 | 118 | @end 119 | -------------------------------------------------------------------------------- /Cycle Atlanta.ipa: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Cycle Atlanta.ipa -------------------------------------------------------------------------------- /Cycle Philly-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | English 7 | CFBundleDisplayName 8 | ${PRODUCT_NAME} 9 | CFBundleExecutable 10 | ${EXECUTABLE_NAME} 11 | CFBundleIconFile 12 | appIcon.png 13 | CFBundleIcons 14 | 15 | CFBundleIcons~ipad 16 | 17 | CFBundleIdentifier 18 | com.CodeforPhilly.Cycle 19 | CFBundleInfoDictionaryVersion 20 | 6.0 21 | CFBundleName 22 | ${PRODUCT_NAME} 23 | CFBundlePackageType 24 | APPL 25 | CFBundleShortVersionString 26 | 1.3 27 | CFBundleSignature 28 | CAGT 29 | CFBundleVersion 30 | 114 31 | LSRequiresIPhoneOS 32 | 33 | NSLocationAlwaysUsageDescription 34 | We need your location to track your routes. 35 | NSMainNibFile 36 | MainWindow 37 | UIBackgroundModes 38 | 39 | fetch 40 | location 41 | 42 | UIPrerenderedIcon 43 | 44 | UIRequiredDeviceCapabilities 45 | 46 | location-services 47 | gps 48 | 49 | UIStatusBarStyle 50 | UIStatusBarStyleBlackTranslucent 51 | UISupportedInterfaceOrientations 52 | 53 | UIInterfaceOrientationPortrait 54 | UIInterfaceOrientationPortraitUpsideDown 55 | 56 | 57 | 58 | -------------------------------------------------------------------------------- /Cycle Philly.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /Cycle Philly.xcodeproj/project.xcworkspace/xcshareddata/Cycle Philly.xccheckout: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDESourceControlProjectFavoriteDictionaryKey 6 | 7 | IDESourceControlProjectIdentifier 8 | 8CDC3EE8-E2D7-4BF6-B686-6B14D1EB681E 9 | IDESourceControlProjectName 10 | Cycle Philly 11 | IDESourceControlProjectOriginsDictionary 12 | 13 | 6110CC6252755727643E36F2E3E0B2B306648F28 14 | https://github.com/PhillyOpen/Cycle-Philly-iOS.git 15 | 97BCBF0230202DF50BD97BB75A9558D280E2EE38 16 | https://github.com/PhillyOpen/Cycle-Philly-iOS.git 17 | 18 | IDESourceControlProjectPath 19 | Cycle Philly.xcodeproj 20 | IDESourceControlProjectRelativeInstallPathDictionary 21 | 22 | 6110CC6252755727643E36F2E3E0B2B306648F28 23 | ../.. 24 | 97BCBF0230202DF50BD97BB75A9558D280E2EE38 25 | ../../.. 26 | 27 | IDESourceControlProjectURL 28 | https://github.com/PhillyOpen/Cycle-Philly-iOS.git 29 | IDESourceControlProjectVersion 30 | 111 31 | IDESourceControlProjectWCCIdentifier 32 | 6110CC6252755727643E36F2E3E0B2B306648F28 33 | IDESourceControlProjectWCConfigurations 34 | 35 | 36 | IDESourceControlRepositoryExtensionIdentifierKey 37 | public.vcs.git 38 | IDESourceControlWCCIdentifierKey 39 | 97BCBF0230202DF50BD97BB75A9558D280E2EE38 40 | IDESourceControlWCCName 41 | 42 | 43 | 44 | IDESourceControlRepositoryExtensionIdentifierKey 45 | public.vcs.git 46 | IDESourceControlWCCIdentifierKey 47 | 6110CC6252755727643E36F2E3E0B2B306648F28 48 | IDESourceControlWCCName 49 | CyclePhilly-iOS 50 | 51 | 52 | 53 | 54 | -------------------------------------------------------------------------------- /Cycle Philly/Images.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "size" : "29x29", 5 | "idiom" : "iphone", 6 | "filename" : "appIcon29x29.png", 7 | "scale" : "1x" 8 | }, 9 | { 10 | "size" : "29x29", 11 | "idiom" : "iphone", 12 | "filename" : "appIcon58x58.png", 13 | "scale" : "2x" 14 | }, 15 | { 16 | "size" : "40x40", 17 | "idiom" : "iphone", 18 | "filename" : "appIcon@Retina.png", 19 | "scale" : "2x" 20 | }, 21 | { 22 | "size" : "57x57", 23 | "idiom" : "iphone", 24 | "filename" : "appicon57x57.png", 25 | "scale" : "1x" 26 | }, 27 | { 28 | "size" : "57x57", 29 | "idiom" : "iphone", 30 | "filename" : "appIcon@2x.png", 31 | "scale" : "2x" 32 | }, 33 | { 34 | "size" : "60x60", 35 | "idiom" : "iphone", 36 | "filename" : "appretina.png", 37 | "scale" : "2x" 38 | }, 39 | { 40 | "idiom" : "iphone", 41 | "size" : "60x60", 42 | "scale" : "3x" 43 | } 44 | ], 45 | "info" : { 46 | "version" : 1, 47 | "author" : "xcode" 48 | } 49 | } -------------------------------------------------------------------------------- /Cycle Philly/Images.xcassets/AppIcon.appiconset/appIcon29x29.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Cycle Philly/Images.xcassets/AppIcon.appiconset/appIcon29x29.png -------------------------------------------------------------------------------- /Cycle Philly/Images.xcassets/AppIcon.appiconset/appIcon58x58.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Cycle Philly/Images.xcassets/AppIcon.appiconset/appIcon58x58.png -------------------------------------------------------------------------------- /Cycle Philly/Images.xcassets/AppIcon.appiconset/appIcon@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Cycle Philly/Images.xcassets/AppIcon.appiconset/appIcon@2x.png -------------------------------------------------------------------------------- /Cycle Philly/Images.xcassets/AppIcon.appiconset/appIcon@Retina.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Cycle Philly/Images.xcassets/AppIcon.appiconset/appIcon@Retina.png -------------------------------------------------------------------------------- /Cycle Philly/Images.xcassets/AppIcon.appiconset/appicon57x57.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Cycle Philly/Images.xcassets/AppIcon.appiconset/appicon57x57.png -------------------------------------------------------------------------------- /Cycle Philly/Images.xcassets/AppIcon.appiconset/appretina.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Cycle Philly/Images.xcassets/AppIcon.appiconset/appretina.png -------------------------------------------------------------------------------- /Cycle Philly/Images.xcassets/LaunchImage.launchimage/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "orientation" : "portrait", 5 | "idiom" : "iphone", 6 | "filename" : "Default@2x.png", 7 | "minimum-system-version" : "7.0", 8 | "scale" : "2x" 9 | }, 10 | { 11 | "orientation" : "portrait", 12 | "idiom" : "iphone", 13 | "filename" : "Default-568h@2x.png", 14 | "minimum-system-version" : "7.0", 15 | "subtype" : "retina4", 16 | "scale" : "2x" 17 | }, 18 | { 19 | "orientation" : "portrait", 20 | "idiom" : "iphone", 21 | "filename" : "Default.png", 22 | "scale" : "1x" 23 | }, 24 | { 25 | "orientation" : "portrait", 26 | "idiom" : "iphone", 27 | "filename" : "Default@2x.png", 28 | "scale" : "2x" 29 | }, 30 | { 31 | "orientation" : "portrait", 32 | "idiom" : "iphone", 33 | "filename" : "Default-568h@2x.png", 34 | "subtype" : "retina4", 35 | "scale" : "2x" 36 | } 37 | ], 38 | "info" : { 39 | "version" : 1, 40 | "author" : "xcode" 41 | } 42 | } -------------------------------------------------------------------------------- /Cycle Philly/Images.xcassets/LaunchImage.launchimage/Default-568h@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Cycle Philly/Images.xcassets/LaunchImage.launchimage/Default-568h@2x.png -------------------------------------------------------------------------------- /Cycle Philly/Images.xcassets/LaunchImage.launchimage/Default.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Cycle Philly/Images.xcassets/LaunchImage.launchimage/Default.png -------------------------------------------------------------------------------- /Cycle Philly/Images.xcassets/LaunchImage.launchimage/Default@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Cycle Philly/Images.xcassets/LaunchImage.launchimage/Default@2x.png -------------------------------------------------------------------------------- /Cycle Philly_Prefix.pch: -------------------------------------------------------------------------------- 1 | // 2 | // CycleTracks_Prefix.pch 3 | // CycleTracks 4 | // 5 | // Copyright 2009-2010 SFCTA. All rights reserved. 6 | // Written by Matt Paul on 8/10/09. 7 | // For more information on the project, 8 | // e-mail Billy Charlton at the SFCTA 9 | 10 | 11 | // 12 | // Prefix header for all source files of the 'CycleTracks' target in the 'CycleTracks' project 13 | // 14 | #import 15 | 16 | #ifndef __IPHONE_3_0 17 | #warning "This project uses features only available in iPhone SDK 3.0 and later." 18 | #endif 19 | 20 | 21 | #ifdef __OBJC__ 22 | #import 23 | #import 24 | #import 25 | #endif 26 | -------------------------------------------------------------------------------- /CycleAtlanta.xcdatamodeld/.xccurrentversion: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | _XCCurrentVersionName 6 | CycleAtlanta 2.xcdatamodel 7 | 8 | 9 | -------------------------------------------------------------------------------- /CycleAtlanta.xcdatamodeld/CycleAtlanta 2.xcdatamodel/elements: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/CycleAtlanta.xcdatamodeld/CycleAtlanta 2.xcdatamodel/elements -------------------------------------------------------------------------------- /CycleAtlanta.xcdatamodeld/CycleAtlanta 2.xcdatamodel/layout: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/CycleAtlanta.xcdatamodeld/CycleAtlanta 2.xcdatamodel/layout -------------------------------------------------------------------------------- /CycleAtlanta.xcdatamodeld/CycleAtlanta.xcdatamodel/elements: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/CycleAtlanta.xcdatamodeld/CycleAtlanta.xcdatamodel/elements -------------------------------------------------------------------------------- /CycleAtlanta.xcdatamodeld/CycleAtlanta.xcdatamodel/layout: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/CycleAtlanta.xcdatamodeld/CycleAtlanta.xcdatamodel/layout -------------------------------------------------------------------------------- /Deprecated Images/20-gear2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/20-gear2.png -------------------------------------------------------------------------------- /Deprecated Images/ArrowButton.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/ArrowButton.png -------------------------------------------------------------------------------- /Deprecated Images/ClearArrowButton.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/ClearArrowButton.png -------------------------------------------------------------------------------- /Deprecated Images/ClearArrowButtonDark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/ClearArrowButtonDark.png -------------------------------------------------------------------------------- /Deprecated Images/ClearArrowButtonWideDark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/ClearArrowButtonWideDark.png -------------------------------------------------------------------------------- /Deprecated Images/GreenCheckMark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/GreenCheckMark.png -------------------------------------------------------------------------------- /Deprecated Images/GreenCheckMark2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/GreenCheckMark2.png -------------------------------------------------------------------------------- /Deprecated Images/GreenCheckMark3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/GreenCheckMark3.png -------------------------------------------------------------------------------- /Deprecated Images/LargeCounter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/LargeCounter.png -------------------------------------------------------------------------------- /Deprecated Images/LockIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/LockIcon.png -------------------------------------------------------------------------------- /Deprecated Images/OpacityMask80.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/OpacityMask80.png -------------------------------------------------------------------------------- /Deprecated Images/OpacityMaskWindow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/OpacityMaskWindow.png -------------------------------------------------------------------------------- /Deprecated Images/SlideToUnlock.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/SlideToUnlock.png -------------------------------------------------------------------------------- /Deprecated Images/UnlockIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/UnlockIcon.png -------------------------------------------------------------------------------- /Deprecated Images/cancel_button.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/cancel_button.png -------------------------------------------------------------------------------- /Deprecated Images/lock_button1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/lock_button1.png -------------------------------------------------------------------------------- /Deprecated Images/lock_button2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/lock_button2.png -------------------------------------------------------------------------------- /Deprecated Images/lock_button_fpo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/lock_button_fpo.png -------------------------------------------------------------------------------- /Deprecated Images/orangeslide.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/orangeslide.png -------------------------------------------------------------------------------- /Deprecated Images/save_button.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/save_button.png -------------------------------------------------------------------------------- /Deprecated Images/save_button_selected.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/save_button_selected.png -------------------------------------------------------------------------------- /Deprecated Images/slider_ball.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/slider_ball.png -------------------------------------------------------------------------------- /Deprecated Images/start_button.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/start_button.png -------------------------------------------------------------------------------- /Deprecated Images/start_button_selected.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/start_button_selected.png -------------------------------------------------------------------------------- /Deprecated Images/yellowslide.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Deprecated Images/yellowslide.png -------------------------------------------------------------------------------- /DetailView.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 75 | 76 | 77 | 78 | 79 | 80 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | -------------------------------------------------------------------------------- /Firebase.framework/Firebase: -------------------------------------------------------------------------------- 1 | Versions/Current/Firebase -------------------------------------------------------------------------------- /Firebase.framework/Headers: -------------------------------------------------------------------------------- 1 | Versions/Current/Headers -------------------------------------------------------------------------------- /Firebase.framework/Versions/A/Firebase: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Firebase.framework/Versions/A/Firebase -------------------------------------------------------------------------------- /Firebase.framework/Versions/A/Headers/FAuthData.h: -------------------------------------------------------------------------------- 1 | // 2 | // FAuthData.h 3 | // Firebase 4 | // 5 | // Created by Katherine Fang on 7/30/14. 6 | // 7 | 8 | #import 9 | #import "FAuthType.h" 10 | 11 | 12 | /** 13 | * The FAuthData class is a wrapper around the user metadata returned from the Firebase auth server. 14 | * It includes the provider authenticated against, a uid (with the possible exception of authenticating against a custom 15 | * backend), and a token used to authenticate with Firebase. 16 | * 17 | * It may include other metadata about the user, depending on the provider used to do the authentication. 18 | */ 19 | @interface FAuthData : NSObject 20 | 21 | /** 22 | * @return Raw authentication token payload returned by the server 23 | */ 24 | @property (nonatomic, strong, readonly) NSDictionary *auth; 25 | 26 | /** 27 | * @return Authentication token expiration timestamp (seconds since epoch) returned by the server 28 | */ 29 | @property (nonatomic, strong, readonly) NSNumber *expires; 30 | 31 | /** 32 | * @return A uid for this user. It is unique across all auth providers. 33 | */ 34 | @property (nonatomic, strong, readonly) NSString *uid; 35 | 36 | 37 | /** 38 | * @return The provider that authenticated this user 39 | */ 40 | @property (nonatomic, readonly) NSString *provider; 41 | 42 | 43 | /** 44 | * @return The token that was used to authenticate this user with Firebase 45 | */ 46 | @property (nonatomic, strong, readonly) NSString *token; 47 | 48 | 49 | /** 50 | * @return Provider data keyed by provider. Includes cached data from third-party providers 51 | */ 52 | @property (nonatomic, strong, readonly) NSDictionary *providerData; 53 | 54 | 55 | @end 56 | -------------------------------------------------------------------------------- /Firebase.framework/Versions/A/Headers/FAuthType.h: -------------------------------------------------------------------------------- 1 | // 2 | // FAuthType.h 3 | // Firebase 4 | // 5 | // Created by Katherine Fang on 7/30/14. 6 | // 7 | // All public-facing auth enums. 8 | // 9 | 10 | #ifndef Firebase_FAuthenticationTypes_h 11 | #define Firebase_FAuthenticationTypes_h 12 | 13 | typedef NS_ENUM(NSInteger, FAuthenticationError) { 14 | // Developer / Config Errors 15 | FAuthenticationErrorProviderDisabled = -1, 16 | FAuthenticationErrorInvalidConfiguration = -2, 17 | FAuthenticationErrorInvalidOrigin = -3, 18 | FAuthenticationErrorInvalidProvider = -4, 19 | 20 | // User Errors (Email / Password) 21 | FAuthenticationErrorInvalidEmail = -5, 22 | FAuthenticationErrorInvalidPassword = -6, 23 | FAuthenticationErrorInvalidToken = -7, 24 | FAuthenticationErrorUserDoesNotExist = -8, 25 | FAuthenticationErrorEmailTaken = -9, 26 | 27 | // User Errors (Facebook / Twitter / Github / Google) 28 | FAuthenticationErrorDeniedByUser = -10, 29 | FAuthenticationErrorInvalidCredentials = -11, 30 | FAuthenticationErrorInvalidArguments = -12, 31 | FAuthenticationErrorProviderError = -13, 32 | FAuthenticationErrorLimitsExceeded = -14, 33 | 34 | // Client side errors 35 | FAuthenticationErrorNetworkError = -15, 36 | FAuthenticationErrorPreempted = -16, 37 | 38 | FAuthenticationErrorUnknown = -9999 39 | }; 40 | 41 | #endif -------------------------------------------------------------------------------- /Firebase.framework/Versions/A/Headers/FDataSnapshot.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Firebase iOS Client Library 3 | * 4 | * Copyright © 2013 Firebase - All Rights Reserved 5 | * https://www.firebase.com 6 | * 7 | * Redistribution and use in source and binary forms, with or without 8 | * modification, are permitted provided that the following conditions are met: 9 | * 10 | * 1. Redistributions of source code must retain the above copyright notice, this 11 | * list of conditions and the following disclaimer. 12 | * 13 | * 2. Redistributions in binaryform must reproduce the above copyright notice, 14 | * this list of conditions and the following disclaimer in the documentation 15 | * and/or other materials provided with the distribution. 16 | * 17 | * THIS SOFTWARE IS PROVIDED BY FIREBASE AS IS AND ANY EXPRESS OR 18 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 19 | * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO 20 | * EVENT SHALL FIREBASE BE LIABLE FOR ANY DIRECT, 21 | * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 22 | * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 23 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF 24 | * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 25 | * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 26 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | */ 28 | 29 | #import 30 | 31 | @class Firebase; 32 | 33 | /** 34 | * An FDataSnapshot contains data from a Firebase location. Any time you read 35 | * Firebase data, you receive the data as an FDataSnapshot. 36 | * 37 | * FDataSnapshots are passed to the blocks you attach with observeEventType:withBlock: or observeSingleEvent:withBlock:. 38 | * They are efficiently-generated immutable copies of the data at a Firebase location. 39 | * They can't be modified and will never change. To modify data at a location, 40 | * use a Firebase reference (e.g. with setValue:). 41 | */ 42 | @interface FDataSnapshot : NSObject 43 | 44 | 45 | /** @name Navigating and inspecting a snapshot */ 46 | 47 | /** 48 | * Get an FDataSnapshot for the location at the specified relative path. 49 | * The relative path can either be a simple child key (e.g. 'fred') 50 | * or a deeper slash-separated path (e.g. 'fred/name/first'). If the child 51 | * location has no data, an empty FDataSnapshot is returned. 52 | * 53 | * @param childPathString A relative path to the location of child data. 54 | * @return The FDataSnapshot for the child location. 55 | */ 56 | - (FDataSnapshot *) childSnapshotForPath:(NSString *)childPathString; 57 | 58 | 59 | /** 60 | * Return YES if the specified child exists. 61 | * 62 | * @param childPathString A relative path to the location of a potential child. 63 | * @return YES if data exists at the specified childPathString, else false. 64 | */ 65 | - (BOOL) hasChild:(NSString *)childPathString; 66 | 67 | 68 | /** 69 | * Return YES if the DataSnapshot has any children. 70 | * 71 | * @return YES if this snapshot has any children, else NO. 72 | */ 73 | - (BOOL) hasChildren; 74 | 75 | 76 | /** 77 | * Return YES if the DataSnapshot contains a non-null value. 78 | * 79 | * @return YES if this snapshot contains a non-null value, otherwise NO. 80 | */ 81 | - (BOOL) exists; 82 | 83 | 84 | /** @name Data export */ 85 | 86 | /** 87 | * Returns the raw value at this location, coupled with any metadata, such as priority. 88 | * 89 | * Priorities, where they exist, are accessible under the ".priority" key in instances of NSDictionary. 90 | * For leaf locations with priorities, the value will be under the ".value" key. 91 | */ 92 | - (id) valueInExportFormat; 93 | 94 | 95 | /** @name Properties */ 96 | 97 | /** 98 | * Returns the contents of this data snapshot as native types. 99 | * 100 | * Data types returned: 101 | * * NSDictionary 102 | * * NSArray 103 | * * NSNumber (also includes booleans) 104 | * * NSString 105 | * 106 | * @return The data as a native object. 107 | */ 108 | @property (strong, readonly, nonatomic) id value; 109 | 110 | 111 | /** 112 | * Get the number of children for this DataSnapshot. 113 | * 114 | * @return An integer indicating the number of children. 115 | */ 116 | @property (readonly, nonatomic) NSUInteger childrenCount; 117 | 118 | 119 | /** 120 | * Get a Firebase reference for the location that this data came from 121 | * 122 | * @return A Firebase instance for the location of this data 123 | */ 124 | @property (nonatomic, readonly, strong) Firebase* ref; 125 | 126 | 127 | /** 128 | * The name of the location that generated this FDataSnapshot. 129 | * 130 | * @return An NSString containing the key for the location of this FDataSnapshot. 131 | */ 132 | @property (strong, readonly, nonatomic) NSString* key; 133 | 134 | 135 | /** 136 | * An iterator for snapshots of the child nodes in this snapshot. 137 | * You can use the native for..in syntax: 138 | * 139 | * for (FDataSnapshot* child in snapshot.children) { 140 | * ... 141 | * } 142 | * 143 | * @return An NSEnumerator of the children 144 | */ 145 | @property (strong, readonly, nonatomic) NSEnumerator* children; 146 | 147 | /** 148 | * The priority of the data in this FDataSnapshot. 149 | * 150 | * @return The priority as a string, or nil if no priority was set. 151 | */ 152 | @property (strong, readonly, nonatomic) id priority; 153 | 154 | @end 155 | -------------------------------------------------------------------------------- /Firebase.framework/Versions/A/Headers/FEventType.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Firebase iOS Client Library 3 | * 4 | * Copyright © 2013 Firebase - All Rights Reserved 5 | * https://www.firebase.com 6 | * 7 | * Redistribution and use in source and binary forms, with or without 8 | * modification, are permitted provided that the following conditions are met: 9 | * 10 | * 1. Redistributions of source code must retain the above copyright notice, this 11 | * list of conditions and the following disclaimer. 12 | * 13 | * 2. Redistributions in binaryform must reproduce the above copyright notice, 14 | * this list of conditions and the following disclaimer in the documentation 15 | * and/or other materials provided with the distribution. 16 | * 17 | * THIS SOFTWARE IS PROVIDED BY FIREBASE AS IS AND ANY EXPRESS OR 18 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 19 | * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO 20 | * EVENT SHALL FIREBASE BE LIABLE FOR ANY DIRECT, 21 | * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 22 | * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 23 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF 24 | * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 25 | * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 26 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | */ 28 | 29 | #ifndef Firebase_FEventType_h 30 | #define Firebase_FEventType_h 31 | 32 | /** 33 | * This enum is the set of events that you can observe at a Firebase location. 34 | */ 35 | typedef NS_ENUM(NSInteger, FEventType) { 36 | FEventTypeChildAdded, // 0, fired when a new child node is added to a location 37 | FEventTypeChildRemoved, // 1, fired when a child node is removed from a location 38 | FEventTypeChildChanged, // 2, fired when a child node at a location changes 39 | FEventTypeChildMoved, // 3, fired when a child node moves relative to the other child nodes at a location 40 | FEventTypeValue // 4, fired when any data changes at a location and, recursively, any children 41 | }; 42 | 43 | #endif 44 | -------------------------------------------------------------------------------- /Firebase.framework/Versions/A/Headers/FMutableData.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Firebase iOS Client Library 3 | * 4 | * Copyright © 2013 Firebase - All Rights Reserved 5 | * https://www.firebase.com 6 | * 7 | * Redistribution and use in source and binary forms, with or without 8 | * modification, are permitted provided that the following conditions are met: 9 | * 10 | * 1. Redistributions of source code must retain the above copyright notice, this 11 | * list of conditions and the following disclaimer. 12 | * 13 | * 2. Redistributions in binaryform must reproduce the above copyright notice, 14 | * this list of conditions and the following disclaimer in the documentation 15 | * and/or other materials provided with the distribution. 16 | * 17 | * THIS SOFTWARE IS PROVIDED BY FIREBASE AS IS AND ANY EXPRESS OR 18 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 19 | * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO 20 | * EVENT SHALL FIREBASE BE LIABLE FOR ANY DIRECT, 21 | * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 22 | * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 23 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF 24 | * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 25 | * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 26 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | */ 28 | 29 | #import 30 | 31 | /** 32 | * An FMutableData instance is populated with data from a Firebase location. 33 | * When you are using runTransactionBlock:, you will be given an instance containing the current 34 | * data at that location. Your block will be responsible for updating that instance to the data 35 | * you wish to save at that location, and then returning using [FTransactionResult successWithValue:]. 36 | * 37 | * To modify the data, set its value property to any of the native types support by Firebase: 38 | * * NSNumber (includes BOOL) 39 | * * NSDictionary 40 | * * NSArray 41 | * * NSString 42 | * * nil / NSNull to remove the data 43 | * 44 | * Note that changes made to a child FMutableData instance will be visible to the parent. 45 | */ 46 | @interface FMutableData : NSObject 47 | 48 | 49 | /** @name Inspecting and navigating the data */ 50 | 51 | 52 | /** 53 | * Returns boolean indicating whether this mutable data has children. 54 | * 55 | * @return YES if this data contains child nodes. 56 | */ 57 | - (BOOL) hasChildren; 58 | 59 | 60 | /** 61 | * Indicates whether this mutable data has a child at the given path. 62 | * 63 | * @param path A path string, consisting either of a single segment, like 'child', or multiple segments, 'a/deeper/child' 64 | * @return YES if this data contains a child at the specified relative path 65 | */ 66 | - (BOOL) hasChildAtPath:(NSString *)path; 67 | 68 | 69 | /** 70 | * Used to obtain an FMutableData instance that encapsulates the data at the given relative path. 71 | * Note that changes made to the child will be visible to the parent. 72 | * 73 | * @param path A path string, consisting either of a single segment, like 'child', or multiple segments, 'a/deeper/child' 74 | * @return An FMutableData instance containing the data at the given path 75 | */ 76 | - (FMutableData *) childDataByAppendingPath:(NSString *)path; 77 | 78 | 79 | /** @name Properties */ 80 | 81 | 82 | /** 83 | * This method is deprecated. 84 | * 85 | * @return An FMutableData instance containing the data at the parent location, or nil if this is the top-most location 86 | */ 87 | @property (strong, readonly, nonatomic) FMutableData* parent __attribute__((deprecated("Deprecated. Do not use.")));; 88 | 89 | 90 | /** 91 | * To modify the data contained by this instance of FMutableData, set this to any of the native types support by Firebase: 92 | * * NSNumber (includes BOOL) 93 | * * NSDictionary 94 | * * NSArray 95 | * * NSString 96 | * * nil / NSNull to remove the data 97 | * 98 | * Note that setting the value will override the priority at this location. 99 | * 100 | * @return The current data at this location as a native object 101 | */ 102 | @property (strong, nonatomic) id value; 103 | 104 | 105 | /** 106 | * Set this property to update the priority of the data at this location. Can be set to the following types: 107 | * * NSNumber 108 | * * NSString 109 | * * nil / NSNull to remove the priority 110 | * 111 | * @return The priority of the data at this location 112 | */ 113 | @property (strong, nonatomic) id priority; 114 | 115 | 116 | /** 117 | * @return The number of child nodes at this location 118 | */ 119 | @property (readonly, nonatomic) NSUInteger childrenCount; 120 | 121 | 122 | /** 123 | * Used to iterate over the children at this location. You can use the native for .. in syntax: 124 | * 125 | * for (FMutableData* child in data.children) { 126 | * ... 127 | * } 128 | * 129 | * Note that this enumerator operates on an immutable copy of the child list. So, you can modify the instance 130 | * during iteration, but the new additions will not be visible until you get a new enumerator. 131 | */ 132 | @property (readonly, nonatomic, strong) NSEnumerator* children; 133 | 134 | 135 | /** 136 | * @return The key name of this node, or nil if it is the top-most location 137 | */ 138 | @property (readonly, nonatomic, strong) NSString* key; 139 | 140 | 141 | @end 142 | -------------------------------------------------------------------------------- /Firebase.framework/Versions/A/Headers/FTransactionResult.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Firebase iOS Client Library 3 | * 4 | * Copyright © 2013 Firebase - All Rights Reserved 5 | * https://www.firebase.com 6 | * 7 | * Redistribution and use in source and binary forms, with or without 8 | * modification, are permitted provided that the following conditions are met: 9 | * 10 | * 1. Redistributions of source code must retain the above copyright notice, this 11 | * list of conditions and the following disclaimer. 12 | * 13 | * 2. Redistributions in binaryform must reproduce the above copyright notice, 14 | * this list of conditions and the following disclaimer in the documentation 15 | * and/or other materials provided with the distribution. 16 | * 17 | * THIS SOFTWARE IS PROVIDED BY FIREBASE AS IS AND ANY EXPRESS OR 18 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 19 | * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO 20 | * EVENT SHALL FIREBASE BE LIABLE FOR ANY DIRECT, 21 | * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 22 | * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 23 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF 24 | * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 25 | * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 26 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | */ 28 | 29 | #import 30 | #import "FMutableData.h" 31 | 32 | /** 33 | * Used for runTransactionBlock:. An FTransactionResult instance is a container for the results of the transaction. 34 | */ 35 | @interface FTransactionResult : NSObject 36 | 37 | /** 38 | * Used for runTransactionBlock:. Indicates that the new value should be saved at this location 39 | * 40 | * @param value An FMutableData instance containing the new value to be set 41 | * @return An FTransactionResult instance that can be used as a return value from the block given to runTransactionBlock: 42 | */ 43 | + (FTransactionResult *) successWithValue:(FMutableData *)value; 44 | 45 | 46 | /** 47 | * Used for runTransactionBlock:. Indicates that the current transaction should no longer proceed. 48 | * 49 | * @return An FTransactionResult instance that can be used as a return value from the block given to runTransactionBlock: 50 | */ 51 | + (FTransactionResult *) abort; 52 | 53 | @end 54 | -------------------------------------------------------------------------------- /Firebase.framework/Versions/A/Headers/FirebaseServerValue.h: -------------------------------------------------------------------------------- 1 | @interface FirebaseServerValue : NSObject 2 | 3 | + (NSDictionary *) timestamp; 4 | 5 | @end -------------------------------------------------------------------------------- /Firebase.framework/Versions/Current: -------------------------------------------------------------------------------- 1 | A -------------------------------------------------------------------------------- /Images/Default.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Images/Default.png -------------------------------------------------------------------------------- /Images/Icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Images/Icon.png -------------------------------------------------------------------------------- /Images/appStoreIcon1024.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Images/appStoreIcon1024.png -------------------------------------------------------------------------------- /Images/appStoreIcon512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Images/appStoreIcon512.png -------------------------------------------------------------------------------- /Images/appicon57x57.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/Images/appicon57x57.png -------------------------------------------------------------------------------- /IndegoIcons/indegoActive.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/IndegoIcons/indegoActive.png -------------------------------------------------------------------------------- /IndegoIcons/indegoActive@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/IndegoIcons/indegoActive@2x.png -------------------------------------------------------------------------------- /IndegoIcons/indegoComingSoon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/IndegoIcons/indegoComingSoon.png -------------------------------------------------------------------------------- /IndegoIcons/indegoComingSoon@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/IndegoIcons/indegoComingSoon@2x.png -------------------------------------------------------------------------------- /IndegoIcons/indegoPartialService.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/IndegoIcons/indegoPartialService.png -------------------------------------------------------------------------------- /IndegoIcons/indegoPartialService@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/IndegoIcons/indegoPartialService@2x.png -------------------------------------------------------------------------------- /IndegoIcons/indegoSpecialEvent.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/IndegoIcons/indegoSpecialEvent.png -------------------------------------------------------------------------------- /IndegoIcons/indegoSpecialEvent@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/IndegoIcons/indegoSpecialEvent@2x.png -------------------------------------------------------------------------------- /IndegoIcons/indegoUnavailable.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/IndegoIcons/indegoUnavailable.png -------------------------------------------------------------------------------- /IndegoIcons/indegoUnavailable@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/IndegoIcons/indegoUnavailable@2x.png -------------------------------------------------------------------------------- /IndegoStationStrings.h: -------------------------------------------------------------------------------- 1 | // 2 | // IndegoStationStrings.h 3 | // Cycle Philly 4 | // 5 | // Created by Kathryn Killebrew on 7/12/15. 6 | // 7 | // 8 | 9 | #ifndef Cycle_Philly_IndegoStationStrings_h 10 | #define Cycle_Philly_IndegoStationStrings_h 11 | 12 | 13 | #define kBikesAvailable @"Bikes Available: " 14 | #define kDocksAvailable @"Open Docks: " 15 | #define kEventStart @"Event Start: " 16 | #define kEventEnd @"Event End: " 17 | 18 | @interface IndegoStationStrings : NSObject 19 | +(NSDictionary*)getStatusDictionary; 20 | @end 21 | 22 | #endif 23 | -------------------------------------------------------------------------------- /IndegoStationStrings.m: -------------------------------------------------------------------------------- 1 | // 2 | // IndegoStationStrings.m 3 | // Cycle Philly 4 | // 5 | // Created by Kathryn Killebrew on 7/12/15. 6 | // 7 | // 8 | 9 | #import 10 | #import "IndegoStationStrings.h" 11 | 12 | @implementation IndegoStationStrings 13 | 14 | +(NSDictionary*)getStatusDictionary { 15 | static NSDictionary *inst = nil; 16 | static dispatch_once_t onceToken; 17 | dispatch_once(&onceToken, ^{ 18 | inst = @{ 19 | @"Active": @"Active", 20 | @"Unavailable": @"Unavailable", 21 | @"PartialService": @"Partial Service", 22 | @"ComingSoon": @"Coming Soon", 23 | @"SpecialEvent": @"Special Event" 24 | }; 25 | }); 26 | return inst; 27 | } 28 | 29 | @end 30 | 31 | -------------------------------------------------------------------------------- /MainWindow.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | -------------------------------------------------------------------------------- /MapViewController.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /NSString+MD5Addition.h: -------------------------------------------------------------------------------- 1 | // 2 | // NSString+MD5Addition.h 3 | // UIDeviceAddition 4 | // 5 | // Created by Georg Kitz on 20.08.11. 6 | // Copyright 2011 Aurora Apps. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface NSString(MD5Addition) 12 | 13 | - (NSString *) stringFromMD5; 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /NSString+MD5Addition.m: -------------------------------------------------------------------------------- 1 | // 2 | // NSString+MD5Addition.m 3 | // UIDeviceAddition 4 | // 5 | // Created by Georg Kitz on 20.08.11. 6 | // Copyright 2011 Aurora Apps. All rights reserved. 7 | // 8 | 9 | #import "NSString+MD5Addition.h" 10 | #import 11 | 12 | @implementation NSString(MD5Addition) 13 | 14 | - (NSString *) stringFromMD5{ 15 | 16 | if(self == nil || [self length] == 0) 17 | return nil; 18 | 19 | const char *value = [self UTF8String]; 20 | 21 | unsigned char outputBuffer[CC_MD5_DIGEST_LENGTH]; 22 | CC_MD5(value, strlen(value), outputBuffer); 23 | 24 | NSMutableString *outputString = [[NSMutableString alloc] initWithCapacity:CC_MD5_DIGEST_LENGTH * 2]; 25 | for(NSInteger count = 0; count < CC_MD5_DIGEST_LENGTH; count++){ 26 | [outputString appendFormat:@"%02x",outputBuffer[count]]; 27 | } 28 | 29 | return [outputString autorelease]; 30 | } 31 | 32 | @end 33 | -------------------------------------------------------------------------------- /Note.h: -------------------------------------------------------------------------------- 1 | // 2 | // Note.h 3 | // Cycle Atlanta 4 | // 5 | // Created by Guo Anhong on 13-2-26. 6 | // adapted for CyclePhilly 2013, CodeforPhilly.org 7 | // 8 | 9 | #import 10 | #import 11 | 12 | @class User; 13 | 14 | @interface Note : NSManagedObject 15 | 16 | @property (nonatomic, retain) NSString * details; 17 | @property (nonatomic, retain) NSNumber * speed; 18 | @property (nonatomic, retain) NSNumber * vAccuracy; 19 | @property (nonatomic, retain) NSNumber * longitude; 20 | @property (nonatomic, retain) NSString * image_url; 21 | @property (nonatomic, retain) NSNumber * note_type; 22 | @property (nonatomic, retain) NSNumber * latitude; 23 | @property (nonatomic, retain) NSNumber * hAccuracy; 24 | @property (nonatomic, retain) NSDate * recorded; 25 | @property (nonatomic, retain) NSNumber * altitude; 26 | @property (nonatomic, retain) NSData * image_data; 27 | @property (nonatomic, retain) NSData * thumbnail; 28 | @property (nonatomic, retain) NSDate * uploaded; 29 | @property (nonatomic, retain) User *user; 30 | 31 | @end 32 | -------------------------------------------------------------------------------- /Note.m: -------------------------------------------------------------------------------- 1 | // 2 | // Note.m 3 | // Cycle Atlanta 4 | // 5 | // Created by Guo Anhong on 13-2-26. 6 | // adapted for CyclePhilly 2013, CodeforPhilly.org 7 | // 8 | 9 | #import "Note.h" 10 | #import "User.h" 11 | 12 | 13 | @implementation Note 14 | 15 | @dynamic details; 16 | @dynamic speed; 17 | @dynamic vAccuracy; 18 | @dynamic longitude; 19 | @dynamic image_url; 20 | @dynamic note_type; 21 | @dynamic latitude; 22 | @dynamic hAccuracy; 23 | @dynamic recorded; 24 | @dynamic altitude; 25 | @dynamic image_data; 26 | @dynamic thumbnail; 27 | @dynamic user; 28 | @dynamic uploaded; 29 | 30 | @end 31 | -------------------------------------------------------------------------------- /PersonalInfo.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | Cycle Philly, 2013 Code for Philly 2 | ----------- 3 | Philadelphia, PA. USA 4 | 5 | Contact: Corey Acri 6 | Lloyd Emelle 7 | 8 | Updated/Modified for Philadelphia's app deployment. Based on the 9 | CycleTracks codebase for SFCTA. 10 | 11 | 12 | CycleTracks 13 | ----------- 14 | Copyright 2009, 2010 San Francisco County Transportation Authority 15 | 100 Van Ness Ave, 26th Floor 16 | San Francisco, CA 94102 USA 17 | 18 | Copyright 2013 Code for Philly 19 | 20 | Code primarily written by Matt Paul, with some mods by Billy Charlton. 21 | 22 | CyclePhilly Modifications written by Lloyd Emelle, Kathryn Killebrew, and Kevin Clough. 23 | 24 | CyclePhilly and CycleTracks is released under the GNU General Public License, version 3. 25 | See 'COPYING' for a detailed description of the GNU GPL. 26 | 27 | ----------- 28 | 29 | Installation Notes 30 | ----------- 31 | CyclePhilly is setup to use Firebase for realtime updates. Please follow the instructions 32 | at https://www.firebase.com/docs/ios-quickstart.html to setup Firebase and its dependencies. 33 | 34 | In the constants.h file, change the kFireDomain variable to your firebase url. 35 | ----------- 36 | 37 | This program is free software: you can redistribute it and/or modify 38 | it under the terms of the GNU General Public License as published by 39 | the Free Software Foundation, either version 3 of the License, or 40 | (at your option) any later version. 41 | 42 | This program is distributed in the hope that it will be useful, 43 | but WITHOUT ANY WARRANTY; without even the implied warranty of 44 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 45 | GNU General Public License for more details. 46 | 47 | You should have received a copy of the GNU General Public License 48 | along with this program. If not, see . 49 | 50 | -------------------------------------------------------------------------------- /TabBarIcons V2/tabbar_instructions.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TabBarIcons V2/tabbar_instructions.png -------------------------------------------------------------------------------- /TabBarIcons V2/tabbar_instructions@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TabBarIcons V2/tabbar_instructions@2x.png -------------------------------------------------------------------------------- /TabBarIcons V2/tabbar_notes.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TabBarIcons V2/tabbar_notes.png -------------------------------------------------------------------------------- /TabBarIcons V2/tabbar_notes@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TabBarIcons V2/tabbar_notes@2x.png -------------------------------------------------------------------------------- /TabBarIcons V2/tabbar_record.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TabBarIcons V2/tabbar_record.png -------------------------------------------------------------------------------- /TabBarIcons V2/tabbar_record@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TabBarIcons V2/tabbar_record@2x.png -------------------------------------------------------------------------------- /TabBarIcons V2/tabbar_settings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TabBarIcons V2/tabbar_settings.png -------------------------------------------------------------------------------- /TabBarIcons V2/tabbar_settings@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TabBarIcons V2/tabbar_settings@2x.png -------------------------------------------------------------------------------- /TabBarIcons V2/tabbar_view.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TabBarIcons V2/tabbar_view.png -------------------------------------------------------------------------------- /TabBarIcons V2/tabbar_view@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TabBarIcons V2/tabbar_view@2x.png -------------------------------------------------------------------------------- /TabBarIcons/settings_icon2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TabBarIcons/settings_icon2.png -------------------------------------------------------------------------------- /TabBarIcons/tabbar_instructions.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TabBarIcons/tabbar_instructions.png -------------------------------------------------------------------------------- /TabBarIcons/tabbar_record.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TabBarIcons/tabbar_record.png -------------------------------------------------------------------------------- /TabBarIcons/tabbar_settings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TabBarIcons/tabbar_settings.png -------------------------------------------------------------------------------- /TabBarIcons/tabbar_view.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TabBarIcons/tabbar_view.png -------------------------------------------------------------------------------- /Trip.h: -------------------------------------------------------------------------------- 1 | // 2 | // Trip.h 3 | // Cycle Atlanta 4 | // 5 | // Created by Guo Anhong on 13-2-26. 6 | // adapted for CyclePhilly 2013, CodeforPhilly.org 7 | // 8 | 9 | #import 10 | #import 11 | 12 | @class Coord, User; 13 | 14 | @interface Trip : NSManagedObject 15 | 16 | @property (nonatomic, retain) NSNumber * distance; 17 | @property (nonatomic, retain) NSDate * start; 18 | @property (nonatomic, retain) NSString * notes; 19 | @property (nonatomic, retain) NSDate * uploaded; 20 | @property (nonatomic, retain) NSString * purpose; 21 | @property (nonatomic, retain) NSNumber * duration; 22 | @property (nonatomic, retain) NSDate * saved; 23 | @property (nonatomic, retain) NSSet *coords; 24 | @property (nonatomic, retain) NSData * thumbnail; 25 | @property (nonatomic, retain) User *user; 26 | @end 27 | 28 | @interface Trip (CoreDataGeneratedAccessors) 29 | 30 | - (void)addCoordsObject:(Coord *)value; 31 | - (void)removeCoordsObject:(Coord *)value; 32 | - (void)addCoords:(NSSet *)values; 33 | - (void)removeCoords:(NSSet *)values; 34 | 35 | @end 36 | -------------------------------------------------------------------------------- /Trip.m: -------------------------------------------------------------------------------- 1 | // 2 | // Trip.m 3 | // Cycle Atlanta 4 | // 5 | // Created by Guo Anhong on 13-2-26. 6 | // adapted for CyclePhilly 2013, CodeforPhilly.org 7 | // 8 | 9 | #import "Trip.h" 10 | #import "Coord.h" 11 | #import "User.h" 12 | 13 | 14 | @implementation Trip 15 | 16 | @dynamic distance; 17 | @dynamic start; 18 | @dynamic notes; 19 | @dynamic uploaded; 20 | @dynamic purpose; 21 | @dynamic duration; 22 | @dynamic saved; 23 | @dynamic coords; 24 | @dynamic thumbnail; 25 | @dynamic user; 26 | 27 | @end 28 | -------------------------------------------------------------------------------- /TripPurposePicker.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 47 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/commute.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/commute.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/commute@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/commute@2x.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/errands.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/errands.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/errands@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/errands@2x.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/exercise.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/exercise.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/exercise@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/exercise@2x.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/failedUpload.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/failedUpload.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/failedUpload@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/failedUpload@2x.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/noteAssetMapGlyph.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/noteAssetMapGlyph.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/noteAssetMapGlyph@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/noteAssetMapGlyph@2x.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/noteAssetPicker.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/noteAssetPicker.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/noteAssetPicker@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/noteAssetPicker@2x.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/noteBlankPicker.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/noteBlankPicker.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/noteBlankPicker@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/noteBlankPicker@2x.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/noteIssueMapGlyph.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/noteIssueMapGlyph.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/noteIssueMapGlyph@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/noteIssueMapGlyph@2x.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/noteIssuePicker.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/noteIssuePicker.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/noteIssuePicker@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/noteIssuePicker@2x.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/other.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/other.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/other@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/other@2x.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/school.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/school.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/school@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/school@2x.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/shopping.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/shopping.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/shopping@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/shopping@2x.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/social.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/social.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/social@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/social@2x.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/tripEnd.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/tripEnd.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/tripEnd@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/tripEnd@2x.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/tripStart.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/tripStart.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/tripStart@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/tripStart@2x.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/workRelated.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/workRelated.png -------------------------------------------------------------------------------- /TripPurposePickerIcons V3/workRelated@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons V3/workRelated@2x.png -------------------------------------------------------------------------------- /TripPurposePickerIcons v2/commute.tif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons v2/commute.tif -------------------------------------------------------------------------------- /TripPurposePickerIcons v2/commuter2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons v2/commuter2.png -------------------------------------------------------------------------------- /TripPurposePickerIcons v2/errands.tif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons v2/errands.tif -------------------------------------------------------------------------------- /TripPurposePickerIcons v2/exercise.tif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons v2/exercise.tif -------------------------------------------------------------------------------- /TripPurposePickerIcons v2/other.tif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons v2/other.tif -------------------------------------------------------------------------------- /TripPurposePickerIcons v2/school.tif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons v2/school.tif -------------------------------------------------------------------------------- /TripPurposePickerIcons v2/shopping.tif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons v2/shopping.tif -------------------------------------------------------------------------------- /TripPurposePickerIcons v2/social.tif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons v2/social.tif -------------------------------------------------------------------------------- /TripPurposePickerIcons v2/work-related.tif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/TripPurposePickerIcons v2/work-related.tif -------------------------------------------------------------------------------- /UI Elements/LCD-screen-288x126.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/UI Elements/LCD-screen-288x126.png -------------------------------------------------------------------------------- /UI Elements/MapCoord.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/UI Elements/MapCoord.png -------------------------------------------------------------------------------- /UI Elements/lcd-screen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/UI Elements/lcd-screen.png -------------------------------------------------------------------------------- /UI Elements/lcd-screen@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/UI Elements/lcd-screen@2x.png -------------------------------------------------------------------------------- /UI Elements/lcdScreen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/UI Elements/lcdScreen.png -------------------------------------------------------------------------------- /UI Elements/lcdScreen@2x copy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/UI Elements/lcdScreen@2x copy.png -------------------------------------------------------------------------------- /UI Elements/lcdScreen@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/UI Elements/lcdScreen@2x.png -------------------------------------------------------------------------------- /UI Elements/photoFrame.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/UI Elements/photoFrame.png -------------------------------------------------------------------------------- /UI Elements/photoFrame@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/UI Elements/photoFrame@2x.png -------------------------------------------------------------------------------- /UI Elements/record-map-frame-288x141.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/UI Elements/record-map-frame-288x141.png -------------------------------------------------------------------------------- /UIDevice+IdentifierAddition.h: -------------------------------------------------------------------------------- 1 | // 2 | // UIDevice(Identifier).h 3 | // UIDeviceAddition 4 | // 5 | // Created by Georg Kitz on 20.08.11. 6 | // Copyright 2011 Aurora Apps. All rights reserved. 7 | // 8 | 9 | #import 10 | //#import 11 | 12 | 13 | @interface UIDevice (IdentifierAddition) 14 | @property(nonatomic, readonly, retain) NSUUID *identifierForVendor; 15 | @property(nonatomic, readonly) NSUUID *advertisingIdentifier; 16 | /* 17 | * @method uniqueDeviceIdentifier 18 | * @description use this method when you need a unique identifier in one app. 19 | * It generates a hash from the MAC-address in combination with the bundle identifier 20 | * of your app. 21 | */ 22 | 23 | - (NSString *) uniqueDeviceIdentifier; 24 | 25 | /* 26 | * @method uniqueGlobalDeviceIdentifier 27 | * @description use this method when you need a unique global identifier to track a device 28 | * with multiple apps. as example a advertising network will use this method to track the device 29 | * from different apps. 30 | * It generates a hash from the MAC-address only. 31 | */ 32 | 33 | - (NSString *) uniqueGlobalDeviceIdentifier; 34 | 35 | @end 36 | -------------------------------------------------------------------------------- /UIDevice+IdentifierAddition.m: -------------------------------------------------------------------------------- 1 | // 2 | // UIDevice(Identifier).m 3 | // UIDeviceAddition 4 | // 5 | // Created by Georg Kitz on 20.08.11. 6 | // Copyright 2011 Aurora Apps. All rights reserved. 7 | // 8 | 9 | #import "UIDevice+IdentifierAddition.h" 10 | #import "NSString+MD5Addition.h" 11 | 12 | #include // Per msqr 13 | #include 14 | #include 15 | #include 16 | 17 | //@interface UIDevice(Private) 18 | // 19 | //- (NSString *) macaddress; 20 | // 21 | //@end 22 | // 23 | //@implementation UIDevice (IdentifierAddition) 24 | 25 | @implementation UIDevice (advertisingIdentifier) 26 | //////////////////////////////////////////////////////////////////////////////// 27 | #pragma mark - 28 | #pragma mark Private Methods 29 | 30 | // Return the local MAC addy 31 | // Courtesy of FreeBSD hackers email list 32 | // Accidentally munged during previous update. Fixed thanks to erica sadun & mlamb. 33 | //- (NSString *) macaddress{ 34 | // 35 | // int mib[6]; 36 | // size_t len; 37 | // char *buf; 38 | // unsigned char *ptr; 39 | // struct if_msghdr *ifm; 40 | // struct sockaddr_dl *sdl; 41 | // 42 | // mib[0] = CTL_NET; 43 | // mib[1] = AF_ROUTE; 44 | // mib[2] = 0; 45 | // mib[3] = AF_LINK; 46 | // mib[4] = NET_RT_IFLIST; 47 | // 48 | // if ((mib[5] = if_nametoindex("en0")) == 0) { 49 | // printf("Error: if_nametoindex error\n"); 50 | // return NULL; 51 | // } 52 | // 53 | // if (sysctl(mib, 6, NULL, &len, NULL, 0) < 0) { 54 | // printf("Error: sysctl, take 1\n"); 55 | // return NULL; 56 | // } 57 | // 58 | // if ((buf = malloc(len)) == NULL) { 59 | // printf("Could not allocate memory. error!\n"); 60 | // return NULL; 61 | // } 62 | // 63 | // if (sysctl(mib, 6, buf, &len, NULL, 0) < 0) { 64 | // printf("Error: sysctl, take 2"); 65 | // free(buf); 66 | // return NULL; 67 | // } 68 | // 69 | // ifm = (struct if_msghdr *)buf; 70 | // sdl = (struct sockaddr_dl *)(ifm + 1); 71 | // ptr = (unsigned char *)LLADDR(sdl); 72 | // NSString *outstring = [NSString stringWithFormat:@"%02X:%02X:%02X:%02X:%02X:%02X", 73 | // *ptr, *(ptr+1), *(ptr+2), *(ptr+3), *(ptr+4), *(ptr+5)]; 74 | // free(buf); 75 | // 76 | // return outstring; 77 | //} 78 | 79 | //////////////////////////////////////////////////////////////////////////////// 80 | #pragma mark - 81 | #pragma mark Public Methods 82 | 83 | - (NSString *) uniqueDeviceIdentifier{ 84 | // NSString *macaddress = [[UIDevice currentDevice] macaddress]; 85 | // NSString *bundleIdentifier = [[NSBundle mainBundle] bundleIdentifier]; 86 | // 87 | // NSString *stringToHash = [NSString stringWithFormat:@"%@%@",macaddress,bundleIdentifier]; 88 | // NSString *uniqueIdentifier = [stringToHash stringFromMD5]; 89 | NSString *uniqueIdentifier =[[[UIDevice currentDevice] identifierForVendor] UUIDString]; 90 | 91 | return uniqueIdentifier; 92 | } 93 | 94 | //- (NSString *) uniqueGlobalDeviceIdentifier{ 95 | // NSString *macaddress = [[UIDevice currentDevice] macaddress]; 96 | // NSString *uniqueIdentifier = [macaddress stringFromMD5]; 97 | // 98 | // return uniqueIdentifier; 99 | //} 100 | 101 | @end 102 | -------------------------------------------------------------------------------- /UIImageViewResizable.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Cycle Atlanta is free software: you can redistribute it and/or modify 18 | * it under the terms of the GNU General Public License as published by 19 | * the Free Software Foundation, either version 3 of the License, or 20 | * (at your option) any later version. 21 | * 22 | * Cycle Atlanta is distributed in the hope that it will be useful, 23 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 24 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 25 | * GNU General Public License for more details. 26 | * 27 | * You should have received a copy of the GNU General Public License 28 | * along with Cycle Atlanta. If not, see . 29 | */ 30 | 31 | // 32 | // UIImageViewResizable.h 33 | // 34 | // Created by Mike Valstar on 2012-09-10. 35 | // 36 | 37 | #import 38 | 39 | @interface UIImageViewResizable : UIImageView { 40 | UIPanGestureRecognizer *panGesture; 41 | } 42 | 43 | @property(nonatomic) BOOL isZoomable; 44 | 45 | - (void) applyGestures; 46 | - (void) scaleToMinimum; 47 | 48 | - (void)pinch:(UIPinchGestureRecognizer *)gesture; 49 | - (void)pan:(UIPanGestureRecognizer *)gesture; 50 | - (void)doubleTap:(UITapGestureRecognizer *)gesture; 51 | 52 | @end -------------------------------------------------------------------------------- /User.h: -------------------------------------------------------------------------------- 1 | // 2 | // User.h 3 | // Cycle Atlanta 4 | // 5 | // Created by Guo Anhong on 13-2-26. 6 | // adapted for CyclePhilly 2013, CodeforPhilly.org 7 | // 8 | 9 | #import 10 | #import 11 | 12 | @class Note, Trip; 13 | 14 | @interface User : NSManagedObject 15 | 16 | @property (nonatomic, retain) NSNumber * age; 17 | @property (nonatomic, retain) NSNumber * cyclingFreq; 18 | @property (nonatomic, retain) NSNumber * rider_history; 19 | @property (nonatomic, retain) NSNumber * rider_type; 20 | @property (nonatomic, retain) NSNumber * income; 21 | @property (nonatomic, retain) NSNumber * ethnicity; 22 | @property (nonatomic, retain) NSString * homeZIP; 23 | @property (nonatomic, retain) NSString * schoolZIP; 24 | @property (nonatomic, retain) NSString * workZIP; 25 | @property (nonatomic, retain) NSNumber * gender; 26 | @property (nonatomic, retain) NSString * email; 27 | @property (nonatomic, retain) NSSet *trips; 28 | @end 29 | 30 | @interface User (CoreDataGeneratedAccessors) 31 | 32 | - (void)addTripsObject:(Trip *)value; 33 | - (void)removeTripsObject:(Trip *)value; 34 | - (void)addTrips:(NSSet *)values; 35 | - (void)removeTrips:(NSSet *)values; 36 | 37 | @end 38 | -------------------------------------------------------------------------------- /User.m: -------------------------------------------------------------------------------- 1 | // 2 | // User.m 3 | // Cycle Atlanta 4 | // 5 | // Created by Guo Anhong on 13-2-26. 6 | // adapted for CyclePhilly 2013, CodeforPhilly.org 7 | // 8 | 9 | #import "User.h" 10 | #import "Trip.h" 11 | 12 | 13 | @implementation User 14 | 15 | @dynamic age; 16 | @dynamic cyclingFreq; 17 | @dynamic rider_history; 18 | @dynamic rider_type; 19 | @dynamic income; 20 | @dynamic ethnicity; 21 | @dynamic homeZIP; 22 | @dynamic schoolZIP; 23 | @dynamic workZIP; 24 | @dynamic gender; 25 | @dynamic email; 26 | @dynamic trips; 27 | 28 | @end 29 | -------------------------------------------------------------------------------- /bicycle-bell-normalized.aiff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CodeForPhilly/CyclePhilly-iOS-app/56f53176d41d77d55e55fa1c306eeaef3026ab78/bicycle-bell-normalized.aiff -------------------------------------------------------------------------------- /constants.h: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * @author Corey Acri 6 | * @author Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // constants.h 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 8/25/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | 51 | #define kActionSheetButtonConfirm 0 52 | #define kActionSheetButtonChange 1 53 | #define kActionSheetButtonDiscard 2 54 | #define kActionSheetButtonCancel 3 55 | 56 | #define kActivityIndicatorSize 20.0 57 | 58 | #define kCounterTimeInterval 0.5 59 | 60 | #define kCustomButtonWidth 136.0 61 | #define kCustomButtonHeight 48.0 62 | 63 | #define kCounterFontSize 26.0 64 | #define kMinimumFontSize 16.0 65 | 66 | #define kStdButtonWidth 106.0 67 | #define kStdButtonHeight 40.0 68 | 69 | #define kJpegQuality 0.9 70 | 71 | // error messages 72 | #define kConnectionError @"Server unreachable, \n try again later." 73 | #define kServerError @"Upload failed, \n try again later." 74 | 75 | // alert titles 76 | #define kBatteryTitle @"Battery Low" 77 | #define kRetryTitle @"Retry Upload?" 78 | #define kSavingTitle @"Uploading your trip" 79 | #define kSuccessTitle @"Upload complete" 80 | #define kTripNotesTitle @"Enter Comments Below" 81 | #define kConsentFor18Title @"In order to transmit route data, you must be at least 18." 82 | 83 | 84 | #define kInterruptedTitle @"Recording Interrupted" 85 | #define kInterruptedMessage @"Oops! Looks like a previous trip recording has been interrupted." 86 | #define kUnsyncedTitle @"Found Unsynced Trip(s)" 87 | #define kUnsyncedMessage @"You have at least one saved trip that has not yet been uploaded." 88 | #define kZeroDistanceTitle @"Recalculate Trip Distance?" 89 | #define kZeroDistanceMessage @"Your trip distance estimates may need to be recalculated..." 90 | 91 | // alert messages 92 | #define kConsentFor18Message @"Are you at least 18 years old?" 93 | #define kBatteryMessage @"Recording of your trip has been halted to preserve battery life." 94 | #define kConnecting @"Contacting server..." 95 | #define kPreparingData @"Preparing your trip data for transfer." 96 | #define kRetryMessage @"This trip has not yet been uploaded successfully. Try again?" 97 | #define kSaveSuccess @"Your trip has been uploaded successfully. Thank you." 98 | #define kSaveAccepted @"Your trip has already been uploaded. Thank you." 99 | #define kSaveError @"Your trip has been saved. Please try uploading again later." 100 | 101 | // updated references for posting to Cycle Philly site for Cycle Philly adaptation for questions email Corey Acri acri.corey@gmail.com 102 | 103 | #define kInfoURL @"http://www.cyclephilly.org/#about" 104 | #define kInstructionsURL @"mailto:support@cyclephilly.org" 105 | 106 | #define kSaveURL @"http://www.cyclephilly.org/post/" 107 | 108 | #define kFireDomain @"https://cyclephilly.firebaseio.com/" 109 | //#define kSaveURL @"" 110 | 111 | #define kTripNotesPlaceholder @"Comments" 112 | 113 | // CustomView metrics used by UIPickerViewDataSource, UIPickerViewDelegate 114 | #define MAIN_FONT_SIZE 18 115 | #define MIN_MAIN_FONT_SIZE 16 116 | 117 | -------------------------------------------------------------------------------- /dist.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | get-task-allow 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /main.m: -------------------------------------------------------------------------------- 1 | /** Cycle Philly, 2013 Code For Philly 2 | * Philadelphia, PA. USA 3 | * 4 | * 5 | * Contact: Corey Acri 6 | * Lloyd Emelle 7 | * 8 | * Updated/Modified for Philadelphia's app deployment. Based on the 9 | * Cycle Atlanta and CycleTracks codebase for SFCTA. 10 | * 11 | * Cycle Atlanta, Copyright 2012, 2013 Georgia Institute of Technology 12 | * Atlanta, GA. USA 13 | * 14 | * @author Christopher Le Dantec 15 | * @author Anhong Guo 16 | * 17 | * Updated/Modified for Atlanta's app deployment. Based on the 18 | * CycleTracks codebase for SFCTA. 19 | * 20 | ** CycleTracks, Copyright 2009,2010 San Francisco County Transportation Authority 21 | * San Francisco, CA, USA 22 | * 23 | * @author Matt Paul 24 | * 25 | * This file is part of CycleTracks. 26 | * 27 | * CycleTracks is free software: you can redistribute it and/or modify 28 | * it under the terms of the GNU General Public License as published by 29 | * the Free Software Foundation, either version 3 of the License, or 30 | * (at your option) any later version. 31 | * 32 | * CycleTracks is distributed in the hope that it will be useful, 33 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 34 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 35 | * GNU General Public License for more details. 36 | * 37 | * You should have received a copy of the GNU General Public License 38 | * along with CycleTracks. If not, see . 39 | */ 40 | 41 | // 42 | // main.m 43 | // CycleTracks 44 | // 45 | // Copyright 2009-2010 SFCTA. All rights reserved. 46 | // Written by Matt Paul on 8/10/09. 47 | // For more information on the project, 48 | // e-mail Billy Charlton at the SFCTA 49 | 50 | #import 51 | 52 | int main(int argc, char *argv[]) { 53 | 54 | NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init]; 55 | int retVal = UIApplicationMain(argc, argv, nil, nil); 56 | [pool release]; 57 | return retVal; 58 | } 59 | -------------------------------------------------------------------------------- /migrate.c: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | #include 5 | 6 | FILE *fopen$UNIX2003( const char *filename, const char *mode ) 7 | { 8 | return fopen(filename, mode); 9 | } 10 | 11 | int fputs$UNIX2003(const char *res1, FILE *res2){ 12 | return fputs(res1,res2); 13 | } 14 | 15 | int nanosleep$UNIX2003(int val){ 16 | return usleep(val); 17 | } 18 | 19 | char* strerror$UNIX2003(int errornum){ 20 | return strerror(errornum); 21 | } 22 | 23 | double strtod$UNIX2003(const char *nptr, char **endptr){ 24 | return strtod(nptr, endptr); 25 | } 26 | 27 | size_t fwrite$UNIX2003( const void *a, size_t b, size_t c, FILE *d ) 28 | { 29 | return fwrite(a, b, c, d); 30 | } --------------------------------------------------------------------------------