From 7ea34a2300990c31784a59b85e5a87b0065f673c Mon Sep 17 00:00:00 2001 From: michael starke Date: Tue, 19 Feb 2013 19:59:18 +0100 Subject: [PATCH] NSOutlineView change to use no Autolayout since it fucked up resizing --- MacPass.xcodeproj/project.pbxproj | 55 +++-- MacPass/EntryView.xib | 7 +- MacPass/GeneralSettings.xib | 217 ++++++++++---------- MacPass/KdbGroup+MPAdditions.h | 18 ++ MacPass/KdbGroup+MPAdditions.m | 24 +++ MacPass/MPAppDelegate.m | 11 - MacPass/MPDatabaseController.h | 6 +- MacPass/MPDatabaseDocument.h | 10 +- MacPass/MPDatabaseDocument.m | 105 ++++++---- MacPass/MPMainWindowController.h | 1 - MacPass/MPMainWindowController.m | 42 ++-- MacPass/MPMainWindowSplitViewDelegate.h | 4 + MacPass/MPMainWindowSplitViewDelegate.m | 49 ++++- MacPass/MPOutlineViewController.m | 11 +- MacPass/MPToolbarDelegate.m | 52 ++++- MacPass/MPViewController.m | 6 + MacPass/MacPass-Info.plist | 2 +- MacPass/MainWindow.xib | 258 ++---------------------- MacPass/OutlineView.xib | 24 +-- MacPass/en.lproj/Credits.rtf | 47 ++--- MacPass/en.lproj/MainMenu.xib | 12 +- 21 files changed, 466 insertions(+), 495 deletions(-) create mode 100644 MacPass/KdbGroup+MPAdditions.h create mode 100644 MacPass/KdbGroup+MPAdditions.m diff --git a/MacPass.xcodeproj/project.pbxproj b/MacPass.xcodeproj/project.pbxproj index 53d3b629..db235f7e 100644 --- a/MacPass.xcodeproj/project.pbxproj +++ b/MacPass.xcodeproj/project.pbxproj @@ -9,6 +9,7 @@ /* Begin PBXBuildFile section */ 4C25D58516CF0F8800F6806C /* WelcomeView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 4C25D58416CF0F8800F6806C /* WelcomeView.xib */; }; 4C25D58716CF0FAA00F6806C /* EntryView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 4C25D58616CF0FAA00F6806C /* EntryView.xib */; }; + 4C2C4C2C16D3BE3700D49295 /* KdbGroup+MPAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 4C2C4C2B16D3BE3700D49295 /* KdbGroup+MPAdditions.m */; }; 4C2E381D16D11FF900037A9D /* 03_ServerTemplate.pdf in Resources */ = {isa = PBXBuildFile; fileRef = 4C2E381A16D11FF900037A9D /* 03_ServerTemplate.pdf */; }; 4C2E381E16D11FF900037A9D /* 04_KlipperTemplate.pdf in Resources */ = {isa = PBXBuildFile; fileRef = 4C2E381B16D11FF900037A9D /* 04_KlipperTemplate.pdf */; }; 4C2E381F16D11FF900037A9D /* 05_LanguagesTemplate.pdf in Resources */ = {isa = PBXBuildFile; fileRef = 4C2E381C16D11FF900037A9D /* 05_LanguagesTemplate.pdf */; }; @@ -62,7 +63,6 @@ 4C77E36715B84A240093A587 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4C77E36615B84A240093A587 /* Cocoa.framework */; }; 4C77E37115B84A240093A587 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 4C77E36F15B84A240093A587 /* InfoPlist.strings */; }; 4C77E37315B84A240093A587 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 4C77E37215B84A240093A587 /* main.m */; }; - 4C77E37715B84A240093A587 /* Credits.rtf in Resources */ = {isa = PBXBuildFile; fileRef = 4C77E37515B84A240093A587 /* Credits.rtf */; }; 4C77E37A15B84A240093A587 /* MPAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 4C77E37915B84A240093A587 /* MPAppDelegate.m */; }; 4C77E37D15B84A240093A587 /* MainMenu.xib in Resources */ = {isa = PBXBuildFile; fileRef = 4C77E37B15B84A240093A587 /* MainMenu.xib */; }; 4C83814215BF4677001AE468 /* MPMainWindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = 4C83814115BF4677001AE468 /* MPMainWindowController.m */; }; @@ -78,6 +78,7 @@ 4CAD747F15B887FD00104512 /* DDXMLNode.m in Sources */ = {isa = PBXBuildFile; fileRef = 4CAD746115B887FD00104512 /* DDXMLNode.m */; settings = {COMPILER_FLAGS = "-fobjc-arc"; }; }; 4CAD748C15B889B700104512 /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4CAD748B15B889B700104512 /* Security.framework */; }; 4CAD748E15B88AC100104512 /* libz.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 4CAD748D15B88AC100104512 /* libz.dylib */; }; + 4CB9339916D3A0DD00A13B5D /* Credits.rtf in Resources */ = {isa = PBXBuildFile; fileRef = 4CB9339716D3A0DD00A13B5D /* Credits.rtf */; }; 4CBA981815BA0DB600721965 /* MPDatabaseDocument.m in Sources */ = {isa = PBXBuildFile; fileRef = 4CBA981715BA0DB600721965 /* MPDatabaseDocument.m */; }; 4CC6259115BA1C99002F5B11 /* MPOutlineViewDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 4CC6259015BA1C99002F5B11 /* MPOutlineViewDelegate.m */; }; 4CD78ABC16D155FF00768A1D /* 07_NotepadTemplate.pdf in Resources */ = {isa = PBXBuildFile; fileRef = 4CD78AB716D155FF00768A1D /* 07_NotepadTemplate.pdf */; }; @@ -92,6 +93,8 @@ /* Begin PBXFileReference section */ 4C25D58416CF0F8800F6806C /* WelcomeView.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = WelcomeView.xib; sourceTree = ""; }; 4C25D58616CF0FAA00F6806C /* EntryView.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = EntryView.xib; sourceTree = ""; }; + 4C2C4C2A16D3BE3700D49295 /* KdbGroup+MPAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "KdbGroup+MPAdditions.h"; sourceTree = ""; }; + 4C2C4C2B16D3BE3700D49295 /* KdbGroup+MPAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "KdbGroup+MPAdditions.m"; sourceTree = ""; }; 4C2E381A16D11FF900037A9D /* 03_ServerTemplate.pdf */ = {isa = PBXFileReference; lastKnownFileType = image.pdf; path = 03_ServerTemplate.pdf; sourceTree = ""; }; 4C2E381B16D11FF900037A9D /* 04_KlipperTemplate.pdf */ = {isa = PBXFileReference; lastKnownFileType = image.pdf; path = 04_KlipperTemplate.pdf; sourceTree = ""; }; 4C2E381C16D11FF900037A9D /* 05_LanguagesTemplate.pdf */ = {isa = PBXFileReference; lastKnownFileType = image.pdf; path = 05_LanguagesTemplate.pdf; sourceTree = ""; }; @@ -196,7 +199,6 @@ 4C77E37015B84A240093A587 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = ""; }; 4C77E37215B84A240093A587 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; 4C77E37415B84A240093A587 /* MacPass-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "MacPass-Prefix.pch"; sourceTree = ""; }; - 4C77E37615B84A240093A587 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.rtf; name = en; path = en.lproj/Credits.rtf; sourceTree = ""; }; 4C77E37815B84A240093A587 /* MPAppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MPAppDelegate.h; sourceTree = ""; }; 4C77E37915B84A240093A587 /* MPAppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MPAppDelegate.m; sourceTree = ""; }; 4C77E37C15B84A240093A587 /* en */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = en; path = en.lproj/MainMenu.xib; sourceTree = ""; }; @@ -225,6 +227,7 @@ 4CAD746315B887FD00104512 /* DDXMLPrivate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DDXMLPrivate.h; sourceTree = ""; }; 4CAD748B15B889B700104512 /* Security.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Security.framework; path = System/Library/Frameworks/Security.framework; sourceTree = SDKROOT; }; 4CAD748D15B88AC100104512 /* libz.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libz.dylib; path = usr/lib/libz.dylib; sourceTree = SDKROOT; }; + 4CB9339816D3A0DD00A13B5D /* en */ = {isa = PBXFileReference; lastKnownFileType = text.rtf; name = en; path = en.lproj/Credits.rtf; sourceTree = ""; }; 4CBA981615BA0DB600721965 /* MPDatabaseDocument.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPDatabaseDocument.h; sourceTree = ""; }; 4CBA981715BA0DB600721965 /* MPDatabaseDocument.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPDatabaseDocument.m; sourceTree = ""; }; 4CC6258F15BA1C99002F5B11 /* MPOutlineViewDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPOutlineViewDelegate.h; sourceTree = ""; }; @@ -268,6 +271,15 @@ name = Views; sourceTree = ""; }; + 4C2C4C2516D3BCEA00D49295 /* KeePassLibAdditions */ = { + isa = PBXGroup; + children = ( + 4C2C4C2A16D3BE3700D49295 /* KdbGroup+MPAdditions.h */, + 4C2C4C2B16D3BE3700D49295 /* KdbGroup+MPAdditions.m */, + ); + name = KeePassLibAdditions; + sourceTree = ""; + }; 4C2E382016D141F700037A9D /* Helper */ = { isa = PBXGroup; children = ( @@ -460,6 +472,7 @@ 4C77E36C15B84A240093A587 /* MacPass */ = { isa = PBXGroup; children = ( + 4C2C4C2516D3BCEA00D49295 /* KeePassLibAdditions */, 4C2E382016D141F700037A9D /* Helper */, 4C586F9C16D07ABD00E7DB57 /* Icons */, 4CA0B30F15BCB85D00654E32 /* General */, @@ -476,11 +489,11 @@ 4C77E36D15B84A240093A587 /* Supporting Files */ = { isa = PBXGroup; children = ( + 4CB9339716D3A0DD00A13B5D /* Credits.rtf */, 4C77E36E15B84A240093A587 /* MacPass-Info.plist */, 4C77E36F15B84A240093A587 /* InfoPlist.strings */, 4C77E37215B84A240093A587 /* main.m */, 4C77E37415B84A240093A587 /* MacPass-Prefix.pch */, - 4C77E37515B84A240093A587 /* Credits.rtf */, ); name = "Supporting Files"; sourceTree = ""; @@ -583,6 +596,7 @@ buildPhases = ( 4C77E35E15B84A240093A587 /* Sources */, 4C77E35F15B84A240093A587 /* Frameworks */, + 4CB9339616D3A04100A13B5D /* ShellScript */, 4C77E36015B84A240093A587 /* Resources */, ); buildRules = ( @@ -629,7 +643,6 @@ buildActionMask = 2147483647; files = ( 4C77E37115B84A240093A587 /* InfoPlist.strings in Resources */, - 4C77E37715B84A240093A587 /* Credits.rtf in Resources */, 4C77E37D15B84A240093A587 /* MainMenu.xib in Resources */, 4CA0B2ED15BCADAC00654E32 /* SettingsWindow.xib in Resources */, 4CA0B2F015BCADC800654E32 /* GeneralSettings.xib in Resources */, @@ -649,11 +662,28 @@ 4CD78ABF16D155FF00768A1D /* 10_ContactTemplate.pdf in Resources */, 4CD78AC016D155FF00768A1D /* 11_CameraTemplate.pdf in Resources */, 4C61EA0516D2FFE200AC519E /* OutlineView.xib in Resources */, + 4CB9339916D3A0DD00A13B5D /* Credits.rtf in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; /* End PBXResourcesBuildPhase section */ +/* Begin PBXShellScriptBuildPhase section */ + 4CB9339616D3A04100A13B5D /* ShellScript */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "#!/bin/bash\nbuildNumber=$(/usr/libexec/PlistBuddy -c \"Print CFBundleVersion\" \"$INFOPLIST_FILE\")\nbuildNumber=$((0x$buildNumber))\nbuildNumber=$(($buildNumber + 1))\nbuildNumber=$(printf \"%X\" $buildNumber)\n/usr/libexec/PlistBuddy -c \"Set :CFBundleVersion $buildNumber\" \"$INFOPLIST_FILE\""; + }; +/* End PBXShellScriptBuildPhase section */ + /* Begin PBXSourcesBuildPhase section */ 4C77E35E15B84A240093A587 /* Sources */ = { isa = PBXSourcesBuildPhase; @@ -715,6 +745,7 @@ 4C3BD51516D276F800389F1F /* MPToolbarDelegate.m in Sources */, 4CAC6F7816D2B54800D79D5E /* MPMainWindowSplitViewDelegate.m in Sources */, 4C61EA0316D2FD0800AC519E /* MPOutlineViewController.m in Sources */, + 4C2C4C2C16D3BE3700D49295 /* KdbGroup+MPAdditions.m in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -729,14 +760,6 @@ name = InfoPlist.strings; sourceTree = ""; }; - 4C77E37515B84A240093A587 /* Credits.rtf */ = { - isa = PBXVariantGroup; - children = ( - 4C77E37615B84A240093A587 /* en */, - ); - name = Credits.rtf; - sourceTree = ""; - }; 4C77E37B15B84A240093A587 /* MainMenu.xib */ = { isa = PBXVariantGroup; children = ( @@ -745,6 +768,14 @@ name = MainMenu.xib; sourceTree = ""; }; + 4CB9339716D3A0DD00A13B5D /* Credits.rtf */ = { + isa = PBXVariantGroup; + children = ( + 4CB9339816D3A0DD00A13B5D /* en */, + ); + name = Credits.rtf; + sourceTree = ""; + }; /* End PBXVariantGroup section */ /* Begin XCBuildConfiguration section */ diff --git a/MacPass/EntryView.xib b/MacPass/EntryView.xib index 744353ab..7fe5b5f2 100644 --- a/MacPass/EntryView.xib +++ b/MacPass/EntryView.xib @@ -50,7 +50,7 @@ {703, 547} - + _NS:13 YES NO @@ -214,6 +214,7 @@ {{1, 119}, {223, 15}} + _NS:60 NO 1 @@ -240,7 +241,7 @@ {703, 564} - + _NS:9 133680 @@ -371,7 +372,7 @@ - 85 + 110 diff --git a/MacPass/GeneralSettings.xib b/MacPass/GeneralSettings.xib index 9d335790..bdd96573 100644 --- a/MacPass/GeneralSettings.xib +++ b/MacPass/GeneralSettings.xib @@ -1,24 +1,24 @@ - 1070 - 11E53 - 2182 - 1138.47 - 569.00 + 1080 + 12C60 + 3084 + 1187.34 + 625.00 com.apple.InterfaceBuilder.CocoaPlugin - 2182 + 3084 - NSTextField + IBNSLayoutConstraint NSCustomObject + NSCustomView NSMenu NSMenuItem NSPopUpButton - NSCustomView NSPopUpButtonCell - IBNSLayoutConstraint + NSTextField NSTextFieldCell @@ -48,12 +48,11 @@ {{146, 292}, {127, 26}} - _NS:9 {750, 751} YES - -2076049856 + -2076180416 2048 LucidaGrande @@ -62,7 +61,7 @@ _NS:9 - 109199615 + 109199360 65 @@ -121,6 +120,7 @@ YES 2 + NO @@ -132,7 +132,7 @@ _NS:1505 YES - 68288064 + 68157504 71304192 Password Encoding @@ -157,6 +157,7 @@ + NO {290, 336} @@ -217,101 +218,21 @@ - - - 5 - 1 - - 5 - 1 - - 20 - - 1000 - 9 - 40 - 3 - - - - - 5 - 0 - - 5 - 1 - - 20 - - 1000 - 9 - 40 - 3 - - - + - 5 + 11 0 - 6 - 1 - - 8 - - 1000 - 9 - 40 - 3 - - - - - 6 - 1 - - 6 - 1 - - 20 - - 1000 - 9 - 40 - 3 - - - - - 3 - 0 - - 3 - 1 - - 20 - - 1000 - 8 - 29 - 3 - - - - - 7 - 0 - - 7 + 11 1 0.0 1000 - 9 - 40 - 5 + 6 + 24 + 2 @@ -324,26 +245,106 @@ 20 1000 + 8 29 3 - - + - 11 + 3 + 0 + + 3 + 1 + + 20 + + 1000 + + 8 + 29 + 3 + + + + 6 + 1 + + 6 + 1 + + 20 + + 1000 + + 9 + 40 + 3 + + + + 5 0 - 11 + 6 + 1 + + 8 + + 1000 + + 9 + 40 + 3 + + + + 7 + 0 + + 7 1 0.0 1000 - 6 - 24 - 2 + 9 + 40 + 5 + + + + 5 + 0 + + 5 + 1 + + 20 + + 1000 + + 9 + 40 + 3 + + + + 5 + 1 + + 5 + 1 + + 20 + + 1000 + + 9 + 40 + 3 @@ -451,10 +452,10 @@ + - @@ -482,7 +483,7 @@ - 131 + 142 diff --git a/MacPass/KdbGroup+MPAdditions.h b/MacPass/KdbGroup+MPAdditions.h new file mode 100644 index 00000000..3f53ce45 --- /dev/null +++ b/MacPass/KdbGroup+MPAdditions.h @@ -0,0 +1,18 @@ +// +// KdbGroup+MPAdditions.h +// MacPass +// +// Created by michael starke on 19.02.13. +// Copyright (c) 2013 HicknHack Software GmbH. All rights reserved. +// + +#import "KdbLib.h" + +@interface KdbGroup (MPAdditions) + ++ (KdbGroup *)group; ++ (KdbGroup *)groupWithName:(NSString *)name; + ++ (void)refreshModificationTime; + +@end diff --git a/MacPass/KdbGroup+MPAdditions.m b/MacPass/KdbGroup+MPAdditions.m new file mode 100644 index 00000000..fde67cb5 --- /dev/null +++ b/MacPass/KdbGroup+MPAdditions.m @@ -0,0 +1,24 @@ +// +// KdbGroup+MPAdditions.m +// MacPass +// +// Created by michael starke on 19.02.13. +// Copyright (c) 2013 HicknHack Software GmbH. All rights reserved. +// + +#import "KdbGroup+MPAdditions.h" + +@implementation KdbGroup (MPAdditions) + ++ (KdbGroup *)group { + KdbGroup *group = [[KdbGroup alloc] init]; + [group setName:@"Default"]; + return [group autorelease]; +} + ++ (KdbGroup *)groupWithName:(NSString *)name { + KdbGroup *group = [KdbGroup group]; + [group setName:name]; + return group; +} +@end diff --git a/MacPass/MPAppDelegate.m b/MacPass/MPAppDelegate.m index b321fc00..b03f6284 100644 --- a/MacPass/MPAppDelegate.m +++ b/MacPass/MPAppDelegate.m @@ -36,17 +36,6 @@ [self.settingsController showWindow:_settingsController.window]; } -- (void)newDocument:(id)sender { -} - -- (void)performClose:(id)sender { - NSLog(@"Close"); -} - -- (void)openDocument:(id)sender { - [self.mainWindowController openDocument]; -} - - (void)toolbarItemPressed:(id)sender { NSLog(@"Pressed %@", sender); } diff --git a/MacPass/MPDatabaseController.h b/MacPass/MPDatabaseController.h index ff5dc1f5..71f04546 100644 --- a/MacPass/MPDatabaseController.h +++ b/MacPass/MPDatabaseController.h @@ -20,10 +20,6 @@ APPKIT_EXTERN NSString *const MPDatabaseControllerDidCloseDatabaseNotification; */ APPKIT_EXTERN NSString *const MPDatabaseControllerDatabaseKey; -typedef enum{ - MPDatabaseVersion1, - MPDatabaseVersion2 -} MPDatabaseVersion; @class MPDatabaseDocument; @@ -33,7 +29,7 @@ typedef enum{ + (MPDatabaseController *)defaultController; -- (MPDatabaseDocument *)createDatabase:(MPDatabaseVersion )version password:(NSString *)password keyfile:(NSURL *)key; +//- (MPDatabaseDocument *)createDatabase:(MPDatabaseVersion )version password:(NSString *)password keyfile:(NSURL *)key; - (MPDatabaseDocument *)openDatabase:(NSURL *)file password:(NSString *)password keyfile:(NSURL *)key; @end diff --git a/MacPass/MPDatabaseDocument.h b/MacPass/MPDatabaseDocument.h index a6b6272b..9062b9d8 100644 --- a/MacPass/MPDatabaseDocument.h +++ b/MacPass/MPDatabaseDocument.h @@ -11,6 +11,11 @@ APPKIT_EXTERN NSString *const MPDidLoadDataBaseNotification; APPKIT_EXTERN NSString *const MPDataBaseDocumentDocumentKey; +typedef enum { + MPDatabaseVersion3, + MPDatabaseVersion4 +} MPDatabaseVersion; + @class KdbPassword; @class KdbGroup; @@ -18,10 +23,13 @@ APPKIT_EXTERN NSString *const MPDataBaseDocumentDocumentKey; @property (retain, readonly) KdbGroup *root; @property (retain, readonly) NSURL *file; -@property (retain, readonly) KdbPassword *password; +@property (nonatomic,retain) NSString *password; +@property (nonatomic, retain) NSURL *key; +@property (assign, readonly) MPDatabaseVersion version; + (id)documentWithFile:(NSURL *)file password:(NSString *)password keyfile:(NSURL *)key; - (id)initWithFile:(NSURL *)file password:(NSString *)password keyfile:(NSURL *)key; +- (id)initWithNewDatabase:(MPDatabaseVersion)version; /* Saves the current database to the filesystem Tries to use the stored password and file path diff --git a/MacPass/MPDatabaseDocument.m b/MacPass/MPDatabaseDocument.m index fad363e2..90db2539 100644 --- a/MacPass/MPDatabaseDocument.m +++ b/MacPass/MPDatabaseDocument.m @@ -8,6 +8,8 @@ #import "MPDatabaseDocument.h" #import "KdbLib.h" +#import "Kdb4Node.h" +#import "Kdb3Node.h" NSString *const MPDidLoadDataBaseNotification = @"DidLoadDataBaseNotification"; @@ -15,7 +17,8 @@ NSString *const MPDidLoadDataBaseNotification = @"DidLoadDataBaseNotification"; @property (retain) KdbTree *tree; @property (retain) NSURL *file; -@property (retain) KdbPassword *password; +@property (nonatomic, readonly) KdbPassword *passwordHash; +@property (assign) MPDatabaseVersion version; @end @@ -29,6 +32,27 @@ NSString *const MPDidLoadDataBaseNotification = @"DidLoadDataBaseNotification"; // create empty document return [self initWithFile:nil password:nil keyfile:nil]; } + +- (id)initWithNewDatabaseVersion:(MPDatabaseVersion)version { + self = [super init]; + if(self) { + switch(version) { + case MPDatabaseVersion3: + self.tree = [[[Kdb3Tree alloc] init] autorelease]; + break; + case MPDatabaseVersion4: + self.tree = [[[Kdb4Tree alloc] init] autorelease]; + break; + default: + [self release]; + return nil; + } + KdbGroup *newGroup = [self.tree createGroup:self.tree.root]; + newGroup.name = @"Default"; + } + return self; +} + /* Designated initalizeder */ @@ -39,50 +63,29 @@ NSString *const MPDidLoadDataBaseNotification = @"DidLoadDataBaseNotification"; /* Create an empty file */ - if(!file) { - self.tree = [[[KdbTree alloc] init] autorelease]; - self.tree.root = [[[KdbGroup alloc] init] autorelease]; - [self.tree.root setName:NSLocalizedString(@"INITIAL_GROUP", @"")]; + self.file = file; + self.key = key; + self.password = password; + @try { + self.tree = [KdbReaderFactory load:[self.file path] withPassword:self.passwordHash]; } - /* - Try to load a given file - */ - else { - self.file = file; - const BOOL hasPassword = (password != nil); - const BOOL hasKeyfile = (key != nil); - - // Create the password for the given parameters - if( hasPassword && hasKeyfile) { - self.password = [[[KdbPassword alloc] initWithPassword:password encoding:NSUTF8StringEncoding keyfile:[key path]] autorelease]; - } - else if( hasPassword ) { - self.password = [[[KdbPassword alloc] initWithPassword:password encoding:NSUTF8StringEncoding] autorelease]; - } - else if( hasKeyfile ) { - self.password = [[[KdbPassword alloc] initWithKeyfile:[key path]] autorelease]; - } - else { - NSLog(@"Error: No password or keyfile given!"); - } - - @try { - self.tree = [KdbReaderFactory load:[self.file path] withPassword:self.password]; - } - @catch (NSException *exception) { - NSLog(@"%@", [exception description]); - } - + @catch (NSException *exception) { + NSLog(@"%@", [exception description]); + [self release]; + return self; + } + + if([self.tree isKindOfClass:[Kdb4Tree class]]) { + self.version = MPDatabaseVersion4; + } + else if( [self.tree isKindOfClass:[Kdb3Tree class]]) { + self.version = MPDatabaseVersion3; } - } - // Test if something went wrong and nil out if so - if( self.tree == nil) { - [self release]; - self = nil; } return self; } + - (void)dealloc { self.tree = nil; @@ -98,9 +101,9 @@ NSString *const MPDidLoadDataBaseNotification = @"DidLoadDataBaseNotification"; - (BOOL)save { NSError *fileError; - if( self.password && [self.file checkResourceIsReachableAndReturnError:&fileError] ) { + if( [self.file checkResourceIsReachableAndReturnError:&fileError] ) { @try { - [KdbWriterFactory persist:self.tree file:[self.file path] withPassword:self.password]; + [KdbWriterFactory persist:self.tree file:[self.file path] withPassword:self.passwordHash]; } @catch (NSException *exception) { NSLog(@"%@", [exception description]); @@ -113,4 +116,24 @@ NSString *const MPDidLoadDataBaseNotification = @"DidLoadDataBaseNotification"; - (BOOL)saveAsFile:(NSURL *)file withPassword:(NSString *)password keyfile:(NSURL *)key { return NO; } + +- (KdbPassword *)passwordHash { + + // Create the password for the given parameters + if( self.password && self.key) { + return [[[KdbPassword alloc] initWithPassword:self.password encoding:NSUTF8StringEncoding keyfile:[self.key path]] autorelease]; + } + + if( self.password ) { + return [[[KdbPassword alloc] initWithPassword:self.password encoding:NSUTF8StringEncoding] autorelease]; + } + + if( self.key ) { + return [[[KdbPassword alloc] initWithKeyfile:[self.key path]] autorelease]; + } + + NSLog(@"Error: No password or keyfile given!"); + return nil; +} + @end diff --git a/MacPass/MPMainWindowController.h b/MacPass/MPMainWindowController.h index 2d30866c..5f64b18d 100644 --- a/MacPass/MPMainWindowController.h +++ b/MacPass/MPMainWindowController.h @@ -12,7 +12,6 @@ @interface MPMainWindowController : NSWindowController -- (void)openDocument; - (void)showEntries; /* Sets the content View controller diff --git a/MacPass/MPMainWindowController.m b/MacPass/MPMainWindowController.m index 74e4c213..9ad43427 100644 --- a/MacPass/MPMainWindowController.m +++ b/MacPass/MPMainWindowController.m @@ -12,21 +12,24 @@ #import "MPEntryViewController.h" #import "MPToolbarDelegate.h" #import "MPOutlineViewController.h" +#import "MPMainWindowSplitViewDelegate.h" @interface MPMainWindowController () -@property (assign) IBOutlet NSToolbar *toolbar; + @property (assign) IBOutlet NSView *outlineView; @property (assign) IBOutlet NSSplitView *splitView; @property (assign) IBOutlet NSView *contentView; @property (retain) IBOutlet NSView *welcomeView; +@property (retain) NSToolbar *toolbar; @property (retain) MPPasswordInputController *passwordInputController; @property (retain) MPEntryViewController *entryViewController; @property (retain) MPOutlineViewController *outlineViewController; @property (retain) MPToolbarDelegate *toolbarDelegate; +@property (retain) MPMainWindowSplitViewDelegate *splitViewDelegate; @end @@ -35,8 +38,9 @@ -(id)init { self = [super initWithWindowNibName:@"MainWindow" owner:self]; if( self ) { - self.toolbarDelegate = [[[MPToolbarDelegate alloc] init] autorelease]; - self.outlineViewController = [[[MPOutlineViewController alloc] init] autorelease]; + _toolbarDelegate = [[MPToolbarDelegate alloc] init]; + _outlineViewController = [[MPOutlineViewController alloc] init]; + _splitViewDelegate = [[MPMainWindowSplitViewDelegate alloc] init]; [[NSBundle mainBundle] loadNibNamed:@"WelcomeView" owner:self topLevelObjects:NULL]; [self.welcomeView setAutoresizingMask:NSViewWidthSizable | NSViewHeightSizable]; @@ -57,15 +61,23 @@ - (void)windowDidLoad { [super windowDidLoad]; + const CGFloat minimumWindowWidth = MPMainWindowSplitViewDelegateMinimumContentWidth + MPMainWindowSplitViewDelegateMinimumOutlineWidth + [self.splitView dividerThickness]; + [self.window setMinSize:NSMakeSize( minimumWindowWidth, 400)]; + + _toolbar = [[NSToolbar alloc] initWithIdentifier:@"MainWindowToolbar"]; + [self.toolbar setAllowsUserCustomization:YES]; [self.toolbar setDelegate:self.toolbarDelegate]; + [self.window setToolbar:self.toolbar]; + + [self.splitView setDelegate:self.splitViewDelegate]; NSRect frame = [self.outlineView frame]; - frame.size.height -= 1; - frame.origin.y = 10; +// frame.size.height -= 1; +// frame.origin.y = 10; [self.outlineViewController.view setFrame:frame]; [self.outlineViewController.view setAutoresizingMask:NSViewWidthSizable | NSViewHeightSizable]; - [self.splitView replaceSubview:self.outlineView with:self.outlineViewController.view]; - + [self.splitView replaceSubview:self.outlineView with:[self.outlineViewController view]]; + [self.splitView adjustSubviews]; [self setContentViewController:nil]; } @@ -94,18 +106,16 @@ else { [self.contentView addSubview:newContentView]; } + [self.splitView adjustSubviews]; /* Set focus AFTER having added the view */ [self.window makeFirstResponder:[viewController reconmendedFirstResponder]]; } -- (void)didOpenDocument:(NSNotification *)notification { - [self showEntries]; -} +#pragma mark Actions - -- (void)openDocument { +- (void)openDocument:(id)sender { if(!self.passwordInputController) { self.passwordInputController = [[[MPPasswordInputController alloc] init] autorelease]; @@ -125,9 +135,15 @@ }]; } +#pragma mark Notifications + +- (void)didOpenDocument:(NSNotification *)notification { + [self showEntries]; +} + - (void)showEntries { if(!self.entryViewController) { - self.entryViewController = [[[MPEntryViewController alloc] init] autorelease]; + _entryViewController = [[MPEntryViewController alloc] init]; } [self setContentViewController:self.entryViewController]; } diff --git a/MacPass/MPMainWindowSplitViewDelegate.h b/MacPass/MPMainWindowSplitViewDelegate.h index 4f3b9f92..ee32aea7 100644 --- a/MacPass/MPMainWindowSplitViewDelegate.h +++ b/MacPass/MPMainWindowSplitViewDelegate.h @@ -8,6 +8,10 @@ #import +extern const CGFloat MPMainWindowSplitViewDelegateMinimumOutlineWidth; +extern const CGFloat MPMainWindowSplitViewDelegateMaximumOutlineWidth; +extern const CGFloat MPMainWindowSplitViewDelegateMinimumContentWidth; + @interface MPMainWindowSplitViewDelegate : NSObject diff --git a/MacPass/MPMainWindowSplitViewDelegate.m b/MacPass/MPMainWindowSplitViewDelegate.m index 39f2586f..cc18c2c5 100644 --- a/MacPass/MPMainWindowSplitViewDelegate.m +++ b/MacPass/MPMainWindowSplitViewDelegate.m @@ -8,19 +8,56 @@ #import "MPMainWindowSplitViewDelegate.h" -const CGFloat _minimumSplitterWidth = 10.0; +const CGFloat MPMainWindowSplitViewDelegateMinimumOutlineWidth = 150.0; +const CGFloat MPMainWindowSplitViewDelegateMaximumOutlineWidth = 400.0; +const CGFloat MPMainWindowSplitViewDelegateMinimumContentWidth = 400.0; + +@interface MPMainWindowSplitViewDelegate () + +- (NSView *)leftView:(NSSplitView *)splitView; +- (NSView *)rightView:(NSSplitView *)splitView; + +@end @implementation MPMainWindowSplitViewDelegate +- (NSView *)leftView:(NSSplitView *)splitView { + return [splitView subviews][0]; +} + +- (NSView *)rightView:(NSSplitView *)splitView { + return [splitView subviews][1]; +} + - (CGFloat)splitView:(NSSplitView *)splitView constrainMinCoordinate:(CGFloat)proposedMinimumPosition ofSubviewAt:(NSInteger)dividerIndex { - return _minimumSplitterWidth; + return (proposedMinimumPosition < MPMainWindowSplitViewDelegateMinimumOutlineWidth) ? MPMainWindowSplitViewDelegateMinimumOutlineWidth : proposedMinimumPosition; } - (CGFloat)splitView:(NSSplitView *)splitView constrainMaxCoordinate:(CGFloat)proposedMaximumPosition ofSubviewAt:(NSInteger)dividerIndex { - NSView *otherView= [splitView subviews][(dividerIndex + 1) % 2]; - - CGFloat maximumWidth = [splitView frame].size.width - ( [splitView dividerThickness] + [otherView frame].size.width + _minimumSplitterWidth ); - return maximumWidth; + CGFloat availableWidth = [splitView frame].size.width - [splitView dividerThickness]; + return (availableWidth - MPMainWindowSplitViewDelegateMinimumOutlineWidth); } +- (void)splitView:(NSSplitView *)splitView resizeSubviewsWithOldSize:(NSSize)oldSize { + NSSize newSize = [splitView frame].size; + const CGFloat dividierThickness = [splitView dividerThickness]; + + NSView *leftView = [self leftView:splitView]; + NSView *rightView = [self rightView:splitView]; + + CGFloat leftRelativeWidth = [leftView frame].size.width / oldSize.width; + CGFloat newLeftWidth = floor(newSize.width * leftRelativeWidth); + + if( newLeftWidth < MPMainWindowSplitViewDelegateMinimumOutlineWidth && newSize.width > MPMainWindowSplitViewDelegateMinimumOutlineWidth ) { + newLeftWidth = MPMainWindowSplitViewDelegateMinimumOutlineWidth; + } + if( newLeftWidth > MPMainWindowSplitViewDelegateMaximumOutlineWidth ) { + newLeftWidth = MPMainWindowSplitViewDelegateMaximumOutlineWidth; + } + NSRect newLeftFrame = NSMakeRect(0, 0, newLeftWidth, newSize.height); + NSRect newRightFrame = NSMakeRect(newLeftWidth + dividierThickness, 0, newSize.width - newLeftWidth - dividierThickness, newSize.height); + [leftView setFrame:newLeftFrame]; + [rightView setFrame:newRightFrame]; +}; + @end diff --git a/MacPass/MPOutlineViewController.m b/MacPass/MPOutlineViewController.m index c1f131a4..5e706477 100644 --- a/MacPass/MPOutlineViewController.m +++ b/MacPass/MPOutlineViewController.m @@ -23,6 +23,7 @@ - (void)didOpenDocument:(NSNotification *)notification; - (void)setupMenu; +- (void)addEntry:(id)sender; @end @@ -69,11 +70,19 @@ - (void)setupMenu { NSMenu *menu = [[NSMenu allocWithZone:[NSMenu menuZone]] init]; - [menu addItemWithTitle:@"Add Group" action:NULL keyEquivalent:@""]; + [menu addItemWithTitle:@"Add Group" action:@selector(addEntry:) keyEquivalent:@""]; [menu addItem: [NSMenuItem separatorItem]]; [menu addItemWithTitle:@"Delete" action:NULL keyEquivalent:@""]; + for(NSMenuItem *item in [menu itemArray]) { + [item setTarget:self]; + } + self.menu = menu; [menu release]; } +- (void)addEntry:(id)sender { + NSLog(@"Add Entry"); +} + @end diff --git a/MacPass/MPToolbarDelegate.m b/MacPass/MPToolbarDelegate.m index 3901d7dd..c0a4c8dc 100644 --- a/MacPass/MPToolbarDelegate.m +++ b/MacPass/MPToolbarDelegate.m @@ -13,6 +13,7 @@ NSString *const MPToolbarItemAddGroup = @"AddGroup"; NSString *const MPToolbarItemAddEntry = @"AddEntry"; NSString *const MPToolbarItemEdit = @"Edit"; NSString *const MPToolbarItemDelete =@"Delete"; +NSString *const MPToolbarItemAction = @"Action"; @interface MPToolbarDelegate() @@ -29,7 +30,7 @@ NSString *const MPToolbarItemDelete =@"Delete"; { self = [super init]; if (self) { - self.toolbarIdentifiers = @[ MPToolbarItemAddEntry, MPToolbarItemDelete, MPToolbarItemEdit, MPToolbarItemAddGroup ]; + self.toolbarIdentifiers = @[ MPToolbarItemAddEntry, MPToolbarItemDelete, MPToolbarItemEdit, MPToolbarItemAddGroup, MPToolbarItemAction ]; self.toolbarItems = [NSMutableDictionary dictionaryWithCapacity:[self.toolbarItems count]]; self.toolbarImages = [self createToolbarImages]; } @@ -40,15 +41,54 @@ NSString *const MPToolbarItemDelete =@"Delete"; NSToolbarItem *item = self.toolbarItems[ itemIdentifier ]; if( !item ) { item = [[NSToolbarItem alloc] initWithItemIdentifier:itemIdentifier]; - [item setImage:self.toolbarImages[itemIdentifier]]; + NSButton *button; + if([itemIdentifier isEqualToString:MPToolbarItemAction]) { + NSPopUpButton *popupButton = [[NSPopUpButton alloc] initWithFrame:NSMakeRect(0, 0, 50, 32) pullsDown:YES]; + [[popupButton cell] setBezelStyle:NSTexturedRoundedBezelStyle]; + [[popupButton cell] setImageScaling:NSImageScaleProportionallyDown]; + [popupButton setTitle:@""]; + /* + Built menu + */ + NSMenu *menu = [NSMenu allocWithZone:[NSMenu menuZone]]; + NSMenuItem *item = [[NSMenuItem allocWithZone:[NSMenu menuZone]] initWithTitle:@"" action:NULL keyEquivalent:@""]; + [item setImage:self.toolbarImages[itemIdentifier]]; + [menu addItem:item]; + [menu addItemWithTitle:@"Foo" action:NULL keyEquivalent:@""]; + [menu addItemWithTitle:@"Bar" action:NULL keyEquivalent:@""]; + [popupButton setMenu:menu]; + + /* + Cleanup + */ + [item release]; + [menu release]; + button = popupButton; + } + else { + button = [[NSButton alloc] initWithFrame:NSMakeRect(0, 0, 32, 32)]; + [[button cell] setBezelStyle:NSTexturedRoundedBezelStyle]; + [[button cell] setImageScaling:NSImageScaleProportionallyDown]; + [button setTitle:@""]; + [button setButtonType:NSMomentaryPushInButton]; + NSImage *image = self.toolbarImages[itemIdentifier]; + [button setImage:image]; + [button setImagePosition:NSImageOnly]; + } + [button sizeToFit]; NSString *label = NSLocalizedString(itemIdentifier, @""); [item setLabel:label]; + [item setView:button]; + [item setAction:@selector(toolbarItemPressed:)]; self.toolbarItems[itemIdentifier] = item; [item release]; + [button release]; + + return item; } return item; @@ -64,12 +104,14 @@ NSString *const MPToolbarItemDelete =@"Delete"; } - (NSDictionary *)createToolbarImages{ - NSDictionary *imageDict = @{ MPToolbarItemAddEntry: [MPIconHelper icon:MPIconCamera], + NSDictionary *imageDict = @{ MPToolbarItemAddEntry: [MPIconHelper icon:MPIconPassword], MPToolbarItemAddGroup: [MPIconHelper icon:MPIconPassword], - MPToolbarItemDelete: [MPIconHelper icon:MPIconServer], - MPToolbarItemEdit: [MPIconHelper icon:MPIconNotepad] + MPToolbarItemDelete: [NSImage imageNamed:NSImageNameRemoveTemplate], + MPToolbarItemEdit: [MPIconHelper icon:MPIconNotepad], + MPToolbarItemAction: [NSImage imageNamed:NSImageNameActionTemplate] }; return imageDict; } + @end diff --git a/MacPass/MPViewController.m b/MacPass/MPViewController.m index 20d2259b..907a9bc4 100644 --- a/MacPass/MPViewController.m +++ b/MacPass/MPViewController.m @@ -12,6 +12,12 @@ - (void)loadView { [super loadView]; + + /* Insert ourselfs in the responder chain */ + NSResponder *nextResponder = [[self view] nextResponder]; + [[self view] setNextResponder:self]; + [self setNextResponder:nextResponder]; + [self didLoadView]; } diff --git a/MacPass/MacPass-Info.plist b/MacPass/MacPass-Info.plist index b7fb37c3..6b8cc046 100644 --- a/MacPass/MacPass-Info.plist +++ b/MacPass/MacPass-Info.plist @@ -21,7 +21,7 @@ CFBundleSignature ???? CFBundleVersion - 1 + 76 LSMinimumSystemVersion ${MACOSX_DEPLOYMENT_TARGET} NSHumanReadableCopyright diff --git a/MacPass/MainWindow.xib b/MacPass/MainWindow.xib index 3e4758d7..9406f6a3 100644 --- a/MacPass/MainWindow.xib +++ b/MacPass/MainWindow.xib @@ -11,13 +11,9 @@ 3084 - IBNSLayoutConstraint NSCustomObject NSCustomView NSSplitView - NSToolbar - NSToolbarFlexibleSpaceItem - NSToolbarSpaceItem NSView NSWindowTemplate @@ -41,105 +37,26 @@ 15 2 - {{196, 240}, {611, 449}} + {{196, 240}, {727, 630}} 544735232 Window NSWindow - - - 04E515E6-01C4-49D0-9F18-CF8CB81C135F - - - YES - YES - YES - NO - 1 - 1 - - - NSToolbarFlexibleSpaceItem - - Flexible Space - - - - - - {1, 5} - {20000, 32} - YES - YES - -1 - YES - 0 - - YES - YES - - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - - - - NSToolbarSpaceItem - - Space - - - - - - {32, 5} - {32, 32} - YES - YES - -1 - YES - 0 - - YES - YES - - - 1048576 - 2147483647 - - - - - - - - - - - - - - + + {400, 400} 256 - 268 + 319 268 - {151, 449} + + {256, 630} @@ -149,7 +66,8 @@ 256 - {{152, 0}, {459, 449}} + + {{257, 0}, {470, 630}} @@ -157,7 +75,7 @@ NSView - {611, 449} + {727, 630} @@ -166,12 +84,13 @@ 2 - {611, 449} + {727, 630} - {{0, 0}, {1920, 1058}} + {{0, 0}, {2560, 1418}} + {400, 422} {10000000000000, 10000000000000} YES @@ -186,14 +105,6 @@ 501 - - - toolbar - - - - 597 - contentView @@ -223,7 +134,7 @@ 0 - + @@ -250,7 +161,6 @@ - @@ -258,93 +168,10 @@ 2 - - - 4 - 0 - - 4 - 1 - - 0.0 - - 1000 - - 8 - 29 - 3 - - - - 6 - 0 - - 6 - 1 - - 0.0 - - 1000 - - 8 - 29 - 3 - - - - 3 - 0 - - 3 - 1 - - 0.0 - - 1000 - - 8 - 29 - 3 - - - - 5 - 0 - - 5 - 1 - - 0.0 - - 1000 - - 8 - 29 - 3 - - - 591 - - - - - - - - - 592 - - - - - 595 - - - 603 @@ -355,35 +182,16 @@ - 619 - - - - - 615 - - - - - 614 - - + 605 + + + 628 - - 605 - - - - - 643 - - - @@ -395,24 +203,10 @@ com.apple.InterfaceBuilder.CocoaPlugin {{357, 418}, {480, 270}} - - - - - - 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 - com.apple.InterfaceBuilder.CocoaPlugin @@ -429,7 +223,6 @@ NSView NSView NSSplitView - NSToolbar NSView @@ -445,10 +238,6 @@ splitView NSSplitView - - toolbar - NSToolbar - welcomeView NSView @@ -459,24 +248,11 @@ ./Classes/MPMainWindowController.h - - NSLayoutConstraint - NSObject - - IBProjectSource - ./Classes/NSLayoutConstraint.h - - 0 IBCocoaFramework YES 3 - - {11, 11} - {10, 3} - - YES diff --git a/MacPass/OutlineView.xib b/MacPass/OutlineView.xib index d783a2e9..ea98b025 100644 --- a/MacPass/OutlineView.xib +++ b/MacPass/OutlineView.xib @@ -152,7 +152,7 @@ MC41AA - 17 + 24 -767557632 @@ -196,7 +196,6 @@ {{1, 119}, {238, 15}} - _NS:60 NO 1 @@ -760,27 +759,24 @@ - 188 + 194 MPOutlineViewController MPViewController - - NSMenu - NSOutlineView - - - - itemMenu - NSMenu - - + + outlineView + NSOutlineView + + + outlineView + outlineView NSOutlineView - + IBProjectSource ./Classes/MPOutlineViewController.h diff --git a/MacPass/en.lproj/Credits.rtf b/MacPass/en.lproj/Credits.rtf index 46576ef2..2b2d060b 100644 --- a/MacPass/en.lproj/Credits.rtf +++ b/MacPass/en.lproj/Credits.rtf @@ -1,29 +1,24 @@ -{\rtf0\ansi{\fonttbl\f0\fswiss Helvetica;} -{\colortbl;\red255\green255\blue255;} -\paperw9840\paperh8400 -\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\ql\qnatural +{\rtf1\ansi\ansicpg1252\cocoartf1187\cocoasubrtf340 +{\fonttbl\f0\fswiss\fcharset0 Helvetica;} +{\colortbl;\red255\green255\blue255;\red52\green110\blue183;\red38\green38\blue38;} +\paperw11900\paperh16840\vieww15320\viewh13520\viewkind0 +\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720 -\f0\b\fs24 \cf0 Engineering: +\f0\b\fs24 \cf0 Project Website:\ + {\field{\*\fldinst{HYPERLINK "https://github.com/mstarke/MacPass"}}{\fldrslt +\b0 MacPass}} \b0 \ - Some people\ -\ -\b Human Interface Design: -\b0 \ - Some other people\ -\ - -\b Testing: -\b0 \ - Hopefully not nobody\ -\ - -\b Documentation: -\b0 \ - Whoever\ -\ - -\b With special thanks to: -\b0 \ - Mom\ -} +\b \ +Credits:\ + {\field{\*\fldinst{HYPERLINK "https://github.com/robbiehanson/KissXML"}}{\fldrslt +\b0 \cf2 KissXML}} +\b0 \cf3 \ + by Robbie Hanson\ + \ + {\field{\*\fldinst{HYPERLINK "https://github.com/MiniKeePass/MiniKeePass"}}{\fldrslt \cf2 MiniKeePass}}\ + by Jason Rush and John Flanagan\ + \ +\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720 +\cf2 {\field{\*\fldinst{HYPERLINK "https://github.com/mpowrie/KeePassLib"}}{\fldrslt KeePass Database Library}}\cf3 \ + by Qiang Yu} \ No newline at end of file diff --git a/MacPass/en.lproj/MainMenu.xib b/MacPass/en.lproj/MainMenu.xib index 10f2d0f0..92141be0 100644 --- a/MacPass/en.lproj/MainMenu.xib +++ b/MacPass/en.lproj/MainMenu.xib @@ -2,18 +2,18 @@ 1070 - 11E53 - 2182 - 1138.47 - 569.00 + 12C60 + 3084 + 1187.34 + 625.00 com.apple.InterfaceBuilder.CocoaPlugin - 2182 + 3084 + NSCustomObject NSMenu NSMenuItem - NSCustomObject com.apple.InterfaceBuilder.CocoaPlugin