From ce49478691a3477d10d8f269bccdd47e39808898 Mon Sep 17 00:00:00 2001 From: michael starke Date: Thu, 4 Dec 2014 21:37:31 +0100 Subject: [PATCH] Added UUID display to EntryInspector --- MacPass/Base.lproj/EntryInspectorView.xib | 59 +++++++++++++++++------ MacPass/MPEntryInspectorViewController.h | 2 + MacPass/MPEntryInspectorViewController.m | 3 ++ 3 files changed, 48 insertions(+), 16 deletions(-) diff --git a/MacPass/Base.lproj/EntryInspectorView.xib b/MacPass/Base.lproj/EntryInspectorView.xib index 8b7f2df8..bffe9c39 100644 --- a/MacPass/Base.lproj/EntryInspectorView.xib +++ b/MacPass/Base.lproj/EntryInspectorView.xib @@ -27,6 +27,7 @@ + @@ -445,10 +446,10 @@ - + - + @@ -456,7 +457,7 @@ - + @@ -470,7 +471,7 @@ - + @@ -478,7 +479,7 @@ - + @@ -492,7 +493,7 @@ - + @@ -506,7 +507,7 @@ - + @@ -514,7 +515,7 @@ - + @@ -522,7 +523,7 @@ - + @@ -550,7 +551,7 @@ - + @@ -604,13 +605,32 @@ - + + + + + + + + + + + + + + + + + + + + @@ -645,12 +665,19 @@ + + + + + - + + + diff --git a/MacPass/MPEntryInspectorViewController.h b/MacPass/MPEntryInspectorViewController.h index 56b67fd2..c5747bcb 100644 --- a/MacPass/MPEntryInspectorViewController.h +++ b/MacPass/MPEntryInspectorViewController.h @@ -20,6 +20,8 @@ @property (weak) IBOutlet NSTextField *URLTextField; @property (weak) IBOutlet HNHRoundedSecureTextField *passwordTextField; +@property (weak) IBOutlet NSTextField *uuidTextField; + @property (weak) IBOutlet NSTextField *createdTextField; @property (weak) IBOutlet NSTextField *modifiedTextField; diff --git a/MacPass/MPEntryInspectorViewController.m b/MacPass/MPEntryInspectorViewController.m index de2d87c2..1c56595e 100644 --- a/MacPass/MPEntryInspectorViewController.m +++ b/MacPass/MPEntryInspectorViewController.m @@ -386,6 +386,8 @@ typedef NS_ENUM(NSUInteger, MPEntryTab) { options:@{ NSValueTransformerNameBindingOption:MPExpiryDateValueTransformer }]; [self.expiresCheckButton bind:NSValueBinding toObject:self.entry.timeInfo withKeyPath:NSStringFromSelector(@selector(expires)) options:nil]; [self.tagsTokenField bind:NSValueBinding toObject:self.entry withKeyPath:NSStringFromSelector(@selector(tags)) options:nil]; + [self.uuidTextField bind:NSValueBinding toObject:self.entry.uuid withKeyPath:NSStringFromSelector(@selector(UUIDString)) options:nil]; + self.uuidTextField.editable = NO; /* Setup enable/disable */ for(id item in items) { @@ -397,6 +399,7 @@ typedef NS_ENUM(NSUInteger, MPEntryTab) { [item unbind:NSValueBinding]; [item unbind:NSEnabledBinding]; } + [self.uuidTextField unbind:NSValueBinding]; [self.expiresCheckButton unbind:NSTitleBinding]; } }