From ece096e4e9cbe827ea607b422b653f00dbf4316f Mon Sep 17 00:00:00 2001 From: Brianna Birman Date: Thu, 18 Jun 2026 23:35:31 -0700 Subject: [PATCH] Update SmartStoreTestApp to use scene lifecycle --- .../SmartStore.xcodeproj/project.pbxproj | 53 ++----------------- .../SmartStoreTestApp/AppDelegate.h | 17 ------ .../SmartStoreTestApp/AppDelegate.m | 45 ---------------- .../Base.lproj/LaunchScreen.storyboard | 27 ---------- .../Base.lproj/Main.storyboard | 25 --------- libs/SmartStore/SmartStoreTestApp/Info.plist | 16 ++++-- .../SmartStoreTestApp/SmartStoreTestApp.swift | 38 +++++++++++++ .../SmartStoreTestApp/ViewController.h | 15 ------ .../SmartStoreTestApp/ViewController.m | 27 ---------- libs/SmartStore/SmartStoreTestApp/main.m | 16 ------ 10 files changed, 55 insertions(+), 224 deletions(-) delete mode 100644 libs/SmartStore/SmartStoreTestApp/AppDelegate.h delete mode 100644 libs/SmartStore/SmartStoreTestApp/AppDelegate.m delete mode 100644 libs/SmartStore/SmartStoreTestApp/Base.lproj/LaunchScreen.storyboard delete mode 100644 libs/SmartStore/SmartStoreTestApp/Base.lproj/Main.storyboard create mode 100644 libs/SmartStore/SmartStoreTestApp/SmartStoreTestApp.swift delete mode 100644 libs/SmartStore/SmartStoreTestApp/ViewController.h delete mode 100644 libs/SmartStore/SmartStoreTestApp/ViewController.m delete mode 100644 libs/SmartStore/SmartStoreTestApp/main.m diff --git a/libs/SmartStore/SmartStore.xcodeproj/project.pbxproj b/libs/SmartStore/SmartStore.xcodeproj/project.pbxproj index cb1d8a0fbb..f22a182bb9 100644 --- a/libs/SmartStore/SmartStore.xcodeproj/project.pbxproj +++ b/libs/SmartStore/SmartStore.xcodeproj/project.pbxproj @@ -21,12 +21,8 @@ /* End PBXAggregateTarget section */ /* Begin PBXBuildFile section */ - 4F06AF0D1C499EB600F70798 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 4F06AF0C1C499EB600F70798 /* main.m */; }; - 4F06AF101C499EB600F70798 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 4F06AF0F1C499EB600F70798 /* AppDelegate.m */; }; - 4F06AF131C499EB600F70798 /* ViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 4F06AF121C499EB600F70798 /* ViewController.m */; }; - 4F06AF161C499EB600F70798 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 4F06AF141C499EB600F70798 /* Main.storyboard */; }; + 695583B12FE4DB6C0042CF83 /* SmartStoreTestApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = 695583B02FE4DB5E0042CF83 /* SmartStoreTestApp.swift */; }; 4F06AF181C499EB600F70798 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 4F06AF171C499EB600F70798 /* Assets.xcassets */; }; - 4F06AF1B1C499EB600F70798 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 4F06AF191C499EB600F70798 /* LaunchScreen.storyboard */; }; 4F06AFF01C49D53D00F70798 /* SmartStore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = CE4CE2B91C0E4581009F6029 /* SmartStore.framework */; }; 4F06AFF11C49D53D00F70798 /* SmartStore.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = CE4CE2B91C0E4581009F6029 /* SmartStore.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 4F5BBB9D23592EBB00E6D619 /* SmartStore.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4F5BBB9C23592EBB00E6D619 /* SmartStore.swift */; }; @@ -217,14 +213,8 @@ /* Begin PBXFileReference section */ 4F06AF091C499EB600F70798 /* SmartStoreTestApp.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = SmartStoreTestApp.app; sourceTree = BUILT_PRODUCTS_DIR; }; - 4F06AF0C1C499EB600F70798 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; - 4F06AF0E1C499EB600F70798 /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; }; - 4F06AF0F1C499EB600F70798 /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = ""; }; - 4F06AF111C499EB600F70798 /* ViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ViewController.h; sourceTree = ""; }; - 4F06AF121C499EB600F70798 /* ViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ViewController.m; sourceTree = ""; }; - 4F06AF151C499EB600F70798 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + 695583B02FE4DB5E0042CF83 /* SmartStoreTestApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SmartStoreTestApp.swift; sourceTree = ""; }; 4F06AF171C499EB600F70798 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; - 4F06AF1A1C499EB600F70798 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; 4F06AF1C1C499EB600F70798 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 4F230BC31BFEAE430030EEFA /* SmartStore-Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "SmartStore-Prefix.pch"; path = "SmartStore/SmartStore-Prefix.pch"; sourceTree = SOURCE_ROOT; }; 4F5BBB9C23592EBB00E6D619 /* SmartStore.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SmartStore.swift; sourceTree = ""; }; @@ -357,30 +347,16 @@ 4F06AF0A1C499EB600F70798 /* SmartStoreTestApp */ = { isa = PBXGroup; children = ( + 695583B02FE4DB5E0042CF83 /* SmartStoreTestApp.swift */, B7282F441D8C713C00475F79 /* SmartStoreTestApp.entitlements */, - 4F06AF0E1C499EB600F70798 /* AppDelegate.h */, - 4F06AF0F1C499EB600F70798 /* AppDelegate.m */, - 4F06AF111C499EB600F70798 /* ViewController.h */, - 4F06AF121C499EB600F70798 /* ViewController.m */, - 4F06AF141C499EB600F70798 /* Main.storyboard */, 4F06AF171C499EB600F70798 /* Assets.xcassets */, - 4F06AF191C499EB600F70798 /* LaunchScreen.storyboard */, 4F06AF1C1C499EB600F70798 /* Info.plist */, - 4F06AF0B1C499EB600F70798 /* Supporting Files */, 4FAB7D781F8D888400226249 /* userstore.json */, 4FAB7D7D1F8D88C100226249 /* globalstore.json */, ); path = SmartStoreTestApp; sourceTree = ""; }; - 4F06AF0B1C499EB600F70798 /* Supporting Files */ = { - isa = PBXGroup; - children = ( - 4F06AF0C1C499EB600F70798 /* main.m */, - ); - name = "Supporting Files"; - sourceTree = ""; - }; 4F5BBB9323592E9600E6D619 /* Extensions */ = { isa = PBXGroup; children = ( @@ -676,6 +652,7 @@ TargetAttributes = { 4F06AF081C499EB600F70798 = { CreatedOnToolsVersion = 7.2; + LastSwiftMigration = 2630; ProvisioningStyle = Manual; SystemCapabilities = { com.apple.Keychain = { @@ -804,10 +781,8 @@ buildActionMask = 2147483647; files = ( 4FAB7D7E1F8D88C100226249 /* globalstore.json in Resources */, - 4F06AF1B1C499EB600F70798 /* LaunchScreen.storyboard in Resources */, 4F06AF181C499EB600F70798 /* Assets.xcassets in Resources */, 4FAB7D791F8D888400226249 /* userstore.json in Resources */, - 4F06AF161C499EB600F70798 /* Main.storyboard in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -878,9 +853,7 @@ isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( - 4F06AF131C499EB600F70798 /* ViewController.m in Sources */, - 4F06AF101C499EB600F70798 /* AppDelegate.m in Sources */, - 4F06AF0D1C499EB600F70798 /* main.m in Sources */, + 695583B12FE4DB6C0042CF83 /* SmartStoreTestApp.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -956,22 +929,6 @@ /* End PBXTargetDependency section */ /* Begin PBXVariantGroup section */ - 4F06AF141C499EB600F70798 /* Main.storyboard */ = { - isa = PBXVariantGroup; - children = ( - 4F06AF151C499EB600F70798 /* Base */, - ); - name = Main.storyboard; - sourceTree = ""; - }; - 4F06AF191C499EB600F70798 /* LaunchScreen.storyboard */ = { - isa = PBXVariantGroup; - children = ( - 4F06AF1A1C499EB600F70798 /* Base */, - ); - name = LaunchScreen.storyboard; - sourceTree = ""; - }; CEAAAE61195911E600CBBFE9 /* InfoPlist.strings */ = { isa = PBXVariantGroup; children = ( diff --git a/libs/SmartStore/SmartStoreTestApp/AppDelegate.h b/libs/SmartStore/SmartStoreTestApp/AppDelegate.h deleted file mode 100644 index e04afc3ed6..0000000000 --- a/libs/SmartStore/SmartStoreTestApp/AppDelegate.h +++ /dev/null @@ -1,17 +0,0 @@ -// -// AppDelegate.h -// SmartStoreTestApp -// -// Created by Wolfgang Mathurin on 1/15/16. -// Copyright © 2016-present Salesforce Inc. All rights reserved. -// - -#import - -@interface AppDelegate : UIResponder - -@property (strong, nonatomic) UIWindow *window; - - -@end - diff --git a/libs/SmartStore/SmartStoreTestApp/AppDelegate.m b/libs/SmartStore/SmartStoreTestApp/AppDelegate.m deleted file mode 100644 index a188887f72..0000000000 --- a/libs/SmartStore/SmartStoreTestApp/AppDelegate.m +++ /dev/null @@ -1,45 +0,0 @@ -// -// AppDelegate.m -// SmartStoreTestApp -// -// Created by Wolfgang Mathurin on 1/15/16. -// Copyright © 2016-present Salesforce Inc. All rights reserved. -// - -#import "AppDelegate.h" - -@interface AppDelegate () - -@end - -@implementation AppDelegate - - -- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { - // Override point for customization after application launch. - return YES; -} - -- (void)applicationWillResignActive:(UIApplication *)application { - // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. - // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game. -} - -- (void)applicationDidEnterBackground:(UIApplication *)application { - // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. - // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. -} - -- (void)applicationWillEnterForeground:(UIApplication *)application { - // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background. -} - -- (void)applicationDidBecomeActive:(UIApplication *)application { - // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. -} - -- (void)applicationWillTerminate:(UIApplication *)application { - // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. -} - -@end diff --git a/libs/SmartStore/SmartStoreTestApp/Base.lproj/LaunchScreen.storyboard b/libs/SmartStore/SmartStoreTestApp/Base.lproj/LaunchScreen.storyboard deleted file mode 100644 index 2e721e1833..0000000000 --- a/libs/SmartStore/SmartStoreTestApp/Base.lproj/LaunchScreen.storyboard +++ /dev/null @@ -1,27 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/libs/SmartStore/SmartStoreTestApp/Base.lproj/Main.storyboard b/libs/SmartStore/SmartStoreTestApp/Base.lproj/Main.storyboard deleted file mode 100644 index f56d2f3bb5..0000000000 --- a/libs/SmartStore/SmartStoreTestApp/Base.lproj/Main.storyboard +++ /dev/null @@ -1,25 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/libs/SmartStore/SmartStoreTestApp/Info.plist b/libs/SmartStore/SmartStoreTestApp/Info.plist index 40c6215d90..2ebb26ef10 100644 --- a/libs/SmartStore/SmartStoreTestApp/Info.plist +++ b/libs/SmartStore/SmartStoreTestApp/Info.plist @@ -22,10 +22,18 @@ 1 LSRequiresIPhoneOS - UILaunchStoryboardName - LaunchScreen - UIMainStoryboardFile - Main + UIApplicationSceneManifest + + UIApplicationSupportsMultipleScenes + + UISceneConfigurations + + + UILaunchScreen + + UILaunchScreen + + UIRequiredDeviceCapabilities armv7 diff --git a/libs/SmartStore/SmartStoreTestApp/SmartStoreTestApp.swift b/libs/SmartStore/SmartStoreTestApp/SmartStoreTestApp.swift new file mode 100644 index 0000000000..67747ce8dd --- /dev/null +++ b/libs/SmartStore/SmartStoreTestApp/SmartStoreTestApp.swift @@ -0,0 +1,38 @@ +// +// SmartStoreTestApp.swift +// SmartStore +// +// Created by Brianna Birman on 6/18/26. +// Copyright (c) 2026-present, salesforce.com, inc. All rights reserved. +// +// Redistribution and use of this software in source and binary forms, with or without modification, +// are permitted provided that the following conditions are met: +// * Redistributions of source code must retain the above copyright notice, this list of conditions +// and the following disclaimer. +// * Redistributions in binary form must reproduce the above copyright notice, this list of +// conditions and the following disclaimer in the documentation and/or other materials provided +// with the distribution. +// * Neither the name of salesforce.com, inc. nor the names of its contributors may be used to +// endorse or promote products derived from this software without specific prior written +// permission of salesforce.com, inc. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR +// IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +// FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR +// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY +// WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +import SwiftUI + +@main +struct SmartStoreTestApp: App { + var body: some Scene { + WindowGroup { + Text("SmartStore Test App") + .padding() + } + } +} diff --git a/libs/SmartStore/SmartStoreTestApp/ViewController.h b/libs/SmartStore/SmartStoreTestApp/ViewController.h deleted file mode 100644 index 3a9de4c7f4..0000000000 --- a/libs/SmartStore/SmartStoreTestApp/ViewController.h +++ /dev/null @@ -1,15 +0,0 @@ -// -// ViewController.h -// SmartStoreTestApp -// -// Created by Wolfgang Mathurin on 1/15/16. -// Copyright © 2016 Salesforce Inc. All rights reserved. -// - -#import - -@interface ViewController : UIViewController - - -@end - diff --git a/libs/SmartStore/SmartStoreTestApp/ViewController.m b/libs/SmartStore/SmartStoreTestApp/ViewController.m deleted file mode 100644 index 6d25ed2590..0000000000 --- a/libs/SmartStore/SmartStoreTestApp/ViewController.m +++ /dev/null @@ -1,27 +0,0 @@ -// -// ViewController.m -// SmartStoreTestApp -// -// Created by Wolfgang Mathurin on 1/15/16. -// Copyright © 2016 Salesforce Inc. All rights reserved. -// - -#import "ViewController.h" - -@interface ViewController () - -@end - -@implementation ViewController - -- (void)viewDidLoad { - [super viewDidLoad]; - // Do any additional setup after loading the view, typically from a nib. -} - -- (void)didReceiveMemoryWarning { - [super didReceiveMemoryWarning]; - // Dispose of any resources that can be recreated. -} - -@end diff --git a/libs/SmartStore/SmartStoreTestApp/main.m b/libs/SmartStore/SmartStoreTestApp/main.m deleted file mode 100644 index 1838281d31..0000000000 --- a/libs/SmartStore/SmartStoreTestApp/main.m +++ /dev/null @@ -1,16 +0,0 @@ -// -// main.m -// SmartStoreTestApp -// -// Created by Wolfgang Mathurin on 1/15/16. -// Copyright © 2016 Salesforce Inc. All rights reserved. -// - -#import -#import "AppDelegate.h" - -int main(int argc, char * argv[]) { - @autoreleasepool { - return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); - } -}