multiple windows, warnings, updating deps

This commit is contained in:
Andy Pack 2022-12-11 08:27:22 +00:00
parent 32af8e8432
commit 17a7600a9d
Signed by: sarsoo
GPG Key ID: A55BA3536A5E0ED7
6 changed files with 25 additions and 18 deletions

View File

@ -674,10 +674,12 @@
DEVELOPMENT_TEAM = 8UZ2659FDY;
ENABLE_PREVIEWS = YES;
INFOPLIST_FILE = Mixonomer/Info.plist;
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.music";
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 0.1;
PRODUCT_BUNDLE_IDENTIFIER = xyz.sarsoo.Mixonomer;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
@ -701,10 +703,12 @@
DEVELOPMENT_TEAM = 8UZ2659FDY;
ENABLE_PREVIEWS = YES;
INFOPLIST_FILE = Mixonomer/Info.plist;
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.music";
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 0.1;
PRODUCT_BUNDLE_IDENTIFIER = xyz.sarsoo.Mixonomer;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";

View File

@ -5,8 +5,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/alamofire/alamofire.git",
"state" : {
"revision" : "0c8cb78d05b6d067ee331c05058ff4dedcb45ffa",
"version" : "5.0.0"
"revision" : "78424be314842833c04bc3bef5b72e85fff99204",
"version" : "5.6.4"
}
},
{
@ -14,8 +14,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/apppear/chartview",
"state" : {
"revision" : "04989ad159380290a74729dbce1d39d64b893ab2",
"version" : "1.4.9"
"revision" : "9115a992c91fa19cbb4f2241084240d38654a1fc",
"version" : "1.5.5"
}
},
{
@ -23,8 +23,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/kishikawakatsumi/keychainaccess",
"state" : {
"revision" : "b920ad7df3c73189dcdd4aa05c540849b2010dbf",
"version" : "4.1.0"
"revision" : "84e546727d66f1adc5439debad16270d0fdd04e7",
"version" : "4.2.2"
}
},
{
@ -32,8 +32,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/swiftyjson/swiftyjson",
"state" : {
"revision" : "2b6054efa051565954e1d2b9da831680026cd768",
"version" : "5.0.0"
"revision" : "b3dcd7dbd0d488e1a7077cb33b00f2083e382f07",
"version" : "5.0.1"
}
},
{
@ -42,7 +42,7 @@
"location" : "https://github.com/quanshousio/ToastUI",
"state" : {
"branch" : "main",
"revision" : "b064788dd92a64fbd01208a65af10beded99062c"
"revision" : "1828801ea49e2ab900ca5e6bb18245312fda66a2"
}
}
],

View File

@ -13,6 +13,7 @@ import KeychainAccess
class SceneDelegate: UIResponder, UIWindowSceneDelegate {
var window: UIWindow?
private var liveUser: LiveUser?
func scene(_ scene: UIScene, willConnectTo session: UISceneSession, options connectionOptions: UIScene.ConnectionOptions) {
// Use this method to optionally configure and attach the UIWindow `window` to the provided UIWindowScene `scene`.
@ -27,9 +28,9 @@ class SceneDelegate: UIResponder, UIWindowSceneDelegate {
// Use a UIHostingController as window root view controller.
if let windowScene = scene as? UIWindowScene {
let window = UIWindow(windowScene: windowScene)
let liveUser = LiveUser(playlists: [], tags: [], username: keychain["username"] ?? "", loggedIn: false).load_user_defaults()
liveUser = LiveUser(playlists: [], tags: [], username: keychain["username"] ?? "", loggedIn: false).load_user_defaults()
window.rootViewController = UIHostingController(rootView: contentView.environmentObject(liveUser))
window.rootViewController = UIHostingController(rootView: contentView.environmentObject(liveUser!))
self.window = window
window.makeKeyAndVisible()
}

View File

@ -27,7 +27,7 @@
<key>UIApplicationSceneManifest</key>
<dict>
<key>UIApplicationSupportsMultipleScenes</key>
<false/>
<true/>
<key>UISceneConfigurations</key>
<dict>
<key>UIWindowSceneSessionRoleApplication</key>
@ -41,12 +41,12 @@
</array>
</dict>
</dict>
<key>UILaunchStoryboardName</key>
<string>LaunchScreen</string>
<key>UIBackgroundModes</key>
<array>
<string>remote-notification</string>
</array>
<key>UILaunchStoryboardName</key>
<string>LaunchScreen</string>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>armv7</string>

View File

@ -36,7 +36,7 @@ struct UserView: View {
HStack {
Text("Last.fm")
Spacer()
Text(user.lastfm_username ?? "")
Text(user.lastfm_username)
.foregroundColor(.gray)
}
}

View File

@ -27,21 +27,21 @@ struct PlaylistView: View {
var trackChartStyle: ChartStyle {
get {
let _style = ChartStyle(backgroundColor: .white, accentColor: Color(red: 0.4765, green: 0.5976, blue: 0.7578), gradientColor: GradientColors.bluPurpl, textColor: .black, legendTextColor: .gray)
let _style = ChartStyle(backgroundColor: .white, accentColor: Color(red: 0.4765, green: 0.5976, blue: 0.7578), gradientColor: GradientColors.bluPurpl, textColor: .black, legendTextColor: .gray, dropShadowColor: .gray)
return _style
}
}
var albumChartStyle: ChartStyle {
get {
let _style = ChartStyle(backgroundColor: .white, accentColor: Color(red: 0.6367, green: 0.2968, blue: 0.4648), gradientColor: GradientColors.bluPurpl, textColor: .black, legendTextColor: .gray)
let _style = ChartStyle(backgroundColor: .white, accentColor: Color(red: 0.6367, green: 0.2968, blue: 0.4648), gradientColor: GradientColors.bluPurpl, textColor: .black, legendTextColor: .gray, dropShadowColor: .gray)
return _style
}
}
var artistChartStyle: ChartStyle {
get {
let _style = ChartStyle(backgroundColor: .white, accentColor: Color(red: 0.3476, green: 0.5195, blue: 0.3359), gradientColor: GradientColors.bluPurpl, textColor: .black, legendTextColor: .gray)
let _style = ChartStyle(backgroundColor: .white, accentColor: Color(red: 0.3476, green: 0.5195, blue: 0.3359), gradientColor: GradientColors.bluPurpl, textColor: .black, legendTextColor: .gray, dropShadowColor: .gray)
return _style
}
}
@ -234,9 +234,11 @@ struct PlaylistView: View {
}
.navigationBarTitle(Text(playlist.name))
#if os(iOS)
.refreshable {
self.refreshPlaylist()
}
#endif
}
func runPlaylist() {