mirror of
https://github.com/MacPass/MacPass.git
synced 2025-12-13 21:42:32 +00:00
Welcome window now displays a list of recent documents.
also the window now gets closed when a document is loaded
This commit is contained in:
@@ -149,6 +149,7 @@
|
||||
4C701CBC178618A000581B88 /* 12_RemoteTemplate.pdf in Resources */ = {isa = PBXBuildFile; fileRef = 4C701CBB178618A000581B88 /* 12_RemoteTemplate.pdf */; };
|
||||
4C7155D81A10DB6D00979307 /* IconSelection.xib in Resources */ = {isa = PBXBuildFile; fileRef = 4C7155DA1A10DB6D00979307 /* IconSelection.xib */; };
|
||||
4C735FC02035FCBF00708D53 /* MPPluginEntryActionContext.m in Sources */ = {isa = PBXBuildFile; fileRef = 4C735FBF2035FCBF00708D53 /* MPPluginEntryActionContext.m */; };
|
||||
4C73B6F1215E64A7009787F7 /* MPWelcomeViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 4C73B6EF215E64A7009787F7 /* MPWelcomeViewController.m */; };
|
||||
4C76155C1764C04C0015A1A6 /* GeneralSettings.xib in Resources */ = {isa = PBXBuildFile; fileRef = 4C76155E1764C04C0015A1A6 /* GeneralSettings.xib */; };
|
||||
4C7615681764C0C40015A1A6 /* PasswordInputView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 4C76156A1764C0C40015A1A6 /* PasswordInputView.xib */; };
|
||||
4C76156D1764C0E20015A1A6 /* InspectorView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 4C76156F1764C0E20015A1A6 /* InspectorView.xib */; };
|
||||
@@ -180,7 +181,7 @@
|
||||
4C7B637F1C0CB57300D7038C /* KeePassKit.framework in CopyFiles */ = {isa = PBXBuildFile; fileRef = 4C7B63791C0CB55600D7038C /* KeePassKit.framework */; settings = {ATTRIBUTES = (RemoveHeadersOnCopy, ); }; };
|
||||
4C7B63801C0CB57300D7038C /* Sparkle.framework in CopyFiles */ = {isa = PBXBuildFile; fileRef = 4C7B637A1C0CB55600D7038C /* Sparkle.framework */; settings = {ATTRIBUTES = (RemoveHeadersOnCopy, ); }; };
|
||||
4C7BD07619FE94C900C7AA5C /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 4C7BD07519FE94C900C7AA5C /* Assets.xcassets */; };
|
||||
4C7F8B681A10B68400CCB83D /* WelcomeWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = 4C7F8B6A1A10B68400CCB83D /* WelcomeWindow.xib */; };
|
||||
4C7F8B681A10B68400CCB83D /* WelcomeView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 4C7F8B6A1A10B68400CCB83D /* WelcomeView.xib */; };
|
||||
4C80304A1E2FBAA300133E4C /* MPTestKeyMapper.m in Sources */ = {isa = PBXBuildFile; fileRef = 4C8030491E2FBAA300133E4C /* MPTestKeyMapper.m */; };
|
||||
4C82046A1FCDC07800EB24A4 /* MPPickfieldViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 4C8204681FCDC07800EB24A4 /* MPPickfieldViewController.m */; };
|
||||
4C82046E1FCDC8A100EB24A4 /* MPPickfieldTableModel.m in Sources */ = {isa = PBXBuildFile; fileRef = 4C82046D1FCDC8A100EB24A4 /* MPPickfieldTableModel.m */; };
|
||||
@@ -300,7 +301,7 @@
|
||||
/* Begin PBXFileReference section */
|
||||
4825CC811C414D57003E37E9 /* it */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = it; path = it.lproj/DatabaseSettingsWindow.strings; sourceTree = "<group>"; };
|
||||
4825CC821C414D57003E37E9 /* it */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = it; path = it.lproj/PasswordEditWindow.strings; sourceTree = "<group>"; };
|
||||
4825CC831C414D57003E37E9 /* it */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = it; path = it.lproj/WelcomeWindow.strings; sourceTree = "<group>"; };
|
||||
4825CC831C414D57003E37E9 /* it */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = it; path = it.lproj/WelcomeView.strings; sourceTree = "<group>"; };
|
||||
4825CC841C414D57003E37E9 /* it */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = it; path = it.lproj/GeneralSettings.strings; sourceTree = "<group>"; };
|
||||
4825CC851C414D57003E37E9 /* it */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = it; path = it.lproj/IntegrationSettings.strings; sourceTree = "<group>"; };
|
||||
4825CC861C414D57003E37E9 /* it */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = it; path = it.lproj/WorkflowSettings.strings; sourceTree = "<group>"; };
|
||||
@@ -465,7 +466,7 @@
|
||||
4C41610E1F50333C003BC0AF /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/IconSelection.strings; sourceTree = "<group>"; };
|
||||
4C41610F1F50333C003BC0AF /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/DatePickingView.strings; sourceTree = "<group>"; };
|
||||
4C4161101F50333C003BC0AF /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/ReferenceBuilderView.strings; sourceTree = "<group>"; };
|
||||
4C4161111F50333C003BC0AF /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/WelcomeWindow.strings; sourceTree = "<group>"; };
|
||||
4C4161111F50333C003BC0AF /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/WelcomeView.strings; sourceTree = "<group>"; };
|
||||
4C4161121F50333C003BC0AF /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/MainMenu.strings; sourceTree = "<group>"; };
|
||||
4C4161131F50333C003BC0AF /* es */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/Localizable.strings; sourceTree = "<group>"; };
|
||||
4C4161141F50333C003BC0AF /* es */ = {isa = PBXFileReference; lastKnownFileType = text.rtf; name = es; path = es.lproj/Credits.rtf; sourceTree = "<group>"; };
|
||||
@@ -574,6 +575,8 @@
|
||||
4C7155EC1A10DB7900979307 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/IconSelection.strings; sourceTree = "<group>"; };
|
||||
4C735FBE2035FCBF00708D53 /* MPPluginEntryActionContext.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MPPluginEntryActionContext.h; sourceTree = "<group>"; };
|
||||
4C735FBF2035FCBF00708D53 /* MPPluginEntryActionContext.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MPPluginEntryActionContext.m; sourceTree = "<group>"; };
|
||||
4C73B6EE215E64A7009787F7 /* MPWelcomeViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MPWelcomeViewController.h; sourceTree = "<group>"; };
|
||||
4C73B6EF215E64A7009787F7 /* MPWelcomeViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MPWelcomeViewController.m; sourceTree = "<group>"; };
|
||||
4C73EB941FBB58730033000F /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/DatabaseSettingsWindow.strings; sourceTree = "<group>"; };
|
||||
4C73EB951FBB5A8F0033000F /* de */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = de; path = de.lproj/AutotypeCandidateSelectionView.strings; sourceTree = "<group>"; };
|
||||
4C73EB961FBB5A910033000F /* de */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = de; path = de.lproj/AutotypeBuilderView.strings; sourceTree = "<group>"; };
|
||||
@@ -633,12 +636,12 @@
|
||||
4C7B63791C0CB55600D7038C /* KeePassKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = KeePassKit.framework; path = Carthage/Build/Mac/KeePassKit.framework; sourceTree = "<group>"; };
|
||||
4C7B637A1C0CB55600D7038C /* Sparkle.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Sparkle.framework; path = Carthage/Build/Mac/Sparkle.framework; sourceTree = "<group>"; };
|
||||
4C7BD07519FE94C900C7AA5C /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
|
||||
4C7F8B691A10B68400CCB83D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/WelcomeWindow.xib; sourceTree = "<group>"; };
|
||||
4C7F8B741A10B69300CCB83D /* nl */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = nl; path = nl.lproj/WelcomeWindow.strings; sourceTree = "<group>"; };
|
||||
4C7F8B761A10B69400CCB83D /* zh-Hans */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = "zh-Hans"; path = "zh-Hans.lproj/WelcomeWindow.strings"; sourceTree = "<group>"; };
|
||||
4C7F8B781A10B69500CCB83D /* fr */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = fr; path = fr.lproj/WelcomeWindow.strings; sourceTree = "<group>"; };
|
||||
4C7F8B7A1A10B69700CCB83D /* de */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = de; path = de.lproj/WelcomeWindow.strings; sourceTree = "<group>"; };
|
||||
4C7F8B7C1A10B69800CCB83D /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/WelcomeWindow.strings; sourceTree = "<group>"; };
|
||||
4C7F8B691A10B68400CCB83D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/WelcomeView.xib; sourceTree = "<group>"; };
|
||||
4C7F8B741A10B69300CCB83D /* nl */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = nl; path = nl.lproj/WelcomeView.strings; sourceTree = "<group>"; };
|
||||
4C7F8B761A10B69400CCB83D /* zh-Hans */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = "zh-Hans"; path = "zh-Hans.lproj/WelcomeView.strings"; sourceTree = "<group>"; };
|
||||
4C7F8B781A10B69500CCB83D /* fr */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = fr; path = fr.lproj/WelcomeView.strings; sourceTree = "<group>"; };
|
||||
4C7F8B7A1A10B69700CCB83D /* de */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = de; path = de.lproj/WelcomeView.strings; sourceTree = "<group>"; };
|
||||
4C7F8B7C1A10B69800CCB83D /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/WelcomeView.strings; sourceTree = "<group>"; };
|
||||
4C8030491E2FBAA300133E4C /* MPTestKeyMapper.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPTestKeyMapper.m; sourceTree = "<group>"; };
|
||||
4C8204671FCDC07800EB24A4 /* MPPickfieldViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MPPickfieldViewController.h; sourceTree = "<group>"; };
|
||||
4C8204681FCDC07800EB24A4 /* MPPickfieldViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MPPickfieldViewController.m; sourceTree = "<group>"; };
|
||||
@@ -648,7 +651,7 @@
|
||||
4C83814115BF4677001AE468 /* MPDocumentWindowController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPDocumentWindowController.m; sourceTree = "<group>"; };
|
||||
4C840C441D773E5D0081F605 /* pl */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = pl; path = pl.lproj/DatabaseSettingsWindow.strings; sourceTree = "<group>"; };
|
||||
4C840C451D773E5D0081F605 /* pl */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = pl; path = pl.lproj/PasswordEditWindow.strings; sourceTree = "<group>"; };
|
||||
4C840C461D773E5D0081F605 /* pl */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = pl; path = pl.lproj/WelcomeWindow.strings; sourceTree = "<group>"; };
|
||||
4C840C461D773E5D0081F605 /* pl */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = pl; path = pl.lproj/WelcomeView.strings; sourceTree = "<group>"; };
|
||||
4C840C471D773E5D0081F605 /* pl */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = pl; path = pl.lproj/GeneralSettings.strings; sourceTree = "<group>"; };
|
||||
4C840C481D773E5D0081F605 /* pl */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = pl; path = pl.lproj/IntegrationSettings.strings; sourceTree = "<group>"; };
|
||||
4C840C491D773E5D0081F605 /* pl */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = pl; path = pl.lproj/WorkflowSettings.strings; sourceTree = "<group>"; };
|
||||
@@ -901,7 +904,7 @@
|
||||
6A74B0742076F4B50049BC29 /* sv-SE */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = "sv-SE"; path = "sv-SE.lproj/AutotypeCandidateSelectionView.strings"; sourceTree = "<group>"; };
|
||||
6A74B0752076F4B50049BC29 /* sv-SE */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = "sv-SE"; path = "sv-SE.lproj/PickcharView.strings"; sourceTree = "<group>"; };
|
||||
6A74B0762076F4B50049BC29 /* sv-SE */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = "sv-SE"; path = "sv-SE.lproj/PickfieldView.strings"; sourceTree = "<group>"; };
|
||||
6A74B0772076F4B50049BC29 /* sv-SE */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = "sv-SE"; path = "sv-SE.lproj/WelcomeWindow.strings"; sourceTree = "<group>"; };
|
||||
6A74B0772076F4B50049BC29 /* sv-SE */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = "sv-SE"; path = "sv-SE.lproj/WelcomeView.strings"; sourceTree = "<group>"; };
|
||||
6A74B0782076F4B50049BC29 /* sv-SE */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = "sv-SE"; path = "sv-SE.lproj/MainMenu.strings"; sourceTree = "<group>"; };
|
||||
6A74B0792076F4B50049BC29 /* sv-SE */ = {isa = PBXFileReference; lastKnownFileType = text.plist.stringsdict; name = "sv-SE"; path = "sv-SE.lproj/Localizable.stringsdict"; sourceTree = "<group>"; };
|
||||
6A74B07A2076F4B60049BC29 /* sv-SE */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = "sv-SE"; path = "sv-SE.lproj/Localizable.strings"; sourceTree = "<group>"; };
|
||||
@@ -937,7 +940,7 @@
|
||||
FA13910E1F9CDB2D0033D256 /* pl */ = {isa = PBXFileReference; lastKnownFileType = text.plist.stringsdict; name = pl; path = pl.lproj/Localizable.stringsdict; sourceTree = "<group>"; };
|
||||
FA638D0E1C39BFCB00B10CC6 /* ru */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = ru; path = ru.lproj/DatabaseSettingsWindow.strings; sourceTree = "<group>"; };
|
||||
FA638D0F1C39BFCB00B10CC6 /* ru */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = ru; path = ru.lproj/PasswordEditWindow.strings; sourceTree = "<group>"; };
|
||||
FA638D101C39BFCB00B10CC6 /* ru */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = ru; path = ru.lproj/WelcomeWindow.strings; sourceTree = "<group>"; };
|
||||
FA638D101C39BFCB00B10CC6 /* ru */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = ru; path = ru.lproj/WelcomeView.strings; sourceTree = "<group>"; };
|
||||
FA638D111C39BFCB00B10CC6 /* ru */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = ru; path = ru.lproj/GeneralSettings.strings; sourceTree = "<group>"; };
|
||||
FA638D121C39BFCB00B10CC6 /* ru */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = ru; path = ru.lproj/IntegrationSettings.strings; sourceTree = "<group>"; };
|
||||
FA638D131C39BFCC00B10CC6 /* ru */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = ru; path = ru.lproj/WorkflowSettings.strings; sourceTree = "<group>"; };
|
||||
@@ -1541,6 +1544,9 @@
|
||||
4C8204671FCDC07800EB24A4 /* MPPickfieldViewController.h */,
|
||||
4C8204681FCDC07800EB24A4 /* MPPickfieldViewController.m */,
|
||||
4C0B5341205C1561003D277E /* PickfieldView.xib */,
|
||||
4C73B6EE215E64A7009787F7 /* MPWelcomeViewController.h */,
|
||||
4C73B6EF215E64A7009787F7 /* MPWelcomeViewController.m */,
|
||||
4C7F8B6A1A10B68400CCB83D /* WelcomeView.xib */,
|
||||
);
|
||||
name = "View Controller";
|
||||
sourceTree = "<group>";
|
||||
@@ -1624,7 +1630,6 @@
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
4C1DDCDC1711ECEB00C98DA3 /* PasswordCreatorWindow.xib */,
|
||||
4C7F8B6A1A10B68400CCB83D /* WelcomeWindow.xib */,
|
||||
);
|
||||
name = Windows;
|
||||
sourceTree = "<group>";
|
||||
@@ -1877,7 +1882,7 @@
|
||||
4C3826761AD04C24007D7D67 /* harddiskTemplate.pdf in Resources */,
|
||||
4C0DBEF51BF508DE00F9B287 /* PluginSettings.xib in Resources */,
|
||||
4CF6653820E67A140008A25C /* PluginDataView.xib in Resources */,
|
||||
4C7F8B681A10B68400CCB83D /* WelcomeWindow.xib in Resources */,
|
||||
4C7F8B681A10B68400CCB83D /* WelcomeView.xib in Resources */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
@@ -1928,6 +1933,7 @@
|
||||
4C37A84015B8B474005EF8EE /* MPOutlineDataSource.m in Sources */,
|
||||
4CA0B2F915BCAF6700654E32 /* MPGeneralSettingsController.m in Sources */,
|
||||
4C8F0C791FD05A6A00BE157F /* NSString+MPPrettyPasswordDisplay.m in Sources */,
|
||||
4C73B6F1215E64A7009787F7 /* MPWelcomeViewController.m in Sources */,
|
||||
4C6B7C7D18BE7EB0001D5D77 /* MPDocument+History.m in Sources */,
|
||||
4CA0B2FC15BCAF8600654E32 /* MPSettingsWindowController.m in Sources */,
|
||||
4C4F72D118DF704400E8D378 /* DDHotKeyTextField.m in Sources */,
|
||||
@@ -2251,7 +2257,7 @@
|
||||
name = MainMenu.xib;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
4C7F8B6A1A10B68400CCB83D /* WelcomeWindow.xib */ = {
|
||||
4C7F8B6A1A10B68400CCB83D /* WelcomeView.xib */ = {
|
||||
isa = PBXVariantGroup;
|
||||
children = (
|
||||
4C7F8B691A10B68400CCB83D /* Base */,
|
||||
@@ -2266,7 +2272,7 @@
|
||||
4C4161111F50333C003BC0AF /* es */,
|
||||
6A74B0772076F4B50049BC29 /* sv-SE */,
|
||||
);
|
||||
name = WelcomeWindow.xib;
|
||||
name = WelcomeView.xib;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
4C888C8E16EB6C91003D34A1 /* Localizable.strings */ = {
|
||||
|
||||
201
MacPass/Base.lproj/WelcomeView.xib
Normal file
201
MacPass/Base.lproj/WelcomeView.xib
Normal file
@@ -0,0 +1,201 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="14313.18" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES">
|
||||
<dependencies>
|
||||
<deployment identifier="macosx"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="14313.18"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
<customObject id="-2" userLabel="File's Owner" customClass="MPWelcomeViewController">
|
||||
<connections>
|
||||
<outlet property="tableView" destination="51b-Ql-3gM" id="g2f-YT-q5R"/>
|
||||
<outlet property="view" destination="9Nv-Zl-Z9p" id="ySe-F6-puU"/>
|
||||
</connections>
|
||||
</customObject>
|
||||
<customObject id="-1" userLabel="First Responder" customClass="FirstResponder"/>
|
||||
<customObject id="-3" userLabel="Application" customClass="NSObject"/>
|
||||
<view id="9Nv-Zl-Z9p">
|
||||
<rect key="frame" x="0.0" y="0.0" width="528" height="300"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<stackView orientation="horizontal" alignment="centerY" horizontalStackHuggingPriority="249.99998474121094" verticalStackHuggingPriority="249.99998474121094" detachesHiddenViews="YES" translatesAutoresizingMaskIntoConstraints="NO" id="ITj-5P-sn9">
|
||||
<rect key="frame" x="20" y="0.0" width="508" height="300"/>
|
||||
<middleViews>
|
||||
<stackView orientation="vertical" alignment="centerX" horizontalStackHuggingPriority="249.99998474121094" verticalStackHuggingPriority="249.99998474121094" misplaced="YES" translatesAutoresizingMaskIntoConstraints="NO" id="jd3-xw-cZP">
|
||||
<rect key="frame" x="143" y="0.0" width="222" height="300"/>
|
||||
<middleViews>
|
||||
<imageView misplaced="YES" translatesAutoresizingMaskIntoConstraints="NO" id="VWi-da-LGh">
|
||||
<rect key="frame" x="47" y="105" width="128" height="128"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="height" constant="128" id="T0d-gp-edr"/>
|
||||
<constraint firstAttribute="width" constant="128" id="Xdf-jE-D9H"/>
|
||||
</constraints>
|
||||
<imageCell key="cell" refusesFirstResponder="YES" alignment="left" imageScaling="proportionallyDown" image="MacPassAppIcon" id="9f2-Co-St2"/>
|
||||
</imageView>
|
||||
<textField verticalHuggingPriority="750" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="EEg-rH-sPx">
|
||||
<rect key="frame" x="-2" y="68" width="226" height="29"/>
|
||||
<textFieldCell key="cell" scrollable="YES" lineBreakMode="clipping" sendsActionOnEndEditing="YES" title="Welcome to MacPass" id="zdv-z8-khG">
|
||||
<font key="font" metaFont="system" size="24"/>
|
||||
<color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/>
|
||||
<color key="backgroundColor" name="controlColor" catalog="System" colorSpace="catalog"/>
|
||||
</textFieldCell>
|
||||
</textField>
|
||||
</middleViews>
|
||||
<endViews>
|
||||
<button verticalHuggingPriority="750" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="MmF-PL-dgZ">
|
||||
<rect key="frame" x="39" y="22" width="144" height="32"/>
|
||||
<buttonCell key="cell" type="push" title="Open Database…" bezelStyle="rounded" alignment="center" state="on" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="Jj3-zy-gaz">
|
||||
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
|
||||
<font key="font" metaFont="system"/>
|
||||
</buttonCell>
|
||||
<connections>
|
||||
<action selector="openDatabase:" target="-1" id="iC6-yP-ZKT"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button verticalHuggingPriority="750" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="IRO-Hz-Zjp">
|
||||
<rect key="frame" x="26" y="-7" width="170" height="32"/>
|
||||
<buttonCell key="cell" type="push" title="Create new Database" bezelStyle="rounded" alignment="center" state="on" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="Vxx-Ql-eI5">
|
||||
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
|
||||
<font key="font" metaFont="system"/>
|
||||
</buttonCell>
|
||||
<connections>
|
||||
<action selector="createNewDatabase:" target="-1" id="hbV-Rz-x5g"/>
|
||||
</connections>
|
||||
</button>
|
||||
</endViews>
|
||||
<constraints>
|
||||
<constraint firstAttribute="width" relation="greaterThanOrEqual" constant="300" id="f86-vL-FmV"/>
|
||||
</constraints>
|
||||
<visibilityPriorities>
|
||||
<integer value="1000"/>
|
||||
<integer value="1000"/>
|
||||
<integer value="1000"/>
|
||||
<integer value="1000"/>
|
||||
</visibilityPriorities>
|
||||
<customSpacing>
|
||||
<real value="3.4028234663852886e+38"/>
|
||||
<real value="3.4028234663852886e+38"/>
|
||||
<real value="3.4028234663852886e+38"/>
|
||||
<real value="3.4028234663852886e+38"/>
|
||||
</customSpacing>
|
||||
</stackView>
|
||||
</middleViews>
|
||||
<endViews>
|
||||
<scrollView misplaced="YES" autohidesScrollers="YES" horizontalLineScroll="40" horizontalPageScroll="10" verticalLineScroll="40" verticalPageScroll="10" usesPredominantAxisScrolling="NO" translatesAutoresizingMaskIntoConstraints="NO" id="eUA-6g-T1O">
|
||||
<rect key="frame" x="373" y="0.0" width="135" height="300"/>
|
||||
<clipView key="contentView" id="0Kf-Fq-by2">
|
||||
<rect key="frame" x="1" y="1" width="133" height="298"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<tableView verticalHuggingPriority="750" allowsExpansionToolTips="YES" columnAutoresizingStyle="lastColumnOnly" columnReordering="NO" columnResizing="NO" multipleSelection="NO" autosaveColumns="NO" rowHeight="38" rowSizeStyle="automatic" viewBased="YES" id="51b-Ql-3gM">
|
||||
<rect key="frame" x="0.0" y="0.0" width="133" height="298"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<size key="intercellSpacing" width="3" height="2"/>
|
||||
<color key="backgroundColor" name="controlBackgroundColor" catalog="System" colorSpace="catalog"/>
|
||||
<color key="gridColor" name="gridColor" catalog="System" colorSpace="catalog"/>
|
||||
<tableColumns>
|
||||
<tableColumn width="130" minWidth="40" maxWidth="1000" id="oLj-wZ-syY">
|
||||
<tableHeaderCell key="headerCell" lineBreakMode="truncatingTail" borderStyle="border">
|
||||
<font key="font" metaFont="smallSystem"/>
|
||||
<color key="textColor" name="headerTextColor" catalog="System" colorSpace="catalog"/>
|
||||
<color key="backgroundColor" name="headerColor" catalog="System" colorSpace="catalog"/>
|
||||
</tableHeaderCell>
|
||||
<textFieldCell key="dataCell" lineBreakMode="truncatingTail" selectable="YES" editable="YES" title="Text Cell" id="Fbl-HT-XIu">
|
||||
<font key="font" metaFont="system"/>
|
||||
<color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/>
|
||||
<color key="backgroundColor" name="controlBackgroundColor" catalog="System" colorSpace="catalog"/>
|
||||
</textFieldCell>
|
||||
<tableColumnResizingMask key="resizingMask" resizeWithTable="YES" userResizable="YES"/>
|
||||
<prototypeCellViews>
|
||||
<tableCellView id="6UF-Gr-4nf">
|
||||
<rect key="frame" x="1" y="1" width="130" height="38"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<imageView horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="Kko-1G-JNn">
|
||||
<rect key="frame" x="2" y="3" width="32" height="32"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="width" secondItem="Kko-1G-JNn" secondAttribute="height" multiplier="1:1" id="DCx-UU-29t"/>
|
||||
<constraint firstAttribute="height" constant="32" id="tUG-uX-FuQ"/>
|
||||
</constraints>
|
||||
<imageCell key="cell" refusesFirstResponder="YES" alignment="left" imageScaling="proportionallyDown" image="NSActionTemplate" id="9TF-9t-7gd"/>
|
||||
</imageView>
|
||||
<textField verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" allowsExpansionToolTips="YES" translatesAutoresizingMaskIntoConstraints="NO" id="Kso-jb-pRH">
|
||||
<rect key="frame" x="39" y="3" width="91" height="32"/>
|
||||
<textFieldCell key="cell" lineBreakMode="truncatingTail" sendsActionOnEndEditing="YES" title="Table View Cell" id="vzM-ly-CYn">
|
||||
<font key="font" metaFont="system"/>
|
||||
<color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/>
|
||||
<color key="backgroundColor" name="controlColor" catalog="System" colorSpace="catalog"/>
|
||||
</textFieldCell>
|
||||
<connections>
|
||||
<binding destination="6UF-Gr-4nf" name="value" keyPath="objectValue" id="xQO-gD-dYm"/>
|
||||
</connections>
|
||||
</textField>
|
||||
</subviews>
|
||||
<constraints>
|
||||
<constraint firstItem="Kso-jb-pRH" firstAttribute="centerY" secondItem="6UF-Gr-4nf" secondAttribute="centerY" id="EFe-Eu-cwW"/>
|
||||
<constraint firstItem="Kso-jb-pRH" firstAttribute="leading" secondItem="Kko-1G-JNn" secondAttribute="trailing" constant="7" id="Jlp-gO-6rv"/>
|
||||
<constraint firstItem="Kso-jb-pRH" firstAttribute="top" secondItem="Kko-1G-JNn" secondAttribute="top" id="KY0-l7-LXd"/>
|
||||
<constraint firstItem="Kko-1G-JNn" firstAttribute="leading" secondItem="6UF-Gr-4nf" secondAttribute="leading" constant="2" id="RV0-o5-iyA"/>
|
||||
<constraint firstItem="Kso-jb-pRH" firstAttribute="bottom" secondItem="Kko-1G-JNn" secondAttribute="bottom" id="d6U-3y-ffn"/>
|
||||
<constraint firstAttribute="trailing" secondItem="Kso-jb-pRH" secondAttribute="trailing" constant="2" id="ptI-vC-fK9"/>
|
||||
</constraints>
|
||||
<connections>
|
||||
<outlet property="imageView" destination="Kko-1G-JNn" id="AvW-EL-9Rw"/>
|
||||
<outlet property="textField" destination="Kso-jb-pRH" id="yWg-4p-sFp"/>
|
||||
</connections>
|
||||
</tableCellView>
|
||||
</prototypeCellViews>
|
||||
</tableColumn>
|
||||
</tableColumns>
|
||||
<connections>
|
||||
<action trigger="doubleAction" selector="openRecentURL:" target="-2" id="kTu-60-aYp"/>
|
||||
<outlet property="dataSource" destination="-2" id="pLD-5Q-GVH"/>
|
||||
<outlet property="delegate" destination="-2" id="hO0-G9-RVy"/>
|
||||
</connections>
|
||||
</tableView>
|
||||
</subviews>
|
||||
</clipView>
|
||||
<constraints>
|
||||
<constraint firstAttribute="width" constant="200" id="R0Z-La-Y3C"/>
|
||||
</constraints>
|
||||
<scroller key="horizontalScroller" hidden="YES" verticalHuggingPriority="750" horizontal="YES" id="bRy-ef-e76">
|
||||
<rect key="frame" x="1" y="283" width="133" height="16"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
</scroller>
|
||||
<scroller key="verticalScroller" hidden="YES" verticalHuggingPriority="750" horizontal="NO" id="2e9-uR-dY7">
|
||||
<rect key="frame" x="224" y="17" width="15" height="102"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
</scroller>
|
||||
</scrollView>
|
||||
</endViews>
|
||||
<constraints>
|
||||
<constraint firstAttribute="bottom" secondItem="jd3-xw-cZP" secondAttribute="bottom" constant="20" id="581-be-EbR"/>
|
||||
<constraint firstItem="jd3-xw-cZP" firstAttribute="top" secondItem="ITj-5P-sn9" secondAttribute="top" constant="20" id="9he-mz-Ciw"/>
|
||||
<constraint firstAttribute="bottom" secondItem="eUA-6g-T1O" secondAttribute="bottom" constant="-1" id="Ejt-qZ-puH"/>
|
||||
<constraint firstAttribute="trailing" secondItem="eUA-6g-T1O" secondAttribute="trailing" constant="-1" id="PEw-In-uMJ"/>
|
||||
<constraint firstItem="eUA-6g-T1O" firstAttribute="top" secondItem="ITj-5P-sn9" secondAttribute="top" constant="-1" id="piI-8Q-zsE"/>
|
||||
</constraints>
|
||||
<visibilityPriorities>
|
||||
<integer value="1000"/>
|
||||
<integer value="1000"/>
|
||||
</visibilityPriorities>
|
||||
<customSpacing>
|
||||
<real value="3.4028234663852886e+38"/>
|
||||
<real value="3.4028234663852886e+38"/>
|
||||
</customSpacing>
|
||||
</stackView>
|
||||
</subviews>
|
||||
<constraints>
|
||||
<constraint firstAttribute="trailing" secondItem="ITj-5P-sn9" secondAttribute="trailing" id="7Bo-Jl-7Zu"/>
|
||||
<constraint firstItem="ITj-5P-sn9" firstAttribute="top" secondItem="9Nv-Zl-Z9p" secondAttribute="top" id="lrE-f8-tD5"/>
|
||||
<constraint firstItem="ITj-5P-sn9" firstAttribute="leading" secondItem="9Nv-Zl-Z9p" secondAttribute="leading" constant="20" id="oWL-PJ-VCT"/>
|
||||
<constraint firstAttribute="bottom" secondItem="ITj-5P-sn9" secondAttribute="bottom" id="syW-TO-uwv"/>
|
||||
</constraints>
|
||||
<point key="canvasLocation" x="-21" y="-483"/>
|
||||
</view>
|
||||
</objects>
|
||||
<resources>
|
||||
<image name="MacPassAppIcon" width="128" height="128"/>
|
||||
<image name="NSActionTemplate" width="14" height="14"/>
|
||||
</resources>
|
||||
</document>
|
||||
@@ -1,92 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="13196" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES">
|
||||
<dependencies>
|
||||
<deployment identifier="macosx"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="13196"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
<customObject id="-2" userLabel="File's Owner" customClass="MPAppDelegate">
|
||||
<connections>
|
||||
<outlet property="welcomeWindow" destination="1" id="94"/>
|
||||
</connections>
|
||||
</customObject>
|
||||
<customObject id="-1" userLabel="First Responder" customClass="FirstResponder"/>
|
||||
<customObject id="-3" userLabel="Application" customClass="NSObject"/>
|
||||
<window title="Welcome" allowsToolTipsWhenApplicationIsInactive="NO" autorecalculatesKeyViewLoop="NO" oneShot="NO" releasedWhenClosed="NO" visibleAtLaunch="NO" animationBehavior="default" id="1">
|
||||
<windowStyleMask key="styleMask" titled="YES" closable="YES" miniaturizable="YES"/>
|
||||
<rect key="contentRect" x="196" y="240" width="448" height="255"/>
|
||||
<rect key="screenRect" x="0.0" y="0.0" width="2560" height="1417"/>
|
||||
<view key="contentView" id="2">
|
||||
<rect key="frame" x="0.0" y="0.0" width="448" height="255"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<imageView translatesAutoresizingMaskIntoConstraints="NO" id="3">
|
||||
<rect key="frame" x="160" y="107" width="128" height="128"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="width" constant="128" id="18"/>
|
||||
<constraint firstAttribute="height" constant="128" id="19"/>
|
||||
</constraints>
|
||||
<imageCell key="cell" refusesFirstResponder="YES" alignment="left" imageScaling="proportionallyDown" image="MacPassAppIcon" id="4"/>
|
||||
</imageView>
|
||||
<textField verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="23">
|
||||
<rect key="frame" x="108" y="70" width="233" height="29"/>
|
||||
<textFieldCell key="cell" scrollable="YES" lineBreakMode="clipping" sendsActionOnEndEditing="YES" title="Welcome to MacPass" id="24">
|
||||
<font key="font" metaFont="system" size="24"/>
|
||||
<color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/>
|
||||
<color key="backgroundColor" name="controlColor" catalog="System" colorSpace="catalog"/>
|
||||
</textFieldCell>
|
||||
</textField>
|
||||
<button verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="43">
|
||||
<rect key="frame" x="172" y="18" width="118" height="25"/>
|
||||
<buttonCell key="cell" type="roundTextured" title="Open Database…" bezelStyle="texturedRounded" alignment="center" state="on" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="44">
|
||||
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
|
||||
<font key="font" metaFont="system"/>
|
||||
</buttonCell>
|
||||
<connections>
|
||||
<action selector="openDatabase:" target="-2" id="101"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="47">
|
||||
<rect key="frame" x="20" y="18" width="144" height="25"/>
|
||||
<buttonCell key="cell" type="roundTextured" title="Create new Database" bezelStyle="texturedRounded" alignment="center" state="on" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="48">
|
||||
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
|
||||
<font key="font" metaFont="system"/>
|
||||
</buttonCell>
|
||||
<connections>
|
||||
<action selector="createNewDatabase:" target="-2" id="102"/>
|
||||
</connections>
|
||||
</button>
|
||||
<button verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="69">
|
||||
<rect key="frame" x="372" y="18" width="56" height="25"/>
|
||||
<buttonCell key="cell" type="roundTextured" title="Cancel" bezelStyle="texturedRounded" alignment="center" state="on" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="70">
|
||||
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
|
||||
<font key="font" metaFont="system"/>
|
||||
</buttonCell>
|
||||
<connections>
|
||||
<action selector="orderOut:" target="1" id="93"/>
|
||||
</connections>
|
||||
</button>
|
||||
</subviews>
|
||||
<constraints>
|
||||
<constraint firstAttribute="bottom" secondItem="43" secondAttribute="bottom" constant="20" symbolic="YES" id="63"/>
|
||||
<constraint firstAttribute="bottom" secondItem="47" secondAttribute="bottom" constant="20" symbolic="YES" id="65"/>
|
||||
<constraint firstItem="47" firstAttribute="leading" secondItem="2" secondAttribute="leading" constant="20" symbolic="YES" id="66"/>
|
||||
<constraint firstItem="43" firstAttribute="leading" secondItem="47" secondAttribute="trailing" constant="8" symbolic="YES" id="68"/>
|
||||
<constraint firstAttribute="bottom" secondItem="69" secondAttribute="bottom" constant="20" symbolic="YES" id="73"/>
|
||||
<constraint firstAttribute="trailing" secondItem="69" secondAttribute="trailing" constant="20" symbolic="YES" id="74"/>
|
||||
<constraint firstItem="3" firstAttribute="centerX" secondItem="23" secondAttribute="centerX" id="85"/>
|
||||
<constraint firstItem="3" firstAttribute="top" secondItem="2" secondAttribute="top" constant="20" symbolic="YES" id="87"/>
|
||||
<constraint firstItem="23" firstAttribute="top" secondItem="3" secondAttribute="bottom" constant="8" symbolic="YES" id="89"/>
|
||||
<constraint firstItem="69" firstAttribute="leading" relation="greaterThanOrEqual" secondItem="43" secondAttribute="trailing" constant="8" symbolic="YES" id="96"/>
|
||||
<constraint firstItem="43" firstAttribute="top" relation="greaterThanOrEqual" secondItem="23" secondAttribute="bottom" constant="8" symbolic="YES" id="98"/>
|
||||
<constraint firstItem="3" firstAttribute="centerX" secondItem="2" secondAttribute="centerX" id="100"/>
|
||||
</constraints>
|
||||
</view>
|
||||
<point key="canvasLocation" x="133" y="85"/>
|
||||
</window>
|
||||
</objects>
|
||||
<resources>
|
||||
<image name="MacPassAppIcon" width="128" height="128"/>
|
||||
</resources>
|
||||
</document>
|
||||
@@ -24,12 +24,8 @@
|
||||
|
||||
APPKIT_EXTERN NSString *const MPDidChangeStoredKeyFilesSettings;
|
||||
|
||||
@class MPAutotypeDaemon;
|
||||
|
||||
@interface MPAppDelegate : NSObject <NSApplicationDelegate, NSMenuDelegate>
|
||||
|
||||
@property (strong) IBOutlet NSWindow *passwordCreatorWindow;
|
||||
@property (strong) IBOutlet NSWindow *welcomeWindow;
|
||||
@property (weak) IBOutlet NSMenuItem *saveMenuItem;
|
||||
@property (weak) IBOutlet NSMenuItem *fixAutotypeMenuItem;
|
||||
@property (weak) IBOutlet NSMenuItem *fileNewMenuItem;
|
||||
@@ -52,5 +48,6 @@ APPKIT_EXTERN NSString *const MPDidChangeStoredKeyFilesSettings;
|
||||
- (void)lockAllDocuments;
|
||||
|
||||
- (void)showWelcomeWindow;
|
||||
- (void)hideWelcomeWindow;
|
||||
|
||||
@end
|
||||
|
||||
@@ -39,6 +39,7 @@
|
||||
#import "MPTemporaryFileStorageCenter.h"
|
||||
#import "MPValueTransformerHelper.h"
|
||||
#import "MPUserNotificationCenterDelegate.h"
|
||||
#import "MPWelcomeViewController.h"
|
||||
|
||||
#import "NSApplication+MPAdditions.h"
|
||||
|
||||
@@ -55,6 +56,8 @@ NSString *const MPDidChangeStoredKeyFilesSettings = @"com.hicknhack.macpass.MPDi
|
||||
BOOL _shouldOpenFile; // YES if app was started to open a
|
||||
}
|
||||
|
||||
@property (strong) NSWindow *welcomeWindow;
|
||||
@property (strong) IBOutlet NSWindow *passwordCreatorWindow;
|
||||
@property (strong, nonatomic) MPSettingsWindowController *settingsController;
|
||||
@property (strong, nonatomic) MPPasswordCreatorViewController *passwordCreatorController;
|
||||
|
||||
@@ -249,10 +252,25 @@ NSString *const MPDidChangeStoredKeyFilesSettings = @"com.hicknhack.macpass.MPDi
|
||||
}
|
||||
|
||||
- (void)showWelcomeWindow {
|
||||
[self _loadWelcomeWindow];
|
||||
if(!self.welcomeWindow) {
|
||||
self.welcomeWindow = [[NSWindow alloc] initWithContentRect:NSMakeRect(0, 0, 100, 100)
|
||||
styleMask:NSWindowStyleMaskTitled|NSWindowStyleMaskClosable|NSWindowStyleMaskResizable
|
||||
backing:NSBackingStoreBuffered
|
||||
defer:NO];
|
||||
self.welcomeWindow.releasedWhenClosed = NO;
|
||||
}
|
||||
if(!self.welcomeWindow.contentViewController) {
|
||||
self.welcomeWindow.contentViewController = [[MPWelcomeViewController alloc] init];
|
||||
}
|
||||
|
||||
[self.welcomeWindow center];
|
||||
[self.welcomeWindow makeKeyAndOrderFront:nil];
|
||||
}
|
||||
|
||||
- (void)hideWelcomeWindow {
|
||||
[self.welcomeWindow orderOut:nil];
|
||||
}
|
||||
|
||||
- (void)clearRememberdKeyFiles:(id)sender {
|
||||
[NSUserDefaults.standardUserDefaults removeObjectForKey:kMPSettingsKeyRememeberdKeysForDatabases];
|
||||
}
|
||||
@@ -296,11 +314,4 @@ NSString *const MPDidChangeStoredKeyFilesSettings = @"com.hicknhack.macpass.MPDi
|
||||
}
|
||||
}
|
||||
|
||||
- (void)_loadWelcomeWindow {
|
||||
if(!_welcomeWindow) {
|
||||
NSArray *topLevelObject;
|
||||
[NSBundle.mainBundle loadNibNamed:@"WelcomeWindow" owner:self topLevelObjects:&topLevelObject];
|
||||
}
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
@@ -78,6 +78,11 @@
|
||||
return [super typeForContentsOfURL:url error:outError];
|
||||
}
|
||||
|
||||
- (void)addDocument:(NSDocument *)document {
|
||||
[((MPAppDelegate *)NSApp.delegate) hideWelcomeWindow];
|
||||
[super addDocument:document];
|
||||
}
|
||||
|
||||
- (BOOL)reopenLastDocument {
|
||||
if(self.documents.count > 0) {
|
||||
return YES; // The document is already open
|
||||
|
||||
17
MacPass/MPWelcomeViewController.h
Normal file
17
MacPass/MPWelcomeViewController.h
Normal file
@@ -0,0 +1,17 @@
|
||||
//
|
||||
// MPWelcomeWindowViewController.h
|
||||
// MacPass
|
||||
//
|
||||
// Created by Michael Starke on 28.09.18.
|
||||
// Copyright © 2018 HicknHack Software GmbH. All rights reserved.
|
||||
//
|
||||
|
||||
#import <Cocoa/Cocoa.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@interface MPWelcomeViewController : NSViewController <NSTableViewDataSource, NSTableViewDelegate>
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
50
MacPass/MPWelcomeViewController.m
Normal file
50
MacPass/MPWelcomeViewController.m
Normal file
@@ -0,0 +1,50 @@
|
||||
//
|
||||
// MPWelcomeWindowViewController.m
|
||||
// MacPass
|
||||
//
|
||||
// Created by Michael Starke on 28.09.18.
|
||||
// Copyright © 2018 HicknHack Software GmbH. All rights reserved.
|
||||
//
|
||||
|
||||
#import "MPWelcomeViewController.h"
|
||||
|
||||
@interface MPWelcomeViewController ()
|
||||
|
||||
@property (strong) IBOutlet NSTableView *tableView;
|
||||
|
||||
@end
|
||||
|
||||
@implementation MPWelcomeViewController
|
||||
|
||||
- (NSNibName)nibName {
|
||||
return @"WelcomeView";
|
||||
}
|
||||
|
||||
- (void)viewWillAppear {
|
||||
[super viewWillAppear];
|
||||
[self.tableView reloadData];
|
||||
}
|
||||
|
||||
- (NSInteger)numberOfRowsInTableView:(NSTableView *)tableView {
|
||||
return NSDocumentController.sharedDocumentController.recentDocumentURLs.count;
|
||||
}
|
||||
|
||||
- (nullable NSView *)tableView:(NSTableView *)tableView viewForTableColumn:(nullable NSTableColumn *)tableColumn row:(NSInteger)row {
|
||||
NSTableCellView *view = [tableView makeViewWithIdentifier:tableColumn.identifier owner:self];
|
||||
NSURL *url = NSDocumentController.sharedDocumentController.recentDocumentURLs[row];
|
||||
view.textField.stringValue = url.lastPathComponent;
|
||||
view.imageView.image = [NSWorkspace.sharedWorkspace iconForFile:url.path];
|
||||
return view;
|
||||
}
|
||||
|
||||
- (IBAction)openRecentURL:(id)sender {
|
||||
NSInteger clicked = self.tableView.clickedRow;
|
||||
NSArray <NSURL *> *recentURLS = NSDocumentController.sharedDocumentController.recentDocumentURLs;
|
||||
if(clicked > 0 && clicked < recentURLS.count) {
|
||||
[NSDocumentController.sharedDocumentController openDocumentWithContentsOfURL:recentURLS[clicked]
|
||||
display:YES
|
||||
completionHandler:^(NSDocument * _Nullable document, BOOL documentWasAlreadyOpen, NSError * _Nullable error) {}];
|
||||
}
|
||||
}
|
||||
|
||||
@end
|
||||
@@ -1,8 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="13196" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES">
|
||||
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="14313.18" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES">
|
||||
<dependencies>
|
||||
<deployment identifier="macosx"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="13196"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="14313.18"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
@@ -13,7 +13,7 @@
|
||||
</customObject>
|
||||
<customObject id="-1" userLabel="First Responder" customClass="FirstResponder"/>
|
||||
<customObject id="-3" userLabel="Application" customClass="NSObject"/>
|
||||
<window title="Password Generator" allowsToolTipsWhenApplicationIsInactive="NO" autorecalculatesKeyViewLoop="NO" oneShot="NO" releasedWhenClosed="NO" visibleAtLaunch="NO" animationBehavior="default" id="1">
|
||||
<window title="Password Generator" allowsToolTipsWhenApplicationIsInactive="NO" autorecalculatesKeyViewLoop="NO" releasedWhenClosed="NO" visibleAtLaunch="NO" animationBehavior="default" id="1">
|
||||
<windowStyleMask key="styleMask" titled="YES" closable="YES" miniaturizable="YES"/>
|
||||
<rect key="contentRect" x="196" y="240" width="338" height="216"/>
|
||||
<rect key="screenRect" x="0.0" y="0.0" width="2560" height="1417"/>
|
||||
@@ -21,7 +21,7 @@
|
||||
<rect key="frame" x="0.0" y="0.0" width="338" height="216"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
</view>
|
||||
<point key="canvasLocation" x="288" y="14"/>
|
||||
<point key="canvasLocation" x="48" y="-70"/>
|
||||
</window>
|
||||
</objects>
|
||||
</document>
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
/* Class = "NSWindow"; title = "Welcome"; ObjectID = "1"; */
|
||||
"1.title" = "Willkommen";
|
||||
|
||||
/* Class = "NSTextFieldCell"; title = "Welcome to MacPass"; ObjectID = "24"; */
|
||||
"24.title" = "Willkommen zu MacPass";
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
/* Class = "NSWindow"; title = "Welcome"; ObjectID = "1"; */
|
||||
"1.title" = "Welcome";
|
||||
|
||||
/* Class = "NSTextFieldCell"; title = "Welcome to MacPass"; ObjectID = "24"; */
|
||||
"24.title" = "Welcome to MacPass";
|
||||
|
||||
@@ -1,7 +1,3 @@
|
||||
|
||||
/* Class = "NSWindow"; title = "Welcome"; ObjectID = "1"; */
|
||||
"1.title" = "Bienvenido";
|
||||
|
||||
/* Class = "NSTextFieldCell"; title = "Welcome to MacPass"; ObjectID = "24"; */
|
||||
"24.title" = "Bienvenido a MacPass";
|
||||
|
||||
@@ -1,7 +1,3 @@
|
||||
|
||||
/* Class = "NSWindow"; title = "Welcome"; ObjectID = "1"; */
|
||||
"1.title" = "Bienvenue";
|
||||
|
||||
/* Class = "NSTextFieldCell"; title = "Welcome to MacPass"; ObjectID = "24"; */
|
||||
"24.title" = "Bienvenue dans MacPass";
|
||||
|
||||
@@ -1,7 +1,3 @@
|
||||
|
||||
/* Class = "NSWindow"; title = "Welcome"; ObjectID = "1"; */
|
||||
"1.title" = "Benvenuto";
|
||||
|
||||
/* Class = "NSTextFieldCell"; title = "Welcome to MacPass"; ObjectID = "24"; */
|
||||
"24.title" = "Benvenuto a MacPass";
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
/* Class = "NSWindow"; title = "Welcome"; ObjectID = "1"; */
|
||||
"1.title" = "Welkom";
|
||||
|
||||
/* Class = "NSTextFieldCell"; title = "Welcome to MacPass"; ObjectID = "24"; */
|
||||
"24.title" = "Welkom bij MacPass";
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
/* Class = "NSWindow"; title = "Welcome"; ObjectID = "1"; */
|
||||
"1.title" = "Witaj";
|
||||
|
||||
/* Class = "NSTextFieldCell"; title = "Welcome to MacPass"; ObjectID = "24"; */
|
||||
"24.title" = "Witaj w MacPass";
|
||||
|
||||
@@ -1,7 +1,3 @@
|
||||
|
||||
/* Class = "NSWindow"; title = "Welcome"; ObjectID = "1"; */
|
||||
"1.title" = "Добро пожаловать";
|
||||
|
||||
/* Class = "NSTextFieldCell"; title = "Welcome to MacPass"; ObjectID = "24"; */
|
||||
"24.title" = "Добро пожаловать в MacPass";
|
||||
|
||||
@@ -1,7 +1,3 @@
|
||||
|
||||
/* Class = "NSWindow"; title = "Welcome"; ObjectID = "1"; */
|
||||
"1.title" = "Välkommen";
|
||||
|
||||
/* Class = "NSTextFieldCell"; title = "Welcome to MacPass"; ObjectID = "24"; */
|
||||
"24.title" = "Välkommen till MacPass";
|
||||
|
||||
@@ -1,7 +1,3 @@
|
||||
|
||||
/* Class = "NSWindow"; title = "Welcome"; ObjectID = "1"; */
|
||||
"1.title" = "Welcome";
|
||||
|
||||
/* Class = "NSTextFieldCell"; title = "Welcome to MacPass"; ObjectID = "24"; */
|
||||
"24.title" = "欢迎使用 MacPass";
|
||||
|
||||
Reference in New Issue
Block a user