Skip to content

Commit 8de44ae

Browse files
authored
Merge branch 'main' into 3.1.3-1
2 parents ebf70d8 + faaf0fe commit 8de44ae

19 files changed

Lines changed: 1638 additions & 563 deletions

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
<a href="https://stikstore.app/altdirect/?url=https://stikdebug.xyz/index.json" target="_blank">
4242
<img src="https://github.com/stikstore/altdirect/blob/main/assets/png/AltSource_Blue.png" alt="Add AltSource" width="200">
4343
</a>
44-
<a href="https://github.com/StephenDev0/StikDebug/releases/download/3.1.2/StikDebug-3.1.2.ipa" target="_blank">
44+
<a href="https://github.com/StephenDev0/StikDebug/releases/download/3.1.3/StikDebug-3.1.3.ipa" target="_blank">
4545
<img src="https://github.com/stikstore/altdirect/blob/main/assets/png/Download_Blue.png" alt="Download .ipa" width="200">
4646
</a>
4747
</div>

StikDebug.xcodeproj/project.pbxproj

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -493,7 +493,7 @@
493493
"$(PROJECT_DIR)/StikJIT/idevice",
494494
);
495495
MACOSX_DEPLOYMENT_TARGET = 15.1;
496-
MARKETING_VERSION = 3.1.2;
496+
MARKETING_VERSION = 3.1.3;
497497
PRODUCT_BUNDLE_IDENTIFIER = com.stik.stikdebug;
498498
PRODUCT_NAME = "$(TARGET_NAME)";
499499
PROVISIONING_PROFILE_SPECIFIER = "";
@@ -555,7 +555,7 @@
555555
"$(PROJECT_DIR)/StikJIT/idevice",
556556
);
557557
MACOSX_DEPLOYMENT_TARGET = 15.1;
558-
MARKETING_VERSION = 3.1.2;
558+
MARKETING_VERSION = 3.1.3;
559559
PRODUCT_BUNDLE_IDENTIFIER = com.stik.stikdebug;
560560
PRODUCT_NAME = "$(TARGET_NAME)";
561561
PROVISIONING_PROFILE_SPECIFIER = "";
@@ -579,14 +579,23 @@
579579
CURRENT_PROJECT_VERSION = 1;
580580
DEVELOPMENT_TEAM = SZ977XLF24;
581581
GENERATE_INFOPLIST_FILE = YES;
582+
HEADER_SEARCH_PATHS = (
583+
"$(inherited)",
584+
"$(PROJECT_DIR)/StikJIT/idevice",
585+
);
582586
IPHONEOS_DEPLOYMENT_TARGET = 18.2;
587+
LIBRARY_SEARCH_PATHS = (
588+
"$(inherited)",
589+
"$(PROJECT_DIR)/StikJIT/idevice",
590+
);
583591
MACOSX_DEPLOYMENT_TARGET = 15.1;
584592
MARKETING_VERSION = 1.0;
585593
PRODUCT_BUNDLE_IDENTIFIER = com.stik.StikJITTests;
586594
PRODUCT_NAME = "$(TARGET_NAME)";
587595
SDKROOT = auto;
588596
SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx xros xrsimulator";
589597
SWIFT_EMIT_LOC_STRINGS = NO;
598+
SWIFT_INCLUDE_PATHS = "$(inherited) $(PROJECT_DIR)/StikJIT/idevice";
590599
SWIFT_VERSION = 5.0;
591600
TARGETED_DEVICE_FAMILY = "1,2,7";
592601
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/StikDebug.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/StikDebug";
@@ -602,14 +611,23 @@
602611
CURRENT_PROJECT_VERSION = 1;
603612
DEVELOPMENT_TEAM = SZ977XLF24;
604613
GENERATE_INFOPLIST_FILE = YES;
614+
HEADER_SEARCH_PATHS = (
615+
"$(inherited)",
616+
"$(PROJECT_DIR)/StikJIT/idevice",
617+
);
605618
IPHONEOS_DEPLOYMENT_TARGET = 18.2;
619+
LIBRARY_SEARCH_PATHS = (
620+
"$(inherited)",
621+
"$(PROJECT_DIR)/StikJIT/idevice",
622+
);
606623
MACOSX_DEPLOYMENT_TARGET = 15.1;
607624
MARKETING_VERSION = 1.0;
608625
PRODUCT_BUNDLE_IDENTIFIER = com.stik.StikJITTests;
609626
PRODUCT_NAME = "$(TARGET_NAME)";
610627
SDKROOT = auto;
611628
SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx xros xrsimulator";
612629
SWIFT_EMIT_LOC_STRINGS = NO;
630+
SWIFT_INCLUDE_PATHS = "$(inherited) $(PROJECT_DIR)/StikJIT/idevice";
613631
SWIFT_VERSION = 5.0;
614632
TARGETED_DEVICE_FAMILY = "1,2,7";
615633
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/StikDebug.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/StikDebug";

StikJIT/Info.plist

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
<string>com.stik.StikJIT.enableJIT</string>
1212
<key>CFBundleURLSchemes</key>
1313
<array>
14+
<string>stikdebug</string>
1415
<string>stikjit</string>
1516
</array>
1617
</dict>

StikJIT/Utilities/AppFeature.swift

Lines changed: 138 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,138 @@
1+
//
2+
// AppFeature.swift
3+
// StikJIT
4+
//
5+
6+
import SwiftUI
7+
8+
enum AppFeature: String, CaseIterable, Identifiable {
9+
case home
10+
case scripts
11+
case tools
12+
case news
13+
case console
14+
case deviceInfo = "deviceinfo"
15+
case profiles
16+
case processes
17+
case location
18+
case settings
19+
20+
var id: String {
21+
rawValue
22+
}
23+
24+
var title: String {
25+
switch self {
26+
case .home:
27+
return "Apps"
28+
case .scripts:
29+
return "Scripts"
30+
case .tools:
31+
return "Tools"
32+
case .news:
33+
return "News"
34+
case .console:
35+
return "Console"
36+
case .deviceInfo:
37+
return "Device Info"
38+
case .profiles:
39+
return "App Expiry"
40+
case .processes:
41+
return "Processes"
42+
case .location:
43+
return "Location"
44+
case .settings:
45+
return "Settings"
46+
}
47+
}
48+
49+
var detail: String {
50+
switch self {
51+
case .home:
52+
return "Manage installed apps"
53+
case .scripts:
54+
return "Manage and run JS scripts"
55+
case .tools:
56+
return "Access additional tools"
57+
case .news:
58+
return "Latest StikDebug updates"
59+
case .console:
60+
return "Live device logs"
61+
case .deviceInfo:
62+
return "View detailed device metadata"
63+
case .profiles:
64+
return "Check app expiration dates"
65+
case .processes:
66+
return "Inspect running apps"
67+
case .location:
68+
return "Simulate GPS location"
69+
case .settings:
70+
return "Configure StikDebug"
71+
}
72+
}
73+
74+
var toolTitle: String {
75+
switch self {
76+
case .location:
77+
return "Location Simulation"
78+
default:
79+
return title
80+
}
81+
}
82+
83+
var systemImage: String {
84+
switch self {
85+
case .home:
86+
return "square.grid.2x2"
87+
case .scripts:
88+
return "scroll"
89+
case .tools:
90+
return "wrench.and.screwdriver"
91+
case .news:
92+
return "newspaper"
93+
case .console:
94+
return "terminal"
95+
case .deviceInfo:
96+
return "iphone.and.arrow.forward"
97+
case .profiles:
98+
return "calendar.badge.clock"
99+
case .processes:
100+
return "rectangle.stack.person.crop"
101+
case .location:
102+
return "location"
103+
case .settings:
104+
return "gearshape.fill"
105+
}
106+
}
107+
108+
@ViewBuilder
109+
var destination: some View {
110+
switch self {
111+
case .home:
112+
HomeView()
113+
case .scripts:
114+
ScriptListView()
115+
case .tools:
116+
ToolsView()
117+
case .news:
118+
NewsView()
119+
case .console:
120+
ConsoleLogsView()
121+
case .deviceInfo:
122+
DeviceInfoView()
123+
case .profiles:
124+
ProfileView()
125+
case .processes:
126+
ProcessInspectorView()
127+
case .location:
128+
LocationSimulationView()
129+
case .settings:
130+
SettingsView()
131+
}
132+
}
133+
}
134+
135+
extension AppFeature {
136+
static let mainTabs: [AppFeature] = [.home, .tools, .news, .settings]
137+
static let toolList: [AppFeature] = [.scripts, .console, .deviceInfo, .profiles, .processes, .location]
138+
}
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
//
2+
// AutoScriptAssignments.swift
3+
// StikJIT
4+
//
5+
6+
private struct AutoScriptAssignment {
7+
let appNames: Set<String>
8+
let resource: ScriptResource
9+
}
10+
11+
extension ScriptStore {
12+
private static let autoScriptAssignments: [AutoScriptAssignment] = [
13+
AutoScriptAssignment(
14+
appNames: [
15+
"Amethyst",
16+
"MeloNX",
17+
"Melo",
18+
"XeniOS",
19+
"MeloCafe",
20+
"Manic EMU",
21+
"Manic",
22+
"Geode",
23+
"DukeX",
24+
"Duke X",
25+
"Duke"
26+
],
27+
resource: ScriptResource(resourceName: "universal", fileName: "universal.js")
28+
),
29+
AutoScriptAssignment(
30+
appNames: [
31+
"UTM",
32+
"DolphiniOS",
33+
"Flycast"
34+
],
35+
resource: ScriptResource(resourceName: "UTM-Dolphin", fileName: "UTM-Dolphin.js")
36+
),
37+
AutoScriptAssignment(
38+
appNames: [
39+
"maciOS"
40+
],
41+
resource: ScriptResource(resourceName: "maciOS", fileName: "maciOS.js")
42+
)
43+
]
44+
45+
static func autoScriptResource(for appName: String) -> ScriptResource? {
46+
autoScriptAssignments.first { assignment in
47+
assignment.appNames.contains(appName)
48+
}?.resource
49+
}
50+
}

StikJIT/Utilities/Extensions.swift

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -158,23 +158,6 @@ enum ScriptStore {
158158
return names?[bundleID]
159159
}
160160

161-
static func autoScriptResource(for appName: String) -> ScriptResource? {
162-
switch appName {
163-
case "maciOS":
164-
return ScriptResource(resourceName: "maciOS", fileName: "maciOS.js")
165-
case "Amethyst", "MeloNX", "XeniOS", "MeloCafe":
166-
return ScriptResource(resourceName: "universal", fileName: "universal.js")
167-
case "Geode":
168-
return ScriptResource(resourceName: "Geode", fileName: "Geode.js")
169-
case "Manic EMU":
170-
return ScriptResource(resourceName: "manic", fileName: "manic.js")
171-
case "UTM", "DolphiniOS", "Flycast":
172-
return ScriptResource(resourceName: "UTM-Dolphin", fileName: "UTM-Dolphin.js")
173-
default:
174-
return nil
175-
}
176-
}
177-
178161
private static func ensureBundledScripts(in directory: URL, fileManager: FileManager) throws {
179162
for resource in bundledResources {
180163
guard let bundleURL = Bundle.main.url(forResource: resource.resourceName, withExtension: "js") else {

StikJIT/Utilities/IdeviceFFIBridge.swift

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -750,6 +750,10 @@ private enum LocationSimulationState {
750750
}
751751
}
752752

753+
enum LocationSimulationCommandQueue {
754+
static let shared = DispatchQueue(label: "com.stik.location-sim", qos: .userInitiated)
755+
}
756+
753757
func simulate_location(_ deviceIP: String, _ latitude: Double, _ longitude: Double, _ pairingFile: String) -> Int32 {
754758
if let locationSimulation = LocationSimulationState.locationSimulation {
755759
if let ffiError = location_simulation_set(locationSimulation, latitude, longitude) {

StikJIT/Utilities/TabConfiguration.swift

Lines changed: 0 additions & 44 deletions
This file was deleted.

0 commit comments

Comments
 (0)