From a1f71a8149d851302b7b4b4f792b5218fd900929 Mon Sep 17 00:00:00 2001 From: Huge_Black Date: Sat, 21 Mar 2026 11:58:20 +0800 Subject: [PATCH 1/2] Fix widget not working --- AltStore.xcodeproj/project.pbxproj | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/AltStore.xcodeproj/project.pbxproj b/AltStore.xcodeproj/project.pbxproj index 78f8fc38..4e8a13ec 100644 --- a/AltStore.xcodeproj/project.pbxproj +++ b/AltStore.xcodeproj/project.pbxproj @@ -2937,6 +2937,13 @@ /* End PBXFileSystemSynchronizedBuildFileExceptionSet section */ /* Begin PBXFileSystemSynchronizedGroupBuildPhaseMembershipExceptionSet section */ + 173100732F6E4550001FBB19 /* PBXFileSystemSynchronizedGroupBuildPhaseMembershipExceptionSet */ = { + isa = PBXFileSystemSynchronizedGroupBuildPhaseMembershipExceptionSet; + buildPhase = BFD247682284B9A500981D42 /* Resources */; + membershipExceptions = ( + Intents/ViewApp.intentdefinition, + ); + }; A8EEC8CC2F4B146B00F2436D /* PBXFileSystemSynchronizedGroupBuildPhaseMembershipExceptionSet */ = { isa = PBXFileSystemSynchronizedGroupBuildPhaseMembershipExceptionSet; buildPhase = BFD247682284B9A500981D42 /* Resources */; @@ -2959,7 +2966,7 @@ A8A5AFE32F4C343200572B4A /* .github */ = {isa = PBXFileSystemSynchronizedRootGroup; explicitFileTypes = {}; explicitFolders = (); path = .github; sourceTree = ""; }; A8A5AFEA2F4C343200572B4A /* keys */ = {isa = PBXFileSystemSynchronizedRootGroup; explicitFileTypes = {}; explicitFolders = (); path = keys; sourceTree = ""; }; A8A5C85B2F4C68BF00572B4A /* libfragmentzip */ = {isa = PBXFileSystemSynchronizedRootGroup; explicitFileTypes = {}; explicitFolders = (); path = libfragmentzip; sourceTree = ""; }; - A8EEC0502F4AF7FB00F2436D /* AltStoreCore */ = {isa = PBXFileSystemSynchronizedRootGroup; exceptions = (A8EEC0BF2F4AF7FB00F2436D /* PBXFileSystemSynchronizedBuildFileExceptionSet */, ); explicitFileTypes = {}; explicitFolders = (); path = AltStoreCore; sourceTree = ""; }; + A8EEC0502F4AF7FB00F2436D /* AltStoreCore */ = {isa = PBXFileSystemSynchronizedRootGroup; exceptions = (173100732F6E4550001FBB19 /* PBXFileSystemSynchronizedGroupBuildPhaseMembershipExceptionSet */, A8EEC0BF2F4AF7FB00F2436D /* PBXFileSystemSynchronizedBuildFileExceptionSet */, ); explicitFileTypes = {}; explicitFolders = (); path = AltStoreCore; sourceTree = ""; }; A8EEC3482F4B0D8600F2436D /* Shared */ = {isa = PBXFileSystemSynchronizedRootGroup; exceptions = (A8EEC36A2F4B0D8700F2436D /* PBXFileSystemSynchronizedBuildFileExceptionSet */, A8EEC36C2F4B0D8700F2436D /* PBXFileSystemSynchronizedBuildFileExceptionSet */, A8EEC36B2F4B0D8700F2436D /* PBXFileSystemSynchronizedBuildFileExceptionSet */, ); explicitFileTypes = {}; explicitFolders = (); path = Shared; sourceTree = ""; }; A8EEC3B92F4B0EFC00F2436D /* AltWidget */ = {isa = PBXFileSystemSynchronizedRootGroup; exceptions = (A8EEC3CA2F4B0EFC00F2436D /* PBXFileSystemSynchronizedBuildFileExceptionSet */, ); explicitFileTypes = {}; explicitFolders = (); path = AltWidget; sourceTree = ""; }; A8EEC3D92F4B0FC800F2436D /* AltBackup */ = {isa = PBXFileSystemSynchronizedRootGroup; exceptions = (A8EEC3E22F4B0FC800F2436D /* PBXFileSystemSynchronizedBuildFileExceptionSet */, ); explicitFileTypes = {}; explicitFolders = (); path = AltBackup; sourceTree = ""; }; From 01e73328f8bf757879b5b496c442ff8ae3dcfc83 Mon Sep 17 00:00:00 2001 From: Huge_Black Date: Sat, 21 Mar 2026 12:01:16 +0800 Subject: [PATCH 2/2] Only run turn off data shortcut when minimuxer is not ready and below 26.4 --- AltStore/Operations/InstallAppOperation.swift | 11 +++++---- AltStore/Operations/OperationContexts.swift | 2 ++ AltStore/Operations/SendAppOperation.swift | 23 +++++++++++++++---- 3 files changed, 28 insertions(+), 8 deletions(-) diff --git a/AltStore/Operations/InstallAppOperation.swift b/AltStore/Operations/InstallAppOperation.swift index 9e94206c..1e68be03 100644 --- a/AltStore/Operations/InstallAppOperation.swift +++ b/AltStore/Operations/InstallAppOperation.swift @@ -214,9 +214,10 @@ final class InstallAppOperation: ResultOperation alert.addAction(UIAlertAction(title: NSLocalizedString("Continue", comment: ""), style: .default, handler: { _ in print("Going home") // Cell Shortcut - UIApplication.shared.open(shortcutURLonDelay, options: [:]) { _ in - print("Cell OFF Shortcut finished execution.")} - + if self.context.shouldTurnOffData { + UIApplication.shared.open(shortcutURLonDelay, options: [:]) { _ in + print("Cell OFF Shortcut finished execution.")} + } UIApplication.shared.perform(#selector(NSXPCConnection.suspend)) })) @@ -234,7 +235,9 @@ final class InstallAppOperation: ResultOperation } } // Cell Shortcut - UIApplication.shared.open(shortcutURLonDelay, options: [:]) { _ in print("Cell OFF Shortcut finished execution.")} + if self.context.shouldTurnOffData { + UIApplication.shared.open(shortcutURLonDelay, options: [:]) { _ in print("Cell OFF Shortcut finished execution.")} + } UIApplication.shared.perform(#selector(NSXPCConnection.suspend)) } } diff --git a/AltStore/Operations/OperationContexts.swift b/AltStore/Operations/OperationContexts.swift index a1327c66..fdbc87bc 100644 --- a/AltStore/Operations/OperationContexts.swift +++ b/AltStore/Operations/OperationContexts.swift @@ -123,6 +123,8 @@ class InstallAppOperationContext: AppOperationContext var alternateIconURL: URL? + var shouldTurnOffData: Bool = false + // Non-nil when installing from a source. @AsyncManaged var appVersion: AppVersion? diff --git a/AltStore/Operations/SendAppOperation.swift b/AltStore/Operations/SendAppOperation.swift index 9a92930d..4d5849dd 100644 --- a/AltStore/Operations/SendAppOperation.swift +++ b/AltStore/Operations/SendAppOperation.swift @@ -42,10 +42,25 @@ final class SendAppOperation: ResultOperation<()> let fileURL = InstalledApp.refreshedIPAURL(for: app) print("AFC App `fileURL`: \(fileURL.absoluteString)") - // Wait for Shortcut to Finish Before Proceeding - UIApplication.shared.open(shortcutURLoff, options: [:]) { _ in - print("Shortcut finished execution. Proceeding with file transfer.") - + // only when minimuxer is not ready and below 26.4 should we turn off data + if #available(iOS 26.4, *) { + context.shouldTurnOffData = false + } else if !isMinimuxerReady { + context.shouldTurnOffData = true + } else { + context.shouldTurnOffData = false + } + + if context.shouldTurnOffData { + // Wait for Shortcut to Finish Before Proceeding + UIApplication.shared.open(shortcutURLoff, options: [:]) { _ in + print("Shortcut finished execution. Proceeding with file transfer.") + + DispatchQueue.global().async { + self.processFile(at: fileURL, for: app.bundleIdentifier) + } + } + } else { DispatchQueue.global().async { self.processFile(at: fileURL, for: app.bundleIdentifier) }