diff --git a/Crashlytics/Crashlytics.framework/Versions/A/Crashlytics b/Crashlytics/Crashlytics.framework/Versions/A/Crashlytics index b8def399..d89efbfd 100644 Binary files a/Crashlytics/Crashlytics.framework/Versions/A/Crashlytics and b/Crashlytics/Crashlytics.framework/Versions/A/Crashlytics differ diff --git a/Crashlytics/Crashlytics.framework/Versions/A/Headers/Crashlytics.h b/Crashlytics/Crashlytics.framework/Versions/A/Headers/Crashlytics.h index fa37983c..77c345d5 100644 --- a/Crashlytics/Crashlytics.framework/Versions/A/Headers/Crashlytics.h +++ b/Crashlytics/Crashlytics.framework/Versions/A/Headers/Crashlytics.h @@ -7,6 +7,46 @@ #import +/** + * + * The CLS_LOG macro provides as easy way to gather more information in your log messages that are + * sent with your crash data. CLS_LOG prepends your custom log message with the function name and + * line number where the macro was used. If your app was built with the DEBUG preprocessor macro + * defined CLS_LOG uses the CLSNSLog function which forwards your log message to NSLog and CLSLog. + * If the DEBUG preprocessor macro is not defined CLS_LOG uses CLSLog only. + * + * Example output: + * -[AppDelegate login:] line 134 $ login start + * + * If you would like to change this macro, create a new header file, unset our define and then define + * your own version. Make sure this new header file is imported after the Crashlytics header file. + * + * #undef CLS_LOG + * #define CLS_LOG(__FORMAT__, ...) CLSNSLog... + * + **/ +#ifdef DEBUG + #define CLS_LOG(__FORMAT__, ...) CLSNSLog((@"%s line %d $ " __FORMAT__), __PRETTY_FUNCTION__, __LINE__, ##__VA_ARGS__); +#else + #define CLS_LOG(__FORMAT__, ...) CLSLog((@"%s line %d $ " __FORMAT__), __PRETTY_FUNCTION__, __LINE__, ##__VA_ARGS__); +#endif + +/** + * + * Add logging that will be sent with your crash data. This logging will not show up in the system.log + * and will only be visible in your Crashlytics dashboard. + * + **/ +void CLSLog(NSString *format, ...); + +/** + * + * Add logging that will be sent with your crash data. This logging will show up in the system.log + * and your Crashlytics dashboard. It is not reccomended for Release builds. + * + **/ +void CLSNSLog(NSString *format, ...); + @protocol CrashlyticsDelegate; @interface Crashlytics : NSObject { @@ -63,6 +103,49 @@ **/ - (void)crash; +/** + * + * Many of our customers have requested the ability to tie crashes to specific end-users of their + * application in order to facilitate responses to support requests or permit the ability to reach + * out for more information. We allow you to specify up to three separate values for display within + * the Crashlytics UI - but please be mindful of your end-user's privacy. + * + * We recommend specifying a user identifier - an arbitrary string that ties an end-user to a record + * in your system. This could be a database id, hash, or other value that is meaningless to a + * third-party observer but can be indexed and queried by you. + * + * Optionally, you may also specify the end-user's name or username, as well as email address if you + * do not have a system that works well with obscured identifiers. + * + * Pursuant to our EULA, this data is transferred securely throughout our system and we will not + * disseminate end-user data unless required to by law. That said, if you choose to provide end-user + * contact information, we strongly recommend that you disclose this in your application's privacy + * policy. Data privacy is of our utmost concern. + * + **/ +- (void)setUserIdentifier:(NSString *)identifier; +- (void)setUserName:(NSString *)name; +- (void)setUserEmail:(NSString *)email; + ++ (void)setUserIdentifier:(NSString *)identifier; ++ (void)setUserName:(NSString *)name; ++ (void)setUserEmail:(NSString *)email; + +/** + * + * Set a value for a key to be associated with your crash data. + * + **/ +- (void)setObjectValue:(id)value forKey:(NSString *)key; +- (void)setIntValue:(int)value forKey:(NSString *)key; +- (void)setBoolValue:(BOOL)value forKey:(NSString *)key; +- (void)setFloatValue:(float)value forKey:(NSString *)key; + ++ (void)setObjectValue:(id)value forKey:(NSString *)key; ++ (void)setIntValue:(int)value forKey:(NSString *)key; ++ (void)setBoolValue:(BOOL)value forKey:(NSString *)key; ++ (void)setFloatValue:(float)value forKey:(NSString *)key; + @end /** @@ -80,7 +163,7 @@ * * Called once a Crashlytics instance has determined that the last execution of the * application ended in a crash. This is called some time after the crash reporting - * process has begun. If you have specififed a delay in one of the + * process has begun. If you have specified a delay in one of the * startWithAPIKey:... calls, this will take at least that long to be invoked. * **/ diff --git a/Crashlytics/Crashlytics.framework/Versions/A/Resources/Info.plist b/Crashlytics/Crashlytics.framework/Versions/A/Resources/Info.plist index f144fde6..2f8fd820 100644 --- a/Crashlytics/Crashlytics.framework/Versions/A/Resources/Info.plist +++ b/Crashlytics/Crashlytics.framework/Versions/A/Resources/Info.plist @@ -17,7 +17,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 1.0.1.3 + 1.1.1 CFBundleSignature ???? CFBundleSupportedPlatforms @@ -25,7 +25,7 @@ iPhoneOS CFBundleVersion - 0100.01.03 + 0101.01.00 CrashlyticsAPIKey 0d10c90776f5ef5acd01ddbeaca9a6cba4814560 DTCompiler diff --git a/Crashlytics/Crashlytics.framework/run b/Crashlytics/Crashlytics.framework/run index 7506e555..018498b2 100755 Binary files a/Crashlytics/Crashlytics.framework/run and b/Crashlytics/Crashlytics.framework/run differ diff --git a/External/Pearl b/External/Pearl index 009482a0..ad9ed240 160000 --- a/External/Pearl +++ b/External/Pearl @@ -1 +1 @@ -Subproject commit 009482a08a2a05e9856c2158c1040d01aeedb5ff +Subproject commit ad9ed24071be86d9e1b2c577beba36a08e602637 diff --git a/MasterPassword-iOS.xcodeproj/project.pbxproj b/MasterPassword-iOS.xcodeproj/project.pbxproj index b12d66ed..cdd4e92e 100644 --- a/MasterPassword-iOS.xcodeproj/project.pbxproj +++ b/MasterPassword-iOS.xcodeproj/project.pbxproj @@ -17,8 +17,8 @@ DA0A1D1515690AF40092735D /* Icon-72@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = DA0A1D1315690AF30092735D /* Icon-72@2x.png */; }; DA0A1D1615690AF40092735D /* Icon-Small-50@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = DA0A1D1415690AF40092735D /* Icon-Small-50@2x.png */; }; DA0E07961577FE490008A67E /* MPEntities.m in Sources */ = {isa = PBXBuildFile; fileRef = DA0E07951577FE490008A67E /* MPEntities.m */; }; - DA30E9CE15722ECA00A68B4C /* NSBundle_PearlMutableInfo.h in Headers */ = {isa = PBXBuildFile; fileRef = DA30E9CB15722ECA00A68B4C /* NSBundle_PearlMutableInfo.h */; }; - DA30E9CF15722ECA00A68B4C /* NSBundle_PearlMutableInfo.m in Sources */ = {isa = PBXBuildFile; fileRef = DA30E9CC15722ECA00A68B4C /* NSBundle_PearlMutableInfo.m */; }; + DA30E9CE15722ECA00A68B4C /* NSBundle+PearlMutableInfo.h in Headers */ = {isa = PBXBuildFile; fileRef = DA30E9CB15722ECA00A68B4C /* NSBundle+PearlMutableInfo.h */; }; + DA30E9CF15722ECA00A68B4C /* NSBundle+PearlMutableInfo.m in Sources */ = {isa = PBXBuildFile; fileRef = DA30E9CC15722ECA00A68B4C /* NSBundle+PearlMutableInfo.m */; }; DA30E9D015722ECA00A68B4C /* Pearl.m in Sources */ = {isa = PBXBuildFile; fileRef = DA30E9CD15722ECA00A68B4C /* Pearl.m */; }; DA30E9D215722EE500A68B4C /* Pearl-Crypto.m in Sources */ = {isa = PBXBuildFile; fileRef = DA30E9D115722EE500A68B4C /* Pearl-Crypto.m */; }; DA30E9D415722EF400A68B4C /* Pearl-UIKit.m in Sources */ = {isa = PBXBuildFile; fileRef = DA30E9D315722EF400A68B4C /* Pearl-UIKit.m */; }; @@ -745,12 +745,12 @@ DAE4C98D157E63BE00EFE047 /* avatar-18.png in Resources */ = {isa = PBXBuildFile; fileRef = DAE4C967157E63BE00EFE047 /* avatar-18.png */; }; DAE4C98E157E63BE00EFE047 /* avatar-18@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = DAE4C968157E63BE00EFE047 /* avatar-18@2x.png */; }; DAEBC45314F6364500987BF6 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DAEBC45214F6364500987BF6 /* QuartzCore.framework */; }; - DAFE4A1315039824003ABA7C /* NSObject_PearlExport.h in Headers */ = {isa = PBXBuildFile; fileRef = DAFE45D815039823003ABA7C /* NSObject_PearlExport.h */; }; - DAFE4A1415039824003ABA7C /* NSObject_PearlExport.m in Sources */ = {isa = PBXBuildFile; fileRef = DAFE45D915039823003ABA7C /* NSObject_PearlExport.m */; }; - DAFE4A1515039824003ABA7C /* NSString_PearlNSArrayFormat.h in Headers */ = {isa = PBXBuildFile; fileRef = DAFE45DA15039823003ABA7C /* NSString_PearlNSArrayFormat.h */; }; - DAFE4A1615039824003ABA7C /* NSString_PearlNSArrayFormat.m in Sources */ = {isa = PBXBuildFile; fileRef = DAFE45DB15039823003ABA7C /* NSString_PearlNSArrayFormat.m */; }; - DAFE4A1715039824003ABA7C /* NSString_PearlSEL.h in Headers */ = {isa = PBXBuildFile; fileRef = DAFE45DC15039823003ABA7C /* NSString_PearlSEL.h */; }; - DAFE4A1815039824003ABA7C /* NSString_PearlSEL.m in Sources */ = {isa = PBXBuildFile; fileRef = DAFE45DD15039823003ABA7C /* NSString_PearlSEL.m */; }; + DAFE4A1315039824003ABA7C /* NSObject+PearlExport.h in Headers */ = {isa = PBXBuildFile; fileRef = DAFE45D815039823003ABA7C /* NSObject+PearlExport.h */; }; + DAFE4A1415039824003ABA7C /* NSObject+PearlExport.m in Sources */ = {isa = PBXBuildFile; fileRef = DAFE45D915039823003ABA7C /* NSObject+PearlExport.m */; }; + DAFE4A1515039824003ABA7C /* NSString+PearlNSArrayFormat.h in Headers */ = {isa = PBXBuildFile; fileRef = DAFE45DA15039823003ABA7C /* NSString+PearlNSArrayFormat.h */; }; + DAFE4A1615039824003ABA7C /* NSString+PearlNSArrayFormat.m in Sources */ = {isa = PBXBuildFile; fileRef = DAFE45DB15039823003ABA7C /* NSString+PearlNSArrayFormat.m */; }; + DAFE4A1715039824003ABA7C /* NSString+PearlSEL.h in Headers */ = {isa = PBXBuildFile; fileRef = DAFE45DC15039823003ABA7C /* NSString+PearlSEL.h */; }; + DAFE4A1815039824003ABA7C /* NSString+PearlSEL.m in Sources */ = {isa = PBXBuildFile; fileRef = DAFE45DD15039823003ABA7C /* NSString+PearlSEL.m */; }; DAFE4A1915039824003ABA7C /* Pearl.h in Headers */ = {isa = PBXBuildFile; fileRef = DAFE45DE15039823003ABA7C /* Pearl.h */; }; DAFE4A1A15039824003ABA7C /* PearlAbstractStrings.h in Headers */ = {isa = PBXBuildFile; fileRef = DAFE45DF15039823003ABA7C /* PearlAbstractStrings.h */; }; DAFE4A1B15039824003ABA7C /* PearlAbstractStrings.m in Sources */ = {isa = PBXBuildFile; fileRef = DAFE45E015039823003ABA7C /* PearlAbstractStrings.m */; }; @@ -810,18 +810,20 @@ DAFE4A5515039824003ABA7C /* PearlValidatingTextField.m in Sources */ = {isa = PBXBuildFile; fileRef = DAFE462115039823003ABA7C /* PearlValidatingTextField.m */; }; DAFE4A5615039824003ABA7C /* PearlWebViewController.h in Headers */ = {isa = PBXBuildFile; fileRef = DAFE462215039823003ABA7C /* PearlWebViewController.h */; }; DAFE4A5715039824003ABA7C /* PearlWebViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = DAFE462315039823003ABA7C /* PearlWebViewController.m */; }; - DAFE4A5815039824003ABA7C /* UIImage_PearlScaling.h in Headers */ = {isa = PBXBuildFile; fileRef = DAFE4A1115039824003ABA7C /* UIImage_PearlScaling.h */; }; - DAFE4A5915039824003ABA7C /* UIImage_PearlScaling.m in Sources */ = {isa = PBXBuildFile; fileRef = DAFE4A1215039824003ABA7C /* UIImage_PearlScaling.m */; }; + DAFE4A5815039824003ABA7C /* UIImage+PearlScaling.h in Headers */ = {isa = PBXBuildFile; fileRef = DAFE4A1115039824003ABA7C /* UIImage+PearlScaling.h */; }; + DAFE4A5915039824003ABA7C /* UIImage+PearlScaling.m in Sources */ = {isa = PBXBuildFile; fileRef = DAFE4A1215039824003ABA7C /* UIImage+PearlScaling.m */; }; DAFE4A5A1503982E003ABA7C /* Pearl.strings in Resources */ = {isa = PBXBuildFile; fileRef = DAFE45FA15039823003ABA7C /* Pearl.strings */; }; DAFE4A62150399FF003ABA7C /* PearlAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = DAFE4A60150399FF003ABA7C /* PearlAppDelegate.m */; }; DAFE4A63150399FF003ABA7C /* PearlAppDelegate.h in Headers */ = {isa = PBXBuildFile; fileRef = DAFE4A61150399FF003ABA7C /* PearlAppDelegate.h */; }; DAFE4A63150399FF003ABA7E /* (null) in Sources */ = {isa = PBXBuildFile; }; - DAFE4A63150399FF003ABA82 /* UIControl_PearlBlocks.m in Sources */ = {isa = PBXBuildFile; fileRef = DAFE4A63150399FF003ABA81 /* UIControl_PearlBlocks.m */; }; - DAFE4A63150399FF003ABA84 /* UIControl_PearlBlocks.h in Headers */ = {isa = PBXBuildFile; fileRef = DAFE4A63150399FF003ABA83 /* UIControl_PearlBlocks.h */; }; + DAFE4A63150399FF003ABA82 /* UIControl+PearlBlocks.m in Sources */ = {isa = PBXBuildFile; fileRef = DAFE4A63150399FF003ABA81 /* UIControl+PearlBlocks.m */; }; + DAFE4A63150399FF003ABA84 /* UIControl+PearlBlocks.h in Headers */ = {isa = PBXBuildFile; fileRef = DAFE4A63150399FF003ABA83 /* UIControl+PearlBlocks.h */; }; DAFE4A63150399FF003ABA86 /* NSObject+PearlKVO.m in Sources */ = {isa = PBXBuildFile; fileRef = DAFE4A63150399FF003ABA85 /* NSObject+PearlKVO.m */; }; DAFE4A63150399FF003ABA88 /* NSObject+PearlKVO.h in Headers */ = {isa = PBXBuildFile; fileRef = DAFE4A63150399FF003ABA87 /* NSObject+PearlKVO.h */; }; DAFE4A63150399FF003ABA8A /* UIControl+PearlSelect.m in Sources */ = {isa = PBXBuildFile; fileRef = DAFE4A63150399FF003ABA89 /* UIControl+PearlSelect.m */; }; DAFE4A63150399FF003ABA8C /* UIControl+PearlSelect.h in Headers */ = {isa = PBXBuildFile; fileRef = DAFE4A63150399FF003ABA8B /* UIControl+PearlSelect.h */; }; + DAFE4A63150399FF003ABA8E /* UIScrollView+PearlFlashingIndicators.m in Sources */ = {isa = PBXBuildFile; fileRef = DAFE4A63150399FF003ABA8D /* UIScrollView+PearlFlashingIndicators.m */; }; + DAFE4A63150399FF003ABA90 /* UIScrollView+PearlFlashingIndicators.h in Headers */ = {isa = PBXBuildFile; fileRef = DAFE4A63150399FF003ABA8F /* UIScrollView+PearlFlashingIndicators.h */; }; /* End PBXBuildFile section */ /* Begin PBXContainerItemProxy section */ @@ -926,8 +928,8 @@ DA0A1D1415690AF40092735D /* Icon-Small-50@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Icon-Small-50@2x.png"; sourceTree = ""; }; DA0E07941577FE490008A67E /* MPEntities.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPEntities.h; sourceTree = ""; }; DA0E07951577FE490008A67E /* MPEntities.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPEntities.m; sourceTree = ""; }; - DA30E9CB15722ECA00A68B4C /* NSBundle_PearlMutableInfo.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NSBundle_PearlMutableInfo.h; sourceTree = ""; }; - DA30E9CC15722ECA00A68B4C /* NSBundle_PearlMutableInfo.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = NSBundle_PearlMutableInfo.m; sourceTree = ""; }; + DA30E9CB15722ECA00A68B4C /* NSBundle+PearlMutableInfo.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSBundle+PearlMutableInfo.h"; sourceTree = ""; }; + DA30E9CC15722ECA00A68B4C /* NSBundle+PearlMutableInfo.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSBundle+PearlMutableInfo.m"; sourceTree = ""; }; DA30E9CD15722ECA00A68B4C /* Pearl.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = Pearl.m; sourceTree = ""; }; DA30E9D115722EE500A68B4C /* Pearl-Crypto.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "Pearl-Crypto.m"; sourceTree = ""; }; DA30E9D315722EF400A68B4C /* Pearl-UIKit.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "Pearl-UIKit.m"; sourceTree = ""; }; @@ -1734,12 +1736,12 @@ DAE4C967157E63BE00EFE047 /* avatar-18.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "avatar-18.png"; sourceTree = ""; }; DAE4C968157E63BE00EFE047 /* avatar-18@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "avatar-18@2x.png"; sourceTree = ""; }; DAEBC45214F6364500987BF6 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; - DAFE45D815039823003ABA7C /* NSObject_PearlExport.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NSObject_PearlExport.h; sourceTree = ""; }; - DAFE45D915039823003ABA7C /* NSObject_PearlExport.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = NSObject_PearlExport.m; sourceTree = ""; }; - DAFE45DA15039823003ABA7C /* NSString_PearlNSArrayFormat.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NSString_PearlNSArrayFormat.h; sourceTree = ""; }; - DAFE45DB15039823003ABA7C /* NSString_PearlNSArrayFormat.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = NSString_PearlNSArrayFormat.m; sourceTree = ""; }; - DAFE45DC15039823003ABA7C /* NSString_PearlSEL.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NSString_PearlSEL.h; sourceTree = ""; }; - DAFE45DD15039823003ABA7C /* NSString_PearlSEL.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = NSString_PearlSEL.m; sourceTree = ""; }; + DAFE45D815039823003ABA7C /* NSObject+PearlExport.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSObject+PearlExport.h"; sourceTree = ""; }; + DAFE45D915039823003ABA7C /* NSObject+PearlExport.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSObject+PearlExport.m"; sourceTree = ""; }; + DAFE45DA15039823003ABA7C /* NSString+PearlNSArrayFormat.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSString+PearlNSArrayFormat.h"; sourceTree = ""; }; + DAFE45DB15039823003ABA7C /* NSString+PearlNSArrayFormat.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSString+PearlNSArrayFormat.m"; sourceTree = ""; }; + DAFE45DC15039823003ABA7C /* NSString+PearlSEL.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSString+PearlSEL.h"; sourceTree = ""; }; + DAFE45DD15039823003ABA7C /* NSString+PearlSEL.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSString+PearlSEL.m"; sourceTree = ""; }; DAFE45DE15039823003ABA7C /* Pearl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Pearl.h; sourceTree = ""; }; DAFE45DF15039823003ABA7C /* PearlAbstractStrings.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PearlAbstractStrings.h; sourceTree = ""; }; DAFE45E015039823003ABA7C /* PearlAbstractStrings.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PearlAbstractStrings.m; sourceTree = ""; }; @@ -1803,16 +1805,18 @@ DAFE462215039823003ABA7C /* PearlWebViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PearlWebViewController.h; sourceTree = ""; }; DAFE462315039823003ABA7C /* PearlWebViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PearlWebViewController.m; sourceTree = ""; }; DAFE462415039823003ABA7C /* README */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = README; sourceTree = ""; }; - DAFE4A1115039824003ABA7C /* UIImage_PearlScaling.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIImage_PearlScaling.h; sourceTree = ""; }; - DAFE4A1215039824003ABA7C /* UIImage_PearlScaling.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UIImage_PearlScaling.m; sourceTree = ""; }; + DAFE4A1115039824003ABA7C /* UIImage+PearlScaling.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIImage+PearlScaling.h"; sourceTree = ""; }; + DAFE4A1215039824003ABA7C /* UIImage+PearlScaling.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIImage+PearlScaling.m"; sourceTree = ""; }; DAFE4A60150399FF003ABA7C /* PearlAppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PearlAppDelegate.m; sourceTree = ""; }; DAFE4A61150399FF003ABA7C /* PearlAppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PearlAppDelegate.h; sourceTree = ""; }; - DAFE4A63150399FF003ABA81 /* UIControl_PearlBlocks.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UIControl_PearlBlocks.m; sourceTree = ""; }; - DAFE4A63150399FF003ABA83 /* UIControl_PearlBlocks.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIControl_PearlBlocks.h; sourceTree = ""; }; + DAFE4A63150399FF003ABA81 /* UIControl+PearlBlocks.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIControl+PearlBlocks.m"; sourceTree = ""; }; + DAFE4A63150399FF003ABA83 /* UIControl+PearlBlocks.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIControl+PearlBlocks.h"; sourceTree = ""; }; DAFE4A63150399FF003ABA85 /* NSObject+PearlKVO.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSObject+PearlKVO.m"; sourceTree = ""; }; DAFE4A63150399FF003ABA87 /* NSObject+PearlKVO.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSObject+PearlKVO.h"; sourceTree = ""; }; DAFE4A63150399FF003ABA89 /* UIControl+PearlSelect.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIControl+PearlSelect.m"; sourceTree = ""; }; DAFE4A63150399FF003ABA8B /* UIControl+PearlSelect.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIControl+PearlSelect.h"; sourceTree = ""; }; + DAFE4A63150399FF003ABA8D /* UIScrollView+PearlFlashingIndicators.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIScrollView+PearlFlashingIndicators.m"; sourceTree = ""; }; + DAFE4A63150399FF003ABA8F /* UIScrollView+PearlFlashingIndicators.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIScrollView+PearlFlashingIndicators.h"; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -3004,14 +3008,14 @@ children = ( DAFE4A63150399FF003ABA87 /* NSObject+PearlKVO.h */, DAFE4A63150399FF003ABA85 /* NSObject+PearlKVO.m */, - DA30E9CB15722ECA00A68B4C /* NSBundle_PearlMutableInfo.h */, - DA30E9CC15722ECA00A68B4C /* NSBundle_PearlMutableInfo.m */, - DAFE45D815039823003ABA7C /* NSObject_PearlExport.h */, - DAFE45D915039823003ABA7C /* NSObject_PearlExport.m */, - DAFE45DA15039823003ABA7C /* NSString_PearlNSArrayFormat.h */, - DAFE45DB15039823003ABA7C /* NSString_PearlNSArrayFormat.m */, - DAFE45DC15039823003ABA7C /* NSString_PearlSEL.h */, - DAFE45DD15039823003ABA7C /* NSString_PearlSEL.m */, + DA30E9CB15722ECA00A68B4C /* NSBundle+PearlMutableInfo.h */, + DA30E9CC15722ECA00A68B4C /* NSBundle+PearlMutableInfo.m */, + DAFE45D815039823003ABA7C /* NSObject+PearlExport.h */, + DAFE45D915039823003ABA7C /* NSObject+PearlExport.m */, + DAFE45DA15039823003ABA7C /* NSString+PearlNSArrayFormat.h */, + DAFE45DB15039823003ABA7C /* NSString+PearlNSArrayFormat.m */, + DAFE45DC15039823003ABA7C /* NSString+PearlSEL.h */, + DAFE45DD15039823003ABA7C /* NSString+PearlSEL.m */, DAFE45DE15039823003ABA7C /* Pearl.h */, DA30E9CD15722ECA00A68B4C /* Pearl.m */, DAFE45DF15039823003ABA7C /* PearlAbstractStrings.h */, @@ -3075,10 +3079,12 @@ DAFE460715039823003ABA7C /* Pearl-UIKit */ = { isa = PBXGroup; children = ( + DAFE4A63150399FF003ABA8F /* UIScrollView+PearlFlashingIndicators.h */, + DAFE4A63150399FF003ABA8D /* UIScrollView+PearlFlashingIndicators.m */, DAFE4A63150399FF003ABA8B /* UIControl+PearlSelect.h */, DAFE4A63150399FF003ABA89 /* UIControl+PearlSelect.m */, - DAFE4A63150399FF003ABA83 /* UIControl_PearlBlocks.h */, - DAFE4A63150399FF003ABA81 /* UIControl_PearlBlocks.m */, + DAFE4A63150399FF003ABA83 /* UIControl+PearlBlocks.h */, + DAFE4A63150399FF003ABA81 /* UIControl+PearlBlocks.m */, DAFE460815039823003ABA7C /* Pearl-UIKit-Dependencies.h */, DAFE460915039823003ABA7C /* Pearl-UIKit.h */, DA30E9D315722EF400A68B4C /* Pearl-UIKit.m */, @@ -3112,8 +3118,8 @@ DAFE462315039823003ABA7C /* PearlWebViewController.m */, DAFE462415039823003ABA7C /* README */, DAFE462515039823003ABA7C /* Resources */, - DAFE4A1115039824003ABA7C /* UIImage_PearlScaling.h */, - DAFE4A1215039824003ABA7C /* UIImage_PearlScaling.m */, + DAFE4A1115039824003ABA7C /* UIImage+PearlScaling.h */, + DAFE4A1215039824003ABA7C /* UIImage+PearlScaling.m */, ); name = "Pearl-UIKit"; path = "External/Pearl/Pearl-UIKit"; @@ -3180,9 +3186,9 @@ isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( - DAFE4A1315039824003ABA7C /* NSObject_PearlExport.h in Headers */, - DAFE4A1515039824003ABA7C /* NSString_PearlNSArrayFormat.h in Headers */, - DAFE4A1715039824003ABA7C /* NSString_PearlSEL.h in Headers */, + DAFE4A1315039824003ABA7C /* NSObject+PearlExport.h in Headers */, + DAFE4A1515039824003ABA7C /* NSString+PearlNSArrayFormat.h in Headers */, + DAFE4A1715039824003ABA7C /* NSString+PearlSEL.h in Headers */, DAFE4A1915039824003ABA7C /* Pearl.h in Headers */, DAFE4A1A15039824003ABA7C /* PearlAbstractStrings.h in Headers */, DAFE4A1E15039824003ABA7C /* PearlCodeUtils.h in Headers */, @@ -3215,13 +3221,14 @@ DAFE4A5215039824003ABA7C /* PearlUIUtils.h in Headers */, DAFE4A5415039824003ABA7C /* PearlValidatingTextField.h in Headers */, DAFE4A5615039824003ABA7C /* PearlWebViewController.h in Headers */, - DAFE4A5815039824003ABA7C /* UIImage_PearlScaling.h in Headers */, + DAFE4A5815039824003ABA7C /* UIImage+PearlScaling.h in Headers */, DAFE4A63150399FF003ABA7C /* PearlAppDelegate.h in Headers */, - DA30E9CE15722ECA00A68B4C /* NSBundle_PearlMutableInfo.h in Headers */, + DA30E9CE15722ECA00A68B4C /* NSBundle+PearlMutableInfo.h in Headers */, DA30E9D715723E6900A68B4C /* PearlLazy.h in Headers */, - DAFE4A63150399FF003ABA84 /* UIControl_PearlBlocks.h in Headers */, + DAFE4A63150399FF003ABA84 /* UIControl+PearlBlocks.h in Headers */, DAFE4A63150399FF003ABA88 /* NSObject+PearlKVO.h in Headers */, DAFE4A63150399FF003ABA8C /* UIControl+PearlSelect.h in Headers */, + DAFE4A63150399FF003ABA90 /* UIScrollView+PearlFlashingIndicators.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -4214,9 +4221,9 @@ isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( - DAFE4A1415039824003ABA7C /* NSObject_PearlExport.m in Sources */, - DAFE4A1615039824003ABA7C /* NSString_PearlNSArrayFormat.m in Sources */, - DAFE4A1815039824003ABA7C /* NSString_PearlSEL.m in Sources */, + DAFE4A1415039824003ABA7C /* NSObject+PearlExport.m in Sources */, + DAFE4A1615039824003ABA7C /* NSString+PearlNSArrayFormat.m in Sources */, + DAFE4A1815039824003ABA7C /* NSString+PearlSEL.m in Sources */, DAFE4A1B15039824003ABA7C /* PearlAbstractStrings.m in Sources */, DAFE4A1F15039824003ABA7C /* PearlCodeUtils.m in Sources */, DAFE4A2115039824003ABA7C /* PearlConfig.m in Sources */, @@ -4244,17 +4251,18 @@ DAFE4A5315039824003ABA7C /* PearlUIUtils.m in Sources */, DAFE4A5515039824003ABA7C /* PearlValidatingTextField.m in Sources */, DAFE4A5715039824003ABA7C /* PearlWebViewController.m in Sources */, - DAFE4A5915039824003ABA7C /* UIImage_PearlScaling.m in Sources */, + DAFE4A5915039824003ABA7C /* UIImage+PearlScaling.m in Sources */, DAFE4A62150399FF003ABA7C /* PearlAppDelegate.m in Sources */, - DA30E9CF15722ECA00A68B4C /* NSBundle_PearlMutableInfo.m in Sources */, + DA30E9CF15722ECA00A68B4C /* NSBundle+PearlMutableInfo.m in Sources */, DA30E9D015722ECA00A68B4C /* Pearl.m in Sources */, DA30E9D215722EE500A68B4C /* Pearl-Crypto.m in Sources */, DA30E9D415722EF400A68B4C /* Pearl-UIKit.m in Sources */, DA30E9D815723E6900A68B4C /* PearlLazy.m in Sources */, DAFE4A63150399FF003ABA7E /* (null) in Sources */, - DAFE4A63150399FF003ABA82 /* UIControl_PearlBlocks.m in Sources */, + DAFE4A63150399FF003ABA82 /* UIControl+PearlBlocks.m in Sources */, DAFE4A63150399FF003ABA86 /* NSObject+PearlKVO.m in Sources */, DAFE4A63150399FF003ABA8A /* UIControl+PearlSelect.m in Sources */, + DAFE4A63150399FF003ABA8E /* UIScrollView+PearlFlashingIndicators.m in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; diff --git a/MasterPassword-iOS.xcodeproj/xcshareddata/xcschemes/MasterPassword (Development).xcscheme b/MasterPassword-iOS.xcodeproj/xcshareddata/xcschemes/MasterPassword (Development).xcscheme index e406054d..93ea75a2 100644 --- a/MasterPassword-iOS.xcodeproj/xcshareddata/xcschemes/MasterPassword (Development).xcscheme +++ b/MasterPassword-iOS.xcodeproj/xcshareddata/xcschemes/MasterPassword (Development).xcscheme @@ -57,12 +57,6 @@ ReferencedContainer = "container:MasterPassword-iOS.xcodeproj"> - - - - #import "MPAppDelegate_Key.h" #import "MPAppDelegate_Store.h" +#import "ATConnect.h" @implementation MPAppDelegate_Shared (Key) @@ -133,6 +135,18 @@ static NSDictionary *keyQuery(MPUserEntity *user) { [self storeSavedKeyFor:user]; } + @try { + if ([[MPiOSConfig get].sendDebugInfo boolValue]) { + [TestFlight addCustomEnvironmentInformation:user.name forKey:@"username"]; + [[Crashlytics sharedInstance] setValue:user.name forKey:@"username"]; + [[ATConnect sharedConnection] addAdditionalInfoToFeedback:user.name withKey:@"username"]; + } + } + @catch (id exception) { + err(@"While setting username: %@", exception); + } + + user.lastUsed = [NSDate date]; self.activeUser = user; [[MPAppDelegate_Shared get] saveContext]; diff --git a/MasterPassword/MPTypes.m b/MasterPassword/MPTypes.m index fee6e6df..217b83b5 100644 --- a/MasterPassword/MPTypes.m +++ b/MasterPassword/MPTypes.m @@ -7,7 +7,7 @@ // #import "MPTypes.h" -#import "MPElementStoredEntity.h" +#import "MPEntities.h" #define MP_N 131072 diff --git a/MasterPassword/iOS/MPAppDelegate.m b/MasterPassword/iOS/MPAppDelegate.m index 343fdf19..c2a671c6 100644 --- a/MasterPassword/iOS/MPAppDelegate.m +++ b/MasterPassword/iOS/MPAppDelegate.m @@ -6,6 +6,7 @@ // Copyright (c) 2011 Lyndir. All rights reserved. // +#import #import "MPAppDelegate.h" #import "MPAppDelegate_Key.h" #import "MPAppDelegate_Store.h" @@ -38,7 +39,7 @@ [MPiOSConfig get]; #ifdef DEBUG - [PearlLogger get].autoprintLevel = PearlLogLevelDebug; + [PearlLogger get].autoprintLevel = PearlLogLevelTrace; //[NSClassFromString(@"WebView") performSelector:NSSelectorFromString(@"_enableRemoteInspector")]; #endif } @@ -52,6 +53,19 @@ if ([[MPConfig get].iCloud boolValue] != [self.storeManager iCloudEnabled]) [self.storeManager useiCloudStore:[[MPConfig get].iCloud boolValue] alertUser:YES]; + if ([[MPiOSConfig get].sendDebugInfo boolValue]) { + [[Crashlytics sharedInstance] setBoolValue:[[MPConfig get].rememberLogin boolValue] forKey:@"rememberLogin"]; + [[Crashlytics sharedInstance] setBoolValue:[[MPConfig get].iCloud boolValue] forKey:@"iCloud"]; + [[Crashlytics sharedInstance] setBoolValue:[[MPConfig get].iCloudDecided boolValue] forKey:@"iCloudDecided"]; + [[Crashlytics sharedInstance] setBoolValue:[[MPiOSConfig get].sendDebugInfo boolValue] forKey:@"sendDebugInfo"]; + [[Crashlytics sharedInstance] setBoolValue:[[MPiOSConfig get].helpHidden boolValue] forKey:@"helpHidden"]; + [[Crashlytics sharedInstance] setBoolValue:[[MPiOSConfig get].showQuickStart boolValue] forKey:@"showQuickStart"]; + [[Crashlytics sharedInstance] setBoolValue:[[PearlConfig get].firstRun boolValue] forKey:@"firstRun"]; + [[Crashlytics sharedInstance] setIntValue:[[PearlConfig get].launchCount intValue] forKey:@"launchCount"]; + [[Crashlytics sharedInstance] setBoolValue:[[PearlConfig get].askForReviews boolValue] forKey:@"askForReviews"]; + [[Crashlytics sharedInstance] setIntValue:[[PearlConfig get].reviewAfterLaunches intValue] forKey:@"reviewAfterLaunches"]; + [[Crashlytics sharedInstance] setObjectValue:[PearlConfig get].reviewedVersion forKey:@"reviewedVersion"]; + } } - (void)showGuide { @@ -146,19 +160,28 @@ [[[NSBundle mainBundle] mutableLocalizedInfoDictionary] setObject:@"Master Password" forKey:@"CFBundleDisplayName"]; dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_BACKGROUND, 0), ^{ -#ifndef DEBUG +//#ifndef DEBUG @try { NSString *testFlightToken = [self testFlightToken]; if ([testFlightToken length]) { dbg(@"Initializing TestFlight"); [TestFlight addCustomEnvironmentInformation:@"Anonymous" forKey:@"username"]; +#ifdef ADHOC + [TestFlight setDeviceIdentifier:[UIDevice currentDevice].uniqueIdentifier]; +#else + [TestFlight setDeviceIdentifier:[PearlKeyChain deviceIdentifier]]; +#endif [TestFlight setOptions:[NSDictionary dictionaryWithObjectsAndKeys: [NSNumber numberWithBool:NO], @"logToConsole", [NSNumber numberWithBool:NO], @"logToSTDERR", nil]]; [TestFlight takeOff:testFlightToken]; [[PearlLogger get] registerListener:^BOOL(PearlLogMessage *message) { - if (message.level >= PearlLogLevelInfo) + PearlLogLevel level = PearlLogLevelInfo; + if ([[MPiOSConfig get].sendDebugInfo boolValue]) + level = PearlLogLevelDebug; + + if (message.level >= level) TFLog(@"%@", message); return YES; @@ -166,7 +189,7 @@ [TestFlight passCheckpoint:MPTestFlightCheckpointLaunched]; } } - @catch (NSException *exception) { + @catch (id exception) { err(@"TestFlight: %@", exception); } @try { @@ -174,10 +197,22 @@ if ([crashlyticsAPIKey length]) { dbg(@"Initializing Crashlytics"); //[Crashlytics sharedInstance].debugMode = YES; + [[Crashlytics sharedInstance] setObjectValue:@"Anonymous" forKey:@"username"]; + [[Crashlytics sharedInstance] setObjectValue:[PearlKeyChain deviceIdentifier] forKey:@"deviceIdentifier"]; [Crashlytics startWithAPIKey:crashlyticsAPIKey afterDelay:0]; + [[PearlLogger get] registerListener:^BOOL(PearlLogMessage *message) { + PearlLogLevel level = PearlLogLevelInfo; + if ([[MPiOSConfig get].sendDebugInfo boolValue]) + level = PearlLogLevelDebug; + + if (message.level >= level) + CLSLog(@"%@", message); + + return YES; + }]; } } - @catch (NSException *exception) { + @catch (id exception) { err(@"Crashlytics: %@", exception); } @try { @@ -199,10 +234,10 @@ }]; } } - @catch (NSException *exception) { + @catch (id exception) { err(@"Localytics exception: %@", exception); } -#endif +//#endif }); @try { @@ -214,6 +249,8 @@ [connection setApiKey:apptentiveAPIKey]; [connection setShouldTakeScreenshot:NO]; [connection addAdditionalInfoToFeedback:[PearlInfoPlist get].CFBundleVersion withKey:@"CFBundleVersion"]; + [connection addAdditionalInfoToFeedback:[PearlKeyChain deviceIdentifier] withKey:@"deviceIdentifier"]; + [connection addAdditionalInfoToFeedback:@"Anonymous" withKey:@"username"]; } } @catch (NSException *exception) { @@ -368,6 +405,8 @@ UIImage *segmentUnselectedUnselected = [UIImage imageNamed:@"segcontrol_uns-uns. - (void)applicationDidBecomeActive:(UIApplication *)application { + [[MPAppDelegate get] checkConfig]; + if ([[MPiOSConfig get].showQuickStart boolValue]) [self showGuide]; diff --git a/MasterPassword/iOS/MPMainViewController.m b/MasterPassword/iOS/MPMainViewController.m index b843961b..306739be 100644 --- a/MasterPassword/iOS/MPMainViewController.m +++ b/MasterPassword/iOS/MPMainViewController.m @@ -103,8 +103,6 @@ } }]; - [[MPAppDelegate get] checkConfig]; - [super viewDidAppear:animated]; } diff --git a/MasterPassword/iOS/MPPreferencesViewController.m b/MasterPassword/iOS/MPPreferencesViewController.m index d655c3a8..5be9aff6 100644 --- a/MasterPassword/iOS/MPPreferencesViewController.m +++ b/MasterPassword/iOS/MPPreferencesViewController.m @@ -29,7 +29,6 @@ for (int a = 0; a < MPAvatarCount; ++a) { UIButton *avatar = [self.avatarTemplate clone]; - avatar.togglesSelectionInSuperview = YES; avatar.tag = a; avatar.hidden = NO; avatar.center = CGPointMake( @@ -37,6 +36,7 @@ self.avatarTemplate.center.y); [avatar setBackgroundImage:[UIImage imageNamed:PearlString(@"avatar-%d", a)] forState:UIControlStateNormal]; + [avatar setSelectionInSuperviewCandidate:YES isClearable:NO]; avatar.layer.cornerRadius = avatar.bounds.size.height / 2; avatar.layer.shadowColor = [UIColor blackColor].CGColor; diff --git a/MasterPassword/iOS/MPUnlockViewController.m b/MasterPassword/iOS/MPUnlockViewController.m index 86c078a1..a5369e23 100644 --- a/MasterPassword/iOS/MPUnlockViewController.m +++ b/MasterPassword/iOS/MPUnlockViewController.m @@ -39,6 +39,50 @@ // self.lock.alpha = 0.5f; // } completion:nil]; +- (void)initAvatarAlert:(UIAlertView *)alert forUser:(MPUserEntity *)user { + + UIScrollView *alertAvatarScrollView = [[UIScrollView alloc] initWithFrame:CGRectMake(12, 30, 260, 150)]; + alertAvatarScrollView.indicatorStyle = UIScrollViewIndicatorStyleWhite; + [alertAvatarScrollView flashScrollIndicatorsContinuously]; + [alert addSubview:alertAvatarScrollView]; + + CGPoint selectedOffset = CGPointZero; + for (int a = 0; a < MPAvatarCount; ++a) { + UIButton *avatar = [self.avatarTemplate cloneAddedTo:alertAvatarScrollView]; + + avatar.tag = a; + avatar.hidden = NO; + avatar.center = CGPointMake( + (20 + self.avatarTemplate.bounds.size.width / 2) * (a + 1) + self.avatarTemplate.bounds.size.width / 2 * a, + 20 + self.avatarTemplate.bounds.size.height / 2); + [avatar setBackgroundImage:[UIImage imageNamed:PearlString(@"avatar-%d", a)] forState:UIControlStateNormal]; + [avatar setSelectionInSuperviewCandidate:YES isClearable:NO]; + + avatar.layer.cornerRadius = avatar.bounds.size.height / 2; + avatar.layer.shadowColor = [UIColor blackColor].CGColor; + avatar.layer.shadowOpacity = 1; + avatar.layer.shadowRadius = 5; + avatar.backgroundColor = [UIColor clearColor]; + + [avatar onHighlightOrSelect:^(BOOL highlighted, BOOL selected) { + if (highlighted || selected) + avatar.backgroundColor = self.avatarTemplate.backgroundColor; + else + avatar.backgroundColor = [UIColor clearColor]; + } options:0]; + [avatar onSelect:^(BOOL selected) { + if (selected) + user.avatar = (unsigned)avatar.tag; + } options:0]; + avatar.selected = (a == user.avatar); + if (avatar.selected) + selectedOffset = CGPointMake(avatar.center.x - alertAvatarScrollView.bounds.size.width / 2, 0); + } + + [alertAvatarScrollView autoSizeContent]; + [alertAvatarScrollView setContentOffset:selectedOffset animated:YES]; +} + - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation { return (interfaceOrientation == UIInterfaceOrientationPortrait); @@ -137,7 +181,6 @@ if (selected) [self didSelectNewUserAvatar:avatar]; } options:0]; - avatar.togglesSelectionInSuperview = YES; avatar.center = CGPointMake(avatar.center.x + [self.avatarToUser count] * 160, avatar.center.y); avatar.hidden = NO; avatar.layer.cornerRadius = avatar.bounds.size.height / 2; @@ -151,6 +194,7 @@ avatar.tag = user.avatar; [avatar setBackgroundImage:[UIImage imageNamed:PearlString(@"avatar-%u", user.avatar)] forState:UIControlStateNormal]; + [avatar setSelectionInSuperviewCandidate:YES isClearable:YES]; [self.avatarToUser setObject:NilToNSNull(user) forKey:[NSValue valueWithNonretainedObject:avatar]]; @@ -179,26 +223,32 @@ - (void)didSelectNewUserAvatar:(UIButton *)newUserAvatar { - [PearlAlert showAlertWithTitle:@"New User" - message:@"Enter your name:" viewStyle:UIAlertViewStylePlainTextInput + [PearlAlert showAlertWithTitle:@"Enter Your Name" + message:nil viewStyle:UIAlertViewStylePlainTextInput initAlert:^(UIAlertView *alert, UITextField *firstField) { firstField.autocapitalizationType = UITextAutocapitalizationTypeWords; - firstField.autocorrectionType = UITextAutocorrectionTypeYes; - firstField.spellCheckingType = UITextSpellCheckingTypeYes; firstField.keyboardType = UIKeyboardTypeAlphabet; } tappedButtonBlock:^(UIAlertView *alert, NSInteger buttonIndex) { - newUserAvatar.selected = NO; - if (buttonIndex == [alert cancelButtonIndex]) return; MPUserEntity *newUser = [NSEntityDescription insertNewObjectForEntityForName:NSStringFromClass([MPUserEntity class]) inManagedObjectContext:[MPAppDelegate managedObjectContext]]; newUser.name = [alert textFieldAtIndex:0].text; + + [PearlAlert showAlertWithTitle:@"Choose Your Avatar" + message:@"\n\n\n\n\n\n" viewStyle:UIAlertViewStyleDefault + initAlert:^(UIAlertView *_alert, UITextField *firstField) { + [self initAvatarAlert:_alert forUser:newUser]; + } + tappedButtonBlock:^(UIAlertView *_alert, NSInteger _buttonIndex) { + + newUserAvatar.selected = NO; self.selectedUser = newUser; [self updateUsers]; + } cancelTitle:nil otherTitles:[PearlStrings get].commonButtonOkay, nil]; } cancelTitle:[PearlStrings get].commonButtonCancel otherTitles:[PearlStrings get].commonButtonSave, nil]; } diff --git a/MasterPassword/iOS/MPiOSConfig.h b/MasterPassword/iOS/MPiOSConfig.h index c4c1f8c1..d087b2f1 100644 --- a/MasterPassword/iOS/MPiOSConfig.h +++ b/MasterPassword/iOS/MPiOSConfig.h @@ -10,6 +10,7 @@ @interface MPiOSConfig : MPConfig +@property (nonatomic, retain) NSNumber *sendDebugInfo; @property (nonatomic, retain) NSNumber *helpHidden; @property (nonatomic, retain) NSNumber *showQuickStart; diff --git a/MasterPassword/iOS/MPiOSConfig.m b/MasterPassword/iOS/MPiOSConfig.m index dd003ed8..1b95d59b 100644 --- a/MasterPassword/iOS/MPiOSConfig.m +++ b/MasterPassword/iOS/MPiOSConfig.m @@ -7,7 +7,7 @@ // @implementation MPiOSConfig -@dynamic helpHidden, showQuickStart; +@dynamic sendDebugInfo, helpHidden, showQuickStart; - (id)init { @@ -15,6 +15,7 @@ return self; [self.defaults registerDefaults:[NSDictionary dictionaryWithObjectsAndKeys: + [NSNumber numberWithBool:NO], NSStringFromSelector(@selector(sendDebugInfo)), [NSNumber numberWithBool:NO], NSStringFromSelector(@selector(helpHidden)), [NSNumber numberWithBool:YES], NSStringFromSelector(@selector(showQuickStart)), @"510296984", NSStringFromSelector(@selector(iTunesID)), diff --git a/MasterPassword/iOS/MainStoryboard_iPhone.storyboard b/MasterPassword/iOS/MainStoryboard_iPhone.storyboard index 9135fd1a..026e5dcb 100644 --- a/MasterPassword/iOS/MainStoryboard_iPhone.storyboard +++ b/MasterPassword/iOS/MainStoryboard_iPhone.storyboard @@ -1244,93 +1244,6 @@ L4m3P4sSw0rD - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/MasterPassword/iOS/Settings.bundle/Root.plist b/MasterPassword/iOS/Settings.bundle/Root.plist index b95b25ff..f0ad438e 100644 --- a/MasterPassword/iOS/Settings.bundle/Root.plist +++ b/MasterPassword/iOS/Settings.bundle/Root.plist @@ -6,7 +6,7 @@ FooterText - http://masterpassword.lyndir.com + If you're experiencing problems, enabling this will send us details that can help diagnose and resolve them. Great care has been taken to guarantee no private information is ever sent. Title Type @@ -42,6 +42,16 @@ Key unset + + Type + PSToggleSwitchSpecifier + Title + Send Diagnostic Info + Key + sendDebugInfo + DefaultValue + + FooterText This causes your master password to be remembered while your device is powered on. Similar to your phone's SIM lock, you only need to enter the password once after powering on. diff --git a/Resources/Avatars/avatar-0.png b/Resources/Avatars/avatar-0.png index e130c614..6df3b1c1 100644 Binary files a/Resources/Avatars/avatar-0.png and b/Resources/Avatars/avatar-0.png differ diff --git a/Resources/Avatars/avatar-0@2x.png b/Resources/Avatars/avatar-0@2x.png index 46bc4f5c..306ca9b5 100644 Binary files a/Resources/Avatars/avatar-0@2x.png and b/Resources/Avatars/avatar-0@2x.png differ diff --git a/Resources/Avatars/avatar-2.png b/Resources/Avatars/avatar-2.png index 6df3b1c1..e130c614 100644 Binary files a/Resources/Avatars/avatar-2.png and b/Resources/Avatars/avatar-2.png differ diff --git a/Resources/Avatars/avatar-2@2x.png b/Resources/Avatars/avatar-2@2x.png index 306ca9b5..46bc4f5c 100644 Binary files a/Resources/Avatars/avatar-2@2x.png and b/Resources/Avatars/avatar-2@2x.png differ