diff --git a/platform-darwin/MasterPassword-iOS.xcodeproj/project.pbxproj b/platform-darwin/MasterPassword-iOS.xcodeproj/project.pbxproj index d61b1495..78833d79 100644 --- a/platform-darwin/MasterPassword-iOS.xcodeproj/project.pbxproj +++ b/platform-darwin/MasterPassword-iOS.xcodeproj/project.pbxproj @@ -23,7 +23,7 @@ 93D393DB5325820241BA90A7 /* PearlSizedTextView.h in Headers */ = {isa = PBXBuildFile; fileRef = 93D39A4759186F6D2D34AA6B /* PearlSizedTextView.h */; }; 93D3942C1B117EE4851AA7B6 /* UIView+Visible.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D3952910EDB8E0EBC94BA9 /* UIView+Visible.m */; }; 93D394982CBD25D46692DD7C /* MPWebViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D3990E0CD1B5CF9FBB2C07 /* MPWebViewController.m */; }; - 93D394B5036C882B33C71872 /* MPPasswordsSegue.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D39E7A12CC352B2825AA66 /* MPPasswordsSegue.m */; }; + 93D394B5036C882B33C71872 /* MPSitesSegue.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D39E7A12CC352B2825AA66 /* MPSitesSegue.m */; }; 93D39508A6814612A5B3C226 /* MPMessageViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D399B36CDB2004D7C51391 /* MPMessageViewController.m */; }; 93D39536EB550E811CCD04BC /* UIResponder+PearlFirstResponder.h in Headers */ = {isa = PBXBuildFile; fileRef = 93D394482BB07F90E8FD1314 /* UIResponder+PearlFirstResponder.h */; }; 93D3954E96236384AFA00453 /* UIScrollView+PearlAdjustInsets.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D390FB3110DCCE68E600DC /* UIScrollView+PearlAdjustInsets.m */; }; @@ -47,13 +47,13 @@ 93D399E4BC1E092A8C8B12AE /* NSOrderedSetOrArray.h in Headers */ = {isa = PBXBuildFile; fileRef = 93D39FBF8FCEB4C106272334 /* NSOrderedSetOrArray.h */; }; 93D39A27F2506C6FEEF9C588 /* MPAlgorithmV2.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D399A8E3181B442D347CD7 /* MPAlgorithmV2.m */; }; 93D39A53D76CA70786423458 /* UICollectionView+PearlReloadItems.h in Headers */ = {isa = PBXBuildFile; fileRef = 93D39246FC21C6E63E35D615 /* UICollectionView+PearlReloadItems.h */; }; - 93D39A5FF670957C0AF8298D /* MPPasswordCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D39DEA995041A13DC9CAF7 /* MPPasswordCell.m */; }; + 93D39A5FF670957C0AF8298D /* MPSiteCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D39DEA995041A13DC9CAF7 /* MPSiteCell.m */; }; 93D39A8EA1C49CE43B63F47B /* PearlUICollectionView.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D39D8A953779B35403AF6E /* PearlUICollectionView.m */; }; 93D39AA4A0BE66A872CCC02E /* NSPersistentStore+PearlMigration.h in Headers */ = {isa = PBXBuildFile; fileRef = 93D397F4BAFFF7CF3F1B21A4 /* NSPersistentStore+PearlMigration.h */; }; 93D39B429C67A62E29DC02DA /* MPRootSegue.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D399493FEDDE74DD1A0C15 /* MPRootSegue.m */; }; 93D39B76DD5AB108BA8928E8 /* UIScrollView+PearlAdjustInsets.h in Headers */ = {isa = PBXBuildFile; fileRef = 93D39DE2CB351D4E3789462B /* UIScrollView+PearlAdjustInsets.h */; }; 93D39B842AB9A5D072810D76 /* NSError+PearlFullDescription.h in Headers */ = {isa = PBXBuildFile; fileRef = 93D398C95847261903D781D3 /* NSError+PearlFullDescription.h */; }; - 93D39B8F90F58A5D158DDBA3 /* MPPasswordsViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D3924EE15017F8A12CB436 /* MPPasswordsViewController.m */; }; + 93D39B8F90F58A5D158DDBA3 /* MPSitesViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D3924EE15017F8A12CB436 /* MPSitesViewController.m */; }; 93D39BA1EA3CAAC8A220B4A6 /* MPAppSettingsViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D3916C1D8F1427DFBDEBCA /* MPAppSettingsViewController.m */; }; 93D39BFB5F5F9337F6565DE3 /* UIView+Visible.h in Headers */ = {isa = PBXBuildFile; fileRef = 93D39B7B765546B1F1900CB7 /* UIView+Visible.h */; }; 93D39C34FE35830EF5BE1D2A /* NSArray+Indexing.h in Headers */ = {isa = PBXBuildFile; fileRef = 93D396D04E57792A54D437AC /* NSArray+Indexing.h */; }; @@ -476,14 +476,14 @@ 93D390FADEB325D8D54A957D /* PearlOverlay.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PearlOverlay.m; sourceTree = ""; }; 93D390FB3110DCCE68E600DC /* UIScrollView+PearlAdjustInsets.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIScrollView+PearlAdjustInsets.m"; sourceTree = ""; }; 93D39149A5F1F9B174D6D061 /* MPStoreViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPStoreViewController.h; sourceTree = ""; }; - 93D3914D7597F9A28DB9D85E /* MPPasswordsViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPPasswordsViewController.h; sourceTree = ""; }; + 93D3914D7597F9A28DB9D85E /* MPSitesViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPSitesViewController.h; sourceTree = ""; }; 93D39156E806BB78E04F78B9 /* PearlSizedTextView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PearlSizedTextView.m; sourceTree = ""; }; 93D3916C1D8F1427DFBDEBCA /* MPAppSettingsViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPAppSettingsViewController.m; sourceTree = ""; }; 93D391943675426839501BB8 /* MPLogsViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPLogsViewController.h; sourceTree = ""; }; 93D391AA32F24290C424438E /* NSNotificationCenter+PearlEasyCleanup.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSNotificationCenter+PearlEasyCleanup.h"; sourceTree = ""; }; 93D39246FC21C6E63E35D615 /* UICollectionView+PearlReloadItems.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UICollectionView+PearlReloadItems.h"; sourceTree = ""; }; 93D3924D6F77E6BF41AC32D3 /* MPRootSegue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPRootSegue.h; sourceTree = ""; }; - 93D3924EE15017F8A12CB436 /* MPPasswordsViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPPasswordsViewController.m; sourceTree = ""; }; + 93D3924EE15017F8A12CB436 /* MPSitesViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPSitesViewController.m; sourceTree = ""; }; 93D392876BE5C011DE73B43F /* MPPopdownSegue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPPopdownSegue.h; sourceTree = ""; }; 93D392C5A6572DB0EB5B82C8 /* mpw-types.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = "mpw-types.c"; sourceTree = ""; }; 93D392D76C091DEA3319F11D /* UIView+AlphaScale.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIView+AlphaScale.h"; sourceTree = ""; }; @@ -517,7 +517,7 @@ 93D3990E0CD1B5CF9FBB2C07 /* MPWebViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPWebViewController.m; sourceTree = ""; }; 93D399493FEDDE74DD1A0C15 /* MPRootSegue.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPRootSegue.m; sourceTree = ""; }; 93D3995B1D4DCE5A30D882BA /* MPCoachmarkViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPCoachmarkViewController.m; sourceTree = ""; }; - 93D39975CE5AEC99E3F086C7 /* MPPasswordCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPPasswordCell.h; sourceTree = ""; }; + 93D39975CE5AEC99E3F086C7 /* MPSiteCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPSiteCell.h; sourceTree = ""; }; 93D3999693660C89A7465F4E /* MPCoachmarkViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPCoachmarkViewController.h; sourceTree = ""; }; 93D399A8E3181B442D347CD7 /* MPAlgorithmV2.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPAlgorithmV2.m; sourceTree = ""; }; 93D399B36CDB2004D7C51391 /* MPMessageViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPMessageViewController.m; sourceTree = ""; }; @@ -541,7 +541,7 @@ 93D39BAA71DE51B4D8A1286C /* MPCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPCell.m; sourceTree = ""; }; 93D39C41A27AA42D044D68AE /* NSString+MPMarkDown.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = "NSString+MPMarkDown.m"; path = "iOS/NSString+MPMarkDown.m"; sourceTree = ""; }; 93D39C426E03358384018E85 /* MPAnswersViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPAnswersViewController.m; sourceTree = ""; }; - 93D39C44361BE57AF0B3071F /* MPPasswordsSegue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPPasswordsSegue.h; sourceTree = ""; }; + 93D39C44361BE57AF0B3071F /* MPSitesSegue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPSitesSegue.h; sourceTree = ""; }; 93D39C86E984EC65DA5ACB1D /* MPAppSettingsViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPAppSettingsViewController.h; sourceTree = ""; }; 93D39CB0EABD2748740992D8 /* MPMessageViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPMessageViewController.h; sourceTree = ""; }; 93D39CC01630D0421205C4C4 /* MPNavigationController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPNavigationController.m; sourceTree = ""; }; @@ -554,8 +554,8 @@ 93D39D8A953779B35403AF6E /* PearlUICollectionView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PearlUICollectionView.m; sourceTree = ""; }; 93D39DA27D768B53C8B1330C /* MPAvatarCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPAvatarCell.h; sourceTree = ""; }; 93D39DE2CB351D4E3789462B /* UIScrollView+PearlAdjustInsets.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIScrollView+PearlAdjustInsets.h"; sourceTree = ""; }; - 93D39DEA995041A13DC9CAF7 /* MPPasswordCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPPasswordCell.m; sourceTree = ""; }; - 93D39E7A12CC352B2825AA66 /* MPPasswordsSegue.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPPasswordsSegue.m; sourceTree = ""; }; + 93D39DEA995041A13DC9CAF7 /* MPSiteCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPSiteCell.m; sourceTree = ""; }; + 93D39E7A12CC352B2825AA66 /* MPSitesSegue.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPSitesSegue.m; sourceTree = ""; }; 93D39F556F2F142740A65E59 /* MPWebViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPWebViewController.h; sourceTree = ""; }; 93D39F7C9F47BF6387FBC5C3 /* PearlEMail.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PearlEMail.h; sourceTree = ""; }; 93D39F9106F2CCFB94283188 /* NSError+PearlFullDescription.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSError+PearlFullDescription.m"; sourceTree = ""; }; @@ -2885,12 +2885,12 @@ 93D39CC01630D0421205C4C4 /* MPNavigationController.m */, 93D39B455A71EC98C749E623 /* MPOverlayViewController.h */, 93D395105935859D71679931 /* MPOverlayViewController.m */, - 93D39975CE5AEC99E3F086C7 /* MPPasswordCell.h */, - 93D39DEA995041A13DC9CAF7 /* MPPasswordCell.m */, - 93D39C44361BE57AF0B3071F /* MPPasswordsSegue.h */, - 93D39E7A12CC352B2825AA66 /* MPPasswordsSegue.m */, - 93D3914D7597F9A28DB9D85E /* MPPasswordsViewController.h */, - 93D3924EE15017F8A12CB436 /* MPPasswordsViewController.m */, + 93D39975CE5AEC99E3F086C7 /* MPSiteCell.h */, + 93D39DEA995041A13DC9CAF7 /* MPSiteCell.m */, + 93D39C44361BE57AF0B3071F /* MPSitesSegue.h */, + 93D39E7A12CC352B2825AA66 /* MPSitesSegue.m */, + 93D3914D7597F9A28DB9D85E /* MPSitesViewController.h */, + 93D3924EE15017F8A12CB436 /* MPSitesViewController.m */, 93D392876BE5C011DE73B43F /* MPPopdownSegue.h */, 93D39B050DD5F55E9794EFD4 /* MPPopdownSegue.m */, DABD3BEA1711E2DC00CF925C /* MPPreferencesViewController.h */, @@ -3859,14 +3859,14 @@ DA095E75172F4CD8001C948B /* MPLogsViewController.m in Sources */, 93D39D596A2E376D6F6F5DA1 /* MPCombinedViewController.m in Sources */, 93D3957237D303DE2D38C267 /* MPAvatarCell.m in Sources */, - 93D39B8F90F58A5D158DDBA3 /* MPPasswordsViewController.m in Sources */, + 93D39B8F90F58A5D158DDBA3 /* MPSitesViewController.m in Sources */, 93D3954FCE045A3CC7E804B7 /* MPUsersViewController.m in Sources */, 93D39392DEDA376F93C6C718 /* MPCell.m in Sources */, DA0CC58E1EB6B030009A8ED9 /* MPSiteQuestionEntity+CoreDataClass.m in Sources */, - 93D39A5FF670957C0AF8298D /* MPPasswordCell.m in Sources */, + 93D39A5FF670957C0AF8298D /* MPSiteCell.m in Sources */, 93D398ECD7D1A0DEDDADF516 /* MPEmergencyViewController.m in Sources */, DA95B50F1C4776F00067F5EF /* NSMutableSet+Pearl.m in Sources */, - 93D394B5036C882B33C71872 /* MPPasswordsSegue.m in Sources */, + 93D394B5036C882B33C71872 /* MPSitesSegue.m in Sources */, DA0CC5911EB6B030009A8ED9 /* MPStoredSiteEntity+CoreDataProperties.m in Sources */, 93D39673DDC085BE72C34D7C /* MPPopdownSegue.m in Sources */, 93D39BA1EA3CAAC8A220B4A6 /* MPAppSettingsViewController.m in Sources */, diff --git a/platform-darwin/MasterPassword-macOS.xcodeproj/project.pbxproj b/platform-darwin/MasterPassword-macOS.xcodeproj/project.pbxproj index d8bb1343..9217ceda 100644 --- a/platform-darwin/MasterPassword-macOS.xcodeproj/project.pbxproj +++ b/platform-darwin/MasterPassword-macOS.xcodeproj/project.pbxproj @@ -7,7 +7,7 @@ objects = { /* Begin PBXBuildFile section */ - 93D390C676DF52DA7E459F19 /* MPPasswordWindow.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D39D9D0061FF1159998F06 /* MPPasswordWindow.m */; }; + 93D390C676DF52DA7E459F19 /* MPSitesWindow.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D39D9D0061FF1159998F06 /* MPSitesWindow.m */; }; 93D391E61DC23E128DA4446C /* NSView+Traversing.h in Headers */ = {isa = PBXBuildFile; fileRef = 93D393EE88DE554BCCBC1C2D /* NSView+Traversing.h */; }; 93D392EC39DA43C46C692C12 /* NSDictionary+Indexing.h in Headers */ = {isa = PBXBuildFile; fileRef = 93D393B97158D7BE9332EA53 /* NSDictionary+Indexing.h */; }; 93D393A1646430FAAC73E7FE /* MPMacApplication.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D39F83DD151985F2C7345A /* MPMacApplication.m */; }; @@ -20,7 +20,7 @@ 93D39C34FE35830EF5BE1D2A /* NSArray+Indexing.h in Headers */ = {isa = PBXBuildFile; fileRef = 93D396D04E57792A54D437AC /* NSArray+Indexing.h */; }; 93D39C5789EFA607CF788082 /* MPSiteModel.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D39E73BF5CBF8E5B005CD3 /* MPSiteModel.m */; }; 93D39E281E3658B30550CB55 /* NSDictionary+Indexing.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D39AA1EE2E1E7B81372240 /* NSDictionary+Indexing.m */; }; - 93D39F833DEC1C89B2F795AC /* MPPasswordWindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D39A57A7823DE98A0FF83C /* MPPasswordWindowController.m */; }; + 93D39F833DEC1C89B2F795AC /* MPSitesWindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = 93D39A57A7823DE98A0FF83C /* MPSitesWindowController.m */; }; DA0933CC1747AD2D00DE1CEF /* shot-laptop-leaning-iphone.png in Resources */ = {isa = PBXBuildFile; fileRef = DA0933CB1747AD2D00DE1CEF /* shot-laptop-leaning-iphone.png */; }; DA0933D01747B91B00DE1CEF /* appstore.png in Resources */ = {isa = PBXBuildFile; fileRef = DA0933CF1747B91B00DE1CEF /* appstore.png */; }; DA09745A1E99582900F0BFE8 /* mpw-tests-util.c in Sources */ = {isa = PBXBuildFile; fileRef = DA0974561E99582200F0BFE8 /* mpw-tests-util.c */; }; @@ -36,6 +36,16 @@ DA16B345170661F2000A0EAB /* libPearl.a in Frameworks */ = {isa = PBXBuildFile; fileRef = DAC77CAD148291A600BCF976 /* libPearl.a */; }; DA2508F119511D3600AC23F1 /* MPPasswordWindowController.xib in Resources */ = {isa = PBXBuildFile; fileRef = DA2508F019511D3600AC23F1 /* MPPasswordWindowController.xib */; }; DA250925195148E200AC23F1 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DAEBC45214F6364500987BF6 /* QuartzCore.framework */; }; + DA26861D1EBFD7A40001E37E /* MPGeneratedSiteEntity+CoreDataClass.m in Sources */ = {isa = PBXBuildFile; fileRef = DA26860A1EBFD7A40001E37E /* MPGeneratedSiteEntity+CoreDataClass.m */; }; + DA26861E1EBFD7A40001E37E /* MPGeneratedSiteEntity+CoreDataProperties.m in Sources */ = {isa = PBXBuildFile; fileRef = DA26860C1EBFD7A40001E37E /* MPGeneratedSiteEntity+CoreDataProperties.m */; }; + DA26861F1EBFD7A40001E37E /* MPSiteEntity+CoreDataClass.m in Sources */ = {isa = PBXBuildFile; fileRef = DA26860E1EBFD7A40001E37E /* MPSiteEntity+CoreDataClass.m */; }; + DA2686201EBFD7A40001E37E /* MPSiteEntity+CoreDataProperties.m in Sources */ = {isa = PBXBuildFile; fileRef = DA2686101EBFD7A40001E37E /* MPSiteEntity+CoreDataProperties.m */; }; + DA2686211EBFD7A40001E37E /* MPSiteQuestionEntity+CoreDataClass.m in Sources */ = {isa = PBXBuildFile; fileRef = DA2686121EBFD7A40001E37E /* MPSiteQuestionEntity+CoreDataClass.m */; }; + DA2686221EBFD7A40001E37E /* MPSiteQuestionEntity+CoreDataProperties.m in Sources */ = {isa = PBXBuildFile; fileRef = DA2686141EBFD7A40001E37E /* MPSiteQuestionEntity+CoreDataProperties.m */; }; + DA2686231EBFD7A40001E37E /* MPStoredSiteEntity+CoreDataClass.m in Sources */ = {isa = PBXBuildFile; fileRef = DA2686161EBFD7A40001E37E /* MPStoredSiteEntity+CoreDataClass.m */; }; + DA2686241EBFD7A40001E37E /* MPStoredSiteEntity+CoreDataProperties.m in Sources */ = {isa = PBXBuildFile; fileRef = DA2686181EBFD7A40001E37E /* MPStoredSiteEntity+CoreDataProperties.m */; }; + DA2686251EBFD7A40001E37E /* MPUserEntity+CoreDataClass.m in Sources */ = {isa = PBXBuildFile; fileRef = DA26861A1EBFD7A40001E37E /* MPUserEntity+CoreDataClass.m */; }; + DA2686261EBFD7A40001E37E /* MPUserEntity+CoreDataProperties.m in Sources */ = {isa = PBXBuildFile; fileRef = DA26861C1EBFD7A40001E37E /* MPUserEntity+CoreDataProperties.m */; }; DA2C3D681BD9665B001137B3 /* PearlProfiler.h in Headers */ = {isa = PBXBuildFile; fileRef = DA2C3D661BD9665B001137B3 /* PearlProfiler.h */; }; DA2C3D691BD9665B001137B3 /* PearlProfiler.m in Sources */ = {isa = PBXBuildFile; fileRef = DA2C3D671BD9665B001137B3 /* PearlProfiler.m */; }; DA2CA4ED18D323D3007798F8 /* NSError+PearlFullDescription.m in Sources */ = {isa = PBXBuildFile; fileRef = DA2CA4E718D323D3007798F8 /* NSError+PearlFullDescription.m */; }; @@ -48,11 +58,6 @@ DA30E9D215722EE500A68B4C /* Pearl-Crypto.m in Sources */ = {isa = PBXBuildFile; fileRef = DA30E9D115722EE500A68B4C /* Pearl-Crypto.m */; }; DA30E9D715723E6900A68B4C /* PearlLazy.h in Headers */ = {isa = PBXBuildFile; fileRef = DA30E9D515723E6900A68B4C /* PearlLazy.h */; }; DA30E9D815723E6900A68B4C /* PearlLazy.m in Sources */ = {isa = PBXBuildFile; fileRef = DA30E9D615723E6900A68B4C /* PearlLazy.m */; }; - DA32CFD919CF1C70004F3F0E /* MPGeneratedSiteEntity.m in Sources */ = {isa = PBXBuildFile; fileRef = DA32CFD819CF1C70004F3F0E /* MPGeneratedSiteEntity.m */; }; - DA32CFDC19CF1C70004F3F0E /* MPStoredSiteEntity.m in Sources */ = {isa = PBXBuildFile; fileRef = DA32CFDB19CF1C70004F3F0E /* MPStoredSiteEntity.m */; }; - DA32CFDF19CF1C70004F3F0E /* MPSiteEntity.m in Sources */ = {isa = PBXBuildFile; fileRef = DA32CFDE19CF1C70004F3F0E /* MPSiteEntity.m */; }; - DA32CFE219CF1C71004F3F0E /* MPSiteQuestionEntity.m in Sources */ = {isa = PBXBuildFile; fileRef = DA32CFE119CF1C71004F3F0E /* MPSiteQuestionEntity.m */; }; - DA32CFE519CF1C71004F3F0E /* MPUserEntity.m in Sources */ = {isa = PBXBuildFile; fileRef = DA32CFE419CF1C71004F3F0E /* MPUserEntity.m */; }; DA3509FE15F101A500C14A8E /* PearlQueue.h in Headers */ = {isa = PBXBuildFile; fileRef = DA3509FC15F101A500C14A8E /* PearlQueue.h */; }; DA3509FF15F101A500C14A8E /* PearlQueue.m in Sources */ = {isa = PBXBuildFile; fileRef = DA3509FD15F101A500C14A8E /* PearlQueue.m */; }; DA3B844F190FC60900246EEA /* Crashlytics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DA3B844A190FC5A900246EEA /* Crashlytics.framework */; }; @@ -265,7 +270,7 @@ 93D39240B5143E01F0B75E96 /* MPSiteModel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPSiteModel.h; sourceTree = ""; }; 93D392870DF659AFC1870521 /* NSView+Traversing.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSView+Traversing.m"; sourceTree = ""; }; 93D392A4F3DE0BD758B9B056 /* MPNoStateButton.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPNoStateButton.h; sourceTree = ""; }; - 93D392C3918763B3B72CF366 /* MPPasswordWindowController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPPasswordWindowController.h; sourceTree = ""; }; + 93D392C3918763B3B72CF366 /* MPSitesWindowController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPSitesWindowController.h; sourceTree = ""; }; 93D392FD65A1DF0E8B2A45C6 /* MPGradientView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPGradientView.h; sourceTree = ""; }; 93D39368EF3CBFEF2AFCA15A /* MPInitialWindowController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPInitialWindowController.h; sourceTree = ""; }; 93D393B97158D7BE9332EA53 /* NSDictionary+Indexing.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSDictionary+Indexing.h"; sourceTree = ""; }; @@ -274,13 +279,13 @@ 93D39423D7BF4FD31FE6D27C /* MPSitesTableView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPSitesTableView.m; sourceTree = ""; }; 93D39538C4CEFF46DF379254 /* MPNoStateButton.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPNoStateButton.m; sourceTree = ""; }; 93D396D04E57792A54D437AC /* NSArray+Indexing.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSArray+Indexing.h"; sourceTree = ""; }; - 93D3977484534E99F9BA579D /* MPPasswordWindow.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPPasswordWindow.h; sourceTree = ""; }; + 93D3977484534E99F9BA579D /* MPSitesWindow.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPSitesWindow.h; sourceTree = ""; }; 93D39934FD8D5BFABA46F41C /* MPGradientView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPGradientView.m; sourceTree = ""; }; - 93D39A57A7823DE98A0FF83C /* MPPasswordWindowController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPPasswordWindowController.m; sourceTree = ""; }; + 93D39A57A7823DE98A0FF83C /* MPSitesWindowController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPSitesWindowController.m; sourceTree = ""; }; 93D39AA1EE2E1E7B81372240 /* NSDictionary+Indexing.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSDictionary+Indexing.m"; sourceTree = ""; }; 93D39AC6360DDC16AEAA4119 /* MPSitesTableView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPSitesTableView.h; sourceTree = ""; }; 93D39D3CB30874147D9A9E1B /* MPInitialWindowController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPInitialWindowController.m; sourceTree = ""; }; - 93D39D9D0061FF1159998F06 /* MPPasswordWindow.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPPasswordWindow.m; sourceTree = ""; }; + 93D39D9D0061FF1159998F06 /* MPSitesWindow.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPSitesWindow.m; sourceTree = ""; }; 93D39E73BF5CBF8E5B005CD3 /* MPSiteModel.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPSiteModel.m; sourceTree = ""; }; 93D39F83DD151985F2C7345A /* MPMacApplication.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPMacApplication.m; sourceTree = ""; }; DA0933C91747A56A00DE1CEF /* MPInitialWindow.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = MPInitialWindow.xib; sourceTree = ""; }; @@ -366,6 +371,26 @@ DA2508F919513C1400AC23F1 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; }; DA2508FA19513C1400AC23F1 /* CoreData.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreData.framework; path = System/Library/Frameworks/CoreData.framework; sourceTree = SDKROOT; }; DA2508FB19513C1400AC23F1 /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = System/Library/Frameworks/AppKit.framework; sourceTree = SDKROOT; }; + DA2686091EBFD7A40001E37E /* MPGeneratedSiteEntity+CoreDataClass.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "MPGeneratedSiteEntity+CoreDataClass.h"; sourceTree = ""; }; + DA26860A1EBFD7A40001E37E /* MPGeneratedSiteEntity+CoreDataClass.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "MPGeneratedSiteEntity+CoreDataClass.m"; sourceTree = ""; }; + DA26860B1EBFD7A40001E37E /* MPGeneratedSiteEntity+CoreDataProperties.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "MPGeneratedSiteEntity+CoreDataProperties.h"; sourceTree = ""; }; + DA26860C1EBFD7A40001E37E /* MPGeneratedSiteEntity+CoreDataProperties.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "MPGeneratedSiteEntity+CoreDataProperties.m"; sourceTree = ""; }; + DA26860D1EBFD7A40001E37E /* MPSiteEntity+CoreDataClass.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "MPSiteEntity+CoreDataClass.h"; sourceTree = ""; }; + DA26860E1EBFD7A40001E37E /* MPSiteEntity+CoreDataClass.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "MPSiteEntity+CoreDataClass.m"; sourceTree = ""; }; + DA26860F1EBFD7A40001E37E /* MPSiteEntity+CoreDataProperties.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "MPSiteEntity+CoreDataProperties.h"; sourceTree = ""; }; + DA2686101EBFD7A40001E37E /* MPSiteEntity+CoreDataProperties.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "MPSiteEntity+CoreDataProperties.m"; sourceTree = ""; }; + DA2686111EBFD7A40001E37E /* MPSiteQuestionEntity+CoreDataClass.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "MPSiteQuestionEntity+CoreDataClass.h"; sourceTree = ""; }; + DA2686121EBFD7A40001E37E /* MPSiteQuestionEntity+CoreDataClass.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "MPSiteQuestionEntity+CoreDataClass.m"; sourceTree = ""; }; + DA2686131EBFD7A40001E37E /* MPSiteQuestionEntity+CoreDataProperties.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "MPSiteQuestionEntity+CoreDataProperties.h"; sourceTree = ""; }; + DA2686141EBFD7A40001E37E /* MPSiteQuestionEntity+CoreDataProperties.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "MPSiteQuestionEntity+CoreDataProperties.m"; sourceTree = ""; }; + DA2686151EBFD7A40001E37E /* MPStoredSiteEntity+CoreDataClass.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "MPStoredSiteEntity+CoreDataClass.h"; sourceTree = ""; }; + DA2686161EBFD7A40001E37E /* MPStoredSiteEntity+CoreDataClass.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "MPStoredSiteEntity+CoreDataClass.m"; sourceTree = ""; }; + DA2686171EBFD7A40001E37E /* MPStoredSiteEntity+CoreDataProperties.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "MPStoredSiteEntity+CoreDataProperties.h"; sourceTree = ""; }; + DA2686181EBFD7A40001E37E /* MPStoredSiteEntity+CoreDataProperties.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "MPStoredSiteEntity+CoreDataProperties.m"; sourceTree = ""; }; + DA2686191EBFD7A40001E37E /* MPUserEntity+CoreDataClass.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "MPUserEntity+CoreDataClass.h"; sourceTree = ""; }; + DA26861A1EBFD7A40001E37E /* MPUserEntity+CoreDataClass.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "MPUserEntity+CoreDataClass.m"; sourceTree = ""; }; + DA26861B1EBFD7A40001E37E /* MPUserEntity+CoreDataProperties.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "MPUserEntity+CoreDataProperties.h"; sourceTree = ""; }; + DA26861C1EBFD7A40001E37E /* MPUserEntity+CoreDataProperties.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "MPUserEntity+CoreDataProperties.m"; sourceTree = ""; }; DA2C3D661BD9665B001137B3 /* PearlProfiler.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PearlProfiler.h; sourceTree = ""; }; DA2C3D671BD9665B001137B3 /* PearlProfiler.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PearlProfiler.m; sourceTree = ""; }; DA2CA4E718D323D3007798F8 /* NSError+PearlFullDescription.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSError+PearlFullDescription.m"; sourceTree = ""; }; @@ -378,16 +403,6 @@ DA30E9D115722EE500A68B4C /* Pearl-Crypto.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "Pearl-Crypto.m"; sourceTree = ""; }; DA30E9D515723E6900A68B4C /* PearlLazy.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PearlLazy.h; sourceTree = ""; }; DA30E9D615723E6900A68B4C /* PearlLazy.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PearlLazy.m; sourceTree = ""; }; - DA32CFD719CF1C70004F3F0E /* MPGeneratedSiteEntity.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPGeneratedSiteEntity.h; sourceTree = ""; }; - DA32CFD819CF1C70004F3F0E /* MPGeneratedSiteEntity.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPGeneratedSiteEntity.m; sourceTree = ""; }; - DA32CFDA19CF1C70004F3F0E /* MPStoredSiteEntity.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPStoredSiteEntity.h; sourceTree = ""; }; - DA32CFDB19CF1C70004F3F0E /* MPStoredSiteEntity.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPStoredSiteEntity.m; sourceTree = ""; }; - DA32CFDD19CF1C70004F3F0E /* MPSiteEntity.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPSiteEntity.h; sourceTree = ""; }; - DA32CFDE19CF1C70004F3F0E /* MPSiteEntity.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPSiteEntity.m; sourceTree = ""; }; - DA32CFE019CF1C71004F3F0E /* MPSiteQuestionEntity.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPSiteQuestionEntity.h; sourceTree = ""; }; - DA32CFE119CF1C71004F3F0E /* MPSiteQuestionEntity.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPSiteQuestionEntity.m; sourceTree = ""; }; - DA32CFE319CF1C71004F3F0E /* MPUserEntity.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPUserEntity.h; sourceTree = ""; }; - DA32CFE419CF1C71004F3F0E /* MPUserEntity.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPUserEntity.m; sourceTree = ""; }; DA3509FC15F101A500C14A8E /* PearlQueue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PearlQueue.h; sourceTree = ""; }; DA3509FD15F101A500C14A8E /* PearlQueue.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PearlQueue.m; sourceTree = ""; }; DA3B844A190FC5A900246EEA /* Crashlytics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = Crashlytics.framework; sourceTree = ""; }; @@ -1244,20 +1259,30 @@ DA5E5CAC1724A667003798D8 /* MPEntities.m */, DA3B8455190FC89700246EEA /* MPFixable.h */, DA3B8454190FC89700246EEA /* MPFixable.m */, - DA32CFD719CF1C70004F3F0E /* MPGeneratedSiteEntity.h */, - DA32CFD819CF1C70004F3F0E /* MPGeneratedSiteEntity.m */, + DA2686091EBFD7A40001E37E /* MPGeneratedSiteEntity+CoreDataClass.h */, + DA26860A1EBFD7A40001E37E /* MPGeneratedSiteEntity+CoreDataClass.m */, + DA26860B1EBFD7A40001E37E /* MPGeneratedSiteEntity+CoreDataProperties.h */, + DA26860C1EBFD7A40001E37E /* MPGeneratedSiteEntity+CoreDataProperties.m */, DA5E5CAD1724A667003798D8 /* MPKey.h */, DA5E5CAE1724A667003798D8 /* MPKey.m */, - DA32CFDD19CF1C70004F3F0E /* MPSiteEntity.h */, - DA32CFDE19CF1C70004F3F0E /* MPSiteEntity.m */, - DA32CFE019CF1C71004F3F0E /* MPSiteQuestionEntity.h */, - DA32CFE119CF1C71004F3F0E /* MPSiteQuestionEntity.m */, - DA32CFDA19CF1C70004F3F0E /* MPStoredSiteEntity.h */, - DA32CFDB19CF1C70004F3F0E /* MPStoredSiteEntity.m */, + DA26860D1EBFD7A40001E37E /* MPSiteEntity+CoreDataClass.h */, + DA26860E1EBFD7A40001E37E /* MPSiteEntity+CoreDataClass.m */, + DA26860F1EBFD7A40001E37E /* MPSiteEntity+CoreDataProperties.h */, + DA2686101EBFD7A40001E37E /* MPSiteEntity+CoreDataProperties.m */, + DA2686111EBFD7A40001E37E /* MPSiteQuestionEntity+CoreDataClass.h */, + DA2686121EBFD7A40001E37E /* MPSiteQuestionEntity+CoreDataClass.m */, + DA2686131EBFD7A40001E37E /* MPSiteQuestionEntity+CoreDataProperties.h */, + DA2686141EBFD7A40001E37E /* MPSiteQuestionEntity+CoreDataProperties.m */, + DA2686151EBFD7A40001E37E /* MPStoredSiteEntity+CoreDataClass.h */, + DA2686161EBFD7A40001E37E /* MPStoredSiteEntity+CoreDataClass.m */, + DA2686171EBFD7A40001E37E /* MPStoredSiteEntity+CoreDataProperties.h */, + DA2686181EBFD7A40001E37E /* MPStoredSiteEntity+CoreDataProperties.m */, DA5E5CAF1724A667003798D8 /* MPTypes.h */, DA4DAE931A7D8117003E5423 /* MPTypes.m */, - DA32CFE319CF1C71004F3F0E /* MPUserEntity.h */, - DA32CFE419CF1C71004F3F0E /* MPUserEntity.m */, + DA2686191EBFD7A40001E37E /* MPUserEntity+CoreDataClass.h */, + DA26861A1EBFD7A40001E37E /* MPUserEntity+CoreDataClass.m */, + DA26861B1EBFD7A40001E37E /* MPUserEntity+CoreDataProperties.h */, + DA26861C1EBFD7A40001E37E /* MPUserEntity+CoreDataProperties.m */, ); path = Source; sourceTree = ""; @@ -1284,10 +1309,10 @@ DA5E5CB61724A667003798D8 /* MPMacConfig.m */, 93D392A4F3DE0BD758B9B056 /* MPNoStateButton.h */, 93D39538C4CEFF46DF379254 /* MPNoStateButton.m */, - 93D3977484534E99F9BA579D /* MPPasswordWindow.h */, - 93D39D9D0061FF1159998F06 /* MPPasswordWindow.m */, - 93D392C3918763B3B72CF366 /* MPPasswordWindowController.h */, - 93D39A57A7823DE98A0FF83C /* MPPasswordWindowController.m */, + 93D3977484534E99F9BA579D /* MPSitesWindow.h */, + 93D39D9D0061FF1159998F06 /* MPSitesWindow.m */, + 93D392C3918763B3B72CF366 /* MPSitesWindowController.h */, + 93D39A57A7823DE98A0FF83C /* MPSitesWindowController.m */, DA2508F019511D3600AC23F1 /* MPPasswordWindowController.xib */, 93D39240B5143E01F0B75E96 /* MPSiteModel.h */, 93D39E73BF5CBF8E5B005CD3 /* MPSiteModel.m */, @@ -2382,35 +2407,40 @@ isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( + DA2686251EBFD7A40001E37E /* MPUserEntity+CoreDataClass.m in Sources */, DA5E5CF61724A667003798D8 /* MPAlgorithm.m in Sources */, - DA32CFE219CF1C71004F3F0E /* MPSiteQuestionEntity.m in Sources */, - DA32CFE519CF1C71004F3F0E /* MPUserEntity.m in Sources */, + DA2686201EBFD7A40001E37E /* MPSiteEntity+CoreDataProperties.m in Sources */, DA5E5CF71724A667003798D8 /* MPAlgorithmV0.m in Sources */, + DA26861E1EBFD7A40001E37E /* MPGeneratedSiteEntity+CoreDataProperties.m in Sources */, DA5E5CF81724A667003798D8 /* MPAlgorithmV1.m in Sources */, + DA2686231EBFD7A40001E37E /* MPStoredSiteEntity+CoreDataClass.m in Sources */, + DA2686221EBFD7A40001E37E /* MPSiteQuestionEntity+CoreDataProperties.m in Sources */, DACBFCDF1C59B22E007EF90F /* NSMutableSet+Pearl.m in Sources */, + DA2686241EBFD7A40001E37E /* MPStoredSiteEntity+CoreDataProperties.m in Sources */, DA6774311A4746AF004F356A /* mpw-util.c in Sources */, DA5E5CF91724A667003798D8 /* MPAppDelegate_Key.m in Sources */, DA5180CE19FF307E00A587E9 /* MPAppDelegate_Store.m in Sources */, DA5E5CFA1724A667003798D8 /* MPAppDelegate_Shared.m in Sources */, DA5E5CFC1724A667003798D8 /* MPConfig.m in Sources */, + DA26861F1EBFD7A40001E37E /* MPSiteEntity+CoreDataClass.m in Sources */, DA3B8456190FC89700246EEA /* MPFixable.m in Sources */, DA5E5D001724A667003798D8 /* MPEntities.m in Sources */, + DA2686261EBFD7A40001E37E /* MPUserEntity+CoreDataProperties.m in Sources */, DA5E5D011724A667003798D8 /* MPKey.m in Sources */, - DA32CFDC19CF1C70004F3F0E /* MPStoredSiteEntity.m in Sources */, DA5E5D031724A667003798D8 /* MPMacAppDelegate.m in Sources */, DA5E5D041724A667003798D8 /* MPMacConfig.m in Sources */, DA5E5D0C1724A667003798D8 /* main.m in Sources */, 93D39C5789EFA607CF788082 /* MPSiteModel.m in Sources */, DA5180CA19FF2F9200A587E9 /* MPAlgorithmV2.m in Sources */, - 93D39F833DEC1C89B2F795AC /* MPPasswordWindowController.m in Sources */, + 93D39F833DEC1C89B2F795AC /* MPSitesWindowController.m in Sources */, DA67742F1A4746AF004F356A /* mpw-types.c in Sources */, - DA32CFD919CF1C70004F3F0E /* MPGeneratedSiteEntity.m in Sources */, - 93D390C676DF52DA7E459F19 /* MPPasswordWindow.m in Sources */, + 93D390C676DF52DA7E459F19 /* MPSitesWindow.m in Sources */, + DA26861D1EBFD7A40001E37E /* MPGeneratedSiteEntity+CoreDataClass.m in Sources */, 93D39784E725A34D1EE3FB3B /* MPInitialWindowController.m in Sources */, - DA32CFDF19CF1C70004F3F0E /* MPSiteEntity.m in Sources */, 93D394C4254EEB45FB335AFB /* MPSitesTableView.m in Sources */, DA6774291A4746AF004F356A /* mpw-algorithm.c in Sources */, DA0CC5591EB6AE45009A8ED9 /* MasterPassword.xcdatamodeld in Sources */, + DA2686211EBFD7A40001E37E /* MPSiteQuestionEntity+CoreDataClass.m in Sources */, 93D395E4830290EBB6E71F34 /* MPNoStateButton.m in Sources */, DA4DAE941A7D8117003E5423 /* MPAlgorithmV3.m in Sources */, DA4DAE951A7D8117003E5423 /* MPTypes.m in Sources */, diff --git a/platform-darwin/Source/MPAlgorithmV0.m b/platform-darwin/Source/MPAlgorithmV0.m index e19057c3..cd281ed5 100644 --- a/platform-darwin/Source/MPAlgorithmV0.m +++ b/platform-darwin/Source/MPAlgorithmV0.m @@ -29,7 +29,7 @@ #define CRACKING_PER_SECOND 2495000000UL #define CRACKING_PRICE 350 -NSOperationQueue *_mpwQueue = nil; +static NSOperationQueue *_mpwQueue = nil; @implementation MPAlgorithmV0 diff --git a/platform-darwin/Source/MPAppDelegate_InApp.m b/platform-darwin/Source/MPAppDelegate_InApp.m index 5f228ee3..ed799f11 100644 --- a/platform-darwin/Source/MPAppDelegate_InApp.m +++ b/platform-darwin/Source/MPAppDelegate_InApp.m @@ -104,8 +104,10 @@ PearlAssociatedObjectProperty( NSMutableArray*, ProductObservers, productObserve #if TARGET_OS_IPHONE if (![[MPAppDelegate_Shared get] canMakePayments]) { - [PearlAlert showAlertWithTitle:@"Store Not Set Up" message: - @"Try logging using the App Store or from Settings." + [PearlAlert showAlertWithTitle:@"App Store Not Set Up" message: + @"Make sure your Apple ID is set under Settings -> iTunes & App Store, " + @"you have a payment method added to the account and purchases are" + @"not disabled under General -> Restrictions." viewStyle:UIAlertViewStyleDefault initAlert:nil tappedButtonBlock:nil cancelTitle:@"Thanks" otherTitles:nil]; return; diff --git a/platform-darwin/Source/MPAppDelegate_Shared.h b/platform-darwin/Source/MPAppDelegate_Shared.h index d2b832b4..b2b00a20 100644 --- a/platform-darwin/Source/MPAppDelegate_Shared.h +++ b/platform-darwin/Source/MPAppDelegate_Shared.h @@ -19,7 +19,9 @@ #import "MPEntities.h" #if TARGET_OS_IPHONE + @interface MPAppDelegate_Shared : PearlAppDelegate + #else @interface MPAppDelegate_Shared : NSObject diff --git a/platform-darwin/Source/MPAppDelegate_Shared.m b/platform-darwin/Source/MPAppDelegate_Shared.m index f17e38d4..1be4054d 100644 --- a/platform-darwin/Source/MPAppDelegate_Shared.m +++ b/platform-darwin/Source/MPAppDelegate_Shared.m @@ -78,7 +78,6 @@ } - (void)handleCoordinatorError:(NSError *)error { - } @end diff --git a/platform-darwin/Source/MPConfig.h b/platform-darwin/Source/MPConfig.h index c5f10643..844e993a 100644 --- a/platform-darwin/Source/MPConfig.h +++ b/platform-darwin/Source/MPConfig.h @@ -1,10 +1,20 @@ +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. // -// MPConfig.h -// MasterPassword +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. // -// Created by Maarten Billemont on 02/01/12. -// Copyright (c) 2012 Lyndir. All rights reserved. +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. // +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== #import "Pearl.h" diff --git a/platform-darwin/Source/MPConfig.m b/platform-darwin/Source/MPConfig.m index 3c4b3e0b..e0b5b4b8 100644 --- a/platform-darwin/Source/MPConfig.m +++ b/platform-darwin/Source/MPConfig.m @@ -1,10 +1,20 @@ +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. // -// MPConfig.m -// MasterPassword +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. // -// Created by Maarten Billemont on 02/01/12. -// Copyright (c) 2012 Lyndir. All rights reserved. +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. // +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== #import "MPAppDelegate_Shared.h" diff --git a/platform-darwin/Source/MPEntities.h b/platform-darwin/Source/MPEntities.h index 274fb676..a5eba703 100644 --- a/platform-darwin/Source/MPEntities.h +++ b/platform-darwin/Source/MPEntities.h @@ -1,10 +1,20 @@ +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. // -// MPEntities.h -// MasterPassword-iOS +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. // -// Created by Maarten Billemont on 31/05/12. -// Copyright (c) 2012 Lyndir. All rights reserved. +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. // +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== #import #import "MPSiteEntity+CoreDataClass.h" diff --git a/platform-darwin/Source/MPEntities.m b/platform-darwin/Source/MPEntities.m index 67f4b7dc..5a08af2d 100644 --- a/platform-darwin/Source/MPEntities.m +++ b/platform-darwin/Source/MPEntities.m @@ -1,10 +1,20 @@ +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. // -// MPEntities.m -// MasterPassword-iOS +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. // -// Created by Maarten Billemont on 31/05/12. -// Copyright (c) 2012 Lyndir. All rights reserved. +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. // +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== #import "MPEntities.h" #import "MPAppDelegate_Shared.h" diff --git a/platform-darwin/Source/MPFixable.h b/platform-darwin/Source/MPFixable.h index 7ad01702..5aed754b 100644 --- a/platform-darwin/Source/MPFixable.h +++ b/platform-darwin/Source/MPFixable.h @@ -1,20 +1,20 @@ -/** -* Copyright Maarten Billemont (http://www.lhunath.com, lhunath@lyndir.com) -* -* See the enclosed file LICENSE for license information (LGPLv3). If you did -* not receive this file, see http://www.gnu.org/licenses/lgpl-3.0.txt -* -* @author Maarten Billemont -* @license http://www.gnu.org/licenses/lgpl-3.0.txt -*/ - +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. // -// MPFixable.h -// MPFixable +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. // -// Created by lhunath on 2014-04-26. -// Copyright, lhunath (Maarten Billemont) 2014. All rights reserved. +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. // +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== #import diff --git a/platform-darwin/Source/MPFixable.m b/platform-darwin/Source/MPFixable.m index 519981e8..d50d536a 100644 --- a/platform-darwin/Source/MPFixable.m +++ b/platform-darwin/Source/MPFixable.m @@ -1,20 +1,20 @@ -/** -* Copyright Maarten Billemont (http://www.lhunath.com, lhunath@lyndir.com) -* -* See the enclosed file LICENSE for license information (LGPLv3). If you did -* not receive this file, see http://www.gnu.org/licenses/lgpl-3.0.txt -* -* @author Maarten Billemont -* @license http://www.gnu.org/licenses/lgpl-3.0.txt -*/ - +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. // -// MPFixable.m -// MPFixable +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. // -// Created by lhunath on 2014-04-26. -// Copyright, lhunath (Maarten Billemont) 2014. All rights reserved. +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. // +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== #import "MPFixable.h" diff --git a/platform-darwin/Source/MPKey.h b/platform-darwin/Source/MPKey.h index b5182d80..c1eeb24c 100644 --- a/platform-darwin/Source/MPKey.h +++ b/platform-darwin/Source/MPKey.h @@ -1,19 +1,20 @@ -/** - * Copyright Maarten Billemont (http://www.lhunath.com, lhunath@lyndir.com) - * - * See the enclosed file LICENSE for license information (LGPLv3). If you did - * not receive this file, see http://www.gnu.org/licenses/lgpl-3.0.txt - * - * @author Maarten Billemont - * @license http://www.gnu.org/licenses/lgpl-3.0.txt - */ - +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. // -// MPKey +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. // -// Created by Maarten Billemont on 16/07/12. -// Copyright 2012 lhunath (Maarten Billemont). All rights reserved. +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. // +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== #import #import "MPAlgorithm.h" diff --git a/platform-darwin/Source/MPKey.m b/platform-darwin/Source/MPKey.m index c3d934be..9d5819cc 100644 --- a/platform-darwin/Source/MPKey.m +++ b/platform-darwin/Source/MPKey.m @@ -1,19 +1,20 @@ -/** -* Copyright Maarten Billemont (http://www.lhunath.com, lhunath@lyndir.com) -* -* See the enclosed file LICENSE for license information (LGPLv3). If you did -* not receive this file, see http://www.gnu.org/licenses/lgpl-3.0.txt -* -* @author Maarten Billemont -* @license http://www.gnu.org/licenses/lgpl-3.0.txt -*/ - +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. // -// MPKey +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. // -// Created by Maarten Billemont on 16/07/12. -// Copyright 2012 lhunath (Maarten Billemont). All rights reserved. +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. // +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== #import "MPAlgorithm.h" @@ -22,12 +23,11 @@ @property(nonatomic) MPKeyOrigin origin; @property(nonatomic, copy) NSString *fullName; @property(nonatomic, copy) NSData *( ^keyResolver )(id); +@property(nonatomic, strong) NSCache *keyCache; @end -@implementation MPKey { - NSCache *_keyCache; -}; +@implementation MPKey; - (instancetype)initForFullName:(NSString *)fullName withMasterPassword:(NSString *)masterPassword { @@ -42,7 +42,7 @@ if (!(self = [super init])) return nil; - _keyCache = [NSCache new]; + self.keyCache = [NSCache new]; self.origin = origin; self.fullName = fullName; @@ -59,13 +59,13 @@ - (NSData *)keyDataForAlgorithm:(id)algorithm { @synchronized (self) { - NSData *keyData = [_keyCache objectForKey:algorithm]; + NSData *keyData = [self.keyCache objectForKey:algorithm]; if (keyData) return keyData; keyData = self.keyResolver( algorithm ); if (keyData) - [_keyCache setObject:keyData forKey:algorithm]; + [self.keyCache setObject:keyData forKey:algorithm]; return keyData; } diff --git a/platform-darwin/Source/MPTypes.h b/platform-darwin/Source/MPTypes.h index d6e54203..04b73410 100644 --- a/platform-darwin/Source/MPTypes.h +++ b/platform-darwin/Source/MPTypes.h @@ -1,10 +1,20 @@ +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. // -// MPTypes.h -// MasterPassword +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. // -// Created by Maarten Billemont on 02/01/12. -// Copyright (c) 2012 Lyndir. All rights reserved. +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. // +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== #import #import @@ -37,7 +47,7 @@ __END_DECLS } \ }) #else -#define MPError(error_, ...) ({ \ +#define MPError(error_, message, ...) ({ \ err( message @"%@%@", ##__VA_ARGS__, error_? @"\n": @"", [error_ fullDescription]?: @"" ); \ }) #endif diff --git a/platform-darwin/Source/MPTypes.m b/platform-darwin/Source/MPTypes.m index 5324fa5a..4b3829b4 100644 --- a/platform-darwin/Source/MPTypes.m +++ b/platform-darwin/Source/MPTypes.m @@ -1,10 +1,20 @@ +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. // -// MPTypes.c -// MasterPassword +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. // -// Created by Maarten Billemont on 02/01/12. -// Copyright (c) 2012 Lyndir. All rights reserved. +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. // +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== #import "MPTypes.h" diff --git a/platform-darwin/Source/Mac/MPGradientView.m b/platform-darwin/Source/Mac/MPGradientView.m index f27366ed..13786fc7 100644 --- a/platform-darwin/Source/Mac/MPGradientView.m +++ b/platform-darwin/Source/Mac/MPGradientView.m @@ -18,9 +18,13 @@ #import "MPGradientView.h" -@implementation MPGradientView { - NSGradient *gradient; -} +@interface MPGradientView() + +@property(nonatomic, strong) NSGradient *gradient; + +@end + +@implementation MPGradientView - (id)initWithFrame:(NSRect)frame { @@ -51,28 +55,28 @@ - (void)setStartingColor:(NSColor *)startingColor { _startingColor = startingColor; - gradient = nil; + self.gradient = nil; [self setNeedsDisplay:YES]; } - (void)setEndingColor:(NSColor *)endingColor { _endingColor = endingColor; - gradient = nil; + self.gradient = nil; [self setNeedsDisplay:YES]; } - (void)setAngle:(NSInteger)angle { _angle = angle; - gradient = nil; + self.gradient = nil; [self setNeedsDisplay:YES]; } - (void)setRatio:(CGFloat)ratio { _ratio = ratio; - gradient = nil; + self.gradient = nil; [self setNeedsDisplay:YES]; } @@ -84,7 +88,7 @@ return; } - [(gradient?: (gradient = [[NSGradient alloc] initWithColorsAndLocations: + [(self.gradient?: (self.gradient = [[NSGradient alloc] initWithColorsAndLocations: self.startingColor, (CGFloat)0.f, [self.startingColor blendedColorWithFraction:0.5f ofColor:self.endingColor], self.ratio, self.endingColor, (CGFloat)1.f, nil])) diff --git a/platform-darwin/Source/Mac/MPMacAppDelegate.h b/platform-darwin/Source/Mac/MPMacAppDelegate.h index 4f664f65..1b82f7ec 100644 --- a/platform-darwin/Source/Mac/MPMacAppDelegate.h +++ b/platform-darwin/Source/Mac/MPMacAppDelegate.h @@ -18,13 +18,13 @@ #import #import "MPAppDelegate_Shared.h" -#import "MPPasswordWindowController.h" +#import "MPSitesWindowController.h" #import "MPInitialWindowController.h" @interface MPMacAppDelegate : MPAppDelegate_Shared @property(nonatomic, strong) NSStatusItem *statusView; -@property(nonatomic, strong) MPPasswordWindowController *passwordWindowController; +@property(nonatomic, strong) MPSitesWindowController *sitesWindowController; @property(nonatomic, strong) MPInitialWindowController *initialWindowController; @property(nonatomic, weak) IBOutlet NSMenuItem *lockItem; @property(nonatomic, weak) IBOutlet NSMenuItem *showItem; diff --git a/platform-darwin/Source/Mac/MPMacAppDelegate.m b/platform-darwin/Source/Mac/MPMacAppDelegate.m index 1bd50449..04d73700 100644 --- a/platform-darwin/Source/Mac/MPMacAppDelegate.m +++ b/platform-darwin/Source/Mac/MPMacAppDelegate.m @@ -430,8 +430,8 @@ static OSStatus MPHotKeyHander(EventHandlerCallRef nextHandler, EventRef theEven - (IBAction)terminate:(id)sender { - [self.passwordWindowController close]; - self.passwordWindowController = nil; + [self.sitesWindowController close]; + self.sitesWindowController = nil; [NSApp terminate:nil]; } @@ -460,11 +460,11 @@ static OSStatus MPHotKeyHander(EventHandlerCallRef nextHandler, EventRef theEven prof_rewind( @"activeUserForMainThread" ); // Don't show window if we weren't already running (ie. if we haven't been activated before). - if (!self.passwordWindowController) - self.passwordWindowController = [[MPPasswordWindowController alloc] initWithWindowNibName:@"MPPasswordWindowController"]; + if (!self.sitesWindowController) + self.sitesWindowController = [[MPSitesWindowController alloc] initWithWindowNibName:@"MPSitesWindowController"]; prof_rewind( @"initWithWindow" ); - [self.passwordWindowController showWindow:self]; + [self.sitesWindowController showWindow:self]; prof_finish( @"showWindow" ); } @@ -604,7 +604,7 @@ static OSStatus MPHotKeyHander(EventHandlerCallRef nextHandler, EventRef theEven - (void)updateMenuItems { MPUserEntity *activeUser = [self activeUserForMainThread]; -// if (!(self.showItem.enabled = ![self.passwordWindowController.window isVisible])) { +// if (!(self.showItem.enabled = ![self.sitesWindowController.window isVisible])) { // self.showItem.title = @"Show (Showing)"; // self.showItem.toolTip = @"Master Password is already showing."; // } diff --git a/platform-darwin/Source/Mac/MPMacApplication.m b/platform-darwin/Source/Mac/MPMacApplication.m index 527de4f1..b11716b9 100644 --- a/platform-darwin/Source/Mac/MPMacApplication.m +++ b/platform-darwin/Source/Mac/MPMacApplication.m @@ -25,8 +25,7 @@ @end -@implementation MPMacApplication { -} +@implementation MPMacApplication - (void)sendEvent:(NSEvent *)event { diff --git a/platform-darwin/Source/Mac/MPMacConfig.h b/platform-darwin/Source/Mac/MPMacConfig.h index 3caf3db3..4b163d2c 100644 --- a/platform-darwin/Source/Mac/MPMacConfig.h +++ b/platform-darwin/Source/Mac/MPMacConfig.h @@ -1,10 +1,20 @@ +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. // -// MPMacConfig.h -// MasterPassword +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. // -// Created by Maarten Billemont on 02/01/12. -// Copyright (c) 2012 Lyndir. All rights reserved. +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. // +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== #import "MPConfig.h" diff --git a/platform-darwin/Source/Mac/MPMacConfig.m b/platform-darwin/Source/Mac/MPMacConfig.m index e0145679..e6512241 100644 --- a/platform-darwin/Source/Mac/MPMacConfig.m +++ b/platform-darwin/Source/Mac/MPMacConfig.m @@ -1,10 +1,20 @@ +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. // -// MPMacConfig.m -// MasterPassword +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. // -// Created by Maarten Billemont on 02/01/12. -// Copyright (c) 2012 Lyndir. All rights reserved. +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. // +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== @implementation MPMacConfig diff --git a/platform-darwin/Source/Mac/MPNoStateButton.h b/platform-darwin/Source/Mac/MPNoStateButton.h index 41250337..932c7d86 100644 --- a/platform-darwin/Source/Mac/MPNoStateButton.h +++ b/platform-darwin/Source/Mac/MPNoStateButton.h @@ -1,20 +1,20 @@ -/** - * Copyright Maarten Billemont (http://www.lhunath.com, lhunath@lyndir.com) - * - * See the enclosed file LICENSE for license information (LGPLv3). If you did - * not receive this file, see http://www.gnu.org/licenses/lgpl-3.0.txt - * - * @author Maarten Billemont - * @license http://www.gnu.org/licenses/lgpl-3.0.txt - */ - +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. // -// MPNoStateButton.h -// MPNoStateButton +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. // -// Created by lhunath on 14-10-27. -// Copyright, lhunath (Maarten Billemont) 2014. All rights reserved. +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. // +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== #import diff --git a/platform-darwin/Source/Mac/MPNoStateButton.m b/platform-darwin/Source/Mac/MPNoStateButton.m index 54a25566..369f576e 100644 --- a/platform-darwin/Source/Mac/MPNoStateButton.m +++ b/platform-darwin/Source/Mac/MPNoStateButton.m @@ -1,25 +1,24 @@ -/** - * Copyright Maarten Billemont (http://www.lhunath.com, lhunath@lyndir.com) - * - * See the enclosed file LICENSE for license information (LGPLv3). If you did - * not receive this file, see http://www.gnu.org/licenses/lgpl-3.0.txt - * - * @author Maarten Billemont - * @license http://www.gnu.org/licenses/lgpl-3.0.txt - */ - +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. // -// MPNoStateButton.h -// MPNoStateButton +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. // -// Created by lhunath on 14-10-27. -// Copyright, lhunath (Maarten Billemont) 2014. All rights reserved. +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. // +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== #import "MPNoStateButton.h" -@implementation MPNoStateButtonCell { -} +@implementation MPNoStateButtonCell - (void)setState:(NSInteger)state { diff --git a/platform-darwin/Source/Mac/MPPasswordWindow.h b/platform-darwin/Source/Mac/MPPasswordWindow.h deleted file mode 100644 index 7219fc04..00000000 --- a/platform-darwin/Source/Mac/MPPasswordWindow.h +++ /dev/null @@ -1,23 +0,0 @@ -/** - * Copyright Maarten Billemont (http://www.lhunath.com, lhunath@lyndir.com) - * - * See the enclosed file LICENSE for license information (LGPLv3). If you did - * not receive this file, see http://www.gnu.org/licenses/lgpl-3.0.txt - * - * @author Maarten Billemont - * @license http://www.gnu.org/licenses/lgpl-3.0.txt - */ - -// -// MPPasswordWindow.h -// MPPasswordWindow -// -// Created by lhunath on 2014-06-19. -// Copyright, lhunath (Maarten Billemont) 2014. All rights reserved. -// - -#import - -@interface MPPasswordWindow : NSWindow - -@end diff --git a/platform-darwin/Source/Mac/MPPasswordWindow.m b/platform-darwin/Source/Mac/MPPasswordWindow.m deleted file mode 100644 index be822bea..00000000 --- a/platform-darwin/Source/Mac/MPPasswordWindow.m +++ /dev/null @@ -1,49 +0,0 @@ -/** - * Copyright Maarten Billemont (http://www.lhunath.com, lhunath@lyndir.com) - * - * See the enclosed file LICENSE for license information (LGPLv3). If you did - * not receive this file, see http://www.gnu.org/licenses/lgpl-3.0.txt - * - * @author Maarten Billemont - * @license http://www.gnu.org/licenses/lgpl-3.0.txt - */ - -// -// MPPasswordWindow.h -// MPPasswordWindow -// -// Created by lhunath on 2014-06-19. -// Copyright, lhunath (Maarten Billemont) 2014. All rights reserved. -// - -#import "MPPasswordWindow.h" - -@implementation MPPasswordWindow - -#pragma mark - Life - -- (BOOL)canBecomeKeyWindow { - - return YES; -} - -#pragma mark - State - -- (void)update { - - if ([[MPMacConfig get].fullScreen boolValue]) { - [self setLevel:NSScreenSaverWindowLevel]; - [self setFrame:self.screen.frame display:YES]; - } - else if (self.level != NSNormalWindowLevel) { - [self setLevel:NSNormalWindowLevel]; - [self setFrame:NSMakeRect( 0, 0, 640, 600 ) display:NO]; - [self center]; - } - - [super update]; -} - -#pragma mark - Private - -@end diff --git a/platform-darwin/Source/Mac/MPPasswordWindowController.xib b/platform-darwin/Source/Mac/MPPasswordWindowController.xib index cf04e138..d59357de 100644 --- a/platform-darwin/Source/Mac/MPPasswordWindowController.xib +++ b/platform-darwin/Source/Mac/MPPasswordWindowController.xib @@ -7,7 +7,7 @@ - + @@ -26,7 +26,7 @@ - + diff --git a/platform-darwin/Source/Mac/MPSiteModel.h b/platform-darwin/Source/Mac/MPSiteModel.h index 47b2e5ac..fabe3794 100644 --- a/platform-darwin/Source/Mac/MPSiteModel.h +++ b/platform-darwin/Source/Mac/MPSiteModel.h @@ -17,9 +17,9 @@ //============================================================================== #import -#import "MPSiteEntity.h" +#import "MPSiteEntity+CoreDataClass.h" #import "MPAlgorithm.h" -#import "MPUserEntity.h" +#import "MPUserEntity+CoreDataClass.h" @class MPSiteEntity; diff --git a/platform-darwin/Source/Mac/MPSiteModel.m b/platform-darwin/Source/Mac/MPSiteModel.m index 59eb674c..a6dfd8b7 100644 --- a/platform-darwin/Source/Mac/MPSiteModel.m +++ b/platform-darwin/Source/Mac/MPSiteModel.m @@ -17,16 +17,19 @@ //============================================================================== #import "MPSiteModel.h" -#import "MPSiteEntity.h" #import "MPEntities.h" #import "MPAppDelegate_Shared.h" #import "MPAppDelegate_Store.h" #import "MPMacAppDelegate.h" -@implementation MPSiteModel { - NSManagedObjectID *_entityOID; - BOOL _initialized; -} +@interface MPSiteModel() + +@property(nonatomic, strong) NSManagedObjectID *entityOID; +@property(nonatomic) BOOL initialized; + +@end + +@implementation MPSiteModel - (instancetype)initWithEntity:(MPSiteEntity *)entity fuzzyGroups:(NSArray *)fuzzyGroups { @@ -34,7 +37,7 @@ return nil; [self setEntity:entity fuzzyGroups:fuzzyGroups]; - _initialized = YES; + self.initialized = YES; return self; } @@ -45,16 +48,16 @@ return nil; [self setTransientSiteName:siteName forUser:user]; - _initialized = YES; + self.initialized = YES; return self; } - (void)setEntity:(MPSiteEntity *)entity fuzzyGroups:(NSArray *)fuzzyGroups { - if ([_entityOID isEqual:entity.permanentObjectID]) + if ([self.entityOID isEqual:entity.permanentObjectID]) return; - _entityOID = entity.permanentObjectID; + self.entityOID = entity.permanentObjectID; NSString *siteName = entity.name; NSMutableAttributedString *attributedSiteName = [[NSMutableAttributedString alloc] initWithString:siteName]; @@ -87,7 +90,7 @@ - (void)setTransientSiteName:(NSString *)siteName forUser:(MPUserEntity *)user { - _entityOID = nil; + self.entityOID = nil; NSMutableParagraphStyle *paragraphStyle = [NSMutableParagraphStyle new]; paragraphStyle.alignment = NSCenterTextAlignment; @@ -109,11 +112,11 @@ - (MPSiteEntity *)entityInContext:(NSManagedObjectContext *)moc { - if (!_entityOID) + if (!self.entityOID) return nil; NSError *error; - MPSiteEntity *entity = (MPSiteEntity *)[moc existingObjectWithID:_entityOID error:&error]; + MPSiteEntity *entity = (MPSiteEntity *)[moc existingObjectWithID:self.entityOID error:&error]; if (!entity) MPError( error, @"Couldn't retrieve active site." ); @@ -122,15 +125,15 @@ - (void)setCounter:(NSUInteger)counter { - if (counter == _counter) + if (self.counter == counter) return; _counter = counter; - if (!_initialized) + if (!self.initialized) // This wasn't a change to the entity. return; - if (_entityOID) + if (self.entityOID) [MPMacAppDelegate managedObjectContextPerformBlock:^(NSManagedObjectContext *context) { MPSiteEntity *entity = [self entityInContext:context]; if ([entity isKindOfClass:[MPGeneratedSiteEntity class]]) { @@ -146,15 +149,15 @@ - (void)setLoginGenerated:(BOOL)loginGenerated { - if (loginGenerated == _loginGenerated) + if (self.loginGenerated == loginGenerated) return; _loginGenerated = loginGenerated; - if (!_initialized) + if (!self.initialized) // This wasn't a change to the entity. return; - if (_entityOID) + if (self.entityOID) [MPMacAppDelegate managedObjectContextPerformBlock:^(NSManagedObjectContext *context) { MPSiteEntity *entity = [self entityInContext:context]; entity.loginGenerated = loginGenerated; @@ -179,7 +182,7 @@ self.algorithm = MPAlgorithmForVersion( algorithmVersion )?: self.algorithm; [self didChangeValueForKey:@"outdated"]; - if (_entityOID) + if (self.entityOID) [MPMacAppDelegate managedObjectContextPerformBlock:^(NSManagedObjectContext *context) { MPSiteEntity *entity = [self entityInContext:context]; entity.algorithm = self.algorithm; @@ -193,7 +196,7 @@ - (void)setQuestion:(NSString *)question { - if ([question isEqualToString:_question]) + if ([self.question isEqualToString:question]) return; _question = question; @@ -217,14 +220,14 @@ - (BOOL)transient { - return _entityOID == nil; + return self.entityOID == nil; } - (void)updateContent { - if (_entityOID) + if (self.entityOID) [MPMacAppDelegate managedObjectContextPerformBlock:^(NSManagedObjectContext *context) { - [self updateContent:[MPSiteEntity existingObjectWithID:_entityOID inContext:context]]; + [self updateContent:[MPSiteEntity existingObjectWithID:self.entityOID inContext:context]]; }]; else diff --git a/platform-darwin/Source/Mac/MPSitesTableView.h b/platform-darwin/Source/Mac/MPSitesTableView.h index e141dcb5..e45b3af1 100644 --- a/platform-darwin/Source/Mac/MPSitesTableView.h +++ b/platform-darwin/Source/Mac/MPSitesTableView.h @@ -18,10 +18,10 @@ #import -@class MPPasswordWindowController; +@class MPSitesWindowController; @interface MPSitesTableView : NSTableView -@property(nonatomic, weak) MPPasswordWindowController *controller; +@property(nonatomic, weak) MPSitesWindowController *controller; @end diff --git a/platform-darwin/Source/Mac/MPSitesTableView.m b/platform-darwin/Source/Mac/MPSitesTableView.m index b3ebe08a..da3d2149 100644 --- a/platform-darwin/Source/Mac/MPSitesTableView.m +++ b/platform-darwin/Source/Mac/MPSitesTableView.m @@ -17,7 +17,7 @@ //============================================================================== #import "MPSitesTableView.h" -#import "MPPasswordWindowController.h" +#import "MPSitesWindowController.h" @implementation MPSitesTableView diff --git a/platform-darwin/Source/Mac/MPSitesWindow.h b/platform-darwin/Source/Mac/MPSitesWindow.h new file mode 100644 index 00000000..71011ac7 --- /dev/null +++ b/platform-darwin/Source/Mac/MPSitesWindow.h @@ -0,0 +1,23 @@ +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. +// +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. +// +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== + +#import + +@interface MPSitesWindow : NSWindow + +@end diff --git a/platform-darwin/Source/Mac/MPSitesWindow.m b/platform-darwin/Source/Mac/MPSitesWindow.m new file mode 100644 index 00000000..d764daf3 --- /dev/null +++ b/platform-darwin/Source/Mac/MPSitesWindow.m @@ -0,0 +1,49 @@ +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. +// +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. +// +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== + +#import "MPSitesWindow.h" + +@implementation MPSitesWindow + +#pragma mark - Life + +- (BOOL)canBecomeKeyWindow { + + return YES; +} + +#pragma mark - State + +- (void)update { + + if ([[MPMacConfig get].fullScreen boolValue]) { + [self setLevel:NSScreenSaverWindowLevel]; + [self setFrame:self.screen.frame display:YES]; + } + else if (self.level != NSNormalWindowLevel) { + [self setLevel:NSNormalWindowLevel]; + [self setFrame:NSMakeRect( 0, 0, 640, 600 ) display:NO]; + [self center]; + } + + [super update]; +} + +#pragma mark - Private + +@end diff --git a/platform-darwin/Source/Mac/MPPasswordWindowController.h b/platform-darwin/Source/Mac/MPSitesWindowController.h similarity index 56% rename from platform-darwin/Source/Mac/MPPasswordWindowController.h rename to platform-darwin/Source/Mac/MPSitesWindowController.h index e2259815..24bc9f0d 100644 --- a/platform-darwin/Source/Mac/MPPasswordWindowController.h +++ b/platform-darwin/Source/Mac/MPSitesWindowController.h @@ -1,29 +1,29 @@ -/** -* Copyright Maarten Billemont (http://www.lhunath.com, lhunath@lyndir.com) -* -* See the enclosed file LICENSE for license information (LGPLv3). If you did -* not receive this file, see http://www.gnu.org/licenses/lgpl-3.0.txt -* -* @author Maarten Billemont -* @license http://www.gnu.org/licenses/lgpl-3.0.txt -*/ - +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. // -// MPPasswordWindowController.h -// MPPasswordWindowController +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. // -// Created by lhunath on 2014-06-18. -// Copyright, lhunath (Maarten Billemont) 2014. All rights reserved. +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. // +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== #import #import "MPSiteModel.h" #import "MPSitesTableView.h" -#import "MPPasswordWindow.h" +#import "MPSitesWindow.h" @class MPMacAppDelegate; -@interface MPPasswordWindowController : NSWindowController +@interface MPSitesWindowController : NSWindowController @property(nonatomic) NSMutableArray *sites; @property(nonatomic) NSString *masterPassword; diff --git a/platform-darwin/Source/Mac/MPPasswordWindowController.m b/platform-darwin/Source/Mac/MPSitesWindowController.m similarity index 99% rename from platform-darwin/Source/Mac/MPPasswordWindowController.m rename to platform-darwin/Source/Mac/MPSitesWindowController.m index 6ffe74c7..9297ee1e 100644 --- a/platform-darwin/Source/Mac/MPPasswordWindowController.m +++ b/platform-darwin/Source/Mac/MPSitesWindowController.m @@ -17,18 +17,18 @@ //============================================================================== #import -#import "MPPasswordWindowController.h" +#import "MPSitesWindowController.h" #import "MPMacAppDelegate.h" #import "MPAppDelegate_Store.h" #import "MPAppDelegate_Key.h" -@interface MPPasswordWindowController() +@interface MPSitesWindowController() @property(nonatomic, strong) CAGradientLayer *siteGradient; @end -@implementation MPPasswordWindowController +@implementation MPSitesWindowController #pragma mark - Life @@ -67,8 +67,8 @@ PearlAddNotificationObserver( MPSignedOutNotification, nil, [NSOperationQueue mainQueue], ^(id host, NSNotification *note) { [self updateUser]; } ); - [self observeKeyPath:@"sitesController.selection" withBlock:^(id from, id to, NSKeyValueChange cause, id _self) { - [_self updateSelection]; + [self observeKeyPath:@"sitesController.selection" withBlock:^(id from, id to, NSKeyValueChange cause, id self) { + [self updateSelection]; }]; prof_rewind( @"observers" ); diff --git a/platform-darwin/Source/Mac/MasterPassword-Info.plist b/platform-darwin/Source/Mac/MasterPassword-Info.plist index 9ba1fb3a..173f4d6c 100644 --- a/platform-darwin/Source/Mac/MasterPassword-Info.plist +++ b/platform-darwin/Source/Mac/MasterPassword-Info.plist @@ -1,109 +1,109 @@ - - ATSApplicationFontsPath - . - CFBundleDevelopmentRegion - en - CFBundleDisplayName - Master Password - CFBundleDocumentTypes - - - CFBundleTypeExtensions - - mpsites - - CFBundleTypeIconFile - - CFBundleTypeIconFiles - - CFBundleTypeMIMETypes - - text/plain - - CFBundleTypeName - Master Password sites - CFBundleTypeRole - Viewer - LSHandlerRank - Owner - LSItemContentTypes - - com.lyndir.masterpassword.sites - - LSTypeIsPackage - 0 - - - CFBundleExecutable - ${EXECUTABLE_NAME} - CFBundleIdentifier - $(PRODUCT_BUNDLE_IDENTIFIER) - CFBundleInfoDictionaryVersion - 6.0 - CFBundleName - Master Password - CFBundlePackageType - APPL - CFBundleShortVersionString - [auto] - CFBundleSignature - ???? - CFBundleVersion - [auto] - Fabric - - APIKey - 0d10c90776f5ef5acd01ddbeaca9a6cba4814560 - Kits - - - KitInfo - - KitName - Crashlytics - - - - LSApplicationCategoryType - public.app-category.productivity - LSMinimumSystemVersion - ${MACOSX_DEPLOYMENT_TARGET} - LSUIElement - - NSHumanReadableCopyright - Copyright © 2011-2014 Lyndir - NSMainNibFile - MainMenu - NSPrincipalClass - MPMacApplication - UTExportedTypeDeclarations - - - UTTypeConformsTo - - public.utf8-plain-text - - UTTypeDescription - Master Password sites - UTTypeIconFile - - UTTypeIdentifier - com.lyndir.masterpassword.sites - UTTypeSize320IconFile - - UTTypeSize64IconFile - - UTTypeTagSpecification - - public.filename-extension - - mpsites - - - - - + + ATSApplicationFontsPath + . + CFBundleDevelopmentRegion + en + CFBundleDisplayName + Master Password + CFBundleDocumentTypes + + + CFBundleTypeExtensions + + mpsites + + CFBundleTypeIconFile + + CFBundleTypeIconFiles + + CFBundleTypeMIMETypes + + text/plain + + CFBundleTypeName + Master Password sites + CFBundleTypeRole + Viewer + LSHandlerRank + Owner + LSItemContentTypes + + com.lyndir.masterpassword.sites + + LSTypeIsPackage + 0 + + + CFBundleExecutable + ${EXECUTABLE_NAME} + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + Master Password + CFBundlePackageType + APPL + CFBundleShortVersionString + [auto] + CFBundleSignature + ???? + CFBundleVersion + [auto] + Fabric + + APIKey + 0d10c90776f5ef5acd01ddbeaca9a6cba4814560 + Kits + + + KitInfo + + KitName + Crashlytics + + + + LSApplicationCategoryType + public.app-category.productivity + LSMinimumSystemVersion + ${MACOSX_DEPLOYMENT_TARGET} + LSUIElement + + NSHumanReadableCopyright + Copyright © 2011-2014 Lyndir + NSMainNibFile + MainMenu + NSPrincipalClass + MPMacApplication + UTExportedTypeDeclarations + + + UTTypeConformsTo + + public.utf8-plain-text + + UTTypeDescription + Master Password sites + UTTypeIconFile + + UTTypeIdentifier + com.lyndir.masterpassword.sites + UTTypeSize320IconFile + + UTTypeSize64IconFile + + UTTypeTagSpecification + + public.filename-extension + + mpsites + + + + + diff --git a/platform-darwin/Source/Mac/MasterPassword-Mac-LoginHelper/MasterPassword-Mac-LoginHelper/MasterPassword-Mac-LoginHelper-Info.plist b/platform-darwin/Source/Mac/MasterPassword-Mac-LoginHelper/MasterPassword-Mac-LoginHelper/MasterPassword-Mac-LoginHelper-Info.plist index 30988ef6..fde7e715 100644 --- a/platform-darwin/Source/Mac/MasterPassword-Mac-LoginHelper/MasterPassword-Mac-LoginHelper/MasterPassword-Mac-LoginHelper-Info.plist +++ b/platform-darwin/Source/Mac/MasterPassword-Mac-LoginHelper/MasterPassword-Mac-LoginHelper/MasterPassword-Mac-LoginHelper-Info.plist @@ -1,34 +1,34 @@ - - CFBundleDevelopmentRegion - en - CFBundleExecutable - ${EXECUTABLE_NAME} - CFBundleIconFile - - CFBundleIdentifier - $(PRODUCT_BUNDLE_IDENTIFIER) - CFBundleInfoDictionaryVersion - 6.0 - CFBundleName - ${PRODUCT_NAME} - CFBundlePackageType - APPL - CFBundleShortVersionString - 1.0 - CFBundleSignature - ???? - CFBundleVersion - 1 - LSBackgroundOnly - - LSMinimumSystemVersion - ${MACOSX_DEPLOYMENT_TARGET} - NSHumanReadableCopyright - Copyright © 2013 Maarten Billemont. All rights reserved. - NSPrincipalClass - NSApplication - + + CFBundleDevelopmentRegion + en + CFBundleExecutable + ${EXECUTABLE_NAME} + CFBundleIconFile + + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + ${PRODUCT_NAME} + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + 1 + LSBackgroundOnly + + LSMinimumSystemVersion + ${MACOSX_DEPLOYMENT_TARGET} + NSHumanReadableCopyright + Copyright © 2013 Maarten Billemont. All rights reserved. + NSPrincipalClass + NSApplication + diff --git a/platform-darwin/Source/iOS/MPAnswersViewController.m b/platform-darwin/Source/iOS/MPAnswersViewController.m index 363327e3..59981825 100644 --- a/platform-darwin/Source/iOS/MPAnswersViewController.m +++ b/platform-darwin/Source/iOS/MPAnswersViewController.m @@ -23,12 +23,12 @@ @interface MPAnswersViewController() +@property(nonatomic, strong) NSManagedObjectID *siteOID; +@property(nonatomic) BOOL multiple; + @end -@implementation MPAnswersViewController { - NSManagedObjectID *_siteOID; - BOOL _multiple; -} +@implementation MPAnswersViewController #pragma mark - Life @@ -80,21 +80,21 @@ - (void)setSite:(MPSiteEntity *)site { - _siteOID = site.permanentObjectID; - _multiple = [site.questions count] > 0; + self.siteOID = site.permanentObjectID; + self.multiple = [site.questions count] > 0; [self.tableView reloadData]; [self updateAnimated:NO]; } - (void)setMultiple:(BOOL)multiple animated:(BOOL)animated { - _multiple = multiple; + self.multiple = multiple; [self updateAnimated:animated]; } - (MPSiteEntity *)siteInContext:(NSManagedObjectContext *)context { - return [MPSiteEntity existingObjectWithID:_siteOID inContext:context]; + return [MPSiteEntity existingObjectWithID:self.siteOID inContext:context]; } #pragma mark - UITableViewDelegate @@ -109,7 +109,7 @@ if (section == 0) return 3; - if (!_multiple) + if (!self.multiple) return 0; return [[self siteInContext:[MPiOSAppDelegate managedObjectContextForMainThreadIfReady]].questions count] + 1; @@ -128,7 +128,7 @@ return [MPSendAnswersCell dequeueCellFromTableView:tableView indexPath:indexPath]; if (indexPath.item == 2) { MPMultipleAnswersCell *cell = [MPMultipleAnswersCell dequeueCellFromTableView:tableView indexPath:indexPath]; - cell.accessoryType = _multiple? UITableViewCellAccessoryCheckmark: UITableViewCellAccessoryNone; + cell.accessoryType = self.multiple? UITableViewCellAccessoryCheckmark: UITableViewCellAccessoryNone; return cell; } Throw( @"Unsupported row index: %@", indexPath ); @@ -165,10 +165,10 @@ [self copyAnswer:((MPGlobalAnswersCell *)cell).answerField.text]; else if ([cell isKindOfClass:[MPMultipleAnswersCell class]]) { - if (!_multiple) + if (!self.multiple) [self setMultiple:YES animated:YES]; - else if (_multiple) { + else if (self.multiple) { if (![site.questions count]) [self setMultiple:NO animated:YES]; @@ -194,7 +194,7 @@ else if ([cell isKindOfClass:[MPSendAnswersCell class]]) { NSString *body; - if (!_multiple) { + if (!self.multiple) { NSObject *answer = [site resolveSiteAnswerUsingKey:[MPiOSAppDelegate get].key]; body = strf( @"Master Password generated the following security answer for your site: %@\n\n" @"%@\n" @@ -245,7 +245,7 @@ PearlMainQueue( ^{ UITableViewCell *multipleAnswersCell = [self.tableView cellForRowAtIndexPath:[NSIndexPath indexPathForItem:2 inSection:0]]; - multipleAnswersCell.accessoryType = _multiple? UITableViewCellAccessoryCheckmark: UITableViewCellAccessoryNone; + multipleAnswersCell.accessoryType = self.multiple? UITableViewCellAccessoryCheckmark: UITableViewCellAccessoryNone; [[NSOperationQueue mainQueue] addOperationWithBlock:^{ [self.tableView reloadSections:[NSIndexSet indexSetWithIndex:1] withRowAnimation:UITableViewRowAnimationAutomatic]; @@ -291,19 +291,23 @@ @end -@implementation MPAnswersQuestionCell { - NSManagedObjectID *_siteOID; - NSManagedObjectID *_questionOID; - __weak MPAnswersViewController *_answersVC; -} +@interface MPAnswersQuestionCell() + +@property(nonatomic, strong) NSManagedObjectID *siteOID; +@property(nonatomic, strong) NSManagedObjectID *questionOID; +@property(nonatomic, weak) MPAnswersViewController *answersVC; + +@end + +@implementation MPAnswersQuestionCell #pragma mark - State - (void)setQuestion:(MPSiteQuestionEntity *)question forSite:(MPSiteEntity *)site inVC:(MPAnswersViewController *)answersVC { - _siteOID = site.permanentObjectID; - _questionOID = question.permanentObjectID; - _answersVC = answersVC; + self.siteOID = site.permanentObjectID; + self.questionOID = question.permanentObjectID; + self.answersVC = answersVC; [self updateAnswerForQuestion:question ofSite:site]; } @@ -322,8 +326,8 @@ NSString *keyword = textField.text; [MPiOSAppDelegate managedObjectContextPerformBlock:^(NSManagedObjectContext *context) { BOOL didAddQuestionObject = NO; - MPSiteEntity *site = [MPSiteEntity existingObjectWithID:_siteOID inContext:context]; - MPSiteQuestionEntity *question = [MPSiteQuestionEntity existingObjectWithID:_questionOID inContext:context]; + MPSiteEntity *site = [MPSiteEntity existingObjectWithID:self.siteOID inContext:context]; + MPSiteQuestionEntity *question = [MPSiteQuestionEntity existingObjectWithID:self.questionOID inContext:context]; if (!question) { didAddQuestionObject = YES; [site addQuestionsObject:question = [MPSiteQuestionEntity insertNewObjectInContext:context]]; @@ -333,11 +337,11 @@ question.keyword = keyword; if ([context saveToStore]) { - _questionOID = question.permanentObjectID; + self.questionOID = question.permanentObjectID; [self updateAnswerForQuestion:question ofSite:site]; if (didAddQuestionObject) - [_answersVC didAddQuestion:question toSite:site]; + [self.answersVC didAddQuestion:question toSite:site]; } }]; } diff --git a/platform-darwin/Source/iOS/MPAppSettingsViewController.m b/platform-darwin/Source/iOS/MPAppSettingsViewController.m index e18d99c7..5b6aa8ad 100644 --- a/platform-darwin/Source/iOS/MPAppSettingsViewController.m +++ b/platform-darwin/Source/iOS/MPAppSettingsViewController.m @@ -19,8 +19,7 @@ #import "MPAppSettingsViewController.h" #import "UIColor+Expanded.h" -@implementation MPAppSettingsViewController { -} +@implementation MPAppSettingsViewController - (void)viewWillAppear:(BOOL)animated { diff --git a/platform-darwin/Source/iOS/MPAvatarCell.m b/platform-darwin/Source/iOS/MPAvatarCell.m index 433c3527..79d803d0 100644 --- a/platform-darwin/Source/iOS/MPAvatarCell.m +++ b/platform-darwin/Source/iOS/MPAvatarCell.m @@ -32,11 +32,12 @@ const long MPAvatarAdd = 10000; @property(strong, nonatomic) IBOutlet NSLayoutConstraint *avatarRaisedConstraint; @property(strong, nonatomic) IBOutlet NSLayoutConstraint *keyboardHeightConstraint; +@property(nonatomic, strong) CAAnimationGroup *targetedShadowAnimation; + +@property(assign, nonatomic, readwrite) BOOL newUser; @end -@implementation MPAvatarCell { - CAAnimationGroup *_targetedShadowAnimation; -} +@implementation MPAvatarCell + (NSString *)reuseIdentifier { @@ -57,14 +58,14 @@ const long MPAvatarAdd = 10000; self.avatarImageView.layer.masksToBounds = NO; self.avatarImageView.backgroundColor = [UIColor clearColor]; - [self observeKeyPath:@"bounds" withBlock:^(id from, id to, NSKeyValueChange cause, MPAvatarCell *_self) { - _self.contentView.frame = _self.bounds; + [self observeKeyPath:@"bounds" withBlock:^(id from, id to, NSKeyValueChange cause, MPAvatarCell *self) { + self.contentView.frame = self.bounds; }]; - [self observeKeyPath:@"selected" withBlock:^(id from, id to, NSKeyValueChange cause, MPAvatarCell *_self) { - [_self updateAnimated:_self.superview != nil]; + [self observeKeyPath:@"selected" withBlock:^(id from, id to, NSKeyValueChange cause, MPAvatarCell *self) { + [self updateAnimated:self.superview != nil]; }]; - [self observeKeyPath:@"highlighted" withBlock:^(id from, id to, NSKeyValueChange cause, MPAvatarCell *_self) { - [_self updateAnimated:_self.superview != nil]; + [self observeKeyPath:@"highlighted" withBlock:^(id from, id to, NSKeyValueChange cause, MPAvatarCell *self) { + [self updateAnimated:self.superview != nil]; }]; PearlAddNotificationObserver( UIKeyboardWillShowNotification, nil, [NSOperationQueue mainQueue], ^(MPAvatarCell *self, NSNotification *note) { @@ -85,9 +86,9 @@ const long MPAvatarAdd = 10000; pulseShadowOpacityAnimation.autoreverses = YES; pulseShadowOpacityAnimation.repeatCount = MAXFLOAT; - _targetedShadowAnimation = [CAAnimationGroup new]; - _targetedShadowAnimation.animations = @[ toShadowOpacityAnimation, pulseShadowOpacityAnimation ]; - _targetedShadowAnimation.duration = MAXFLOAT; + self.targetedShadowAnimation = [CAAnimationGroup new]; + self.targetedShadowAnimation.animations = @[ toShadowOpacityAnimation, pulseShadowOpacityAnimation ]; + self.targetedShadowAnimation.duration = MAXFLOAT; self.avatarImageView.layer.shadowColor = [UIColor whiteColor].CGColor; self.avatarImageView.layer.shadowOffset = CGSizeZero; } @@ -96,10 +97,10 @@ const long MPAvatarAdd = 10000; [super prepareForReuse]; - _newUser = NO; - _visibility = 0; - _mode = MPAvatarModeLowered; - _spinnerActive = NO; + self.newUser = NO; + self.visibility = 0; + self.mode = MPAvatarModeLowered; + self.spinnerActive = NO; } - (void)dealloc { @@ -114,13 +115,13 @@ const long MPAvatarAdd = 10000; _avatar = avatar == MPAvatarAdd? MPAvatarAdd: (avatar + MPAvatarCount) % MPAvatarCount; - if (_avatar == MPAvatarAdd) { + if (self.avatar == MPAvatarAdd) { self.avatarImageView.image = [UIImage imageNamed:@"avatar-add"]; self.name = strl( @"New User" ); - _newUser = YES; + self.newUser = YES; } else - self.avatarImageView.image = [UIImage imageNamed:strf( @"avatar-%lu", (unsigned long)_avatar )]; + self.avatarImageView.image = [UIImage imageNamed:strf( @"avatar-%lu", (unsigned long)self.avatar )]; } - (NSString *)name { @@ -140,7 +141,7 @@ const long MPAvatarAdd = 10000; - (void)setVisibility:(CGFloat)visibility animated:(BOOL)animated { - if (visibility == _visibility) + if (self.visibility == visibility) return; _visibility = visibility; @@ -161,7 +162,7 @@ const long MPAvatarAdd = 10000; - (void)setMode:(MPAvatarMode)mode animated:(BOOL)animated { - if (mode == _mode) + if (self.mode == mode) return; _mode = mode; @@ -175,7 +176,7 @@ const long MPAvatarAdd = 10000; - (void)setSpinnerActive:(BOOL)spinnerActive animated:(BOOL)animated { - if (_spinnerActive == spinnerActive) + if (self.spinnerActive == spinnerActive) return; _spinnerActive = spinnerActive; @@ -284,7 +285,7 @@ const long MPAvatarAdd = 10000; if (self.mode == MPAvatarModeRaisedAndMinimized) [self.avatarImageView.layer removeAnimationForKey:@"targetedShadow"]; else if (![self.avatarImageView.layer animationForKey:@"targetedShadow"]) - [self.avatarImageView.layer addAnimation:_targetedShadowAnimation forKey:@"targetedShadow"]; + [self.avatarImageView.layer addAnimation:self.targetedShadowAnimation forKey:@"targetedShadow"]; // Avatar selection and spinner. if (self.mode != MPAvatarModeRaisedAndMinimized && (self.selected || self.highlighted) && !self.spinnerActive) diff --git a/platform-darwin/Source/iOS/MPCell.m b/platform-darwin/Source/iOS/MPCell.m index 5199f13b..29924960 100644 --- a/platform-darwin/Source/iOS/MPCell.m +++ b/platform-darwin/Source/iOS/MPCell.m @@ -18,7 +18,6 @@ #import "MPCell.h" -@implementation MPCell { -} +@implementation MPCell @end diff --git a/platform-darwin/Source/iOS/MPCoachmarkViewController.m b/platform-darwin/Source/iOS/MPCoachmarkViewController.m index 97386b0a..a37d0c7d 100644 --- a/platform-darwin/Source/iOS/MPCoachmarkViewController.m +++ b/platform-darwin/Source/iOS/MPCoachmarkViewController.m @@ -18,17 +18,23 @@ #import "MPCoachmarkViewController.h" -@implementation MPCoachmarkViewController { - NSArray *_views; - NSUInteger _nextView; - __weak NSTimer *_viewTimer; -} +@interface MPCoachmarkViewController() + +@property(nonatomic, strong) NSArray *views; +@property(nonatomic) NSUInteger nextView; +@property(nonatomic, weak) NSTimer *viewTimer; + +@end + +@implementation MPCoachmarkViewController - (void)viewDidLoad { [super viewDidLoad]; - _views = @[ self.view0, self.view1, self.view2, self.view3, self.view4, self.view5, self.view6, self.view7, self.view8, self.view9 ]; + self.views = @[ + self.view0, self.view1, self.view2, self.view3, self.view4, self.view5, self.view6, self.view7, self.view8, self.view9 + ]; } - (void)viewWillAppear:(BOOL)animated { @@ -37,8 +43,8 @@ self.viewProgress.visible = YES; self.viewProgress.progress = 0; - [_views makeObjectsPerformSelector:@selector( setVisible: ) withObject:@NO]; - _nextView = 0; + [self.views makeObjectsPerformSelector:@selector( setVisible: ) withObject:@NO]; + self.nextView = 0; } - (void)viewDidAppear:(BOOL)animated { @@ -46,23 +52,23 @@ [super viewDidAppear:animated]; [UIView animateWithDuration:0.3f animations:^{ - [_views[_nextView++] setVisible:YES]; + [self.views[self.nextView++] setVisible:YES]; }]; - _viewTimer = [NSTimer scheduledTimerWithTimeInterval:0.1 block:^(NSTimer *timer) { + self.viewTimer = [NSTimer scheduledTimerWithTimeInterval:0.1 block:^(NSTimer *timer) { self.viewProgress.progress += 1.0f / 50; if (self.viewProgress.progress == 1) [UIView animateWithDuration:0.3f animations:^{ self.viewProgress.progress = 0; - [_views[_nextView++] setVisible:YES]; + [self.views[self.nextView++] setVisible:YES]; - if (_nextView >= [_views count]) { - [_viewTimer invalidate]; + if (self.nextView >= [self.views count]) { + [self.viewTimer invalidate]; self.viewProgress.visible = NO; } }]; - } repeats:YES]; + } repeats:YES]; } - (UIStatusBarStyle)preferredStatusBarStyle { diff --git a/platform-darwin/Source/iOS/MPCombinedViewController.h b/platform-darwin/Source/iOS/MPCombinedViewController.h index 59851ac0..1d3d99bf 100644 --- a/platform-darwin/Source/iOS/MPCombinedViewController.h +++ b/platform-darwin/Source/iOS/MPCombinedViewController.h @@ -17,7 +17,7 @@ //============================================================================== #import "MPUsersViewController.h" -#import "MPPasswordsViewController.h" +#import "MPSitesViewController.h" #import "MPEmergencyViewController.h" typedef NS_ENUM( NSUInteger, MPCombinedMode ) { @@ -29,7 +29,7 @@ typedef NS_ENUM( NSUInteger, MPCombinedMode ) { @property(nonatomic) MPCombinedMode mode; @property(nonatomic, weak) MPUsersViewController *usersVC; -@property(nonatomic, weak) MPPasswordsViewController *passwordsVC; +@property(nonatomic, weak) MPSitesViewController *sitesVC; @property(nonatomic, weak) MPEmergencyViewController *emergencyVC; @end diff --git a/platform-darwin/Source/iOS/MPCombinedViewController.m b/platform-darwin/Source/iOS/MPCombinedViewController.m index 2720d5d1..31c9bc32 100644 --- a/platform-darwin/Source/iOS/MPCombinedViewController.m +++ b/platform-darwin/Source/iOS/MPCombinedViewController.m @@ -18,9 +18,9 @@ #import "MPCombinedViewController.h" #import "MPUsersViewController.h" -#import "MPPasswordsViewController.h" +#import "MPSitesViewController.h" #import "MPEmergencyViewController.h" -#import "MPPasswordsSegue.h" +#import "MPSitesSegue.h" @implementation MPCombinedViewController @@ -30,7 +30,7 @@ [super viewDidLoad]; - _mode = MPCombinedModeUserSelection; + self.mode = MPCombinedModeUserSelection; [self performSegueWithIdentifier:@"users" sender:self]; } @@ -67,12 +67,12 @@ if ([segue.identifier isEqualToString:@"users"]) self.usersVC = segue.destinationViewController; if ([segue.identifier isEqualToString:@"passwords"]) { - NSAssert( [segue isKindOfClass:[MPPasswordsSegue class]], @"passwords segue should be MPPasswordsSegue: %@", segue ); + NSAssert( [segue isKindOfClass:[MPSitesSegue class]], @"passwords segue should be MPSitesSegue: %@", segue ); NSAssert( [sender isKindOfClass:[NSDictionary class]], @"sender should be dictionary: %@", sender ); NSAssert( [[sender objectForKey:@"animated"] isKindOfClass:[NSNumber class]], @"sender should contain 'animated': %@", sender ); - [(MPPasswordsSegue *)segue setAnimated:[sender[@"animated"] boolValue]]; + [(MPSitesSegue *)segue setAnimated:[sender[@"animated"] boolValue]]; UIViewController *destinationVC = segue.destinationViewController; - _passwordsVC = [destinationVC isKindOfClass:[MPPasswordsViewController class]]? (MPPasswordsViewController *)destinationVC: nil; + self.sitesVC = [destinationVC isKindOfClass:[MPSitesViewController class]]? (MPSitesViewController *)destinationVC: nil; } if ([segue.identifier isEqualToString:@"emergency"]) self.emergencyVC = segue.destinationViewController; @@ -115,7 +115,7 @@ - (void)setMode:(MPCombinedMode)mode animated:(BOOL)animated { - if (_mode == mode && animated) + if (self.mode == mode && animated) return; _mode = mode; @@ -129,8 +129,8 @@ case MPCombinedModeUserSelection: { self.usersVC.view.userInteractionEnabled = YES; [self.usersVC setActive:YES animated:animated]; - if (_passwordsVC) { - MPPasswordsSegue *segue = [[MPPasswordsSegue alloc] initWithIdentifier:@"passwords" source:_passwordsVC destination:self]; + if (self.sitesVC) { + MPSitesSegue *segue = [[MPSitesSegue alloc] initWithIdentifier:@"passwords" source:self.sitesVC destination:self]; [self prepareForSegue:segue sender:@{ @"animated": @(animated) }]; [segue perform]; } diff --git a/platform-darwin/Source/iOS/MPEmergencyViewController.m b/platform-darwin/Source/iOS/MPEmergencyViewController.m index 613778d5..693cbff9 100644 --- a/platform-darwin/Source/iOS/MPEmergencyViewController.m +++ b/platform-darwin/Source/iOS/MPEmergencyViewController.m @@ -19,18 +19,22 @@ #import "MPEmergencyViewController.h" #import "MPEntities.h" -@implementation MPEmergencyViewController { - MPKey *_key; - NSOperationQueue *_emergencyKeyQueue; - NSOperationQueue *_emergencyPasswordQueue; -} +@interface MPEmergencyViewController() + +@property(nonatomic, strong) MPKey *key; +@property(nonatomic, strong) NSOperationQueue *emergencyKeyQueue; +@property(nonatomic, strong) NSOperationQueue *emergencyPasswordQueue; + +@end + +@implementation MPEmergencyViewController - (void)viewDidLoad { [super viewDidLoad]; - [_emergencyKeyQueue = [NSOperationQueue new] setMaxConcurrentOperationCount:1]; - [_emergencyPasswordQueue = [NSOperationQueue new] setMaxConcurrentOperationCount:1]; + [self.emergencyKeyQueue = [NSOperationQueue new] setMaxConcurrentOperationCount:1]; + [self.emergencyPasswordQueue = [NSOperationQueue new] setMaxConcurrentOperationCount:1]; self.view.backgroundColor = [UIColor clearColor]; self.dialogView.layer.cornerRadius = 5; @@ -117,12 +121,12 @@ [self.passwordButton setTitle:nil forState:UIControlStateNormal]; [self.activity startAnimating]; - [_emergencyKeyQueue cancelAllOperations]; - [_emergencyKeyQueue addOperationWithBlock:^{ + [self.emergencyKeyQueue cancelAllOperations]; + [self.emergencyKeyQueue addOperationWithBlock:^{ if ([masterPassword length] && [fullName length]) - _key = [[MPKey alloc] initForFullName:fullName withMasterPassword:masterPassword]; + self.key = [[MPKey alloc] initForFullName:fullName withMasterPassword:masterPassword]; else - _key = nil; + self.key = nil; PearlMainQueue( ^{ [self updatePassword]; @@ -139,11 +143,12 @@ [self.passwordButton setTitle:nil forState:UIControlStateNormal]; [self.activity startAnimating]; - [_emergencyPasswordQueue cancelAllOperations]; - [_emergencyPasswordQueue addOperationWithBlock:^{ + [self.emergencyPasswordQueue cancelAllOperations]; + [self.emergencyPasswordQueue addOperationWithBlock:^{ NSString *sitePassword = nil; - if (_key && [siteName length]) - sitePassword = [MPAlgorithmDefault generatePasswordForSiteNamed:siteName ofType:siteType withCounter:siteCounter usingKey:_key]; + if (self.key && [siteName length]) + sitePassword = [MPAlgorithmDefault generatePasswordForSiteNamed:siteName ofType:siteType withCounter:siteCounter + usingKey:self.key]; PearlMainQueue( ^{ [self.activity stopAnimating]; diff --git a/platform-darwin/Source/iOS/MPOverlayViewController.m b/platform-darwin/Source/iOS/MPOverlayViewController.m index 2a94f11a..a4ac3b57 100644 --- a/platform-darwin/Source/iOS/MPOverlayViewController.m +++ b/platform-darwin/Source/iOS/MPOverlayViewController.m @@ -18,15 +18,19 @@ #import "MPOverlayViewController.h" -@implementation MPOverlayViewController { - NSMutableDictionary *_dismissSegueByButton; -} +@interface MPOverlayViewController() + +@property(nonatomic, strong) NSMutableDictionary *dismissSegueByButton; + +@end + +@implementation MPOverlayViewController - (void)awakeFromNib { [super awakeFromNib]; - _dismissSegueByButton = [NSMutableDictionary dictionary]; + self.dismissSegueByButton = [NSMutableDictionary dictionary]; } - (void)viewDidLoad { @@ -60,7 +64,7 @@ dismissButton.visible = NO; dismissButton.frame = self.view.bounds; dismissButton.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight; - _dismissSegueByButton[[NSValue valueWithNonretainedObject:dismissButton]] = + self.dismissSegueByButton[[NSValue valueWithNonretainedObject:dismissButton]] = [[MPOverlaySegue alloc] initWithIdentifier:@"dismiss-overlay" source:segue.destinationViewController destination:segue.sourceViewController]; @@ -71,14 +75,14 @@ - (void)dismissOverlay:(UIButton *)dismissButton { NSValue *dismissSegueKey = [NSValue valueWithNonretainedObject:dismissButton]; - [((UIStoryboardSegue *)_dismissSegueByButton[dismissSegueKey]) perform]; + [((UIStoryboardSegue *)self.dismissSegueByButton[dismissSegueKey]) perform]; } - (void)removeDismissButtonForViewController:(UIViewController *)viewController { UIButton *dismissButton = nil; - for (NSValue *dismissButtonValue in [_dismissSegueByButton allKeys]) - if (((UIStoryboardSegue *)_dismissSegueByButton[dismissButtonValue]).sourceViewController == viewController) { + for (NSValue *dismissButtonValue in [self.dismissSegueByButton allKeys]) + if (((UIStoryboardSegue *)self.dismissSegueByButton[dismissButtonValue]).sourceViewController == viewController) { dismissButton = [dismissButtonValue nonretainedObjectValue]; NSAssert( [self.view.subviews containsObject:dismissButton], @"Missing dismiss button in dictionary." ); } @@ -86,7 +90,7 @@ return; NSValue *dismissSegueKey = [NSValue valueWithNonretainedObject:dismissButton]; - [_dismissSegueByButton removeObjectForKey:dismissSegueKey]; + [self.dismissSegueByButton removeObjectForKey:dismissSegueKey]; [UIView animateWithDuration:0.1f animations:^{ dismissButton.visible = NO; diff --git a/platform-darwin/Source/iOS/MPPopdownSegue.m b/platform-darwin/Source/iOS/MPPopdownSegue.m index 2859c402..d6a07671 100644 --- a/platform-darwin/Source/iOS/MPPopdownSegue.m +++ b/platform-darwin/Source/iOS/MPPopdownSegue.m @@ -17,16 +17,15 @@ //============================================================================== #import "MPPopdownSegue.h" -#import "MPPasswordsViewController.h" +#import "MPSitesViewController.h" -@implementation MPPopdownSegue { -} +@implementation MPPopdownSegue - (void)perform { - MPPasswordsViewController *passwordsVC; + MPSitesViewController *passwordsVC; UIViewController *popdownVC; - if ([self.sourceViewController isKindOfClass:[MPPasswordsViewController class]]) { + if ([self.sourceViewController isKindOfClass:[MPSitesViewController class]]) { passwordsVC = self.sourceViewController; popdownVC = self.destinationViewController; UIView *popdownView = popdownVC.view; @@ -55,7 +54,7 @@ } else { popdownVC = self.sourceViewController; - for (passwordsVC = self.sourceViewController; passwordsVC && ![(id)passwordsVC isKindOfClass:[MPPasswordsViewController class]]; + for (passwordsVC = self.sourceViewController; passwordsVC && ![(id)passwordsVC isKindOfClass:[MPSitesViewController class]]; passwordsVC = (id)passwordsVC.parentViewController); NSAssert( passwordsVC, @"Couldn't find passwords VC to pop back to." ); diff --git a/platform-darwin/Source/iOS/MPPreferencesViewController.h b/platform-darwin/Source/iOS/MPPreferencesViewController.h index e74a3f87..285f5a13 100644 --- a/platform-darwin/Source/iOS/MPPreferencesViewController.h +++ b/platform-darwin/Source/iOS/MPPreferencesViewController.h @@ -32,7 +32,7 @@ @property(weak, nonatomic) IBOutlet UISegmentedControl *generated1TypeControl; @property(weak, nonatomic) IBOutlet UISegmentedControl *generated2TypeControl; @property(weak, nonatomic) IBOutlet UISegmentedControl *storedTypeControl; -@property(weak, nonatomic) IBOutlet UILabel *passwordTypeExample; +@property(weak, nonatomic) IBOutlet UILabel *typeSamplePassword; - (IBAction)previousAvatar:(id)sender; - (IBAction)nextAvatar:(id)sender; diff --git a/platform-darwin/Source/iOS/MPPreferencesViewController.m b/platform-darwin/Source/iOS/MPPreferencesViewController.m index ae83dd00..f679cf9f 100644 --- a/platform-darwin/Source/iOS/MPPreferencesViewController.m +++ b/platform-darwin/Source/iOS/MPPreferencesViewController.m @@ -21,7 +21,7 @@ #import "MPAppDelegate_Key.h" #import "MPAppDelegate_Store.h" #import "UIColor+Expanded.h" -#import "MPPasswordsViewController.h" +#import "MPSitesViewController.h" #import "MPAppDelegate_InApp.h" @interface MPPreferencesViewController() @@ -70,7 +70,7 @@ examplePassword = [MPAlgorithmDefault generatePasswordForSiteNamed:@"test" ofType:defaultType withCounter:1 usingKey:[MPiOSAppDelegate get].key]; PearlMainQueue( ^{ - self.passwordTypeExample.text = [examplePassword length]? [NSString stringWithFormat:@"eg. %@", examplePassword]: nil; + self.typeSamplePassword.text = [examplePassword length]? [NSString stringWithFormat:@"eg. %@", examplePassword]: nil; } ); } ); } @@ -108,7 +108,7 @@ [[MPiOSAppDelegate get] showExportForVC:self]; if (cell == self.showHelpCell) { - MPPasswordsViewController *passwordsVC = [self dismissPopup]; + MPSitesViewController *passwordsVC = [self dismissPopup]; [passwordsVC performSegueWithIdentifier:@"guide" sender:self]; } @@ -230,11 +230,11 @@ #pragma mark - Private -- (MPPasswordsViewController *)dismissPopup { +- (MPSitesViewController *)dismissPopup { for (UIViewController *vc = self; (vc = vc.parentViewController);) - if ([vc isKindOfClass:[MPPasswordsViewController class]]) { - MPPasswordsViewController *passwordsVC = (MPPasswordsViewController *)vc; + if ([vc isKindOfClass:[MPSitesViewController class]]) { + MPSitesViewController *passwordsVC = (MPSitesViewController *)vc; [passwordsVC dismissPopdown:self]; return passwordsVC; } @@ -254,32 +254,32 @@ case 1: return MPSiteTypeGeneratedName; default: - switch (selectedGenerated2Index) { - case 0: - return MPSiteTypeGeneratedMaximum; - case 1: - return MPSiteTypeGeneratedLong; - case 2: - return MPSiteTypeGeneratedMedium; - case 3: - return MPSiteTypeGeneratedBasic; - case 4: - return MPSiteTypeGeneratedShort; - case 5: - return MPSiteTypeGeneratedPIN; - default: - - switch (selectedStoredIndex) { + switch (selectedGenerated2Index) { case 0: - return MPSiteTypeStoredPersonal; + return MPSiteTypeGeneratedMaximum; case 1: - return MPSiteTypeStoredDevicePrivate; + return MPSiteTypeGeneratedLong; + case 2: + return MPSiteTypeGeneratedMedium; + case 3: + return MPSiteTypeGeneratedBasic; + case 4: + return MPSiteTypeGeneratedShort; + case 5: + return MPSiteTypeGeneratedPIN; default: - Throw( @"unsupported selected type index: generated1=%ld, generated2=%ld, stored=%ld", - (long)selectedGenerated1Index, (long)selectedGenerated2Index, (long)selectedStoredIndex ); + + switch (selectedStoredIndex) { + case 0: + return MPSiteTypeStoredPersonal; + case 1: + return MPSiteTypeStoredDevicePrivate; + default: + Throw( @"unsupported selected type index: generated1=%ld, generated2=%ld, stored=%ld", + (long)selectedGenerated1Index, (long)selectedGenerated2Index, (long)selectedStoredIndex ); + } } } - } } - (NSInteger)generated1SegmentIndexForType:(MPSiteType)type { diff --git a/platform-darwin/Source/iOS/MPRootSegue.m b/platform-darwin/Source/iOS/MPRootSegue.m index 5c265079..21b3b889 100644 --- a/platform-darwin/Source/iOS/MPRootSegue.m +++ b/platform-darwin/Source/iOS/MPRootSegue.m @@ -18,8 +18,7 @@ #import "MPRootSegue.h" -@implementation MPRootSegue { -} +@implementation MPRootSegue - (void)perform { diff --git a/platform-darwin/Source/iOS/MPPasswordCell.h b/platform-darwin/Source/iOS/MPSiteCell.h similarity index 86% rename from platform-darwin/Source/iOS/MPPasswordCell.h rename to platform-darwin/Source/iOS/MPSiteCell.h index 536defdd..4b78adc7 100644 --- a/platform-darwin/Source/iOS/MPPasswordCell.h +++ b/platform-darwin/Source/iOS/MPSiteCell.h @@ -20,18 +20,18 @@ #import "MPEntities.h" #import "MPCell.h" -typedef NS_ENUM ( NSUInteger, MPPasswordCellMode ) { +typedef NS_ENUM ( NSUInteger, MPSiteCellMode ) { MPPasswordCellModePassword, MPPasswordCellModeSettings, }; -@interface MPPasswordCell : MPCell +@interface MPSiteCell : MPCell @property(nonatomic) NSArray *fuzzyGroups; - (void)setSite:(MPSiteEntity *)site animated:(BOOL)animated; - (void)setTransientSite:(NSString *)siteName animated:(BOOL)animated; -- (void)setMode:(MPPasswordCellMode)mode animated:(BOOL)animated; +- (void)setMode:(MPSiteCellMode)mode animated:(BOOL)animated; - (MPSiteEntity *)siteInContext:(NSManagedObjectContext *)context; @end diff --git a/platform-darwin/Source/iOS/MPPasswordCell.m b/platform-darwin/Source/iOS/MPSiteCell.m similarity index 97% rename from platform-darwin/Source/iOS/MPPasswordCell.m rename to platform-darwin/Source/iOS/MPSiteCell.m index 16dda370..4eeb6c1a 100644 --- a/platform-darwin/Source/iOS/MPPasswordCell.m +++ b/platform-darwin/Source/iOS/MPSiteCell.m @@ -16,13 +16,12 @@ // LICENSE file. Alternatively, see . //============================================================================== -#import "MPPasswordCell.h" +#import "MPSiteCell.h" #import "MPiOSAppDelegate.h" #import "MPAppDelegate_Store.h" -#import "UIColor+Expanded.h" #import "MPAppDelegate_InApp.h" -@interface MPPasswordCell() +@interface MPSiteCell() @property(nonatomic, strong) IBOutlet UILabel *siteNameLabel; @property(nonatomic, strong) IBOutlet UITextField *passwordField; @@ -41,14 +40,13 @@ @property(nonatomic, strong) IBOutlet UIButton *loginNameButton; @property(nonatomic, strong) IBOutlet UIView *indicatorView; -@property(nonatomic) MPPasswordCellMode mode; +@property(nonatomic) MPSiteCellMode mode; @property(nonatomic, copy) NSString *transientSite; +@property(nonatomic, strong) NSManagedObjectID *siteOID; @end -@implementation MPPasswordCell { - NSManagedObjectID *_siteOID; -} +@implementation MPSiteCell #pragma mark - Life cycle @@ -65,9 +63,9 @@ [self setupLayer]; - [self observeKeyPath:@"bounds" withBlock:^(id from, id to, NSKeyValueChange cause, MPPasswordCell *_self) { + [self observeKeyPath:@"bounds" withBlock:^(id from, id to, NSKeyValueChange cause, MPSiteCell *self) { if (from && !CGSizeEqualToSize( [from CGRectValue].size, [to CGRectValue].size )) - [_self setupLayer]; + [self setupLayer]; }]; [self.contentButton observeKeyPath:@"highlighted" withBlock:^(id from, id to, NSKeyValueChange cause, UIButton *button) { @@ -135,8 +133,8 @@ [super prepareForReuse]; - _siteOID = nil; - _fuzzyGroups = nil; + self.siteOID = nil; + self.fuzzyGroups = nil; self.transientSite = nil; self.mode = MPPasswordCellModePassword; [self updateAnimated:NO]; @@ -153,25 +151,25 @@ - (void)setFuzzyGroups:(NSArray *)fuzzyGroups { - if (_fuzzyGroups == fuzzyGroups) + if (self.fuzzyGroups == fuzzyGroups) return; _fuzzyGroups = fuzzyGroups; [self updateSiteName:[self siteInContext:[MPiOSAppDelegate managedObjectContextForMainThreadIfReady]]]; } -- (void)setMode:(MPPasswordCellMode)mode animated:(BOOL)animated { +- (void)setMode:(MPSiteCellMode)mode animated:(BOOL)animated { - if (mode == _mode) + if (self.mode == mode) return; - _mode = mode; + [self updateAnimated:animated]; } - (void)setSite:(MPSiteEntity *)site animated:(BOOL)animated { - _siteOID = site.permanentObjectID; + self.siteOID = site.permanentObjectID; [self updateAnimated:animated]; } @@ -368,7 +366,7 @@ } - (IBAction)doAction:(UIButton *)sender { - + [MPiOSAppDelegate managedObjectContextForMainThreadPerformBlock:^(NSManagedObjectContext *mainContext) { MPSiteEntity *mainSite = [self siteInContext:mainContext]; [PearlAlert showAlertWithTitle:@"Login Page" message:nil @@ -531,7 +529,7 @@ MPSiteEntity *mainSite = [self siteInContext:[MPiOSAppDelegate managedObjectContextForMainThreadIfReady]]; // UI - self.backgroundColor = mainSite.url? [UIColor greenColor]: [UIColor redColor]; + //self.backgroundColor = mainSite.url? [UIColor greenColor]: [UIColor redColor]; self.upgradeButton.gone = !mainSite.requiresExplicitMigration && ![[MPiOSConfig get].allowDowngrade boolValue]; self.answersButton.gone = ![[MPiOSAppDelegate get] isFeatureUnlocked:MPProductGenerateAnswers]; BOOL settingsMode = self.mode == MPPasswordCellModeSettings; @@ -678,7 +676,7 @@ [self.window endEditing:YES]; UIPasteboard *pasteboard = [UIPasteboard generalPasteboard]; - if ([pasteboard respondsToSelector:@selector(setItems:options:)]) { + if ([pasteboard respondsToSelector:@selector( setItems:options: )]) { [pasteboard setItems:@[ @{ UIPasteboardTypeAutomatic: password } ] options:@{ UIPasteboardOptionLocalOnly : @NO, @@ -718,7 +716,7 @@ - (MPSiteEntity *)siteInContext:(NSManagedObjectContext *)context { - return [MPSiteEntity existingObjectWithID:_siteOID inContext:context]; + return [MPSiteEntity existingObjectWithID:self.siteOID inContext:context]; } @end diff --git a/platform-darwin/Source/iOS/MPPasswordsSegue.h b/platform-darwin/Source/iOS/MPSitesSegue.h similarity index 95% rename from platform-darwin/Source/iOS/MPPasswordsSegue.h rename to platform-darwin/Source/iOS/MPSitesSegue.h index ab1497d7..5848cfa4 100644 --- a/platform-darwin/Source/iOS/MPPasswordsSegue.h +++ b/platform-darwin/Source/iOS/MPSitesSegue.h @@ -18,7 +18,7 @@ #import -@interface MPPasswordsSegue : UIStoryboardSegue +@interface MPSitesSegue : UIStoryboardSegue @property(nonatomic, assign) BOOL animated; diff --git a/platform-darwin/Source/iOS/MPPasswordsSegue.m b/platform-darwin/Source/iOS/MPSitesSegue.m similarity index 53% rename from platform-darwin/Source/iOS/MPPasswordsSegue.m rename to platform-darwin/Source/iOS/MPSitesSegue.m index 1a9ea38b..da77e624 100644 --- a/platform-darwin/Source/iOS/MPPasswordsSegue.m +++ b/platform-darwin/Source/iOS/MPSitesSegue.m @@ -16,12 +16,11 @@ // LICENSE file. Alternatively, see . //============================================================================== -#import "MPPasswordsSegue.h" -#import "MPPasswordsViewController.h" +#import "MPSitesSegue.h" +#import "MPSitesViewController.h" #import "MPCombinedViewController.h" -@implementation MPPasswordsSegue { -} +@implementation MPSitesSegue - (id)initWithIdentifier:(NSString *)identifier source:(UIViewController *)source destination:(UIViewController *)destination { @@ -35,34 +34,34 @@ - (void)perform { - if ([self.destinationViewController isKindOfClass:[MPPasswordsViewController class]]) { - __weak MPPasswordsViewController *passwordsVC = self.destinationViewController; + if ([self.destinationViewController isKindOfClass:[MPSitesViewController class]]) { + __weak MPSitesViewController *sitesVC = self.destinationViewController; MPCombinedViewController *combinedVC = self.sourceViewController; - [combinedVC addChildViewController:passwordsVC]; - passwordsVC.active = NO; + [combinedVC addChildViewController:sitesVC]; + sitesVC.active = NO; - UIView *passwordsView = passwordsVC.view; - passwordsView.frame = combinedVC.view.bounds; - passwordsView.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight; - [combinedVC.view insertSubview:passwordsView belowSubview:combinedVC.usersVC.view]; + UIView *sitesView = sitesVC.view; + sitesView.frame = combinedVC.view.bounds; + sitesView.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight; + [combinedVC.view insertSubview:sitesView belowSubview:combinedVC.usersVC.view]; - [passwordsVC setActive:YES animated:self.animated completion:^(BOOL finished) { + [sitesVC setActive:YES animated:self.animated completion:^(BOOL finished) { if (!finished) return; - [passwordsVC didMoveToParentViewController:combinedVC]; + [sitesVC didMoveToParentViewController:combinedVC]; }]; } - else if ([self.sourceViewController isKindOfClass:[MPPasswordsViewController class]]) { - __weak MPPasswordsViewController *passwordsVC = self.sourceViewController; + else if ([self.sourceViewController isKindOfClass:[MPSitesViewController class]]) { + __weak MPSitesViewController *sitesVC = self.sourceViewController; - [passwordsVC willMoveToParentViewController:nil]; - [passwordsVC setActive:NO animated:self.animated completion:^(BOOL finished) { + [sitesVC willMoveToParentViewController:nil]; + [sitesVC setActive:NO animated:self.animated completion:^(BOOL finished) { if (!finished) return; - [passwordsVC.view removeFromSuperview]; - [passwordsVC removeFromParentViewController]; + [sitesVC.view removeFromSuperview]; + [sitesVC removeFromParentViewController]; }]; } } diff --git a/platform-darwin/Source/iOS/MPPasswordsViewController.h b/platform-darwin/Source/iOS/MPSitesViewController.h similarity index 59% rename from platform-darwin/Source/iOS/MPPasswordsViewController.h rename to platform-darwin/Source/iOS/MPSitesViewController.h index 9aa3c4a4..6bfa83d8 100644 --- a/platform-darwin/Source/iOS/MPPasswordsViewController.h +++ b/platform-darwin/Source/iOS/MPSitesViewController.h @@ -19,22 +19,22 @@ @class MPSiteEntity; @class MPCoachmark; -@interface MPPasswordsViewController : UIViewController +@interface MPSitesViewController : UIViewController -@property(strong, nonatomic) IBOutlet UIView *passwordSelectionContainer; -@property(strong, nonatomic) IBOutlet UICollectionView *passwordCollectionView; -@property(strong, nonatomic) IBOutlet UISearchBar *passwordsSearchBar; -@property(strong, nonatomic) IBOutlet NSLayoutConstraint *passwordsToBottomConstraint; -@property(strong, nonatomic) IBOutlet NSLayoutConstraint *navigationBarToTopConstraint; -@property(strong, nonatomic) IBOutlet NSLayoutConstraint *popdownToTopConstraint; -@property(strong, nonatomic) IBOutlet UIView *badNameTipContainer; -@property(strong, nonatomic) IBOutlet UIView *popdownView; -@property(strong, nonatomic) IBOutlet UIView *popdownContainer; +@property(nonatomic, strong) IBOutlet UICollectionView *collectionView; +@property(nonatomic, strong) IBOutlet UINavigationBar *navigationBar; +@property(nonatomic, strong) IBOutlet UISearchBar *searchBar; +@property(nonatomic, strong) IBOutlet NSLayoutConstraint *sitesToBottomConstraint; +@property(nonatomic, strong) IBOutlet NSLayoutConstraint *navigationBarToTopConstraint; +@property(nonatomic, strong) IBOutlet NSLayoutConstraint *popdownToTopConstraint; +@property(nonatomic, strong) IBOutlet UIView *badNameTipContainer; +@property(nonatomic, strong) IBOutlet UIView *popdownView; +@property(nonatomic, strong) IBOutlet UIView *popdownContainer; @property(assign, nonatomic) BOOL active; - (void)setActive:(BOOL)active animated:(BOOL)animated completion:(void ( ^ )(BOOL finished))completion; -- (void)reloadPasswords; +- (void)reloadSites; - (IBAction)dismissPopdown:(id)sender; diff --git a/platform-darwin/Source/iOS/MPPasswordsViewController.m b/platform-darwin/Source/iOS/MPSitesViewController.m similarity index 72% rename from platform-darwin/Source/iOS/MPPasswordsViewController.m rename to platform-darwin/Source/iOS/MPSitesViewController.m index 2995973e..a36ffb60 100644 --- a/platform-darwin/Source/iOS/MPPasswordsViewController.m +++ b/platform-darwin/Source/iOS/MPSitesViewController.m @@ -16,12 +16,12 @@ // LICENSE file. Alternatively, see . //============================================================================== -#import "MPPasswordsViewController.h" +#import "MPSitesViewController.h" #import "MPiOSAppDelegate.h" #import "MPAppDelegate_Store.h" #import "MPPopdownSegue.h" #import "MPAppDelegate_Key.h" -#import "MPPasswordCell.h" +#import "MPSiteCell.h" #import "MPAnswersViewController.h" #import "MPMessageViewController.h" @@ -31,22 +31,17 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { MPPasswordsBadNameTip = 1 << 0, }; -@interface MPPasswordsViewController() +@interface MPSitesViewController() -@property(nonatomic, strong) IBOutlet UINavigationBar *navigationBar; +@property(nonatomic, strong) NSFetchedResultsController *fetchedResultsController; +@property(nonatomic, strong) NSArray *fuzzyGroups; +@property(nonatomic, strong) NSCharacterSet *siteNameAcceptableCharactersSet; +@property(nonatomic, strong) NSMutableArray *dataSource; +@property(nonatomic, weak) UIViewController *popdownVC; @end -@implementation MPPasswordsViewController { - __weak UITapGestureRecognizer *_passwordsDismissRecognizer; - NSFetchedResultsController *_fetchedResultsController; - UIColor *_backgroundColor; - UIColor *_darkenedBackgroundColor; - __weak UIViewController *_popdownVC; - NSCharacterSet *_siteNameAcceptableCharactersSet; - NSArray *_fuzzyGroups; - NSMutableArray *_passwordCollectionSections; -} +@implementation MPSitesViewController #pragma mark - Life @@ -57,22 +52,20 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { NSMutableCharacterSet *siteNameAcceptableCharactersSet = [[NSCharacterSet alphanumericCharacterSet] mutableCopy]; [siteNameAcceptableCharactersSet formIntersectionWithCharacterSet:[[NSCharacterSet uppercaseLetterCharacterSet] invertedSet]]; [siteNameAcceptableCharactersSet addCharactersInString:@"@.-+~&_;:/"]; - _siteNameAcceptableCharactersSet = siteNameAcceptableCharactersSet; + self.siteNameAcceptableCharactersSet = siteNameAcceptableCharactersSet; - _backgroundColor = self.passwordCollectionView.backgroundColor; - _darkenedBackgroundColor = [_backgroundColor colorWithAlphaComponent:0.6f]; - _passwordCollectionSections = [NSMutableArray new]; + self.dataSource = [NSMutableArray new]; self.view.backgroundColor = [UIColor clearColor]; - [self.passwordCollectionView automaticallyAdjustInsetsForKeyboard]; - self.passwordsSearchBar.autocapitalizationType = UITextAutocapitalizationTypeNone; - if ([self.passwordsSearchBar respondsToSelector:@selector( keyboardAppearance )]) - self.passwordsSearchBar.keyboardAppearance = UIKeyboardAppearanceDark; + [self.collectionView automaticallyAdjustInsetsForKeyboard]; + self.searchBar.autocapitalizationType = UITextAutocapitalizationTypeNone; + if ([self.searchBar respondsToSelector:@selector( keyboardAppearance )]) + self.searchBar.keyboardAppearance = UIKeyboardAppearanceDark; else - [self.passwordsSearchBar enumerateViews:^(UIView *subview, BOOL *stop, BOOL *recurse) { + [self.searchBar enumerateViews:^(UIView *subview, BOOL *stop, BOOL *recurse) { if ([subview isKindOfClass:[UITextField class]]) ((UITextField *)subview).keyboardAppearance = UIKeyboardAppearanceDark; - } recurse:YES]; + } recurse:YES]; } - (void)viewWillAppear:(BOOL)animated { @@ -98,7 +91,7 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { if (pasteboardURL.host) self.query = NSNullToNil( [pasteboardURL.host firstMatchGroupsOfExpression:bareHostRE][0] ); else - [self reloadPasswords]; + [self reloadSites]; } - (void)viewDidAppear:(BOOL)animated { @@ -131,17 +124,17 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { - (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender { if ([segue.identifier isEqualToString:@"popdown"]) - _popdownVC = segue.destinationViewController; + self.popdownVC = segue.destinationViewController; if ([segue.identifier isEqualToString:@"answers"]) ((MPAnswersViewController *)segue.destinationViewController).site = - [[MPPasswordCell findAsSuperviewOf:sender] siteInContext:[MPiOSAppDelegate managedObjectContextForMainThreadIfReady]]; + [[MPSiteCell findAsSuperviewOf:sender] siteInContext:[MPiOSAppDelegate managedObjectContextForMainThreadIfReady]]; if ([segue.identifier isEqualToString:@"message"]) ((MPMessageViewController *)segue.destinationViewController).message = sender; } - (void)viewWillTransitionToSize:(CGSize)size withTransitionCoordinator:(id)coordinator { - [self.passwordCollectionView.collectionViewLayout invalidateLayout]; + [self.collectionView.collectionViewLayout invalidateLayout]; [super viewWillTransitionToSize:size withTransitionCoordinator:coordinator]; } @@ -159,7 +152,7 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { insetForSectionAtIndex:(NSInteger)section { UICollectionViewFlowLayout *layout = (UICollectionViewFlowLayout *)collectionViewLayout; - UIEdgeInsets occludedInsets = [self.passwordCollectionView occludedInsets]; + UIEdgeInsets occludedInsets = [self.collectionView occludedInsets]; UIEdgeInsets insets = layout.sectionInset; insets.top = insets.bottom; // Undo storyboard hack for manual top-occluded insets. @@ -176,19 +169,19 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { - (NSInteger)numberOfSectionsInCollectionView:(UICollectionView *)collectionView { - return [_passwordCollectionSections count]; + return [self.dataSource count]; } - (NSInteger)collectionView:(UICollectionView *)collectionView numberOfItemsInSection:(NSInteger)section { - return [_passwordCollectionSections[(NSUInteger)section] count]; + return [self.dataSource[(NSUInteger)section] count]; } - (UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath { - MPPasswordCell *cell = [MPPasswordCell dequeueCellFromCollectionView:collectionView indexPath:indexPath]; - [cell setFuzzyGroups:_fuzzyGroups]; - id item = _passwordCollectionSections[(NSUInteger)indexPath.section][(NSUInteger)indexPath.item]; + MPSiteCell *cell = [MPSiteCell dequeueCellFromCollectionView:collectionView indexPath:indexPath]; + [cell setFuzzyGroups:self.fuzzyGroups]; + id item = self.dataSource[(NSUInteger)indexPath.section][(NSUInteger)indexPath.item]; if ([item isKindOfClass:[MPSiteEntity class]]) [cell setSite:item animated:NO]; else // item == MPTransientPasswordItem @@ -201,8 +194,8 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { - (void)scrollViewWillBeginDragging:(UIScrollView *)scrollView { - if (scrollView == self.passwordCollectionView) - for (MPPasswordCell *cell in [self.passwordCollectionView visibleCells]) + if (scrollView == self.collectionView) + for (MPSiteCell *cell in [self.collectionView visibleCells]) [cell setMode:MPPasswordCellModePassword animated:YES]; } @@ -210,11 +203,11 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { - (void)controllerDidChangeContent:(NSFetchedResultsController *)controller { - if (controller == _fetchedResultsController) + if (controller == self.fetchedResultsController) PearlMainQueue( ^{ - [self.passwordCollectionView updateDataSource:_passwordCollectionSections - toSections:[self createPasswordCollectionSections] - reloadItems:nil completion:nil]; + [self.collectionView updateDataSource:self.dataSource + toSections:[self createPasswordCollectionSections] + reloadItems:nil completion:nil]; } ); } @@ -222,7 +215,7 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { - (BOOL)searchBarShouldBeginEditing:(UISearchBar *)searchBar { - if (searchBar == self.passwordsSearchBar) { + if (searchBar == self.searchBar) { searchBar.text = nil; return YES; } @@ -232,24 +225,22 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { - (void)searchBarTextDidBeginEditing:(UISearchBar *)searchBar { - if (searchBar == self.passwordsSearchBar) { - [self.passwordsSearchBar setShowsCancelButton:YES animated:YES]; + if (searchBar == self.searchBar) { + [self.searchBar setShowsCancelButton:YES animated:YES]; [UIView animateWithDuration:0.3f animations:^{ - self.passwordCollectionView.backgroundColor = _darkenedBackgroundColor; + self.collectionView.backgroundColor = [self.collectionView.backgroundColor colorWithAlphaComponent:0.6f]; }]; } } - (void)searchBarTextDidEndEditing:(UISearchBar *)searchBar { - if (searchBar == self.passwordsSearchBar) { - [self.passwordsSearchBar setShowsCancelButton:NO animated:YES]; - if (_passwordsDismissRecognizer) - [self.view removeGestureRecognizer:_passwordsDismissRecognizer]; + if (searchBar == self.searchBar) { + [self.searchBar setShowsCancelButton:NO animated:YES]; + [self reloadSites]; - [self reloadPasswords]; [UIView animateWithDuration:0.3f animations:^{ - self.passwordCollectionView.backgroundColor = _backgroundColor; + self.collectionView.backgroundColor = [self.collectionView.backgroundColor colorWithAlphaComponent:0]; }]; } } @@ -267,11 +258,11 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { - (void)searchBar:(UISearchBar *)searchBar textDidChange:(NSString *)searchText { - if (searchBar == self.passwordsSearchBar) { - if ([[self.query stringByTrimmingCharactersInSet:_siteNameAcceptableCharactersSet] length]) + if (searchBar == self.searchBar) { + if ([[self.query stringByTrimmingCharactersInSet:self.siteNameAcceptableCharactersSet] length]) [self showTips:MPPasswordsBadNameTip]; - [self reloadPasswords]; + [self reloadSites]; } } @@ -321,42 +312,42 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { PearlRemoveNotificationObservers(); PearlAddNotificationObserver( UIApplicationWillResignActiveNotification, nil, [NSOperationQueue mainQueue], - ^(MPPasswordsViewController *self, NSNotification *note) { + ^(MPSitesViewController *self, NSNotification *note) { [self.view endEditing:YES]; - self.passwordSelectionContainer.visible = NO; + self.view.visible = NO; } ); PearlAddNotificationObserver( UIApplicationDidBecomeActiveNotification, nil, [NSOperationQueue mainQueue], - ^(MPPasswordsViewController *self, NSNotification *note) { + ^(MPSitesViewController *self, NSNotification *note) { [UIView animateWithDuration:0.7f animations:^{ - self.passwordSelectionContainer.visible = YES; + self.view.visible = YES; }]; } ); PearlAddNotificationObserver( UIApplicationWillEnterForegroundNotification, nil, [NSOperationQueue mainQueue], - ^(MPPasswordsViewController *self, NSNotification *note) { + ^(MPSitesViewController *self, NSNotification *note) { [self viewWillAppear:YES]; } ); PearlAddNotificationObserver( MPSignedOutNotification, nil, nil, - ^(MPPasswordsViewController *self, NSNotification *note) { + ^(MPSitesViewController *self, NSNotification *note) { PearlMainQueue( ^{ - self->_fetchedResultsController = nil; + self.fetchedResultsController = nil; self.query = nil; } ); } ); PearlAddNotificationObserver( MPCheckConfigNotification, nil, nil, - ^(MPPasswordsViewController *self, NSNotification *note) { + ^(MPSitesViewController *self, NSNotification *note) { PearlMainQueue( ^{ [self updateConfigKey:note.object]; } ); } ); PearlAddNotificationObserver( NSPersistentStoreCoordinatorStoresWillChangeNotification, nil, nil, - ^(MPPasswordsViewController *self, NSNotification *note) { - self->_fetchedResultsController = nil; - [self reloadPasswords]; + ^(MPSitesViewController *self, NSNotification *note) { + self.fetchedResultsController = nil; + [self reloadSites]; } ); PearlAddNotificationObserver( NSPersistentStoreCoordinatorStoresDidChangeNotification, nil, nil, - ^(MPPasswordsViewController *self, NSNotification *note) { + ^(MPSitesViewController *self, NSNotification *note) { PearlMainQueue( ^{ - [self reloadPasswords]; + [self reloadSites]; [self registerObservers]; } ); } ); @@ -373,12 +364,12 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { - (void)updateConfigKey:(NSString *)key { if (!key || [key isEqualToString:NSStringFromSelector( @selector( dictationSearch ) )]) - self.passwordsSearchBar.keyboardType = [[MPiOSConfig get].dictationSearch boolValue]? UIKeyboardTypeDefault: UIKeyboardTypeURL; + self.searchBar.keyboardType = [[MPiOSConfig get].dictationSearch boolValue]? UIKeyboardTypeDefault: UIKeyboardTypeURL; if (!key || [key isEqualToString:NSStringFromSelector( @selector( hidePasswords ) )]) - [self.passwordCollectionView reloadData]; + [self.collectionView reloadData]; } -- (void)reloadPasswords { +- (void)reloadSites { [self.fetchedResultsController.managedObjectContext performBlock:^{ static NSRegularExpression *fuzzyRE; @@ -395,7 +386,7 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { usingBlock:^(NSTextCheckingResult *result, NSMatchingFlags flags, BOOL *stop) { [fuzzyGroups addObject:[queryString substringWithRange:result.range]]; }]; - _fuzzyGroups = fuzzyGroups; + self.fuzzyGroups = fuzzyGroups; NSError *error = nil; self.fetchedResultsController.fetchRequest.predicate = @@ -404,11 +395,11 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { MPError( error, @"Couldn't fetch sites." ); PearlMainQueue( ^{ - [self.passwordCollectionView updateDataSource:_passwordCollectionSections - toSections:[self createPasswordCollectionSections] - reloadItems:@[ MPTransientPasswordItem ] completion:^(BOOL finished) { - for (MPPasswordCell *cell in self.passwordCollectionView.visibleCells) - [cell setFuzzyGroups:_fuzzyGroups]; + [self.collectionView updateDataSource:self.dataSource + toSections:[self createPasswordCollectionSections] + reloadItems:@[ MPTransientPasswordItem ] completion:^(BOOL finished) { + for (MPSiteCell *cell in self.collectionView.visibleCells) + [cell setFuzzyGroups:self.fuzzyGroups]; }]; } ); }]; @@ -418,33 +409,33 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { - (NSString *)query { - return [self.passwordsSearchBar.text stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceCharacterSet]]; + return [self.searchBar.text stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceCharacterSet]]; } - (void)setQuery:(NSString *)query { - self.passwordsSearchBar.text = [query stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceCharacterSet]]; - [self reloadPasswords]; + self.searchBar.text = [query stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceCharacterSet]]; + [self reloadSites]; } - (NSFetchedResultsController *)fetchedResultsController { - if (!_fetchedResultsController) { + if (!self.fetchedResultsController) { [MPiOSAppDelegate managedObjectContextForMainThreadPerformBlockAndWait:^(NSManagedObjectContext *mainContext) { NSFetchRequest *fetchRequest = [NSFetchRequest fetchRequestWithEntityName:NSStringFromClass( [MPSiteEntity class] )]; fetchRequest.sortDescriptors = @[ [[NSSortDescriptor alloc] initWithKey:NSStringFromSelector( @selector( lastUsed ) ) ascending:NO] ]; fetchRequest.fetchBatchSize = 10; - _fetchedResultsController = + self.fetchedResultsController = [[NSFetchedResultsController alloc] initWithFetchRequest:fetchRequest managedObjectContext:mainContext sectionNameKeyPath:nil cacheName:nil]; - _fetchedResultsController.delegate = self; + self.fetchedResultsController.delegate = self; }]; [self registerObservers]; } - return _fetchedResultsController; + return self.fetchedResultsController; } - (void)setActive:(BOOL)active { @@ -458,7 +449,7 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { [UIView animateWithDuration:animated? 0.4f: 0 animations:^{ [self.navigationBarToTopConstraint updatePriority:active? 1: UILayoutPriorityDefaultHigh]; - [self.passwordsToBottomConstraint updatePriority:active? 1: UILayoutPriorityDefaultHigh]; + [self.sitesToBottomConstraint updatePriority:active? 1: UILayoutPriorityDefaultHigh]; [self.view layoutIfNeeded]; } completion:completion]; } @@ -467,8 +458,8 @@ typedef NS_OPTIONS( NSUInteger, MPPasswordsTips ) { - (IBAction)dismissPopdown:(id)sender { - if (_popdownVC) - [[[MPPopdownSegue alloc] initWithIdentifier:@"unwind-popdown" source:_popdownVC destination:self] perform]; + if (self.popdownVC) + [[[MPPopdownSegue alloc] initWithIdentifier:@"unwind-popdown" source:self.popdownVC destination:self] perform]; else self.popdownToTopConstraint.priority = UILayoutPriorityDefaultHigh; } diff --git a/platform-darwin/Source/iOS/MPStoreViewController.m b/platform-darwin/Source/iOS/MPStoreViewController.m index 8e62674c..d6081f59 100644 --- a/platform-darwin/Source/iOS/MPStoreViewController.m +++ b/platform-darwin/Source/iOS/MPStoreViewController.m @@ -20,7 +20,7 @@ #import "MPiOSAppDelegate.h" #import "UIColor+Expanded.h" #import "MPAppDelegate_InApp.h" -#import "MPPasswordsViewController.h" +#import "MPSitesViewController.h" PearlEnum( MPDevelopmentFuelConsumption, MPDevelopmentFuelConsumptionQuarterly, MPDevelopmentFuelConsumptionMonthly, MPDevelopmentFuelWeekly ); @@ -191,11 +191,11 @@ PearlEnum( MPDevelopmentFuelConsumption, #pragma mark - Private -- (MPPasswordsViewController *)dismissPopup { +- (MPSitesViewController *)dismissPopup { for (UIViewController *vc = self; (vc = vc.parentViewController);) - if ([vc isKindOfClass:[MPPasswordsViewController class]]) { - MPPasswordsViewController *passwordsVC = (MPPasswordsViewController *)vc; + if ([vc isKindOfClass:[MPSitesViewController class]]) { + MPSitesViewController *passwordsVC = (MPSitesViewController *)vc; [passwordsVC dismissPopdown:self]; return passwordsVC; } diff --git a/platform-darwin/Source/iOS/MPUsersViewController.m b/platform-darwin/Source/iOS/MPUsersViewController.m index ac3d2a5b..93e93e6f 100644 --- a/platform-darwin/Source/iOS/MPUsersViewController.m +++ b/platform-darwin/Source/iOS/MPUsersViewController.m @@ -54,19 +54,19 @@ typedef NS_ENUM( NSUInteger, MPActiveUserState ) { @property(nonatomic, strong) NSTimer *marqueeTipTimer; @property(nonatomic, strong) NSArray *marqueeTipTexts; @property(nonatomic) NSUInteger marqueeTipTextIndex; +@property(nonatomic, copy) NSString *masterPasswordChoice; +@property(nonatomic, strong) NSOperationQueue *afterUpdates; +@property(nonatomic, weak) id contextChangedObserver; + @end -@implementation MPUsersViewController { - NSString *_masterPasswordChoice; - NSOperationQueue *_afterUpdates; - __weak id _contextChangedObserver; -} +@implementation MPUsersViewController - (void)viewDidLoad { [super viewDidLoad]; - _afterUpdates = [NSOperationQueue new]; + self.afterUpdates = [NSOperationQueue new]; self.marqueeTipTexts = @[ strl( @"Thanks, lhunath ➚" ), @@ -205,7 +205,7 @@ typedef NS_ENUM( NSUInteger, MPActiveUserState ) { return NO; } - if (![masterPassword isEqualToString:_masterPasswordChoice]) { + if (![masterPassword isEqualToString:self.masterPasswordChoice]) { // Master password confirmation failed. [self showEntryTip:strl( @"Looks like a typo!\nTry again; enter your master password twice." )]; self.activeUserState = MPActiveUserStateMasterPasswordChoice; @@ -655,7 +655,7 @@ referenceSizeForFooterInSection:(NSInteger)section { - (void)afterUpdatesMainQueue:(void ( ^ )(void))block { - [_afterUpdates addOperationWithBlock:^{ + [self.afterUpdates addOperationWithBlock:^{ PearlMainQueue( block ); }]; } @@ -664,15 +664,15 @@ referenceSizeForFooterInSection:(NSInteger)section { [self removeKeyPathObservers]; PearlRemoveNotificationObservers(); - [[NSNotificationCenter defaultCenter] removeObserver:_contextChangedObserver]; + [[NSNotificationCenter defaultCenter] removeObserver:self.contextChangedObserver]; } - (void)registerObservers { [self removeObservers]; [self observeKeyPath:@"avatarCollectionView.contentOffset" withBlock: - ^(id from, id to, NSKeyValueChange cause, MPUsersViewController *_self) { - [_self updateAvatarVisibility]; + ^(id from, id to, NSKeyValueChange cause, MPUsersViewController *self) { + [self updateAvatarVisibility]; }]; PearlAddNotificationObserver( UIApplicationDidEnterBackgroundNotification, nil, [NSOperationQueue mainQueue], @@ -696,13 +696,14 @@ referenceSizeForFooterInSection:(NSInteger)section { [self.keyboardHeightConstraint updateConstant:keyboardHeight]; } ); - if ((_contextChangedObserver = [MPiOSAppDelegate managedObjectContextChanged:^(NSDictionary *affectedObjects) { - if ([[[affectedObjects allKeys] filteredArrayUsingPredicate: - [NSPredicate predicateWithBlock:^BOOL(NSManagedObjectID *objectID, NSDictionary *bindings) { - return [objectID.entity.name isEqualToString:NSStringFromClass( [MPUserEntity class] )]; - }]] count]) - [self reloadUsers]; - }])) + if ((self.contextChangedObserver + = [MPiOSAppDelegate managedObjectContextChanged:^(NSDictionary *affectedObjects) { + if ([[[affectedObjects allKeys] filteredArrayUsingPredicate: + [NSPredicate predicateWithBlock:^BOOL(NSManagedObjectID *objectID, NSDictionary *bindings) { + return [objectID.entity.name isEqualToString:NSStringFromClass( [MPUserEntity class] )]; + }]] count]) + [self reloadUsers]; + }])) [UIView animateWithDuration:0.3f animations:^{ self.avatarCollectionView.visible = YES; [self.storeLoadingActivity stopAnimating]; @@ -772,7 +773,7 @@ referenceSizeForFooterInSection:(NSInteger)section { isNew:&isNew].permanentObjectID; [self.avatarCollectionView reloadData]; - NSUInteger selectedAvatarItem = isNew? [_userIDs count]: selectUserID? [_userIDs indexOfObject:selectUserID]: NSNotFound; + NSUInteger selectedAvatarItem = isNew? [self.userIDs count]: selectUserID? [self.userIDs indexOfObject:selectUserID]: NSNotFound; if (selectedAvatarItem != NSNotFound) [self.avatarCollectionView selectItemAtIndexPath:[NSIndexPath indexPathForItem:selectedAvatarItem inSection:0] animated:NO scrollPosition:UICollectionViewScrollPositionCenteredHorizontally]; @@ -791,7 +792,7 @@ referenceSizeForFooterInSection:(NSInteger)section { - (void)setActiveUserState:(MPActiveUserState)activeUserState animated:(BOOL)animated { _activeUserState = activeUserState; - _masterPasswordChoice = nil; + self.masterPasswordChoice = nil; if (activeUserState != MPActiveUserStateMinimized && (!self.active || [MPiOSAppDelegate get].activeUserOID)) { [[MPiOSAppDelegate get] signOutAnimated:YES]; @@ -799,7 +800,7 @@ referenceSizeForFooterInSection:(NSInteger)section { } // Set the entry container's contents. - [_afterUpdates setSuspended:YES]; + [self.afterUpdates setSuspended:YES]; __block BOOL requestFirstResponder = NO; [self.view layoutIfNeeded]; [UIView animateWithDuration:animated? 0.4f: 0 animations:^{ @@ -828,7 +829,7 @@ referenceSizeForFooterInSection:(NSInteger)section { break; } case MPActiveUserStateMasterPasswordConfirmation: { - _masterPasswordChoice = self.entryField.text; + self.masterPasswordChoice = self.entryField.text; self.entryLabel.text = strl( @"Confirm your master password:" ); self.entryField.secureTextEntry = YES; self.entryField.autocapitalizationType = UITextAutocapitalizationTypeNone; @@ -890,7 +891,7 @@ referenceSizeForFooterInSection:(NSInteger)section { [self.view layoutIfNeeded]; } completion:^(BOOL finished) { - [_afterUpdates setSuspended:NO]; + [self.afterUpdates setSuspended:NO]; }]; [self.entryField resignFirstResponder]; diff --git a/platform-darwin/Source/iOS/MasterPassword-Info.plist b/platform-darwin/Source/iOS/MasterPassword-Info.plist index de00a7aa..11501761 100644 --- a/platform-darwin/Source/iOS/MasterPassword-Info.plist +++ b/platform-darwin/Source/iOS/MasterPassword-Info.plist @@ -1,137 +1,137 @@ - - CFBundleDevelopmentRegion - en - CFBundleDisplayName - M. Password - CFBundleDocumentTypes - - - CFBundleTypeExtensions - - mpsites - - CFBundleTypeIconFiles - - Icon-Small - - CFBundleTypeName - Master Password sites - LSHandlerRank - Owner - LSItemContentTypes - - com.lyndir.masterpassword.sites - - - - CFBundleExecutable - ${EXECUTABLE_NAME} - CFBundleIdentifier - $(PRODUCT_BUNDLE_IDENTIFIER) - CFBundleInfoDictionaryVersion - 6.0 - CFBundleName - ${PRODUCT_NAME} - CFBundlePackageType - APPL - CFBundleShortVersionString - [auto] - CFBundleSignature - ???? - CFBundleVersion - [auto] - Fabric - - APIKey - 0d10c90776f5ef5acd01ddbeaca9a6cba4814560 - Kits - - - KitInfo - - KitName - Crashlytics - - - - LSRequiresIPhoneOS - - NSHumanReadableCopyright - © 2011-2017 - UIAppFonts - - Exo2.0-Bold.otf - Exo2.0-ExtraBold.otf - Exo2.0-Regular.otf - Exo2.0-Thin.otf - SourceCodePro-Black.otf - SourceCodePro-Regular.otf - SourceCodePro-ExtraLight.otf - - UIMainStoryboardFile - Storyboard - UIStatusBarHidden - - UIStatusBarStyle - UIStatusBarStyleDefault - UIStatusBarTintParameters - - UINavigationBar - - Style - UIBarStyleDefault - TintColor - - Blue - 0.42745098039215684 - Green - 0.39215686274509803 - Red - 0.37254901960784315 - - Translucent - - - - UISupportedInterfaceOrientations - - UIInterfaceOrientationPortrait - UIInterfaceOrientationLandscapeLeft - UIInterfaceOrientationLandscapeRight - - UISupportedInterfaceOrientations~ipad - - UIInterfaceOrientationPortrait - UIInterfaceOrientationPortraitUpsideDown - UIInterfaceOrientationLandscapeLeft - UIInterfaceOrientationLandscapeRight - - UTExportedTypeDeclarations - - - UTTypeConformsTo - - public.utf8-plain-text - - UTTypeDescription - Master Password sites - UTTypeIdentifier - com.lyndir.masterpassword.sites - UTTypeSize320IconFile - Icon-320.png - UTTypeSize64IconFile - Icon-64.png - UTTypeTagSpecification - - public.filename-extension - - mpsites - - - - - + + CFBundleDevelopmentRegion + en + CFBundleDisplayName + M. Password + CFBundleDocumentTypes + + + CFBundleTypeExtensions + + mpsites + + CFBundleTypeIconFiles + + Icon-Small + + CFBundleTypeName + Master Password sites + LSHandlerRank + Owner + LSItemContentTypes + + com.lyndir.masterpassword.sites + + + + CFBundleExecutable + ${EXECUTABLE_NAME} + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + ${PRODUCT_NAME} + CFBundlePackageType + APPL + CFBundleShortVersionString + [auto] + CFBundleSignature + ???? + CFBundleVersion + [auto] + Fabric + + APIKey + 0d10c90776f5ef5acd01ddbeaca9a6cba4814560 + Kits + + + KitInfo + + KitName + Crashlytics + + + + LSRequiresIPhoneOS + + NSHumanReadableCopyright + © 2011-2017 + UIAppFonts + + Exo2.0-Bold.otf + Exo2.0-ExtraBold.otf + Exo2.0-Regular.otf + Exo2.0-Thin.otf + SourceCodePro-Black.otf + SourceCodePro-Regular.otf + SourceCodePro-ExtraLight.otf + + UIMainStoryboardFile + Storyboard + UIStatusBarHidden + + UIStatusBarStyle + UIStatusBarStyleDefault + UIStatusBarTintParameters + + UINavigationBar + + Style + UIBarStyleDefault + TintColor + + Blue + 0.42745098039215684 + Green + 0.39215686274509803 + Red + 0.37254901960784315 + + Translucent + + + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UTExportedTypeDeclarations + + + UTTypeConformsTo + + public.utf8-plain-text + + UTTypeDescription + Master Password sites + UTTypeIdentifier + com.lyndir.masterpassword.sites + UTTypeSize320IconFile + Icon-320.png + UTTypeSize64IconFile + Icon-64.png + UTTypeTagSpecification + + public.filename-extension + + mpsites + + + + + diff --git a/platform-darwin/Source/iOS/NSString+MPMarkDown.h b/platform-darwin/Source/iOS/NSString+MPMarkDown.h index 812cbf7b..4259585c 100644 --- a/platform-darwin/Source/iOS/NSString+MPMarkDown.h +++ b/platform-darwin/Source/iOS/NSString+MPMarkDown.h @@ -1,20 +1,20 @@ -/** - * Copyright Maarten Billemont (http://www.lhunath.com, lhunath@lyndir.com) - * - * See the enclosed file LICENSE for license information (LGPLv3). If you did - * not receive this file, see http://www.gnu.org/licenses/lgpl-3.0.txt - * - * @author Maarten Billemont - * @license http://www.gnu.org/licenses/lgpl-3.0.txt - */ - +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. // -// NSString(MPMarkDown).h -// NSString(MPMarkDown) +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. // -// Created by lhunath on 2014-09-28. -// Copyright, lhunath (Maarten Billemont) 2014. All rights reserved. +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. // +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== #import diff --git a/platform-darwin/Source/iOS/NSString+MPMarkDown.m b/platform-darwin/Source/iOS/NSString+MPMarkDown.m index 901e5f0b..2d62993f 100644 --- a/platform-darwin/Source/iOS/NSString+MPMarkDown.m +++ b/platform-darwin/Source/iOS/NSString+MPMarkDown.m @@ -1,20 +1,20 @@ -/** -* Copyright Maarten Billemont (http://www.lhunath.com, lhunath@lyndir.com) -* -* See the enclosed file LICENSE for license information (LGPLv3). If you did -* not receive this file, see http://www.gnu.org/licenses/lgpl-3.0.txt -* -* @author Maarten Billemont -* @license http://www.gnu.org/licenses/lgpl-3.0.txt -*/ - +//============================================================================== +// This file is part of Master Password. +// Copyright (c) 2011-2017, Maarten Billemont. // -// NSString(MPMarkDown).h -// NSString(MPMarkDown) +// Master Password is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. // -// Created by lhunath on 2014-09-28. -// Copyright, lhunath (Maarten Billemont) 2014. All rights reserved. +// Master Password is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. // +// You can find a copy of the GNU General Public License in the +// LICENSE file. Alternatively, see . +//============================================================================== #import "NSString+MPMarkDown.h" #import "markdown_lib.h" diff --git a/platform-darwin/Source/iOS/Storyboard.storyboard b/platform-darwin/Source/iOS/Storyboard.storyboard index 34cd5d29..31e785a9 100644 --- a/platform-darwin/Source/iOS/Storyboard.storyboard +++ b/platform-darwin/Source/iOS/Storyboard.storyboard @@ -4,7 +4,6 @@ - @@ -104,7 +103,7 @@ - + - + - + - + - + - + - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + - - + - + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + - - - - - - - - - - - - - + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - + + + + + + + + + - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + - - + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + - + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - + - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + + + + + + - - - + + + + + + + + + + + + + + + + + + @@ -1743,12 +1727,11 @@ eg. apple.com, rmitchell@twitter.com + - - - - + + @@ -1780,7 +1763,7 @@ eg. apple.com, rmitchell@twitter.com - +