Fixed issue resulting in opening the fix autotype window instead of a new document window (fixes #668)

This also fixes an isse resulting to save request not being shown when closing the document window but when closing the fix-autotype window.
This commit is contained in:
michael starke
2017-11-21 10:43:06 +01:00
parent 68a4864051
commit d051421f14
3 changed files with 5 additions and 5 deletions

View File

@@ -51,10 +51,10 @@
<window title="Window" allowsToolTipsWhenApplicationIsInactive="NO" autorecalculatesKeyViewLoop="NO" oneShot="NO" releasedWhenClosed="NO" visibleAtLaunch="NO" animationBehavior="default" id="1">
<windowStyleMask key="styleMask" titled="YES" closable="YES" miniaturizable="YES"/>
<windowPositionMask key="initialPositionMask" leftStrut="YES" rightStrut="YES" topStrut="YES" bottomStrut="YES"/>
<rect key="contentRect" x="196" y="240" width="500" height="406"/>
<rect key="contentRect" x="196" y="240" width="500" height="360"/>
<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="500" height="360"/>
<rect key="frame" x="0.0" y="0.0" width="500" height="336"/>
<autoresizingMask key="autoresizingMask"/>
<subviews>
<button verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="288">
@@ -84,7 +84,7 @@ Gw
</connections>
</button>
<tabView translatesAutoresizingMaskIntoConstraints="NO" id="357">
<rect key="frame" x="13" y="41" width="474" height="313"/>
<rect key="frame" x="13" y="41" width="474" height="289"/>
<font key="font" metaFont="system"/>
<tabViewItems>
<tabViewItem label="General" identifier="1" id="358">

View File

@@ -293,7 +293,7 @@ typedef void (^MPPasswordChangedBlock)(BOOL didChangePassword);
if(!self.fixAutotypeWindowController) {
self.fixAutotypeWindowController = [[MPFixAutotypeWindowController alloc] init];
}
[self.document addWindowController:self.fixAutotypeWindowController];
self.fixAutotypeWindowController.document = self.document;
[self.fixAutotypeWindowController.window makeKeyAndOrderFront:sender];
}

View File

@@ -68,7 +68,7 @@ NSString *const kMPIconCell = @"IconCell";
- (void)dealloc {
[[NSNotificationCenter defaultCenter] removeObserver:self];
[self.window orderOut:self];
[self.window performClose:self];
}