Revision: 15298
http://sourceforge.net/p/skim-app/code/15298
Author: hofman
Date: 2025-05-26 15:58:46 +0000 (Mon, 26 May 2025)
Log Message:
-----------
wee already set the window frame implicitly in full screen
Modified Paths:
--------------
trunk/SKMainWindowController.m
Modified: trunk/SKMainWindowController.m
===================================================================
--- trunk/SKMainWindowController.m 2025-05-26 15:39:33 UTC (rev 15297)
+++ trunk/SKMainWindowController.m 2025-05-26 15:58:46 UTC (rev 15298)
@@ -562,9 +562,7 @@
NSString *rectString = [setup objectForKey:MAINWINDOWFRAME_KEY];
if (rectString) {
- if ([self interactionMode] == SKFullScreenMode)
- [savedNormalSetup setObject:rectString
forKey:MAINWINDOWFRAME_KEY];
- else
+ if ([self interactionMode] != SKFullScreenMode)
[mainWindow setFrame:NSRectFromString(rectString)
display:[mainWindow isVisible]];
}
@@ -1782,6 +1780,7 @@
NSView *contentView = [findBar superview];
NSLayoutConstraint *barTopConstraint = [findController topConstraint];
CGFloat barHeight = [findController height];
+ NSWindow *window = [self window];
if (mwcFlags.fullSizeContent)
findBarTopConstraint = nil;
@@ -1788,8 +1787,8 @@
else
findBarTopConstraint = [[pdfSplitView topAnchor]
constraintEqualToAnchor:[contentView topAnchor]];
- if ([[mainWindow firstResponder] isDescendantOf:findBar])
- [mainWindow makeFirstResponder:pdfView];
+ if ([[window firstResponder] isDescendantOf:findBar])
+ [window makeFirstResponder:pdfView];
if (mwcFlags.fullSizeContent) {
[[pdfView scrollView] setAutomaticallyAdjustsContentInsets:YES];
@@ -1808,7 +1807,7 @@
completionHandler:^{
[findBar removeFromSuperview];
[findBarTopConstraint setActive:YES];
- [mainWindow recalculateKeyViewLoop];
+ [window recalculateKeyViewLoop];
mwcFlags.isAnimatingFindBar = NO;
}];
@@ -1816,7 +1815,7 @@
[findBar removeFromSuperview];
[findBarTopConstraint setActive:YES];
[contentView layoutSubtreeIfNeeded];
- [mainWindow recalculateKeyViewLoop];
+ [window recalculateKeyViewLoop];
}
}
@@ -1872,7 +1871,7 @@
[[barTopConstraint animator] setConstant:0.0];
}
completionHandler:^{
- [mainWindow recalculateKeyViewLoop];
+ [[self window] recalculateKeyViewLoop];
[findField selectText:nil];
mwcFlags.isAnimatingFindBar = NO;
@@ -1879,7 +1878,7 @@
}];
} else {
[contentView layoutSubtreeIfNeeded];
- [mainWindow recalculateKeyViewLoop];
+ [[self window] recalculateKeyViewLoop];
[findField selectText:nil];
}
}
@@ -2636,7 +2635,7 @@
} else if (context == &SKMainWindowContentLayoutObservationContext) {
- CGFloat titleHeight = NSHeight([mainWindow frame]) -
NSHeight([mainWindow contentLayoutRect]);
+ CGFloat titleHeight = NSHeight([object frame]) - NSHeight([object
contentLayoutRect]);
if (fabs(titleHeight - titleBarHeight) > 0.0) {
titleBarHeight = titleHeight;
[rightSideController setTopInset:titleBarHeight];
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit