From a7a2eabf78ca81a99c0b1cc3db2e0c815cdc5901 Mon Sep 17 00:00:00 2001 From: Brent Simmons Date: Sun, 21 Jan 2018 13:11:09 -0800 Subject: [PATCH] Remove unneeded window layout call. Change placement of initial inspector origin. --- Evergreen/Inspector/InspectorWindowController.swift | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/Evergreen/Inspector/InspectorWindowController.swift b/Evergreen/Inspector/InspectorWindowController.swift index 723fc4af7..69f1bca91 100644 --- a/Evergreen/Inspector/InspectorWindowController.swift +++ b/Evergreen/Inspector/InspectorWindowController.swift @@ -65,7 +65,7 @@ final class InspectorWindowController: NSWindowController { inspectors = [feedInspector, folderInspector, builtinSmartFeedInspector, nothingInspector] currentInspector = nothingInspector - window?.flippedOrigin = NSPoint(x: 128, y: 128) + window?.flippedOrigin = NSPoint(x: 256, y: 256) } func inspector(for objects: [Any]?) -> InspectorViewController { @@ -100,9 +100,8 @@ private extension InspectorWindowController { let flippedOrigin = window.flippedOrigin window.contentViewController = inspector - window.layoutIfNeeded() - if let origin = flippedOrigin { - window.setFlippedOriginAdjustingForScreen(origin) + if let flippedOrigin = flippedOrigin { + window.setFlippedOriginAdjustingForScreen(flippedOrigin) } } }