added sketch for autotype builder to show all autotype commands

This commit is contained in:
michael starke
2016-09-01 19:54:21 +02:00
parent 1c39f1c3fe
commit 6e2203bf51
7 changed files with 75 additions and 34 deletions

View File

@@ -191,6 +191,8 @@
4CA2335A176DBFE100F0B6AC /* MPLockDaemon.m in Sources */ = {isa = PBXBuildFile; fileRef = 4CA23359176DBFE100F0B6AC /* MPLockDaemon.m */; }; 4CA2335A176DBFE100F0B6AC /* MPLockDaemon.m in Sources */ = {isa = PBXBuildFile; fileRef = 4CA23359176DBFE100F0B6AC /* MPLockDaemon.m */; };
4CA334CA18AD60D1008A3322 /* MPWindowAssociationsTableViewDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 4CA334C918AD60D1008A3322 /* MPWindowAssociationsTableViewDelegate.m */; }; 4CA334CA18AD60D1008A3322 /* MPWindowAssociationsTableViewDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 4CA334C918AD60D1008A3322 /* MPWindowAssociationsTableViewDelegate.m */; };
4CA3530B18A53CB800839B0F /* MPKeyMapper.m in Sources */ = {isa = PBXBuildFile; fileRef = 4CA3530A18A53CB800839B0F /* MPKeyMapper.m */; }; 4CA3530B18A53CB800839B0F /* MPKeyMapper.m in Sources */ = {isa = PBXBuildFile; fileRef = 4CA3530A18A53CB800839B0F /* MPKeyMapper.m */; };
4CAAA8271D787B8B00CDE977 /* MPAutotypeBuilderViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 4CAAA8251D787B8B00CDE977 /* MPAutotypeBuilderViewController.m */; };
4CAAA8281D787B8B00CDE977 /* AutotypeBuilderView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 4CAAA8261D787B8B00CDE977 /* AutotypeBuilderView.xib */; };
4CAD748C15B889B700104512 /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4CAD748B15B889B700104512 /* Security.framework */; }; 4CAD748C15B889B700104512 /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4CAD748B15B889B700104512 /* Security.framework */; };
4CAD748E15B88AC100104512 /* libz.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 4CAD748D15B88AC100104512 /* libz.dylib */; }; 4CAD748E15B88AC100104512 /* libz.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 4CAD748D15B88AC100104512 /* libz.dylib */; };
4CB915941A0159A20089CE5B /* DuplicateEntryOptionsWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = 4CB915931A0159A20089CE5B /* DuplicateEntryOptionsWindow.xib */; }; 4CB915941A0159A20089CE5B /* DuplicateEntryOptionsWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = 4CB915931A0159A20089CE5B /* DuplicateEntryOptionsWindow.xib */; };
@@ -602,6 +604,9 @@
4CA334C918AD60D1008A3322 /* MPWindowAssociationsTableViewDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPWindowAssociationsTableViewDelegate.m; sourceTree = "<group>"; }; 4CA334C918AD60D1008A3322 /* MPWindowAssociationsTableViewDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPWindowAssociationsTableViewDelegate.m; sourceTree = "<group>"; };
4CA3530918A53CB800839B0F /* MPKeyMapper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPKeyMapper.h; sourceTree = "<group>"; }; 4CA3530918A53CB800839B0F /* MPKeyMapper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPKeyMapper.h; sourceTree = "<group>"; };
4CA3530A18A53CB800839B0F /* MPKeyMapper.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPKeyMapper.m; sourceTree = "<group>"; }; 4CA3530A18A53CB800839B0F /* MPKeyMapper.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPKeyMapper.m; sourceTree = "<group>"; };
4CAAA8241D787B8B00CDE977 /* MPAutotypeBuilderViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPAutotypeBuilderViewController.h; sourceTree = "<group>"; };
4CAAA8251D787B8B00CDE977 /* MPAutotypeBuilderViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPAutotypeBuilderViewController.m; sourceTree = "<group>"; };
4CAAA8261D787B8B00CDE977 /* AutotypeBuilderView.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = AutotypeBuilderView.xib; sourceTree = "<group>"; };
4CAD748B15B889B700104512 /* Security.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Security.framework; path = System/Library/Frameworks/Security.framework; sourceTree = SDKROOT; }; 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; }; 4CAD748D15B88AC100104512 /* libz.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libz.dylib; path = usr/lib/libz.dylib; sourceTree = SDKROOT; };
4CB63A6018986530002DEC4C /* MPFlagsHelper.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MPFlagsHelper.h; sourceTree = "<group>"; }; 4CB63A6018986530002DEC4C /* MPFlagsHelper.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MPFlagsHelper.h; sourceTree = "<group>"; };
@@ -844,6 +849,7 @@
6021FE7918E15FF300C3BC51 /* DatePickingView.xib */, 6021FE7918E15FF300C3BC51 /* DatePickingView.xib */,
4C26C34A18D8D5A300CF1A1C /* PreviewView.xib */, 4C26C34A18D8D5A300CF1A1C /* PreviewView.xib */,
4CD820231A32173100399DBB /* ReferenceBuilderView.xib */, 4CD820231A32173100399DBB /* ReferenceBuilderView.xib */,
4CAAA8261D787B8B00CDE977 /* AutotypeBuilderView.xib */,
4CE8247316E2F2B900573141 /* MPOverlayView.h */, 4CE8247316E2F2B900573141 /* MPOverlayView.h */,
4CE8247416E2F2B900573141 /* MPOverlayView.m */, 4CE8247416E2F2B900573141 /* MPOverlayView.m */,
4CFC53BD16E94729007396BE /* MPShadowBox.h */, 4CFC53BD16E94729007396BE /* MPShadowBox.h */,
@@ -1305,6 +1311,8 @@
4C26C34918D8D5A300CF1A1C /* MPPreviewViewController.m */, 4C26C34918D8D5A300CF1A1C /* MPPreviewViewController.m */,
4CE30ACA1A312B7F0063FCC6 /* MPReferenceBuilderViewController.h */, 4CE30ACA1A312B7F0063FCC6 /* MPReferenceBuilderViewController.h */,
4CE30ACB1A312B7F0063FCC6 /* MPReferenceBuilderViewController.m */, 4CE30ACB1A312B7F0063FCC6 /* MPReferenceBuilderViewController.m */,
4CAAA8241D787B8B00CDE977 /* MPAutotypeBuilderViewController.h */,
4CAAA8251D787B8B00CDE977 /* MPAutotypeBuilderViewController.m */,
); );
name = "View Controller"; name = "View Controller";
sourceTree = "<group>"; sourceTree = "<group>";
@@ -1539,6 +1547,7 @@
files = ( files = (
4C3826AE1AD04D8E007D7D67 /* 33_RunTemplate.pdf in Resources */, 4C3826AE1AD04D8E007D7D67 /* 33_RunTemplate.pdf in Resources */,
4C3826A51AD04D8E007D7D67 /* 21_OrganizerTemplate.pdf in Resources */, 4C3826A51AD04D8E007D7D67 /* 21_OrganizerTemplate.pdf in Resources */,
4CAAA8281D787B8B00CDE977 /* AutotypeBuilderView.xib in Resources */,
4C17F108184E6B6C00E85625 /* 31_PrintTemplate.pdf in Resources */, 4C17F108184E6B6C00E85625 /* 31_PrintTemplate.pdf in Resources */,
4C77E37115B84A240093A587 /* InfoPlist.strings in Resources */, 4C77E37115B84A240093A587 /* InfoPlist.strings in Resources */,
4C3826781AD04C8A007D7D67 /* createdTemplate.pdf in Resources */, 4C3826781AD04C8A007D7D67 /* createdTemplate.pdf in Resources */,
@@ -1791,6 +1800,7 @@
4CE2961518429AA5005F01CE /* MPAutotypeKeyPress.m in Sources */, 4CE2961518429AA5005F01CE /* MPAutotypeKeyPress.m in Sources */,
4C32B0E71A1D4436007E12F1 /* KPKFormat+MPUTIDetection.m in Sources */, 4C32B0E71A1D4436007E12F1 /* KPKFormat+MPUTIDetection.m in Sources */,
4C5807781C64F67000E7171F /* NSString+MPHash.m in Sources */, 4C5807781C64F67000E7171F /* NSString+MPHash.m in Sources */,
4CAAA8271D787B8B00CDE977 /* MPAutotypeBuilderViewController.m in Sources */,
4CE501341BBC47F500FB819D /* MPTagsTokenFieldDelegate.m in Sources */, 4CE501341BBC47F500FB819D /* MPTagsTokenFieldDelegate.m in Sources */,
4CC6DB7A17D23719002C6091 /* KPKNode+IconImage.m in Sources */, 4CC6DB7A17D23719002C6091 /* KPKNode+IconImage.m in Sources */,
4C15B74618BCA3B1003F8008 /* MPDocument+Search.m in Sources */, 4C15B74618BCA3B1003F8008 /* MPDocument+Search.m in Sources */,

View File

@@ -7,31 +7,26 @@
<objects> <objects>
<customObject id="-2" userLabel="File's Owner" customClass="MPAutotypeBuilderViewController"> <customObject id="-2" userLabel="File's Owner" customClass="MPAutotypeBuilderViewController">
<connections> <connections>
<outlet property="tokenField" destination="k06-gn-ahB" id="YKa-O1-bpM"/>
<outlet property="view" destination="Hz6-mo-xeY" id="0bl-1N-x8E"/> <outlet property="view" destination="Hz6-mo-xeY" id="0bl-1N-x8E"/>
</connections> </connections>
</customObject> </customObject>
<customObject id="-1" userLabel="First Responder" customClass="FirstResponder"/> <customObject id="-1" userLabel="First Responder" customClass="FirstResponder"/>
<customObject id="-3" userLabel="Application" customClass="NSObject"/> <customObject id="-3" userLabel="Application" customClass="NSObject"/>
<customView misplaced="YES" id="Hz6-mo-xeY"> <customView id="Hz6-mo-xeY">
<rect key="frame" x="0.0" y="0.0" width="405" height="298"/> <rect key="frame" x="0.0" y="0.0" width="405" height="298"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/> <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
<subviews> <subviews>
<tokenField verticalHuggingPriority="750" misplaced="YES" translatesAutoresizingMaskIntoConstraints="NO" id="Kvn-IG-DGI"> <tokenField verticalHuggingPriority="750" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="k06-gn-ahB">
<rect key="frame" x="20" y="-76" width="443" height="354"/> <rect key="frame" x="20" y="15" width="365" height="268"/>
<tokenFieldCell key="cell" selectable="YES" editable="YES" alignment="left" allowsEditingTextAttributes="YES" id="GSA-a9-99Q"> <tokenFieldCell key="cell" selectable="YES" editable="YES" borderStyle="bezel" alignment="left" drawsBackground="YES" allowsEditingTextAttributes="YES" id="mfe-Zs-cxC">
<font key="font" metaFont="cellTitle"/> <font key="font" metaFont="cellTitle"/>
<color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/> <color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/>
<color key="backgroundColor" name="textBackgroundColor" catalog="System" colorSpace="catalog"/> <color key="backgroundColor" name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
</tokenFieldCell> </tokenFieldCell>
</tokenField> </tokenField>
</subviews> </subviews>
<constraints> <point key="canvasLocation" x="344.5" y="200"/>
<constraint firstAttribute="bottom" secondItem="Kvn-IG-DGI" secondAttribute="bottom" constant="20" id="YKC-lP-F5T"/>
<constraint firstItem="Kvn-IG-DGI" firstAttribute="top" secondItem="Hz6-mo-xeY" secondAttribute="top" constant="20" id="bJu-XA-mqO"/>
<constraint firstItem="Kvn-IG-DGI" firstAttribute="leading" secondItem="Hz6-mo-xeY" secondAttribute="leading" constant="22" id="p3m-hr-McG"/>
<constraint firstAttribute="trailing" secondItem="Kvn-IG-DGI" secondAttribute="trailing" constant="20" id="wNY-D6-iuK"/>
</constraints>
<point key="canvasLocation" x="324.5" y="487"/>
</customView> </customView>
</objects> </objects>
</document> </document>

View File

@@ -15,8 +15,6 @@
<outlet property="customEntrySequenceTextField" destination="cDK-DM-F5z" id="CDU-Oq-AHP"/> <outlet property="customEntrySequenceTextField" destination="cDK-DM-F5z" id="CDU-Oq-AHP"/>
<outlet property="customFieldsTableView" destination="193" id="266"/> <outlet property="customFieldsTableView" destination="193" id="266"/>
<outlet property="enableAutotypeCheckButton" destination="kdV-Xa-8p3" id="vlC-HP-lBv"/> <outlet property="enableAutotypeCheckButton" destination="kdV-Xa-8p3" id="vlC-HP-lBv"/>
<outlet property="enableCustomAssociationSequenceButton" destination="m1C-m8-BKR" id="NCR-jQ-A0t"/>
<outlet property="enableCustomEntrySequenceButton" destination="HDS-Bz-jrr" id="z3o-uN-efY"/>
<outlet property="expiresCheckButton" destination="7" id="286"/> <outlet property="expiresCheckButton" destination="7" id="286"/>
<outlet property="generalView" destination="4" id="270"/> <outlet property="generalView" destination="4" id="270"/>
<outlet property="generatePasswordButton" destination="59" id="282"/> <outlet property="generatePasswordButton" destination="59" id="282"/>
@@ -24,6 +22,8 @@
<outlet property="obfuscateAutotypeCheckButton" destination="I7L-Am-Qpa" id="hwa-zl-24W"/> <outlet property="obfuscateAutotypeCheckButton" destination="I7L-Am-Qpa" id="hwa-zl-24W"/>
<outlet property="passwordTextField" destination="60" id="263"/> <outlet property="passwordTextField" destination="60" id="263"/>
<outlet property="removeAssociationButton" destination="AAj-Ak-z46" id="7Xj-Tf-8CI"/> <outlet property="removeAssociationButton" destination="AAj-Ak-z46" id="7Xj-Tf-8CI"/>
<outlet property="showCustomAssociationSequenceAutotypeBuilderButton" destination="m1C-m8-BKR" id="B3I-AG-TCJ"/>
<outlet property="showCustomEntrySequenceAutotypeBuilderButton" destination="HDS-Bz-jrr" id="7u1-17-oMK"/>
<outlet property="tabView" destination="83" id="269"/> <outlet property="tabView" destination="83" id="269"/>
<outlet property="tagsTokenField" destination="5" id="287"/> <outlet property="tagsTokenField" destination="5" id="287"/>
<outlet property="titleTextField" destination="53" id="260"/> <outlet property="titleTextField" destination="53" id="260"/>
@@ -534,7 +534,7 @@
<font key="font" metaFont="system"/> <font key="font" metaFont="system"/>
</buttonCell> </buttonCell>
<connections> <connections>
<action selector="_popUpPasswordGenerator:" target="-2" id="272"/> <action selector="showPasswordGenerator:" target="-2" id="xxV-lD-L1K"/>
<outlet property="nextKeyView" destination="56" id="rY0-PH-WBT"/> <outlet property="nextKeyView" destination="56" id="rY0-PH-WBT"/>
</connections> </connections>
</button> </button>
@@ -874,9 +874,12 @@
<constraint firstAttribute="width" constant="32" id="Ek5-IH-qGo"/> <constraint firstAttribute="width" constant="32" id="Ek5-IH-qGo"/>
</constraints> </constraints>
<buttonCell key="cell" type="roundTextured" bezelStyle="texturedRounded" image="NSActionTemplate" imagePosition="only" alignment="center" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="HIC-T9-j9G"> <buttonCell key="cell" type="roundTextured" bezelStyle="texturedRounded" image="NSActionTemplate" imagePosition="only" alignment="center" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="HIC-T9-j9G">
<behavior key="behavior" pushIn="YES" changeContents="YES" lightByContents="YES"/> <behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
<font key="font" metaFont="system"/> <font key="font" metaFont="system"/>
</buttonCell> </buttonCell>
<connections>
<action selector="showAutotypeBuilder:" target="-2" id="uGu-Lw-qBV"/>
</connections>
</button> </button>
<button verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="HDS-Bz-jrr"> <button verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="HDS-Bz-jrr">
<rect key="frame" x="249" y="325" width="32" height="25"/> <rect key="frame" x="249" y="325" width="32" height="25"/>
@@ -884,9 +887,12 @@
<constraint firstAttribute="width" constant="32" id="CbR-2P-dZH"/> <constraint firstAttribute="width" constant="32" id="CbR-2P-dZH"/>
</constraints> </constraints>
<buttonCell key="cell" type="roundTextured" bezelStyle="texturedRounded" image="NSActionTemplate" imagePosition="only" alignment="center" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="V5Z-qf-FVH"> <buttonCell key="cell" type="roundTextured" bezelStyle="texturedRounded" image="NSActionTemplate" imagePosition="only" alignment="center" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="V5Z-qf-FVH">
<behavior key="behavior" pushIn="YES" changeContents="YES" lightByContents="YES"/> <behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
<font key="font" metaFont="system"/> <font key="font" metaFont="system"/>
</buttonCell> </buttonCell>
<connections>
<action selector="showAutotypeBuilder:" target="-2" id="qyX-xA-cKB"/>
</connections>
</button> </button>
</subviews> </subviews>
<constraints> <constraints>

View File

@@ -1,8 +1,8 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="9059" systemVersion="15B42" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES" customObjectInstantitationMethod="direct"> <document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="10117" systemVersion="15G31" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES" customObjectInstantitationMethod="direct">
<dependencies> <dependencies>
<deployment identifier="macosx"/> <deployment identifier="macosx"/>
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="9059"/> <plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="10117"/>
</dependencies> </dependencies>
<objects> <objects>
<customObject id="-2" userLabel="File's Owner" customClass="MPReferenceBuilderViewController"> <customObject id="-2" userLabel="File's Owner" customClass="MPReferenceBuilderViewController">
@@ -22,7 +22,6 @@
<subviews> <subviews>
<popUpButton verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="IZP-Gd-jdU"> <popUpButton verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="IZP-Gd-jdU">
<rect key="frame" x="13" y="153" width="80" height="19"/> <rect key="frame" x="13" y="153" width="80" height="19"/>
<animations/>
<popUpButtonCell key="cell" type="roundRect" bezelStyle="roundedRect" alignment="center" lineBreakMode="truncatingTail" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="KPf-xE-gde"> <popUpButtonCell key="cell" type="roundRect" bezelStyle="roundedRect" alignment="center" lineBreakMode="truncatingTail" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="KPf-xE-gde">
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/> <behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
<font key="font" metaFont="cellTitle"/> <font key="font" metaFont="cellTitle"/>
@@ -41,7 +40,6 @@
<constraints> <constraints>
<constraint firstAttribute="width" relation="greaterThanOrEqual" constant="100" id="Seu-01-P53"/> <constraint firstAttribute="width" relation="greaterThanOrEqual" constant="100" id="Seu-01-P53"/>
</constraints> </constraints>
<animations/>
<textFieldCell key="cell" scrollable="YES" lineBreakMode="clipping" selectable="YES" editable="YES" sendsActionOnEndEditing="YES" state="on" borderStyle="bezel" placeholderString="Value" drawsBackground="YES" id="fNP-ye-2bD"> <textFieldCell key="cell" scrollable="YES" lineBreakMode="clipping" selectable="YES" editable="YES" sendsActionOnEndEditing="YES" state="on" borderStyle="bezel" placeholderString="Value" drawsBackground="YES" id="fNP-ye-2bD">
<font key="font" metaFont="system"/> <font key="font" metaFont="system"/>
<color key="textColor" name="textColor" catalog="System" colorSpace="catalog"/> <color key="textColor" name="textColor" catalog="System" colorSpace="catalog"/>
@@ -50,7 +48,6 @@
</textField> </textField>
<button verticalHuggingPriority="750" misplaced="YES" translatesAutoresizingMaskIntoConstraints="NO" id="T2o-aJ-JmD"> <button verticalHuggingPriority="750" misplaced="YES" translatesAutoresizingMaskIntoConstraints="NO" id="T2o-aJ-JmD">
<rect key="frame" x="143" y="18" width="37" height="25"/> <rect key="frame" x="143" y="18" width="37" height="25"/>
<animations/>
<buttonCell key="cell" type="roundTextured" title="Use" bezelStyle="texturedRounded" alignment="center" state="on" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="Kqx-qm-nMG"> <buttonCell key="cell" type="roundTextured" title="Use" bezelStyle="texturedRounded" alignment="center" state="on" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="Kqx-qm-nMG">
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/> <behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
<font key="font" metaFont="system"/> <font key="font" metaFont="system"/>
@@ -58,7 +55,6 @@
</button> </button>
<textField horizontalHuggingPriority="251" verticalHuggingPriority="750" misplaced="YES" translatesAutoresizingMaskIntoConstraints="NO" id="VR5-Rx-ueN"> <textField horizontalHuggingPriority="251" verticalHuggingPriority="750" misplaced="YES" translatesAutoresizingMaskIntoConstraints="NO" id="VR5-Rx-ueN">
<rect key="frame" x="99" y="180" width="23" height="14"/> <rect key="frame" x="99" y="180" width="23" height="14"/>
<animations/>
<textFieldCell key="cell" controlSize="small" scrollable="YES" lineBreakMode="clipping" sendsActionOnEndEditing="YES" title="Key" id="K1t-OZ-ACe"> <textFieldCell key="cell" controlSize="small" scrollable="YES" lineBreakMode="clipping" sendsActionOnEndEditing="YES" title="Key" id="K1t-OZ-ACe">
<font key="font" metaFont="smallSystem"/> <font key="font" metaFont="smallSystem"/>
<color key="textColor" name="disabledControlTextColor" catalog="System" colorSpace="catalog"/> <color key="textColor" name="disabledControlTextColor" catalog="System" colorSpace="catalog"/>
@@ -67,7 +63,6 @@
</textField> </textField>
<textField horizontalHuggingPriority="251" verticalHuggingPriority="750" misplaced="YES" translatesAutoresizingMaskIntoConstraints="NO" id="sZo-ie-Asw"> <textField horizontalHuggingPriority="251" verticalHuggingPriority="750" misplaced="YES" translatesAutoresizingMaskIntoConstraints="NO" id="sZo-ie-Asw">
<rect key="frame" x="11" y="180" width="57" height="14"/> <rect key="frame" x="11" y="180" width="57" height="14"/>
<animations/>
<textFieldCell key="cell" controlSize="small" scrollable="YES" lineBreakMode="clipping" sendsActionOnEndEditing="YES" title="Reference" id="r1V-VE-ngy"> <textFieldCell key="cell" controlSize="small" scrollable="YES" lineBreakMode="clipping" sendsActionOnEndEditing="YES" title="Reference" id="r1V-VE-ngy">
<font key="font" metaFont="smallSystem"/> <font key="font" metaFont="smallSystem"/>
<color key="textColor" name="disabledControlTextColor" catalog="System" colorSpace="catalog"/> <color key="textColor" name="disabledControlTextColor" catalog="System" colorSpace="catalog"/>
@@ -76,7 +71,6 @@
</textField> </textField>
<popUpButton horizontalHuggingPriority="249" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="b4e-k2-WPS"> <popUpButton horizontalHuggingPriority="249" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="b4e-k2-WPS">
<rect key="frame" x="101" y="153" width="79" height="19"/> <rect key="frame" x="101" y="153" width="79" height="19"/>
<animations/>
<popUpButtonCell key="cell" type="roundRect" title="Matching" bezelStyle="roundedRect" alignment="center" lineBreakMode="truncatingTail" state="on" borderStyle="border" imageScaling="proportionallyDown" inset="2" selectedItem="yT1-XL-k6a" id="Aob-tW-bUP"> <popUpButtonCell key="cell" type="roundRect" title="Matching" bezelStyle="roundedRect" alignment="center" lineBreakMode="truncatingTail" state="on" borderStyle="border" imageScaling="proportionallyDown" inset="2" selectedItem="yT1-XL-k6a" id="Aob-tW-bUP">
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/> <behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
<font key="font" metaFont="cellTitle"/> <font key="font" metaFont="cellTitle"/>
@@ -94,7 +88,6 @@
</popUpButton> </popUpButton>
<textField horizontalHuggingPriority="251" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="WTJ-he-uTu"> <textField horizontalHuggingPriority="251" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="WTJ-he-uTu">
<rect key="frame" x="11" y="132" width="37" height="14"/> <rect key="frame" x="11" y="132" width="37" height="14"/>
<animations/>
<textFieldCell key="cell" controlSize="small" scrollable="YES" lineBreakMode="clipping" sendsActionOnEndEditing="YES" title="Match" id="9ce-da-syF"> <textFieldCell key="cell" controlSize="small" scrollable="YES" lineBreakMode="clipping" sendsActionOnEndEditing="YES" title="Match" id="9ce-da-syF">
<font key="font" metaFont="smallSystem"/> <font key="font" metaFont="smallSystem"/>
<color key="textColor" name="disabledControlTextColor" catalog="System" colorSpace="catalog"/> <color key="textColor" name="disabledControlTextColor" catalog="System" colorSpace="catalog"/>
@@ -103,7 +96,6 @@
</textField> </textField>
<textField horizontalHuggingPriority="251" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="mcC-bG-cCz"> <textField horizontalHuggingPriority="251" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="mcC-bG-cCz">
<rect key="frame" x="11" y="80" width="92" height="14"/> <rect key="frame" x="11" y="80" width="92" height="14"/>
<animations/>
<textFieldCell key="cell" controlSize="small" scrollable="YES" lineBreakMode="clipping" sendsActionOnEndEditing="YES" title="Reference String" id="gik-Ha-hRd"> <textFieldCell key="cell" controlSize="small" scrollable="YES" lineBreakMode="clipping" sendsActionOnEndEditing="YES" title="Reference String" id="gik-Ha-hRd">
<font key="font" metaFont="smallSystem"/> <font key="font" metaFont="smallSystem"/>
<color key="textColor" name="disabledControlTextColor" catalog="System" colorSpace="catalog"/> <color key="textColor" name="disabledControlTextColor" catalog="System" colorSpace="catalog"/>
@@ -112,7 +104,6 @@
</textField> </textField>
<textField verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="b36-T7-1tO" customClass="HNHUIRoundedTextField"> <textField verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="b36-T7-1tO" customClass="HNHUIRoundedTextField">
<rect key="frame" x="13" y="50" width="167" height="22"/> <rect key="frame" x="13" y="50" width="167" height="22"/>
<animations/>
<textFieldCell key="cell" scrollable="YES" lineBreakMode="clipping" sendsActionOnEndEditing="YES" state="on" borderStyle="bezel" placeholderString="Reference" drawsBackground="YES" id="dr9-x8-kKk"> <textFieldCell key="cell" scrollable="YES" lineBreakMode="clipping" sendsActionOnEndEditing="YES" state="on" borderStyle="bezel" placeholderString="Reference" drawsBackground="YES" id="dr9-x8-kKk">
<font key="font" metaFont="system"/> <font key="font" metaFont="system"/>
<color key="textColor" name="textColor" catalog="System" colorSpace="catalog"/> <color key="textColor" name="textColor" catalog="System" colorSpace="catalog"/>
@@ -146,7 +137,6 @@
<constraint firstItem="mcC-bG-cCz" firstAttribute="top" secondItem="IFf-vC-3vk" secondAttribute="bottom" constant="8" id="wNQ-xf-cQH"/> <constraint firstItem="mcC-bG-cCz" firstAttribute="top" secondItem="IFf-vC-3vk" secondAttribute="bottom" constant="8" id="wNQ-xf-cQH"/>
<constraint firstItem="T2o-aJ-JmD" firstAttribute="trailing" secondItem="b36-T7-1tO" secondAttribute="trailing" id="yQJ-FX-1Xw"/> <constraint firstItem="T2o-aJ-JmD" firstAttribute="trailing" secondItem="b36-T7-1tO" secondAttribute="trailing" id="yQJ-FX-1Xw"/>
</constraints> </constraints>
<animations/>
<point key="canvasLocation" x="-219" y="-73.5"/> <point key="canvasLocation" x="-219" y="-73.5"/>
</customView> </customView>
</objects> </objects>

View File

@@ -7,16 +7,45 @@
// //
#import "MPAutotypeBuilderViewController.h" #import "MPAutotypeBuilderViewController.h"
#import <KeePassKit/KeePassKit.h>
@interface MPAutotypeBuilderViewController () @interface MPAutotypeBuilderViewController ()
@property (weak) IBOutlet NSTokenField *tokenField;
@property (nonatomic, readonly, strong) NSArray<NSString *> *tokens;
@end @end
@implementation MPAutotypeBuilderViewController @implementation MPAutotypeBuilderViewController
#define _MPToken(short,long) [NSString stringWithFormat:@"%@ %@", short, long]
- (NSArray<NSString *> *)tokens {
static NSArray *_tokens;
static dispatch_once_t onceToken;
dispatch_once(&onceToken, ^{
NSMutableArray *fields = [[NSMutableArray alloc] init];
for(NSString *attribute in [KPKFormat sharedFormat].entryDefaultKeys) {
[fields addObject:[NSString stringWithFormat:@"{%@}", attribute]];
}
_tokens = [fields arrayByAddingObjectsFromArray:@[ _MPToken(kKPKAutotypeShortEnter, kKPKAutotypeEnter),
_MPToken(kKPKAutotypeShortAlt, kKPKAutotypeAlt),
_MPToken(kKPKAutotypeShortControl, kKPKAutotypeControl),
]];
});
return _tokens;
}
- (NSString *)nibName {
return @"AutotypeBuilderView";
}
- (void)viewDidLoad { - (void)viewDidLoad {
[super viewDidLoad]; [super viewDidLoad];
// Do view setup here. self.tokenField.editable = NO;
self.tokenField.objectValue = self.tokens;
} }
@end @end

View File

@@ -42,18 +42,20 @@
@property (weak) IBOutlet NSButton *enableAutotypeCheckButton; @property (weak) IBOutlet NSButton *enableAutotypeCheckButton;
@property (weak) IBOutlet NSButton *obfuscateAutotypeCheckButton; @property (weak) IBOutlet NSButton *obfuscateAutotypeCheckButton;
@property (weak) IBOutlet NSTableView *windowAssociationsTableView; @property (weak) IBOutlet NSTableView *windowAssociationsTableView;
@property (weak) IBOutlet NSButton *enableCustomEntrySequenceButton; @property (weak) IBOutlet NSButton *showCustomEntrySequenceAutotypeBuilderButton;
@property (weak) IBOutlet NSTextField *customEntrySequenceTextField; @property (weak) IBOutlet NSTextField *customEntrySequenceTextField;
@property (weak) IBOutlet NSComboBox *windowTitleComboBox; @property (weak) IBOutlet NSComboBox *windowTitleComboBox;
@property (weak) IBOutlet NSButton *removeAssociationButton; @property (weak) IBOutlet NSButton *removeAssociationButton;
@property (weak) IBOutlet NSButton *addAssociationButton; @property (weak) IBOutlet NSButton *addAssociationButton;
@property (weak) IBOutlet NSButton *enableCustomAssociationSequenceButton; @property (weak) IBOutlet NSButton *showCustomAssociationSequenceAutotypeBuilderButton;
@property (weak) IBOutlet NSTextField *associationSequenceTextField; @property (weak) IBOutlet NSTextField *associationSequenceTextField;
- (void)registerNotificationsForDocument:(MPDocument *)document; - (void)registerNotificationsForDocument:(MPDocument *)document;
- (IBAction)showPasswordGenerator:(id)sender;
- (IBAction)saveAttachment:(id)sender; - (IBAction)saveAttachment:(id)sender;
- (IBAction)addAttachment:(id)sender; - (IBAction)addAttachment:(id)sender;
- (IBAction)removeAttachment:(id)sender; - (IBAction)removeAttachment:(id)sender;

View File

@@ -13,6 +13,7 @@
#import "MPPasswordCreatorViewController.h" #import "MPPasswordCreatorViewController.h"
#import "MPWindowAssociationsTableViewDelegate.h" #import "MPWindowAssociationsTableViewDelegate.h"
#import "MPWindowTitleComboBoxDelegate.h" #import "MPWindowTitleComboBoxDelegate.h"
#import "MPAutotypeBuilderViewController.h"
#import "NSString+MPPasswordCreation.h" #import "NSString+MPPasswordCreation.h"
@@ -275,13 +276,19 @@ typedef NS_ENUM(NSUInteger, MPEntryTab) {
#pragma mark - #pragma mark -
#pragma mark Popovers #pragma mark Popovers
- (IBAction)_popUpPasswordGenerator:(id)sender { - (IBAction)showAutotypeBuilder:(id)sender {
[sender setEnabled:NO];
MPAutotypeBuilderViewController *autotypeBuilder = [[MPAutotypeBuilderViewController alloc] init];
[self _showPopopver:autotypeBuilder atView:sender onEdge:NSMinYEdge];
}
- (IBAction)showPasswordGenerator:(id)sender {
self.generatePasswordButton.enabled = NO; self.generatePasswordButton.enabled = NO;
MPPasswordCreatorViewController *viewController = [[MPPasswordCreatorViewController alloc] init]; MPPasswordCreatorViewController *viewController = [[MPPasswordCreatorViewController alloc] init];
viewController.allowsEntryDefaults = YES; viewController.allowsEntryDefaults = YES;
viewController.representedObject = self.representedObject; viewController.representedObject = self.representedObject;
viewController.observer = self.windowController.document; viewController.observer = self.windowController.document;
[self _showPopopver:viewController atView:self.passwordTextField onEdge:NSMinYEdge]; [self _showPopopver:viewController atView:sender onEdge:NSMinYEdge];
} }
- (void)_showPopopver:(NSViewController *)viewController atView:(NSView *)view onEdge:(NSRectEdge)edge { - (void)_showPopopver:(NSViewController *)viewController atView:(NSView *)view onEdge:(NSRectEdge)edge {
@@ -299,6 +306,8 @@ typedef NS_ENUM(NSUInteger, MPEntryTab) {
- (void)popoverDidClose:(NSNotification *)notification { - (void)popoverDidClose:(NSNotification *)notification {
self.generatePasswordButton.enabled = YES; self.generatePasswordButton.enabled = YES;
self.showCustomEntrySequenceAutotypeBuilderButton.enabled = YES;
self.showCustomAssociationSequenceAutotypeBuilderButton.enabled = YES;
self.activePopover = nil; self.activePopover = nil;
} }