diff --git a/HNHUi b/HNHUi index 5655cb45..260aa47e 160000 --- a/HNHUi +++ b/HNHUi @@ -1 +1 @@ -Subproject commit 5655cb45194b9542cf2abf58cad6fb6508c22773 +Subproject commit 260aa47e80c53df5a0648f868482ba767cfd1fc2 diff --git a/MacPass/Base.lproj/InspectorView.xib b/MacPass/Base.lproj/InspectorView.xib index 4d72c25f..6808ec9f 100644 --- a/MacPass/Base.lproj/InspectorView.xib +++ b/MacPass/Base.lproj/InspectorView.xib @@ -20,6 +20,8 @@ NSImageView NSScrollView NSScroller + NSSecureTextField + NSSecureTextFieldCell NSSegmentedCell NSSegmentedControl NSTabView @@ -200,13 +202,13 @@ {{0, 31}, {293, 399}} - + _NS:9 1 - + 256 @@ -214,6 +216,7 @@ 268 {{17, 365}, {35, 14}} + _NS:1535 YES @@ -246,6 +249,7 @@ 268 {{20, 335}, {253, 22}} + _NS:9 YES @@ -280,6 +284,7 @@ 268 {{17, 313}, {58, 14}} + _NS:1535 YES @@ -300,6 +305,7 @@ 268 {{20, 283}, {253, 22}} + _NS:9 YES @@ -321,6 +327,7 @@ 268 {{20, 231}, {253, 22}} + _NS:9 YES @@ -342,6 +349,7 @@ 268 {{17, 261}, {25, 14}} + _NS:1535 YES @@ -362,7 +370,8 @@ 268 {{17, 209}, {58, 14}} - + + _NS:1535 YES @@ -377,32 +386,13 @@ NO - - - 268 - {{20, 179}, {253, 22}} - - - _NS:9 - YES - - -1804599231 - 272630784 - - - _NS:9 - - YES - - - - NO - 268 {{20, 152}, {253, 19}} + + _NS:9 {250, 750} YES @@ -431,6 +421,7 @@ 268 {{17, 35}, {259, 11}} + _NS:1535 YES @@ -455,7 +446,8 @@ 268 {{17, 16}, {259, 11}} - + + _NS:1535 YES @@ -470,8 +462,64 @@ NO + + + 268 + {{20, 179}, {214, 22}} + + + + _NS:9 + YES + + 342884416 + 272630848 + + + _NS:9 + + YES + + + + NSAllRomanInputSourcesLocaleIdentifier + + + NO + + + + 268 + {{242, 177}, {31, 25}} + + + + _NS:22 + YES + + 67108864 + 134217728 + + + _NS:22 + + -926662656 + 163 + + NSImage + NSQuickLookTemplate + + + + 400 + 75 + + NO + {293, 399} + + _NS:11 @@ -655,7 +703,7 @@ - + 256 @@ -663,7 +711,6 @@ 268 {{241, 362}, {32, 19}} - _NS:9 YES @@ -692,7 +739,6 @@ 268 {{17, 365}, {79, 14}} - _NS:1535 YES @@ -722,7 +768,6 @@ {251, 332} - _NS:13 YES @@ -807,7 +852,6 @@ {{1, 1}, {251, 332}} - _NS:11 @@ -819,7 +863,6 @@ -2147483392 {{37, 1}, {16, 2}} - _NS:58 NO @@ -832,8 +875,6 @@ -2147483392 {{1, 147}, {52, 16}} - - _NS:60 NO 1 @@ -844,7 +885,6 @@ {{20, 20}, {253, 334}} - _NS:9 133682 @@ -858,8 +898,6 @@ {293, 399} - - Attachments @@ -1045,13 +1083,13 @@ - + 6 YES YES - + @@ -1128,14 +1166,6 @@ 1287 - - - passwordTextField - - - - 1284 - _popUpPasswordGenerator: @@ -1232,6 +1262,22 @@ 2244 + + + passwordTextField + + + + 2279 + + + + togglePassword + + + + 2280 + imageView @@ -2198,6 +2244,70 @@ 29 3 + + + 5 + 0 + + 6 + 1 + + 8 + + 1000 + + 6 + 24 + 3 + + + + 6 + 0 + + 6 + 1 + + 20 + + 1000 + + 8 + 29 + 3 + + + + 3 + 0 + + 4 + 1 + + 8 + + 1000 + + 6 + 24 + 3 + + + + 3 + 0 + + 4 + 1 + + 8 + + 1000 + + 6 + 24 + 3 + 6 @@ -2214,22 +2324,6 @@ 29 3 - - - 3 - 0 - - 4 - 1 - - 8 - - 1000 - - 9 - 40 - 3 - 5 @@ -2246,40 +2340,8 @@ 29 3 - - - 6 - 0 - - 6 - 1 - - 20 - - 1000 - - 8 - 29 - 3 - - - - 3 - 0 - - 4 - 1 - - 8 - - 1000 - - 9 - 40 - 3 - - + 5 0 @@ -2294,6 +2356,22 @@ 29 3 + + + 3 + 0 + + 4 + 1 + + 8 + + 1000 + + 6 + 24 + 3 + 3 @@ -2589,10 +2667,11 @@ - + + @@ -2687,19 +2766,6 @@ - - 1232 - - - - - - - - 1273 - - - 1231 @@ -2823,11 +2889,6 @@ - - 1672 - - - 1697 @@ -2903,16 +2964,6 @@ - - 1901 - - - - - 1903 - - - 1884 @@ -3932,11 +3983,6 @@ - - 2082 - - - 2083 @@ -4442,6 +4488,62 @@ + + 2263 + + + + + + + + 2264 + + + + + 2266 + + + + + 2267 + + + + + 2268 + + + + + 2273 + + + + + + + + 2274 + + + + + 2275 + + + + + 2276 + + + + + 2278 + + + @@ -4453,8 +4555,6 @@ com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin HNHRoundedTextField @@ -4480,8 +4580,6 @@ com.apple.InterfaceBuilder.CocoaPlugin HNHRoundedTextFieldCell com.apple.InterfaceBuilder.CocoaPlugin - HNHRoundedSecureTextFieldCell - com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin @@ -4502,7 +4600,7 @@ com.apple.InterfaceBuilder.CocoaPlugin - + @@ -4521,12 +4619,14 @@ + - - - + + + + @@ -4608,7 +4708,6 @@ com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin @@ -4627,8 +4726,6 @@ com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin @@ -4727,7 +4824,6 @@ com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin @@ -4811,6 +4907,19 @@ com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin + HNHRoundedSecureTextField + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin @@ -4857,7 +4966,7 @@ - 2261 + 2280 @@ -4870,11 +4979,22 @@ - HNHRoundedSecureTextFieldCell - NSTextFieldCell + HNHRoundedSecureTextField + NSSecureTextField + + toggleDisplay: + id + + + toggleDisplay: + + toggleDisplay: + id + + IBProjectSource - ./Classes/HNHRoundedSecureTextFieldCell.h + ./Classes/HNHRoundedSecureTextField.h @@ -4973,10 +5093,11 @@ NSTextField NSTextField NSTextView - NSTextField + HNHRoundedSecureTextField NSTabView NSTextField NSTextField + NSButton NSTextField @@ -5030,7 +5151,7 @@ passwordTextField - NSTextField + HNHRoundedSecureTextField tabView @@ -5044,6 +5165,10 @@ titleTextField NSTextField + + togglePassword + NSButton + usernameTextField NSTextField @@ -5114,6 +5239,7 @@ {15, 15} {8, 8} {128, 128} + {21, 16} {8, 8} {15, 15} diff --git a/MacPass/Base.lproj/PasswordInputView.xib b/MacPass/Base.lproj/PasswordInputView.xib index b018a6eb..3e034fd0 100644 --- a/MacPass/Base.lproj/PasswordInputView.xib +++ b/MacPass/Base.lproj/PasswordInputView.xib @@ -95,7 +95,7 @@ _NS:22 - -1228652544 + -926662656 163 NSImage @@ -606,6 +606,38 @@ 40 3 + + + 9 + 0 + + 9 + 1 + + 0.0 + + 1000 + + 6 + 24 + 2 + + + + 3 + 0 + + 4 + 1 + + 8 + + 1000 + + 6 + 24 + 3 + 3 @@ -654,38 +686,6 @@ 24 2 - - - 9 - 0 - - 9 - 1 - - 0.0 - - 1000 - - 6 - 24 - 2 - - - - 3 - 0 - - 4 - 1 - - 8 - - 1000 - - 6 - 24 - 3 - 5 @@ -1119,11 +1119,11 @@ - - + + diff --git a/MacPass/DatabaseSettingsWindow.xib b/MacPass/DatabaseSettingsWindow.xib index 638312ed..aa021f30 100644 --- a/MacPass/DatabaseSettingsWindow.xib +++ b/MacPass/DatabaseSettingsWindow.xib @@ -71,7 +71,6 @@ {{384, 13}, {69, 32}} - _NS:9 YES @@ -428,7 +427,6 @@ {{142, 69}, {164, 19}} - _NS:9 YES @@ -467,7 +465,7 @@ _NS:22 - -1228652544 + -926662656 163 NSImage @@ -2825,12 +2823,12 @@ 3 - + diff --git a/MacPass/MPInspectorViewController.h b/MacPass/MPInspectorViewController.h index 33215c5b..3ca51dbe 100644 --- a/MacPass/MPInspectorViewController.h +++ b/MacPass/MPInspectorViewController.h @@ -12,6 +12,7 @@ @class KdbEntry; @class KdbGroup; @class HNHGradientView; +@class HNHRoundedSecureTextField; @class MPDocumentWindowController; @interface MPInspectorViewController : MPViewController @@ -22,7 +23,7 @@ @property (weak) IBOutlet NSTextField *titleTextField; @property (weak) IBOutlet NSTextField *usernameTextField; @property (weak) IBOutlet NSTextField *URLTextField; -@property (weak) IBOutlet NSTextField *passwordTextField; +@property (weak) IBOutlet HNHRoundedSecureTextField *passwordTextField; @property (weak) IBOutlet NSTextField *titleOrNameLabel; @property (weak) IBOutlet HNHGradientView *bottomBar; @property (weak) IBOutlet NSTextField *createdTextField; @@ -32,6 +33,7 @@ @property (weak) IBOutlet NSTableView *customFieldsTableView; @property (unsafe_unretained) IBOutlet NSTextView *notesTextView; @property (weak) IBOutlet NSTextField *customFieldsTextField; +@property (weak) IBOutlet NSButton *togglePassword; /* Seperate call to ensure alle registered objects are in place */ diff --git a/MacPass/MPInspectorViewController.m b/MacPass/MPInspectorViewController.m index 8a88f51c..c41a398d 100644 --- a/MacPass/MPInspectorViewController.m +++ b/MacPass/MPInspectorViewController.m @@ -32,6 +32,7 @@ #import "HNHGradientView.h" #import "HNHTableRowView.h" +#import "HNHRoundedSecureTextField.h" enum { MPGeneralTab, @@ -53,6 +54,8 @@ enum { @property (nonatomic, weak) NSDate *modificationDate; @property (nonatomic, weak) NSDate *creationDate; +@property (nonatomic, assign) BOOL showPassword; + @property (nonatomic, assign) NSUInteger activeTab; @property (weak) IBOutlet NSTabView *tabView; @property (strong) NSArrayController *attachmentsController; @@ -75,6 +78,7 @@ enum { - (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil { self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]; if (self) { + _showPassword = NO; _selectedEntry = nil; _selectedGroup = nil; _attachmentsController = [[NSArrayController alloc] init]; @@ -106,6 +110,9 @@ enum { [_customFieldsTableView bind:NSContentBinding toObject:self.customFieldsController withKeyPath:@"arrangedObjects" options:nil]; [_customFieldsTableView setDelegate:self]; + [self.passwordTextField bind:@"showPassword" toObject:self withKeyPath:@"showPassword" options:nil]; + [self.togglePassword bind:NSValueBinding toObject:self withKeyPath:@"showPassword" options:nil]; + [self _clearContent]; } @@ -255,6 +262,7 @@ enum { enabled &= (self.selectedEntry != nil); [self.passwordTextField setEnabled:enabled]; + [self.togglePassword setEnabled:enabled]; [self.usernameTextField setEnabled:enabled]; [self.URLTextField setEnabled:enabled]; [self.generatePasswordButton setEnabled:enabled]; diff --git a/MacPass/MacPass-Info.plist b/MacPass/MacPass-Info.plist index af1bf220..e28404f1 100644 --- a/MacPass/MacPass-Info.plist +++ b/MacPass/MacPass-Info.plist @@ -48,7 +48,7 @@ CFBundleSignature ???? CFBundleVersion - 2288 + 2301 LSMinimumSystemVersion ${MACOSX_DEPLOYMENT_TARGET} NSHumanReadableCopyright