app icon and splash screen updates
@@ -163,7 +163,7 @@
|
|||||||
"CODE_SIGN_IDENTITY[sdk=macosx*]" = "Apple Development";
|
"CODE_SIGN_IDENTITY[sdk=macosx*]" = "Apple Development";
|
||||||
CODE_SIGN_STYLE = Automatic;
|
CODE_SIGN_STYLE = Automatic;
|
||||||
COMBINE_HIDPI_IMAGES = YES;
|
COMBINE_HIDPI_IMAGES = YES;
|
||||||
CURRENT_PROJECT_VERSION = 11;
|
CURRENT_PROJECT_VERSION = 12;
|
||||||
DEAD_CODE_STRIPPING = YES;
|
DEAD_CODE_STRIPPING = YES;
|
||||||
DEBUG_INFORMATION_FORMAT = dwarf;
|
DEBUG_INFORMATION_FORMAT = dwarf;
|
||||||
ENABLE_HARDENED_RUNTIME = YES;
|
ENABLE_HARDENED_RUNTIME = YES;
|
||||||
@@ -175,7 +175,7 @@
|
|||||||
"@executable_path/../Frameworks",
|
"@executable_path/../Frameworks",
|
||||||
);
|
);
|
||||||
MACOSX_DEPLOYMENT_TARGET = 15.0;
|
MACOSX_DEPLOYMENT_TARGET = 15.0;
|
||||||
MARKETING_VERSION = 2.1.3;
|
MARKETING_VERSION = 2.1.4;
|
||||||
PRODUCT_BUNDLE_IDENTIFIER = net.realizedsound.ShoeGazeBuilder;
|
PRODUCT_BUNDLE_IDENTIFIER = net.realizedsound.ShoeGazeBuilder;
|
||||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||||
SWIFT_EMIT_LOC_STRINGS = YES;
|
SWIFT_EMIT_LOC_STRINGS = YES;
|
||||||
@@ -193,7 +193,7 @@
|
|||||||
"CODE_SIGN_IDENTITY[sdk=macosx*]" = "Apple Development";
|
"CODE_SIGN_IDENTITY[sdk=macosx*]" = "Apple Development";
|
||||||
CODE_SIGN_STYLE = Automatic;
|
CODE_SIGN_STYLE = Automatic;
|
||||||
COMBINE_HIDPI_IMAGES = YES;
|
COMBINE_HIDPI_IMAGES = YES;
|
||||||
CURRENT_PROJECT_VERSION = 11;
|
CURRENT_PROJECT_VERSION = 12;
|
||||||
DEAD_CODE_STRIPPING = YES;
|
DEAD_CODE_STRIPPING = YES;
|
||||||
ENABLE_HARDENED_RUNTIME = YES;
|
ENABLE_HARDENED_RUNTIME = YES;
|
||||||
INFOPLIST_FILE = ShoeGazeBuilder/Info.plist;
|
INFOPLIST_FILE = ShoeGazeBuilder/Info.plist;
|
||||||
@@ -204,7 +204,7 @@
|
|||||||
"@executable_path/../Frameworks",
|
"@executable_path/../Frameworks",
|
||||||
);
|
);
|
||||||
MACOSX_DEPLOYMENT_TARGET = 15.0;
|
MACOSX_DEPLOYMENT_TARGET = 15.0;
|
||||||
MARKETING_VERSION = 2.1.3;
|
MARKETING_VERSION = 2.1.4;
|
||||||
PRODUCT_BUNDLE_IDENTIFIER = net.realizedsound.ShoeGazeBuilder;
|
PRODUCT_BUNDLE_IDENTIFIER = net.realizedsound.ShoeGazeBuilder;
|
||||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||||
SWIFT_EMIT_LOC_STRINGS = YES;
|
SWIFT_EMIT_LOC_STRINGS = YES;
|
||||||
|
|||||||
|
Before Width: | Height: | Size: 25 KiB After Width: | Height: | Size: 18 KiB |
|
Before Width: | Height: | Size: 91 KiB After Width: | Height: | Size: 55 KiB |
|
Before Width: | Height: | Size: 782 B After Width: | Height: | Size: 2.0 KiB |
|
Before Width: | Height: | Size: 2.0 KiB After Width: | Height: | Size: 3.0 KiB |
|
Before Width: | Height: | Size: 91 KiB After Width: | Height: | Size: 55 KiB |
|
Before Width: | Height: | Size: 345 KiB After Width: | Height: | Size: 200 KiB |
|
Before Width: | Height: | Size: 2.0 KiB After Width: | Height: | Size: 3.0 KiB |
|
Before Width: | Height: | Size: 6.9 KiB After Width: | Height: | Size: 6.6 KiB |
|
Before Width: | Height: | Size: 345 KiB After Width: | Height: | Size: 200 KiB |
|
Before Width: | Height: | Size: 1.2 MiB After Width: | Height: | Size: 643 KiB |
@@ -28,9 +28,9 @@
|
|||||||
<key>CFBundlePackageType</key>
|
<key>CFBundlePackageType</key>
|
||||||
<string>APPL</string>
|
<string>APPL</string>
|
||||||
<key>CFBundleShortVersionString</key>
|
<key>CFBundleShortVersionString</key>
|
||||||
<string>2.1.3</string>
|
<string>${MARKETING_VERSION}</string>
|
||||||
<key>CFBundleVersion</key>
|
<key>CFBundleVersion</key>
|
||||||
<string>11</string>
|
<string>${CURRENT_PROJECT_VERSION}</string>
|
||||||
<key>LSApplicationCategoryType</key>
|
<key>LSApplicationCategoryType</key>
|
||||||
<string>public.app-category.music</string>
|
<string>public.app-category.music</string>
|
||||||
<key>LSMinimumSystemVersion</key>
|
<key>LSMinimumSystemVersion</key>
|
||||||
|
|||||||
@@ -14,6 +14,7 @@
|
|||||||
C3C10000000000000000000D /* LyrebirdUI in Frameworks */ = {isa = PBXBuildFile; productRef = C3C10000000000000000001C /* LyrebirdUI */; };
|
C3C10000000000000000000D /* LyrebirdUI in Frameworks */ = {isa = PBXBuildFile; productRef = C3C10000000000000000001C /* LyrebirdUI */; };
|
||||||
C3C10000000000000000001D /* Lyrebird in Frameworks */ = {isa = PBXBuildFile; productRef = C3C10000000000000000001E /* Lyrebird */; };
|
C3C10000000000000000001D /* Lyrebird in Frameworks */ = {isa = PBXBuildFile; productRef = C3C10000000000000000001E /* Lyrebird */; };
|
||||||
C3C100000000000000000031 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = C3C100000000000000000030 /* Assets.xcassets */; };
|
C3C100000000000000000031 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = C3C100000000000000000030 /* Assets.xcassets */; };
|
||||||
|
C3C1000000000000000000B1 /* SplashView.swift in Sources */ = {isa = PBXBuildFile; fileRef = C3C1000000000000000000B0 /* SplashView.swift */; };
|
||||||
/* End PBXBuildFile section */
|
/* End PBXBuildFile section */
|
||||||
|
|
||||||
/* Begin PBXFileReference section */
|
/* Begin PBXFileReference section */
|
||||||
@@ -22,6 +23,7 @@
|
|||||||
C3C100000000000000000007 /* ShoeGazeBuilderiOSApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ShoeGazeBuilderiOSApp.swift; sourceTree = "<group>"; };
|
C3C100000000000000000007 /* ShoeGazeBuilderiOSApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ShoeGazeBuilderiOSApp.swift; sourceTree = "<group>"; };
|
||||||
C3C100000000000000000008 /* ShoeGazeBuilderiOSAppModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ShoeGazeBuilderiOSAppModel.swift; sourceTree = "<group>"; };
|
C3C100000000000000000008 /* ShoeGazeBuilderiOSAppModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ShoeGazeBuilderiOSAppModel.swift; sourceTree = "<group>"; };
|
||||||
C3C100000000000000000030 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
|
C3C100000000000000000030 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
|
||||||
|
C3C1000000000000000000B0 /* SplashView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SplashView.swift; sourceTree = "<group>"; };
|
||||||
/* End PBXFileReference section */
|
/* End PBXFileReference section */
|
||||||
|
|
||||||
/* Begin PBXFrameworksBuildPhase section */
|
/* Begin PBXFrameworksBuildPhase section */
|
||||||
@@ -60,6 +62,7 @@
|
|||||||
children = (
|
children = (
|
||||||
C3C100000000000000000007 /* ShoeGazeBuilderiOSApp.swift */,
|
C3C100000000000000000007 /* ShoeGazeBuilderiOSApp.swift */,
|
||||||
C3C100000000000000000008 /* ShoeGazeBuilderiOSAppModel.swift */,
|
C3C100000000000000000008 /* ShoeGazeBuilderiOSAppModel.swift */,
|
||||||
|
C3C1000000000000000000B0 /* SplashView.swift */,
|
||||||
C3C100000000000000000030 /* Assets.xcassets */,
|
C3C100000000000000000030 /* Assets.xcassets */,
|
||||||
C3C100000000000000000006 /* Info.plist */,
|
C3C100000000000000000006 /* Info.plist */,
|
||||||
);
|
);
|
||||||
@@ -100,7 +103,7 @@
|
|||||||
attributes = {
|
attributes = {
|
||||||
BuildIndependentTargetsInParallel = 1;
|
BuildIndependentTargetsInParallel = 1;
|
||||||
LastSwiftUpdateCheck = 1600;
|
LastSwiftUpdateCheck = 1600;
|
||||||
LastUpgradeCheck = 2620;
|
LastUpgradeCheck = 2660;
|
||||||
TargetAttributes = {
|
TargetAttributes = {
|
||||||
C3C100000000000000000011 = {
|
C3C100000000000000000011 = {
|
||||||
CreatedOnToolsVersion = 16.0;
|
CreatedOnToolsVersion = 16.0;
|
||||||
@@ -147,6 +150,7 @@
|
|||||||
files = (
|
files = (
|
||||||
C3C100000000000000000009 /* ShoeGazeBuilderiOSApp.swift in Sources */,
|
C3C100000000000000000009 /* ShoeGazeBuilderiOSApp.swift in Sources */,
|
||||||
C3C10000000000000000000A /* ShoeGazeBuilderiOSAppModel.swift in Sources */,
|
C3C10000000000000000000A /* ShoeGazeBuilderiOSAppModel.swift in Sources */,
|
||||||
|
C3C1000000000000000000B1 /* SplashView.swift in Sources */,
|
||||||
);
|
);
|
||||||
runOnlyForDeploymentPostprocessing = 0;
|
runOnlyForDeploymentPostprocessing = 0;
|
||||||
};
|
};
|
||||||
@@ -163,7 +167,6 @@
|
|||||||
CODE_SIGN_STYLE = Automatic;
|
CODE_SIGN_STYLE = Automatic;
|
||||||
CURRENT_PROJECT_VERSION = 7;
|
CURRENT_PROJECT_VERSION = 7;
|
||||||
DEBUG_INFORMATION_FORMAT = dwarf;
|
DEBUG_INFORMATION_FORMAT = dwarf;
|
||||||
DEVELOPMENT_TEAM = HE5VJFE9E4;
|
|
||||||
INFOPLIST_FILE = ShoeGazeBuilderiOS/Info.plist;
|
INFOPLIST_FILE = ShoeGazeBuilderiOS/Info.plist;
|
||||||
INFOPLIST_KEY_CFBundleDisplayName = ShoeGaze;
|
INFOPLIST_KEY_CFBundleDisplayName = ShoeGaze;
|
||||||
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.music";
|
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.music";
|
||||||
@@ -192,7 +195,6 @@
|
|||||||
CODE_SIGN_ENTITLEMENTS = ShoeGazeBuilderiOS/ShoeGazeBuilderiOS.entitlements;
|
CODE_SIGN_ENTITLEMENTS = ShoeGazeBuilderiOS/ShoeGazeBuilderiOS.entitlements;
|
||||||
CODE_SIGN_STYLE = Automatic;
|
CODE_SIGN_STYLE = Automatic;
|
||||||
CURRENT_PROJECT_VERSION = 7;
|
CURRENT_PROJECT_VERSION = 7;
|
||||||
DEVELOPMENT_TEAM = HE5VJFE9E4;
|
|
||||||
INFOPLIST_FILE = ShoeGazeBuilderiOS/Info.plist;
|
INFOPLIST_FILE = ShoeGazeBuilderiOS/Info.plist;
|
||||||
INFOPLIST_KEY_CFBundleDisplayName = ShoeGaze;
|
INFOPLIST_KEY_CFBundleDisplayName = ShoeGaze;
|
||||||
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.music";
|
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.music";
|
||||||
@@ -246,6 +248,7 @@
|
|||||||
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
|
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
|
||||||
COPY_PHASE_STRIP = NO;
|
COPY_PHASE_STRIP = NO;
|
||||||
DEBUG_INFORMATION_FORMAT = dwarf;
|
DEBUG_INFORMATION_FORMAT = dwarf;
|
||||||
|
DEVELOPMENT_TEAM = HE5VJFE9E4;
|
||||||
ENABLE_STRICT_OBJC_MSGSEND = YES;
|
ENABLE_STRICT_OBJC_MSGSEND = YES;
|
||||||
ENABLE_TESTABILITY = YES;
|
ENABLE_TESTABILITY = YES;
|
||||||
ENABLE_USER_SCRIPT_SANDBOXING = YES;
|
ENABLE_USER_SCRIPT_SANDBOXING = YES;
|
||||||
@@ -308,6 +311,7 @@
|
|||||||
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
|
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
|
||||||
COPY_PHASE_STRIP = NO;
|
COPY_PHASE_STRIP = NO;
|
||||||
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
|
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
|
||||||
|
DEVELOPMENT_TEAM = HE5VJFE9E4;
|
||||||
ENABLE_NS_ASSERTIONS = NO;
|
ENABLE_NS_ASSERTIONS = NO;
|
||||||
ENABLE_STRICT_OBJC_MSGSEND = YES;
|
ENABLE_STRICT_OBJC_MSGSEND = YES;
|
||||||
ENABLE_USER_SCRIPT_SANDBOXING = YES;
|
ENABLE_USER_SCRIPT_SANDBOXING = YES;
|
||||||
|
|||||||
|
Before Width: | Height: | Size: 402 KiB After Width: | Height: | Size: 643 KiB |
@@ -0,0 +1,12 @@
|
|||||||
|
{
|
||||||
|
"colors" : [
|
||||||
|
{
|
||||||
|
"idiom" : "universal",
|
||||||
|
"color" : {
|
||||||
|
"color-space" : "srgb",
|
||||||
|
"components" : { "red" : "0.080", "green" : "0.070", "blue" : "0.060", "alpha" : "1.000" }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"info" : { "author" : "xcode", "version" : 1 }
|
||||||
|
}
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
{
|
||||||
|
"images" : [
|
||||||
|
{ "idiom" : "universal", "filename" : "splashlogo.png", "scale" : "1x" },
|
||||||
|
{ "idiom" : "universal", "filename" : "splashlogo@2x.png", "scale" : "2x" },
|
||||||
|
{ "idiom" : "universal", "filename" : "splashlogo@3x.png", "scale" : "3x" }
|
||||||
|
],
|
||||||
|
"info" : { "author" : "xcode", "version" : 1 }
|
||||||
|
}
|
||||||
|
After Width: | Height: | Size: 57 KiB |
|
After Width: | Height: | Size: 208 KiB |
|
After Width: | Height: | Size: 420 KiB |
@@ -59,7 +59,10 @@
|
|||||||
<false/>
|
<false/>
|
||||||
</dict>
|
</dict>
|
||||||
<key>UILaunchScreen</key>
|
<key>UILaunchScreen</key>
|
||||||
<dict/>
|
<dict>
|
||||||
|
<key>UIColorName</key>
|
||||||
|
<string>LaunchBackground</string>
|
||||||
|
</dict>
|
||||||
<key>UIRequiresFullScreen</key>
|
<key>UIRequiresFullScreen</key>
|
||||||
<true/>
|
<true/>
|
||||||
<key>UISupportedInterfaceOrientations</key>
|
<key>UISupportedInterfaceOrientations</key>
|
||||||
|
|||||||
@@ -20,21 +20,30 @@ import LyrebirdShoeGazeUI
|
|||||||
struct ShoeGazeBuilderiOSApp: App {
|
struct ShoeGazeBuilderiOSApp: App {
|
||||||
|
|
||||||
@State private var model: ShoeGazeBuilderiOSAppModel = ShoeGazeBuilderiOSAppModel()
|
@State private var model: ShoeGazeBuilderiOSAppModel = ShoeGazeBuilderiOSAppModel()
|
||||||
|
@State private var showSplash: Bool = true
|
||||||
@Environment(\.scenePhase) private var scenePhase
|
@Environment(\.scenePhase) private var scenePhase
|
||||||
|
|
||||||
var body: some Scene {
|
var body: some Scene {
|
||||||
WindowGroup {
|
WindowGroup {
|
||||||
ShoeGazeBuilderView(
|
ZStack {
|
||||||
shoeGaze: model.shoeGaze,
|
ShoeGazeBuilderView(
|
||||||
library: model.library,
|
shoeGaze: model.shoeGaze,
|
||||||
hardwareSampleRate: { model.hardwareSampleRate },
|
library: model.library,
|
||||||
onEnableLiveInput: { model.enableLiveInput() },
|
hardwareSampleRate: { model.hardwareSampleRate },
|
||||||
midi: model.midi
|
onEnableLiveInput: { model.enableLiveInput() },
|
||||||
)
|
midi: model.midi
|
||||||
.frame(maxWidth: .infinity, maxHeight: .infinity, alignment: .topLeading)
|
)
|
||||||
.task { await model.startLibrary() }
|
.frame(maxWidth: .infinity, maxHeight: .infinity, alignment: .topLeading)
|
||||||
.onDisappear { model.stop() }
|
.task { await model.startLibrary() }
|
||||||
.onOpenURL { url in model.importDocument(at: url) }
|
.onDisappear { model.stop() }
|
||||||
|
.onOpenURL { url in model.importDocument(at: url) }
|
||||||
|
|
||||||
|
if showSplash {
|
||||||
|
SplashView(isActive: $showSplash)
|
||||||
|
.transition(.opacity)
|
||||||
|
.zIndex(1)
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
.onChange(of: scenePhase) { _, phase in
|
.onChange(of: scenePhase) { _, phase in
|
||||||
// Persist the rig whenever the app leaves the foreground.
|
// Persist the rig whenever the app leaves the foreground.
|
||||||
|
|||||||
@@ -0,0 +1,82 @@
|
|||||||
|
// SplashView.swift
|
||||||
|
// Lyrebird
|
||||||
|
//
|
||||||
|
// Copyright (c) 2026 Joshua Parmenter / realizedsound
|
||||||
|
// SPDX-License-Identifier: MIT
|
||||||
|
|
||||||
|
import SwiftUI
|
||||||
|
|
||||||
|
/// Animated launch splash shown over the app on cold start.
|
||||||
|
///
|
||||||
|
/// The native launch screen (`UILaunchScreen` → `LaunchBackground`) paints an instant dark
|
||||||
|
/// backdrop with no visible jump; this view then fades and scales the ShoeGaze pedal logo in,
|
||||||
|
/// holds briefly, and fades the whole overlay away to reveal ``ShoeGazeBuilderView``. Colors match
|
||||||
|
/// the app background so the hand-off is seamless. Respects Reduce Motion by skipping the scale.
|
||||||
|
struct SplashView: View {
|
||||||
|
|
||||||
|
/// Background matching the builder's app background (`0.08, 0.07, 0.06`).
|
||||||
|
private static let backgroundColor: Color = Color(red: 0.08, green: 0.07, blue: 0.06)
|
||||||
|
|
||||||
|
private static let logoSize: CGFloat = 200
|
||||||
|
private static let logoCornerRadius: CGFloat = 44
|
||||||
|
private static let logoStartScale: CGFloat = 0.86
|
||||||
|
private static let wordmarkKerning: CGFloat = 4
|
||||||
|
|
||||||
|
private static let logoFadeInDuration: Double = 0.55
|
||||||
|
private static let wordmarkFadeInDelay: Double = 0.30
|
||||||
|
private static let wordmarkFadeInDuration: Double = 0.45
|
||||||
|
private static let holdDuration: Double = 0.85
|
||||||
|
private static let fadeOutDuration: Double = 0.45
|
||||||
|
|
||||||
|
@Environment(\.accessibilityReduceMotion) private var reduceMotion
|
||||||
|
|
||||||
|
/// Set false to fade the overlay out; parent removes it when the fade completes.
|
||||||
|
@Binding var isActive: Bool
|
||||||
|
|
||||||
|
@State private var logoOpacity: Double = 0
|
||||||
|
@State private var logoScale: CGFloat = SplashView.logoStartScale
|
||||||
|
@State private var wordmarkOpacity: Double = 0
|
||||||
|
|
||||||
|
var body: some View {
|
||||||
|
ZStack {
|
||||||
|
SplashView.backgroundColor
|
||||||
|
.ignoresSafeArea()
|
||||||
|
|
||||||
|
VStack(spacing: 22) {
|
||||||
|
Image("SplashLogo")
|
||||||
|
.resizable()
|
||||||
|
.scaledToFit()
|
||||||
|
.frame(width: SplashView.logoSize, height: SplashView.logoSize)
|
||||||
|
.clipShape(RoundedRectangle(cornerRadius: SplashView.logoCornerRadius,
|
||||||
|
style: .continuous))
|
||||||
|
.opacity(logoOpacity)
|
||||||
|
.scaleEffect(logoScale)
|
||||||
|
|
||||||
|
Text("ShoeGaze")
|
||||||
|
.font(.system(size: 34, weight: .semibold, design: .rounded))
|
||||||
|
.kerning(SplashView.wordmarkKerning)
|
||||||
|
.foregroundStyle(.white)
|
||||||
|
.opacity(wordmarkOpacity)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.onAppear { runSequence() }
|
||||||
|
}
|
||||||
|
|
||||||
|
private func runSequence() {
|
||||||
|
withAnimation(.easeOut(duration: SplashView.logoFadeInDuration)) {
|
||||||
|
logoOpacity = 1
|
||||||
|
if !reduceMotion { logoScale = 1 }
|
||||||
|
}
|
||||||
|
withAnimation(.easeOut(duration: SplashView.wordmarkFadeInDuration)
|
||||||
|
.delay(SplashView.wordmarkFadeInDelay)) {
|
||||||
|
wordmarkOpacity = 1
|
||||||
|
}
|
||||||
|
|
||||||
|
let holdUntil: Double = SplashView.logoFadeInDuration + SplashView.holdDuration
|
||||||
|
DispatchQueue.main.asyncAfter(deadline: .now() + holdUntil) {
|
||||||
|
withAnimation(.easeIn(duration: SplashView.fadeOutDuration)) {
|
||||||
|
isActive = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -24,7 +24,7 @@ let package = Package(
|
|||||||
.library(name: "LyrebirdShoeGazeUI", targets: ["LyrebirdShoeGazeUI"]),
|
.library(name: "LyrebirdShoeGazeUI", targets: ["LyrebirdShoeGazeUI"]),
|
||||||
],
|
],
|
||||||
dependencies: [
|
dependencies: [
|
||||||
.package(url: "https://realizedsound.mooo.com/josh/Lyrebird", from: "1.2.4"),
|
.package(url: "https://realizedsound.mooo.com/josh/Lyrebird", from: "1.6.3"),
|
||||||
],
|
],
|
||||||
targets: [
|
targets: [
|
||||||
// The core target depends on LyrebirdUI as well as the synthesis core:
|
// The core target depends on LyrebirdUI as well as the synthesis core:
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"originHash" : "9786d88c1bf20540d8a635ebd8d373be29f0831e15ddefb3e92c9a5a87ea6e98",
|
"originHash" : "4c33c107b780400f6ccd69fd1203a485fca3ff6a90f93c3aad40bd403ef33702",
|
||||||
"pins" : [
|
"pins" : [
|
||||||
{
|
{
|
||||||
"identity" : "linenoise-swift",
|
"identity" : "linenoise-swift",
|
||||||
@@ -15,8 +15,8 @@
|
|||||||
"kind" : "remoteSourceControl",
|
"kind" : "remoteSourceControl",
|
||||||
"location" : "https://realizedsound.mooo.com/josh/Lyrebird",
|
"location" : "https://realizedsound.mooo.com/josh/Lyrebird",
|
||||||
"state" : {
|
"state" : {
|
||||||
"revision" : "63d6e0746fdedce626c9eff832e799bad949708e",
|
"revision" : "5e6534a615af6c075fc539e909cef3a63b038ced",
|
||||||
"version" : "1.2.4"
|
"version" : "1.6.3"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -51,6 +51,10 @@ public struct BoardFlowView: View {
|
|||||||
private static let splitToggleWidth: CGFloat = 200
|
private static let splitToggleWidth: CGFloat = 200
|
||||||
private static let emptyLaneOpacity: Double = 0.4
|
private static let emptyLaneOpacity: Double = 0.4
|
||||||
|
|
||||||
|
/// Extra height the content may exceed the viewport by before vertical scrolling turns on, so a
|
||||||
|
/// sub-pixel rounding difference doesn't flip the axis set on and off.
|
||||||
|
private static let verticalScrollSlack: CGFloat = 1
|
||||||
|
|
||||||
/// Signal-path accent (the pink/magenta connector colour).
|
/// Signal-path accent (the pink/magenta connector colour).
|
||||||
private static let flowColor: Color = Color(red: 0.92, green: 0.32, blue: 0.70)
|
private static let flowColor: Color = Color(red: 0.92, green: 0.32, blue: 0.70)
|
||||||
|
|
||||||
@@ -62,6 +66,10 @@ public struct BoardFlowView: View {
|
|||||||
/// Identifier of the lane/card currently hovered as a drop target, for highlight.
|
/// Identifier of the lane/card currently hovered as a drop target, for highlight.
|
||||||
@State private var dropTarget: String?
|
@State private var dropTarget: String?
|
||||||
|
|
||||||
|
/// Measured height of the flow content, used to enable vertical scrolling only when the stacked
|
||||||
|
/// lanes exceed the viewport height (tall parallel splits). Otherwise scrolling stays horizontal.
|
||||||
|
@State private var contentHeight: CGFloat = 0
|
||||||
|
|
||||||
public init(shoeGaze: ShoeGaze, boardIndex: Int) {
|
public init(shoeGaze: ShoeGaze, boardIndex: Int) {
|
||||||
self.shoeGaze = shoeGaze
|
self.shoeGaze = shoeGaze
|
||||||
self.boardIndex = boardIndex
|
self.boardIndex = boardIndex
|
||||||
@@ -81,19 +89,55 @@ public struct BoardFlowView: View {
|
|||||||
|
|
||||||
private func flow(board: PedalBoard) -> some View {
|
private func flow(board: PedalBoard) -> some View {
|
||||||
let stages: [StageModel] = stageModels(board: board)
|
let stages: [StageModel] = stageModels(board: board)
|
||||||
return ScrollView([.horizontal, .vertical], showsIndicators: true) {
|
return GeometryReader { proxy in
|
||||||
HStack(alignment: .center, spacing: BoardFlowView.stageSpacing) {
|
let viewportHeight: CGFloat = proxy.size.height
|
||||||
endpoint("IN")
|
// Lock to horizontal, adding the vertical axis only when the chain is taller than the
|
||||||
ForEach(stages) { stage in
|
// viewport (deep parallel splits) so it can be reached instead of clipped.
|
||||||
connector(stereo: stage.stereoIn)
|
let axes: Axis.Set = contentHeight > viewportHeight + BoardFlowView.verticalScrollSlack
|
||||||
stageView(stage)
|
? [.horizontal, .vertical]
|
||||||
|
: .horizontal
|
||||||
|
ScrollView(axes, showsIndicators: true) {
|
||||||
|
// The spacers centre the chain vertically when it is shorter than the viewport; when
|
||||||
|
// it overflows, the min-height floor is already exceeded so they collapse to zero and
|
||||||
|
// the chain scrolls. Pedals keep their intrinsic height either way — the window no
|
||||||
|
// longer stretches them.
|
||||||
|
VStack(spacing: 0) {
|
||||||
|
Spacer(minLength: 0)
|
||||||
|
chainRow(board: board, stages: stages)
|
||||||
|
Spacer(minLength: 0)
|
||||||
}
|
}
|
||||||
connector(stereo: board.width == 2)
|
.frame(minHeight: viewportHeight)
|
||||||
endpoint(board.width == 2 ? "OUT ⇒" : "OUT")
|
}
|
||||||
|
.frame(maxWidth: .infinity, maxHeight: .infinity)
|
||||||
|
.onPreferenceChange(BoardFlowContentHeightKey.self) { height in
|
||||||
|
contentHeight = height
|
||||||
}
|
}
|
||||||
.padding(.vertical, BoardFlowView.regionPadding)
|
|
||||||
}
|
}
|
||||||
.frame(maxWidth: .infinity, maxHeight: .infinity)
|
}
|
||||||
|
|
||||||
|
/// The left→right chain of endpoints, connectors and stage cards. Reports its own intrinsic
|
||||||
|
/// height through `BoardFlowContentHeightKey` so `flow` can decide whether vertical scrolling is
|
||||||
|
/// needed. Each pedal sizes to its own content, so the row is only as tall as its tallest card —
|
||||||
|
/// a short pedal stays short next to a tall one.
|
||||||
|
private func chainRow(board: PedalBoard, stages: [StageModel]) -> some View {
|
||||||
|
HStack(alignment: .center, spacing: BoardFlowView.stageSpacing) {
|
||||||
|
endpoint("IN")
|
||||||
|
ForEach(stages) { stage in
|
||||||
|
connector(stereo: stage.stereoIn)
|
||||||
|
stageView(stage)
|
||||||
|
}
|
||||||
|
connector(stereo: board.width == 2)
|
||||||
|
endpoint(board.width == 2 ? "OUT ⇒" : "OUT")
|
||||||
|
}
|
||||||
|
.padding(.vertical, BoardFlowView.regionPadding)
|
||||||
|
.background(
|
||||||
|
GeometryReader { contentProxy in
|
||||||
|
Color.clear.preference(
|
||||||
|
key: BoardFlowContentHeightKey.self,
|
||||||
|
value: contentProxy.size.height
|
||||||
|
)
|
||||||
|
}
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
// MARK: - Stage model
|
// MARK: - Stage model
|
||||||
@@ -531,3 +575,12 @@ private extension String {
|
|||||||
return String(dropFirst(prefix.count))
|
return String(dropFirst(prefix.count))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// Carries the measured height of the flow content up to `BoardFlowView`, which compares it to the
|
||||||
|
/// viewport height to decide whether the vertical scroll axis is needed.
|
||||||
|
private struct BoardFlowContentHeightKey: PreferenceKey {
|
||||||
|
static let defaultValue: CGFloat = 0
|
||||||
|
static func reduce(value: inout CGFloat, nextValue: () -> CGFloat) {
|
||||||
|
value = max(value, nextValue())
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@@ -474,7 +474,20 @@ public struct PedalView: View {
|
|||||||
// the enclosure-width calculation consume the same array.
|
// the enclosure-width calculation consume the same array.
|
||||||
let sliders: [PedalSlider] = pedal.effectSliders
|
let sliders: [PedalSlider] = pedal.effectSliders
|
||||||
|
|
||||||
ZStack(alignment: .topLeading) {
|
// Content is the sizing layer so the enclosure hugs it vertically — a short pedal stays
|
||||||
|
// short. The gradient fill and border/screw strokes are attached as background/overlay so
|
||||||
|
// they conform to the content height instead of a greedy `RoundedRectangle` in a ZStack
|
||||||
|
// dictating (and stretching) the height to fill the row.
|
||||||
|
Group {
|
||||||
|
if let looper: LooperPedal = pedal as? LooperPedal {
|
||||||
|
looperColumnarContent(looper)
|
||||||
|
} else {
|
||||||
|
defaultContent(sliders: sliders)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.padding(PedalView.enclosurePadding)
|
||||||
|
.frame(width: enclosureWidth(for: sliders))
|
||||||
|
.background(
|
||||||
// Enclosure fill with top-to-bottom gradient
|
// Enclosure fill with top-to-bottom gradient
|
||||||
RoundedRectangle(cornerRadius: PedalView.enclosureCornerRadius)
|
RoundedRectangle(cornerRadius: PedalView.enclosureCornerRadius)
|
||||||
.fill(
|
.fill(
|
||||||
@@ -484,38 +497,28 @@ public struct PedalView: View {
|
|||||||
endPoint: .bottom
|
endPoint: .bottom
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
)
|
||||||
// Outer border
|
.overlay(
|
||||||
RoundedRectangle(cornerRadius: PedalView.enclosureCornerRadius)
|
|
||||||
.stroke(Color.black.opacity(PedalView.outerBorderOpacity),
|
|
||||||
lineWidth: PedalView.outerBorderLineWidth)
|
|
||||||
|
|
||||||
// Inner highlight rim (subtle bevel)
|
// Inner highlight rim (subtle bevel)
|
||||||
RoundedRectangle(cornerRadius: PedalView.enclosureCornerRadius - PedalView.innerHighlightPadding)
|
RoundedRectangle(cornerRadius: PedalView.enclosureCornerRadius - PedalView.innerHighlightPadding)
|
||||||
.stroke(Color.white.opacity(PedalView.innerHighlightOpacity),
|
.stroke(Color.white.opacity(PedalView.innerHighlightOpacity),
|
||||||
lineWidth: PedalView.innerHighlightLineWidth)
|
lineWidth: PedalView.innerHighlightLineWidth)
|
||||||
.padding(PedalView.innerHighlightPadding)
|
.padding(PedalView.innerHighlightPadding)
|
||||||
|
)
|
||||||
// Content stack — the looper uses a wide, columnar layout to stay short; every other
|
.overlay(
|
||||||
// pedal uses the default single-column section stack.
|
// Outer border
|
||||||
Group {
|
RoundedRectangle(cornerRadius: PedalView.enclosureCornerRadius)
|
||||||
if let looper: LooperPedal = pedal as? LooperPedal {
|
.stroke(Color.black.opacity(PedalView.outerBorderOpacity),
|
||||||
looperColumnarContent(looper)
|
lineWidth: PedalView.outerBorderLineWidth)
|
||||||
} else {
|
)
|
||||||
defaultContent(sliders: sliders)
|
// Corner screws — overlaid at the four corners.
|
||||||
}
|
.overlay { screwCorners }
|
||||||
}
|
// Info button, tucked just under the top-left corner screw.
|
||||||
.padding(PedalView.enclosurePadding)
|
.overlay(alignment: .topLeading) {
|
||||||
|
|
||||||
// Corner screws — overlaid at the four corners
|
|
||||||
screwCorners
|
|
||||||
|
|
||||||
// Info button, tucked just under the top-left corner screw.
|
|
||||||
infoButton
|
infoButton
|
||||||
.padding(.leading, PedalView.infoButtonLeading)
|
.padding(.leading, PedalView.infoButtonLeading)
|
||||||
.padding(.top, PedalView.infoButtonTop)
|
.padding(.top, PedalView.infoButtonTop)
|
||||||
}
|
}
|
||||||
.frame(width: enclosureWidth(for: sliders))
|
|
||||||
.shadow(
|
.shadow(
|
||||||
color: Color.black.opacity(PedalView.shadowOpacity),
|
color: Color.black.opacity(PedalView.shadowOpacity),
|
||||||
radius: PedalView.shadowRadius,
|
radius: PedalView.shadowRadius,
|
||||||
@@ -543,7 +546,6 @@ public struct PedalView: View {
|
|||||||
.id(ObjectIdentifier(pedal))
|
.id(ObjectIdentifier(pedal))
|
||||||
buttonRow
|
buttonRow
|
||||||
sliderBank(sliders)
|
sliderBank(sliders)
|
||||||
Spacer(minLength: 0)
|
|
||||||
bottomControls
|
bottomControls
|
||||||
PedalMappingStrip(pedal: pedal, map: controlMappingMap)
|
PedalMappingStrip(pedal: pedal, map: controlMappingMap)
|
||||||
}
|
}
|
||||||
@@ -579,7 +581,6 @@ public struct PedalView: View {
|
|||||||
looperTransportGrid(columns: 2)
|
looperTransportGrid(columns: 2)
|
||||||
.id(ObjectIdentifier(pedal))
|
.id(ObjectIdentifier(pedal))
|
||||||
}
|
}
|
||||||
Spacer(minLength: 0)
|
|
||||||
PedalMappingStrip(pedal: pedal, map: controlMappingMap)
|
PedalMappingStrip(pedal: pedal, map: controlMappingMap)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||