diff --git a/MasterPassword.xcodeproj/project.pbxproj b/MasterPassword.xcodeproj/project.pbxproj index 9f97b020..c0d15476 100644 --- a/MasterPassword.xcodeproj/project.pbxproj +++ b/MasterPassword.xcodeproj/project.pbxproj @@ -107,6 +107,15 @@ DA5BFA5B147E415C00F98B1E /* MPAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = DA5BFA5A147E415C00F98B1E /* MPAppDelegate.m */; }; DA5BFA64147E415C00F98B1E /* MasterPassword.xcdatamodeld in Sources */ = {isa = PBXBuildFile; fileRef = DA5BFA62147E415C00F98B1E /* MasterPassword.xcdatamodeld */; }; DA5BFA67147E415C00F98B1E /* MPMainViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = DA5BFA66147E415C00F98B1E /* MPMainViewController.m */; }; + DA5BFCD01502CDF5005BFE16 /* Exo-Black.otf in Resources */ = {isa = PBXBuildFile; fileRef = DA5BFCBE1502CDF5005BFE16 /* Exo-Black.otf */; }; + DA5BFCD21502CDF5005BFE16 /* Exo-Bold.otf in Resources */ = {isa = PBXBuildFile; fileRef = DA5BFCC01502CDF5005BFE16 /* Exo-Bold.otf */; }; + DA5BFCD41502CDF5005BFE16 /* Exo-DemiBold.otf in Resources */ = {isa = PBXBuildFile; fileRef = DA5BFCC21502CDF5005BFE16 /* Exo-DemiBold.otf */; }; + DA5BFCD61502CDF5005BFE16 /* Exo-ExtraBold.otf in Resources */ = {isa = PBXBuildFile; fileRef = DA5BFCC41502CDF5005BFE16 /* Exo-ExtraBold.otf */; }; + DA5BFCD81502CDF5005BFE16 /* Exo-ExtraLight.otf in Resources */ = {isa = PBXBuildFile; fileRef = DA5BFCC61502CDF5005BFE16 /* Exo-ExtraLight.otf */; }; + DA5BFCDA1502CDF5005BFE16 /* Exo-Light.otf in Resources */ = {isa = PBXBuildFile; fileRef = DA5BFCC81502CDF5005BFE16 /* Exo-Light.otf */; }; + DA5BFCDC1502CDF5005BFE16 /* Exo-Medium.otf in Resources */ = {isa = PBXBuildFile; fileRef = DA5BFCCA1502CDF5005BFE16 /* Exo-Medium.otf */; }; + DA5BFCDE1502CDF5005BFE16 /* Exo-Regular.otf in Resources */ = {isa = PBXBuildFile; fileRef = DA5BFCCC1502CDF5005BFE16 /* Exo-Regular.otf */; }; + DA5BFCE01502CDF5005BFE16 /* Exo-Thin.otf in Resources */ = {isa = PBXBuildFile; fileRef = DA5BFCCE1502CDF5005BFE16 /* Exo-Thin.otf */; }; DA5DB7A614BE4B19002DD256 /* Default.png in Resources */ = {isa = PBXBuildFile; fileRef = DA5DB7A514BE4B19002DD256 /* Default.png */; }; DA5DB7A814BE4B4B002DD256 /* Default@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = DA5DB7A714BE4B4B002DD256 /* Default@2x.png */; }; DA6556FE14D730B700841C99 /* guide_page_1.png in Resources */ = {isa = PBXBuildFile; fileRef = DA6556F814D730B700841C99 /* guide_page_1.png */; }; @@ -935,6 +944,15 @@ DA5BFA63147E415C00F98B1E /* MasterPassword.xcdatamodel */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcdatamodel; path = MasterPassword.xcdatamodel; sourceTree = ""; }; DA5BFA65147E415C00F98B1E /* MPMainViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MPMainViewController.h; sourceTree = ""; }; DA5BFA66147E415C00F98B1E /* MPMainViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MPMainViewController.m; sourceTree = ""; }; + DA5BFCBE1502CDF5005BFE16 /* Exo-Black.otf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "Exo-Black.otf"; sourceTree = ""; }; + DA5BFCC01502CDF5005BFE16 /* Exo-Bold.otf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "Exo-Bold.otf"; sourceTree = ""; }; + DA5BFCC21502CDF5005BFE16 /* Exo-DemiBold.otf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "Exo-DemiBold.otf"; sourceTree = ""; }; + DA5BFCC41502CDF5005BFE16 /* Exo-ExtraBold.otf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "Exo-ExtraBold.otf"; sourceTree = ""; }; + DA5BFCC61502CDF5005BFE16 /* Exo-ExtraLight.otf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "Exo-ExtraLight.otf"; sourceTree = ""; }; + DA5BFCC81502CDF5005BFE16 /* Exo-Light.otf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "Exo-Light.otf"; sourceTree = ""; }; + DA5BFCCA1502CDF5005BFE16 /* Exo-Medium.otf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "Exo-Medium.otf"; sourceTree = ""; }; + DA5BFCCC1502CDF5005BFE16 /* Exo-Regular.otf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "Exo-Regular.otf"; sourceTree = ""; }; + DA5BFCCE1502CDF5005BFE16 /* Exo-Thin.otf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "Exo-Thin.otf"; sourceTree = ""; }; DA5DB7A514BE4B19002DD256 /* Default.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = Default.png; path = ../Default.png; sourceTree = ""; }; DA5DB7A714BE4B4B002DD256 /* Default@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = "Default@2x.png"; path = "../Default@2x.png"; sourceTree = ""; }; DA6556F814D730B700841C99 /* guide_page_1.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = guide_page_1.png; sourceTree = ""; }; @@ -2304,6 +2322,7 @@ DA5BFA51147E415C00F98B1E /* Supporting Files */ = { isa = PBXGroup; children = ( + DA5BFCBC1502CDF5005BFE16 /* Fonts */, DA566D3114F8EB0700A6EB2E /* Background */, DA566D1E14F8EAF200A6EB2E /* Lock */, DA8E8E4514DD7C1D0044257E /* logo-bare.png */, @@ -2332,6 +2351,23 @@ name = "Supporting Files"; sourceTree = ""; }; + DA5BFCBC1502CDF5005BFE16 /* Fonts */ = { + isa = PBXGroup; + children = ( + DA5BFCBE1502CDF5005BFE16 /* Exo-Black.otf */, + DA5BFCC41502CDF5005BFE16 /* Exo-ExtraBold.otf */, + DA5BFCC01502CDF5005BFE16 /* Exo-Bold.otf */, + DA5BFCC21502CDF5005BFE16 /* Exo-DemiBold.otf */, + DA5BFCCA1502CDF5005BFE16 /* Exo-Medium.otf */, + DA5BFCCC1502CDF5005BFE16 /* Exo-Regular.otf */, + DA5BFCC81502CDF5005BFE16 /* Exo-Light.otf */, + DA5BFCC61502CDF5005BFE16 /* Exo-ExtraLight.otf */, + DA5BFCCE1502CDF5005BFE16 /* Exo-Thin.otf */, + ); + name = Fonts; + path = Resources/Fonts; + sourceTree = ""; + }; DA6556F714D730B700841C99 /* Guide */ = { isa = PBXGroup; children = ( @@ -3591,6 +3627,15 @@ DA67305314F98B6F004A189C /* icon_wrench.png in Resources */, DA67305414F98B6F004A189C /* icon_wrench@2x.png in Resources */, DADC288814FDAC0C00047FEB /* Pearl.strings in Resources */, + DA5BFCD01502CDF5005BFE16 /* Exo-Black.otf in Resources */, + DA5BFCD21502CDF5005BFE16 /* Exo-Bold.otf in Resources */, + DA5BFCD41502CDF5005BFE16 /* Exo-DemiBold.otf in Resources */, + DA5BFCD61502CDF5005BFE16 /* Exo-ExtraBold.otf in Resources */, + DA5BFCD81502CDF5005BFE16 /* Exo-ExtraLight.otf in Resources */, + DA5BFCDA1502CDF5005BFE16 /* Exo-Light.otf in Resources */, + DA5BFCDC1502CDF5005BFE16 /* Exo-Medium.otf in Resources */, + DA5BFCDE1502CDF5005BFE16 /* Exo-Regular.otf in Resources */, + DA5BFCE01502CDF5005BFE16 /* Exo-Thin.otf in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; diff --git a/MasterPassword.xcodeproj/xcshareddata/xcschemes/MasterPassword (App Store).xcscheme b/MasterPassword.xcodeproj/xcshareddata/xcschemes/MasterPassword (App Store).xcscheme index 4144fae6..8400d12e 100644 --- a/MasterPassword.xcodeproj/xcshareddata/xcschemes/MasterPassword (App Store).xcscheme +++ b/MasterPassword.xcodeproj/xcshareddata/xcschemes/MasterPassword (App Store).xcscheme @@ -1,10 +1,16 @@ - + + buildForTesting = "YES" + buildForRunning = "YES" + buildForProfiling = "YES" + buildForArchiving = "YES" + buildForAnalyzing = "YES"> + + + + + buildConfiguration = "Production" + ignoresPersistentStateOnLaunch = "NO" + debugDocumentVersioning = "YES" + allowLocationSimulation = "YES"> + + + + + + + + diff --git a/MasterPassword.xcodeproj/xcshareddata/xcschemes/MasterPassword (Development).xcscheme b/MasterPassword.xcodeproj/xcshareddata/xcschemes/MasterPassword (Development).xcscheme index d25d3e26..f9742ba4 100644 --- a/MasterPassword.xcodeproj/xcshareddata/xcschemes/MasterPassword (Development).xcscheme +++ b/MasterPassword.xcodeproj/xcshareddata/xcschemes/MasterPassword (Development).xcscheme @@ -1,10 +1,16 @@ - + + buildForTesting = "YES" + buildForRunning = "YES" + buildForProfiling = "YES" + buildForArchiving = "YES" + buildForAnalyzing = "YES"> + + + + + buildConfiguration = "Debug" + ignoresPersistentStateOnLaunch = "NO" + debugDocumentVersioning = "YES" + allowLocationSimulation = "YES"> + + + + + + + + diff --git a/MasterPassword/.OPMainViewController.h.swk b/MasterPassword/.OPMainViewController.h.swk deleted file mode 100644 index 865b09f3..00000000 Binary files a/MasterPassword/.OPMainViewController.h.swk and /dev/null differ diff --git a/MasterPassword/.OPMainViewController.h.swl b/MasterPassword/.OPMainViewController.h.swl deleted file mode 100644 index 2866df1f..00000000 Binary files a/MasterPassword/.OPMainViewController.h.swl and /dev/null differ diff --git a/MasterPassword/.OPMainViewController.h.swm b/MasterPassword/.OPMainViewController.h.swm deleted file mode 100644 index 3f3de861..00000000 Binary files a/MasterPassword/.OPMainViewController.h.swm and /dev/null differ diff --git a/MasterPassword/.OPMainViewController.h.swn b/MasterPassword/.OPMainViewController.h.swn deleted file mode 100644 index abd242bc..00000000 Binary files a/MasterPassword/.OPMainViewController.h.swn and /dev/null differ diff --git a/MasterPassword/.OPMainViewController.h.swo b/MasterPassword/.OPMainViewController.h.swo deleted file mode 100644 index e358fb72..00000000 Binary files a/MasterPassword/.OPMainViewController.h.swo and /dev/null differ diff --git a/MasterPassword/.OPTypes.m.swn b/MasterPassword/.OPTypes.m.swn deleted file mode 100644 index 6105d5a9..00000000 Binary files a/MasterPassword/.OPTypes.m.swn and /dev/null differ diff --git a/MasterPassword/.OPTypes.m.swo b/MasterPassword/.OPTypes.m.swo deleted file mode 100644 index 13f70f77..00000000 Binary files a/MasterPassword/.OPTypes.m.swo and /dev/null differ diff --git a/MasterPassword/MPMainViewController.m b/MasterPassword/MPMainViewController.m index 533bdfe1..e8b96062 100644 --- a/MasterPassword/MPMainViewController.m +++ b/MasterPassword/MPMainViewController.m @@ -94,6 +94,8 @@ - (void)viewDidLoad { self.view.backgroundColor = [UIColor colorWithPatternImage:[UIImage imageNamed:@"ui_background"]]; + + self.contentField.font = [UIFont fontWithName:@"Exo-Black" size:self.contentField.font.pointSize]; // Put the search tip on the window so it's above the nav bar. if (![self.searchTipContainer.superview isEqual:self.navigationController.navigationBar.superview]) { @@ -367,124 +369,123 @@ case 4: [TestFlight openFeedbackView]; break; - case 5: { + case 5: #else - case 4: { + case 4: #endif [[MPAppDelegate get] signOut]; break; - } - } - -#ifndef PRODUCTION - [TestFlight passCheckpoint:MPTestFlightCheckpointAction]; -#endif - } cancelTitle:[PearlStrings get].commonButtonCancel destructiveTitle:nil - otherTitles: - [self isHelpVisible]? @"Hide Help": @"Show Help", @"FAQ", @"Tutorial", @"Settings", -#ifndef PRODUCTION - @"Feedback", -#endif - @"Sign Out", - nil]; - } - - - (MPElementType)selectedType { - - return self.activeElement.type; - } - - - (void)didSelectType:(MPElementType)type { - - [self updateElement:^{ - // Update password type. - if (ClassFromMPElementType(type) != ClassFromMPElementType(self.activeElement.type)) - // Type requires a different class of element. Recreate the element. - [[MPAppDelegate managedObjectContext] performBlockAndWait:^{ - MPElementEntity *newElement = [NSEntityDescription insertNewObjectForEntityForName:ClassNameFromMPElementType(type) - inManagedObjectContext:[MPAppDelegate managedObjectContext]]; - newElement.name = self.activeElement.name; - newElement.mpHashHex = self.activeElement.mpHashHex; - newElement.uses = self.activeElement.uses; - newElement.lastUsed = self.activeElement.lastUsed; + } - [[MPAppDelegate managedObjectContext] deleteObject:self.activeElement]; - self.activeElement = newElement; - }]; - - self.activeElement.type = type; - #ifndef PRODUCTION - [TestFlight passCheckpoint:[NSString stringWithFormat:MPTestFlightCheckpointSelectType, NSStringFromMPElementType(type)]]; + [TestFlight passCheckpoint:MPTestFlightCheckpointAction]; #endif - - if (type & MPElementTypeClassStored && ![self.activeElement.description length]) - [self showContentTip:@"Tap to set a password." withIcon:self.contentTipEditIcon]; - }]; - } - - - (void)didSelectElement:(MPElementEntity *)element { - - if (element) { - self.activeElement = element; - [self.activeElement use]; - - [self.searchDisplayController setActive:NO animated:YES]; - self.searchDisplayController.searchBar.text = self.activeElement.name; - + } cancelTitle:[PearlStrings get].commonButtonCancel destructiveTitle:nil + otherTitles: + [self isHelpVisible]? @"Hide Help": @"Show Help", @"FAQ", @"Tutorial", @"Settings", #ifndef PRODUCTION - [TestFlight passCheckpoint:MPTestFlightCheckpointSelectElement]; + @"Feedback", #endif - } - - [self updateAnimated:YES]; - } - - - (BOOL)textFieldShouldReturn:(UITextField *)textField { - - if (textField == self.contentField) - [self.contentField resignFirstResponder]; - - return YES; - } - - - (void)textFieldDidEndEditing:(UITextField *)textField { - - if (textField == self.contentField) { - self.contentField.enabled = NO; - if (![self.activeElement isKindOfClass:[MPElementStoredEntity class]]) - // Not of a type whose content can be edited. - return; - - if ([((MPElementStoredEntity *) self.activeElement).content isEqual:self.contentField.text]) - // Content hasn't changed. - return; - - [self updateElement:^{ - ((MPElementStoredEntity *) self.activeElement).content = self.contentField.text; - }]; - } - } - - - (BOOL)webView:(UIWebView *)webView shouldStartLoadWithRequest:(NSURLRequest *)request - navigationType:(UIWebViewNavigationType)navigationType { - - if (navigationType == UIWebViewNavigationTypeLinkClicked) { + @"Sign Out", + nil]; +} + +- (MPElementType)selectedType { + + return self.activeElement.type; +} + +- (void)didSelectType:(MPElementType)type { + + [self updateElement:^{ + // Update password type. + if (ClassFromMPElementType(type) != ClassFromMPElementType(self.activeElement.type)) + // Type requires a different class of element. Recreate the element. + [[MPAppDelegate managedObjectContext] performBlockAndWait:^{ + MPElementEntity *newElement = [NSEntityDescription insertNewObjectForEntityForName:ClassNameFromMPElementType(type) + inManagedObjectContext:[MPAppDelegate managedObjectContext]]; + newElement.name = self.activeElement.name; + newElement.mpHashHex = self.activeElement.mpHashHex; + newElement.uses = self.activeElement.uses; + newElement.lastUsed = self.activeElement.lastUsed; + + [[MPAppDelegate managedObjectContext] deleteObject:self.activeElement]; + self.activeElement = newElement; + }]; + + self.activeElement.type = type; + #ifndef PRODUCTION - [TestFlight passCheckpoint:MPTestFlightCheckpointExternalLink]; + [TestFlight passCheckpoint:[NSString stringWithFormat:MPTestFlightCheckpointSelectType, NSStringFromMPElementType(type)]]; #endif - - [[UIApplication sharedApplication] openURL:[request URL]]; - return NO; - } - - return YES; - } - - - (void)settingsViewControllerDidEnd:(IASKAppSettingsViewController *)sender { - - while ([self.navigationController.viewControllers containsObject:sender]) - [self.navigationController popViewControllerAnimated:YES]; - } - - @end + + if (type & MPElementTypeClassStored && ![self.activeElement.description length]) + [self showContentTip:@"Tap to set a password." withIcon:self.contentTipEditIcon]; + }]; +} + +- (void)didSelectElement:(MPElementEntity *)element { + + if (element) { + self.activeElement = element; + [self.activeElement use]; + + [self.searchDisplayController setActive:NO animated:YES]; + self.searchDisplayController.searchBar.text = self.activeElement.name; + +#ifndef PRODUCTION + [TestFlight passCheckpoint:MPTestFlightCheckpointSelectElement]; +#endif + } + + [self updateAnimated:YES]; +} + +- (BOOL)textFieldShouldReturn:(UITextField *)textField { + + if (textField == self.contentField) + [self.contentField resignFirstResponder]; + + return YES; +} + +- (void)textFieldDidEndEditing:(UITextField *)textField { + + if (textField == self.contentField) { + self.contentField.enabled = NO; + if (![self.activeElement isKindOfClass:[MPElementStoredEntity class]]) + // Not of a type whose content can be edited. + return; + + if ([((MPElementStoredEntity *) self.activeElement).content isEqual:self.contentField.text]) + // Content hasn't changed. + return; + + [self updateElement:^{ + ((MPElementStoredEntity *) self.activeElement).content = self.contentField.text; + }]; + } +} + +- (BOOL)webView:(UIWebView *)webView shouldStartLoadWithRequest:(NSURLRequest *)request + navigationType:(UIWebViewNavigationType)navigationType { + + if (navigationType == UIWebViewNavigationTypeLinkClicked) { +#ifndef PRODUCTION + [TestFlight passCheckpoint:MPTestFlightCheckpointExternalLink]; +#endif + + [[UIApplication sharedApplication] openURL:[request URL]]; + return NO; + } + + return YES; +} + +- (void)settingsViewControllerDidEnd:(IASKAppSettingsViewController *)sender { + + while ([self.navigationController.viewControllers containsObject:sender]) + [self.navigationController popViewControllerAnimated:YES]; +} + +@end diff --git a/MasterPassword/MainStoryboard_iPhone.storyboard b/MasterPassword/MainStoryboard_iPhone.storyboard index 41b289f3..75446528 100644 --- a/MasterPassword/MainStoryboard_iPhone.storyboard +++ b/MasterPassword/MainStoryboard_iPhone.storyboard @@ -811,64 +811,6 @@ L4m3P4sSw0rD - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/MasterPassword/MasterPassword-Info.plist b/MasterPassword/MasterPassword-Info.plist index 4bf4db4d..d383d18e 100644 --- a/MasterPassword/MasterPassword-Info.plist +++ b/MasterPassword/MasterPassword-Info.plist @@ -46,6 +46,18 @@ NSHumanReadableCopyright © 2011-2012, Lyndir + UIAppFonts + + Exo-Black.otf + Exo-ExtraBold.otf + Exo-Bold.otf + Exo-DemiBold.otf + Exo-Medium.otf + Exo-Regular.otf + Exo-Light.otf + Exo-ExtraLight.otf + Exo-Thin.otf + UIMainStoryboardFile MainStoryboard_iPhone UIMainStoryboardFile~ipad diff --git a/MasterPassword/Resources/Fonts/Exo-Black.otf b/MasterPassword/Resources/Fonts/Exo-Black.otf new file mode 100644 index 00000000..56b2484e Binary files /dev/null and b/MasterPassword/Resources/Fonts/Exo-Black.otf differ diff --git a/MasterPassword/Resources/Fonts/Exo-Bold.otf b/MasterPassword/Resources/Fonts/Exo-Bold.otf new file mode 100644 index 00000000..02ff3b55 Binary files /dev/null and b/MasterPassword/Resources/Fonts/Exo-Bold.otf differ diff --git a/MasterPassword/Resources/Fonts/Exo-DemiBold.otf b/MasterPassword/Resources/Fonts/Exo-DemiBold.otf new file mode 100644 index 00000000..b83a13a4 Binary files /dev/null and b/MasterPassword/Resources/Fonts/Exo-DemiBold.otf differ diff --git a/MasterPassword/Resources/Fonts/Exo-ExtraBold.otf b/MasterPassword/Resources/Fonts/Exo-ExtraBold.otf new file mode 100644 index 00000000..1e1c3311 Binary files /dev/null and b/MasterPassword/Resources/Fonts/Exo-ExtraBold.otf differ diff --git a/MasterPassword/Resources/Fonts/Exo-ExtraLight.otf b/MasterPassword/Resources/Fonts/Exo-ExtraLight.otf new file mode 100644 index 00000000..c04ff16a Binary files /dev/null and b/MasterPassword/Resources/Fonts/Exo-ExtraLight.otf differ diff --git a/MasterPassword/Resources/Fonts/Exo-Light.otf b/MasterPassword/Resources/Fonts/Exo-Light.otf new file mode 100644 index 00000000..490fe6da Binary files /dev/null and b/MasterPassword/Resources/Fonts/Exo-Light.otf differ diff --git a/MasterPassword/Resources/Fonts/Exo-Medium.otf b/MasterPassword/Resources/Fonts/Exo-Medium.otf new file mode 100644 index 00000000..f86f3ffe Binary files /dev/null and b/MasterPassword/Resources/Fonts/Exo-Medium.otf differ diff --git a/MasterPassword/Resources/Fonts/Exo-Regular.otf b/MasterPassword/Resources/Fonts/Exo-Regular.otf new file mode 100644 index 00000000..4c4691f2 Binary files /dev/null and b/MasterPassword/Resources/Fonts/Exo-Regular.otf differ diff --git a/MasterPassword/Resources/Fonts/Exo-Thin.otf b/MasterPassword/Resources/Fonts/Exo-Thin.otf new file mode 100644 index 00000000..96e9f379 Binary files /dev/null and b/MasterPassword/Resources/Fonts/Exo-Thin.otf differ