diff --git a/Pareto Security.xcodeproj/project.pbxproj b/Pareto Security.xcodeproj/project.pbxproj index 8ca453e..d1a19e4 100644 --- a/Pareto Security.xcodeproj/project.pbxproj +++ b/Pareto Security.xcodeproj/project.pbxproj @@ -1286,7 +1286,7 @@ COMBINE_HIDPI_IMAGES = YES; DEAD_CODE_STRIPPING = YES; DEVELOPMENT_ASSET_PATHS = "\"Pareto/Preview Content\""; - DEVELOPMENT_TEAM = JND55328G8; + DEVELOPMENT_TEAM = PM784W7B8X; ENABLE_HARDENED_RUNTIME = YES; ENABLE_PREVIEWS = YES; GCC_PREPROCESSOR_DEFINITIONS = ( @@ -1327,7 +1327,7 @@ COMBINE_HIDPI_IMAGES = YES; DEAD_CODE_STRIPPING = YES; DEVELOPMENT_ASSET_PATHS = "\"Pareto/Preview Content\""; - DEVELOPMENT_TEAM = JND55328G8; + DEVELOPMENT_TEAM = PM784W7B8X; ENABLE_HARDENED_RUNTIME = YES; ENABLE_PREVIEWS = YES; GCC_PREPROCESSOR_DEFINITIONS = "SETAPP_ENABLED=1"; @@ -1598,12 +1598,11 @@ CLANG_USE_OPTIMIZATION_PROFILE = NO; CODE_SIGN_ENTITLEMENTS = Pareto/Pareto.entitlements; CODE_SIGN_IDENTITY = "Apple Development"; - "CODE_SIGN_IDENTITY[sdk=macosx*]" = "Apple Development"; CODE_SIGN_STYLE = Automatic; COMBINE_HIDPI_IMAGES = YES; DEAD_CODE_STRIPPING = YES; DEVELOPMENT_ASSET_PATHS = "\"Pareto/Preview Content\""; - DEVELOPMENT_TEAM = JND55328G8; + DEVELOPMENT_TEAM = PM784W7B8X; ENABLE_HARDENED_RUNTIME = YES; ENABLE_PREVIEWS = YES; GCC_PREPROCESSOR_DEFINITIONS = "SETAPP_ENABLED=0"; @@ -1636,7 +1635,7 @@ COMBINE_HIDPI_IMAGES = YES; DEAD_CODE_STRIPPING = YES; DEVELOPMENT_ASSET_PATHS = "\"Pareto/Preview Content\""; - DEVELOPMENT_TEAM = JND55328G8; + DEVELOPMENT_TEAM = PM784W7B8X; ENABLE_HARDENED_RUNTIME = YES; ENABLE_PREVIEWS = YES; GCC_PREPROCESSOR_DEFINITIONS = "SETAPP_ENABLED=0"; diff --git a/Pareto/AppHandlers.swift b/Pareto/AppHandlers.swift index 820f3e1..3ddd1e5 100644 --- a/Pareto/AppHandlers.swift +++ b/Pareto/AppHandlers.swift @@ -330,30 +330,20 @@ class AppHandlers: NSObject, NetworkHandlerObserver { } @objc func showSettingsFallback() { - DispatchQueue.main.async { [self] in - if welcomeWindow == nil { - let settings = SettingsView(selected: SettingsView.Tabs.general) - // Create the preferences window and set content - welcomeWindow = NSWindow( - contentRect: NSRect(x: 0, y: 0, width: 420, height: 280), - styleMask: [.closable, .titled], - backing: .buffered, - defer: false - ) - - welcomeWindow!.titlebarAppearsTransparent = false - welcomeWindow!.center() - welcomeWindow!.setFrameAutosaveName("settingsView") - welcomeWindow!.isReleasedWhenClosed = false - welcomeWindow?.level = .floating - - let hosting = NSHostingView(rootView: settings) - hosting.autoresizingMask = [NSView.AutoresizingMask.width, NSView.AutoresizingMask.height] - welcomeWindow!.contentView = hosting - welcomeWindow!.contentView?.translatesAutoresizingMaskIntoConstraints = true + DispatchQueue.main.async { + let hostingController = NSHostingController(rootView: SettingsView(selected: SettingsView.Tabs.general)) + hostingController.preferredContentSize = NSSize(width: 640, height: 280) + if #available(macOS 13.0, *) { + hostingController.sizingOptions = .preferredContentSize } - - welcomeWindow!.makeKeyAndOrderFront(nil) + let window = NSWindow(contentViewController: hostingController) + window.title = "Preferences" + window.center() + window.titlebarAppearsTransparent = true + window.setContentSize(NSSize(width: 640, height: 280)) + + let controller = NSWindowController(window: window) + controller.showWindow(nil) } } diff --git a/Pareto/Info.plist b/Pareto/Info.plist index 0dd6383..0b1fcef 100644 --- a/Pareto/Info.plist +++ b/Pareto/Info.plist @@ -26,7 +26,7 @@ CFBundleVersion - 5384 + 5403 LSApplicationCategoryType public.app-category.utilities LSMinimumSystemVersion diff --git a/Pareto/Views/Settings/GeneralSettingsView.swift b/Pareto/Views/Settings/GeneralSettingsView.swift index 9e19a9c..5793248 100644 --- a/Pareto/Views/Settings/GeneralSettingsView.swift +++ b/Pareto/Views/Settings/GeneralSettingsView.swift @@ -103,7 +103,7 @@ struct GeneralSettingsView: View { #endif } } - }.frame(maxWidth: 380, minHeight: 210).padding(25) + }.frame(minWidth: 420, minHeight: 210).padding(25) } func selectFolder() { diff --git a/exportOptions.plist b/exportOptions.plist index 5f88b03..a8f79a4 100644 --- a/exportOptions.plist +++ b/exportOptions.plist @@ -13,7 +13,7 @@ onDemandResourcesAssetPacksBaseURL 0 teamID - JND55328G8 + PM784W7B8X uploadBitcode uploadSymbols