mirror of
https://github.com/yattee/yattee.git
synced 2024-12-14 06:10:32 +05:30
Remove Sparkle update framework
This commit is contained in:
parent
1ae89ee03d
commit
1c0dae4bed
@ -5,7 +5,7 @@ import SwiftUI
|
|||||||
struct SettingsView: View {
|
struct SettingsView: View {
|
||||||
#if os(macOS)
|
#if os(macOS)
|
||||||
private enum Tabs: Hashable {
|
private enum Tabs: Hashable {
|
||||||
case instances, browsing, player, history, sponsorBlock, updates, help
|
case instances, browsing, player, history, sponsorBlock, help
|
||||||
}
|
}
|
||||||
|
|
||||||
@State private var selection = Tabs.instances
|
@State private var selection = Tabs.instances
|
||||||
@ -68,14 +68,6 @@ struct SettingsView: View {
|
|||||||
}
|
}
|
||||||
.tag(Tabs.sponsorBlock)
|
.tag(Tabs.sponsorBlock)
|
||||||
|
|
||||||
Form {
|
|
||||||
UpdatesSettings()
|
|
||||||
}
|
|
||||||
.tabItem {
|
|
||||||
Label("Updates", systemImage: "gearshape.2")
|
|
||||||
}
|
|
||||||
.tag(Tabs.updates)
|
|
||||||
|
|
||||||
Form {
|
Form {
|
||||||
Help()
|
Help()
|
||||||
}
|
}
|
||||||
@ -184,8 +176,6 @@ struct SettingsView: View {
|
|||||||
return 480
|
return 480
|
||||||
case .sponsorBlock:
|
case .sponsorBlock:
|
||||||
return 660
|
return 660
|
||||||
case .updates:
|
|
||||||
return 200
|
|
||||||
case .help:
|
case .help:
|
||||||
return 570
|
return 570
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,6 @@ struct YatteeApp: App {
|
|||||||
|
|
||||||
#if os(macOS)
|
#if os(macOS)
|
||||||
@NSApplicationDelegateAdaptor(AppDelegate.self) var appDelegate
|
@NSApplicationDelegateAdaptor(AppDelegate.self) var appDelegate
|
||||||
@StateObject private var updater = UpdaterModel()
|
|
||||||
#elseif os(iOS)
|
#elseif os(iOS)
|
||||||
@UIApplicationDelegateAdaptor(AppDelegate.self) var appDelegate
|
@UIApplicationDelegateAdaptor(AppDelegate.self) var appDelegate
|
||||||
#endif
|
#endif
|
||||||
@ -80,13 +79,6 @@ struct YatteeApp: App {
|
|||||||
|
|
||||||
CommandGroup(replacing: .newItem, addition: {})
|
CommandGroup(replacing: .newItem, addition: {})
|
||||||
|
|
||||||
#if os(macOS)
|
|
||||||
CommandGroup(after: .appInfo) {
|
|
||||||
CheckForUpdatesView()
|
|
||||||
.environmentObject(updater)
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
MenuCommands(model: Binding<MenuModel>(get: { menu }, set: { _ in }))
|
MenuCommands(model: Binding<MenuModel>(get: { menu }, set: { _ in }))
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@ -134,7 +126,6 @@ struct YatteeApp: App {
|
|||||||
.environmentObject(instances)
|
.environmentObject(instances)
|
||||||
.environmentObject(player)
|
.environmentObject(player)
|
||||||
.environmentObject(playerControls)
|
.environmentObject(playerControls)
|
||||||
.environmentObject(updater)
|
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
@ -63,7 +63,6 @@
|
|||||||
3703100227B0713600ECDDAA /* PlayerGestures.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3703100127B0713600ECDDAA /* PlayerGestures.swift */; };
|
3703100227B0713600ECDDAA /* PlayerGestures.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3703100127B0713600ECDDAA /* PlayerGestures.swift */; };
|
||||||
3703100327B0713600ECDDAA /* PlayerGestures.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3703100127B0713600ECDDAA /* PlayerGestures.swift */; };
|
3703100327B0713600ECDDAA /* PlayerGestures.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3703100127B0713600ECDDAA /* PlayerGestures.swift */; };
|
||||||
3703205827D2BAE4007A0CB8 /* Siesta in Frameworks */ = {isa = PBXBuildFile; productRef = 3703205727D2BAE4007A0CB8 /* Siesta */; };
|
3703205827D2BAE4007A0CB8 /* Siesta in Frameworks */ = {isa = PBXBuildFile; productRef = 3703205727D2BAE4007A0CB8 /* Siesta */; };
|
||||||
3703205A27D2BAE9007A0CB8 /* Sparkle in Frameworks */ = {isa = PBXBuildFile; productRef = 3703205927D2BAE9007A0CB8 /* Sparkle */; };
|
|
||||||
3703205C27D2BAF3007A0CB8 /* SwiftyJSON in Frameworks */ = {isa = PBXBuildFile; productRef = 3703205B27D2BAF3007A0CB8 /* SwiftyJSON */; };
|
3703205C27D2BAF3007A0CB8 /* SwiftyJSON in Frameworks */ = {isa = PBXBuildFile; productRef = 3703205B27D2BAF3007A0CB8 /* SwiftyJSON */; };
|
||||||
3703205E27D2BB12007A0CB8 /* SDWebImageWebPCoder in Frameworks */ = {isa = PBXBuildFile; productRef = 3703205D27D2BB12007A0CB8 /* SDWebImageWebPCoder */; };
|
3703205E27D2BB12007A0CB8 /* SDWebImageWebPCoder in Frameworks */ = {isa = PBXBuildFile; productRef = 3703205D27D2BB12007A0CB8 /* SDWebImageWebPCoder */; };
|
||||||
3703206027D2BB16007A0CB8 /* SDWebImageSwiftUI in Frameworks */ = {isa = PBXBuildFile; productRef = 3703205F27D2BB16007A0CB8 /* SDWebImageSwiftUI */; };
|
3703206027D2BB16007A0CB8 /* SDWebImageSwiftUI in Frameworks */ = {isa = PBXBuildFile; productRef = 3703205F27D2BB16007A0CB8 /* SDWebImageSwiftUI */; };
|
||||||
@ -567,7 +566,6 @@
|
|||||||
37BE0BD726A1D4A90092E2DB /* AppleAVPlayerViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37BE0BD526A1D4A90092E2DB /* AppleAVPlayerViewController.swift */; };
|
37BE0BD726A1D4A90092E2DB /* AppleAVPlayerViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37BE0BD526A1D4A90092E2DB /* AppleAVPlayerViewController.swift */; };
|
||||||
37BE0BDA26A214630092E2DB /* AppleAVPlayerViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37BE0BD926A214630092E2DB /* AppleAVPlayerViewController.swift */; };
|
37BE0BDA26A214630092E2DB /* AppleAVPlayerViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37BE0BD926A214630092E2DB /* AppleAVPlayerViewController.swift */; };
|
||||||
37BE0BDC26A2367F0092E2DB /* AppleAVPlayerView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37BE0BDB26A2367F0092E2DB /* AppleAVPlayerView.swift */; };
|
37BE0BDC26A2367F0092E2DB /* AppleAVPlayerView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37BE0BDB26A2367F0092E2DB /* AppleAVPlayerView.swift */; };
|
||||||
37BE7AF12760013C00DBECED /* UpdatesSettings.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37BE7AF02760013C00DBECED /* UpdatesSettings.swift */; };
|
|
||||||
37BF661C27308859008CCFB0 /* DropFavorite.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37BF661B27308859008CCFB0 /* DropFavorite.swift */; };
|
37BF661C27308859008CCFB0 /* DropFavorite.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37BF661B27308859008CCFB0 /* DropFavorite.swift */; };
|
||||||
37BF661D27308859008CCFB0 /* DropFavorite.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37BF661B27308859008CCFB0 /* DropFavorite.swift */; };
|
37BF661D27308859008CCFB0 /* DropFavorite.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37BF661B27308859008CCFB0 /* DropFavorite.swift */; };
|
||||||
37BF661F27308884008CCFB0 /* DropFavoriteOutside.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37BF661E27308884008CCFB0 /* DropFavoriteOutside.swift */; };
|
37BF661F27308884008CCFB0 /* DropFavoriteOutside.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37BF661E27308884008CCFB0 /* DropFavoriteOutside.swift */; };
|
||||||
@ -611,8 +609,6 @@
|
|||||||
37C7A1D6267BFD9D0010EAD6 /* SponsorBlockSegment.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37C7A1D4267BFD9D0010EAD6 /* SponsorBlockSegment.swift */; };
|
37C7A1D6267BFD9D0010EAD6 /* SponsorBlockSegment.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37C7A1D4267BFD9D0010EAD6 /* SponsorBlockSegment.swift */; };
|
||||||
37C7A1D7267BFD9D0010EAD6 /* SponsorBlockSegment.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37C7A1D4267BFD9D0010EAD6 /* SponsorBlockSegment.swift */; };
|
37C7A1D7267BFD9D0010EAD6 /* SponsorBlockSegment.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37C7A1D4267BFD9D0010EAD6 /* SponsorBlockSegment.swift */; };
|
||||||
37C7A1DA267CACF50010EAD6 /* TrendingCountry.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3705B17F267B4DFB00704544 /* TrendingCountry.swift */; };
|
37C7A1DA267CACF50010EAD6 /* TrendingCountry.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3705B17F267B4DFB00704544 /* TrendingCountry.swift */; };
|
||||||
37C90AF1275F9D450015EAF7 /* UpdaterModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37C90AF0275F9D450015EAF7 /* UpdaterModel.swift */; };
|
|
||||||
37C90AF3275F9D5D0015EAF7 /* CheckForUpdatesView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37C90AF2275F9D5D0015EAF7 /* CheckForUpdatesView.swift */; };
|
|
||||||
37CB12792724C76D00213B45 /* VideoURLParser.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37CB12782724C76D00213B45 /* VideoURLParser.swift */; };
|
37CB12792724C76D00213B45 /* VideoURLParser.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37CB12782724C76D00213B45 /* VideoURLParser.swift */; };
|
||||||
37CB127A2724C76D00213B45 /* VideoURLParser.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37CB12782724C76D00213B45 /* VideoURLParser.swift */; };
|
37CB127A2724C76D00213B45 /* VideoURLParser.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37CB12782724C76D00213B45 /* VideoURLParser.swift */; };
|
||||||
37CB128B2724CC1F00213B45 /* VideoURLParserTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37CB127B2724C79D00213B45 /* VideoURLParserTests.swift */; };
|
37CB128B2724CC1F00213B45 /* VideoURLParserTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37CB127B2724C79D00213B45 /* VideoURLParserTests.swift */; };
|
||||||
@ -1024,7 +1020,6 @@
|
|||||||
37BE0BD526A1D4A90092E2DB /* AppleAVPlayerViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppleAVPlayerViewController.swift; sourceTree = "<group>"; };
|
37BE0BD526A1D4A90092E2DB /* AppleAVPlayerViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppleAVPlayerViewController.swift; sourceTree = "<group>"; };
|
||||||
37BE0BD926A214630092E2DB /* AppleAVPlayerViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppleAVPlayerViewController.swift; sourceTree = "<group>"; };
|
37BE0BD926A214630092E2DB /* AppleAVPlayerViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppleAVPlayerViewController.swift; sourceTree = "<group>"; };
|
||||||
37BE0BDB26A2367F0092E2DB /* AppleAVPlayerView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppleAVPlayerView.swift; sourceTree = "<group>"; };
|
37BE0BDB26A2367F0092E2DB /* AppleAVPlayerView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppleAVPlayerView.swift; sourceTree = "<group>"; };
|
||||||
37BE7AF02760013C00DBECED /* UpdatesSettings.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = UpdatesSettings.swift; sourceTree = "<group>"; };
|
|
||||||
37BF661B27308859008CCFB0 /* DropFavorite.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DropFavorite.swift; sourceTree = "<group>"; };
|
37BF661B27308859008CCFB0 /* DropFavorite.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DropFavorite.swift; sourceTree = "<group>"; };
|
||||||
37BF661E27308884008CCFB0 /* DropFavoriteOutside.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DropFavoriteOutside.swift; sourceTree = "<group>"; };
|
37BF661E27308884008CCFB0 /* DropFavoriteOutside.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DropFavoriteOutside.swift; sourceTree = "<group>"; };
|
||||||
37C069772725962F00F7F6CB /* ScreenSaverManager.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ScreenSaverManager.swift; sourceTree = "<group>"; };
|
37C069772725962F00F7F6CB /* ScreenSaverManager.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ScreenSaverManager.swift; sourceTree = "<group>"; };
|
||||||
@ -1048,8 +1043,6 @@
|
|||||||
37C3A24C272360470087A57A /* ChannelPlaylist+Fixtures.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "ChannelPlaylist+Fixtures.swift"; sourceTree = "<group>"; };
|
37C3A24C272360470087A57A /* ChannelPlaylist+Fixtures.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "ChannelPlaylist+Fixtures.swift"; sourceTree = "<group>"; };
|
||||||
37C3A250272366440087A57A /* ChannelPlaylistView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ChannelPlaylistView.swift; sourceTree = "<group>"; };
|
37C3A250272366440087A57A /* ChannelPlaylistView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ChannelPlaylistView.swift; sourceTree = "<group>"; };
|
||||||
37C7A1D4267BFD9D0010EAD6 /* SponsorBlockSegment.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SponsorBlockSegment.swift; sourceTree = "<group>"; };
|
37C7A1D4267BFD9D0010EAD6 /* SponsorBlockSegment.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SponsorBlockSegment.swift; sourceTree = "<group>"; };
|
||||||
37C90AF0275F9D450015EAF7 /* UpdaterModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = UpdaterModel.swift; sourceTree = "<group>"; };
|
|
||||||
37C90AF2275F9D5D0015EAF7 /* CheckForUpdatesView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CheckForUpdatesView.swift; sourceTree = "<group>"; };
|
|
||||||
37CB12782724C76D00213B45 /* VideoURLParser.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = VideoURLParser.swift; sourceTree = "<group>"; };
|
37CB12782724C76D00213B45 /* VideoURLParser.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = VideoURLParser.swift; sourceTree = "<group>"; };
|
||||||
37CB127B2724C79D00213B45 /* VideoURLParserTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = VideoURLParserTests.swift; sourceTree = "<group>"; };
|
37CB127B2724C79D00213B45 /* VideoURLParserTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = VideoURLParserTests.swift; sourceTree = "<group>"; };
|
||||||
37CC3F44270CE30600608308 /* PlayerQueueItem.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PlayerQueueItem.swift; sourceTree = "<group>"; };
|
37CC3F44270CE30600608308 /* PlayerQueueItem.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PlayerQueueItem.swift; sourceTree = "<group>"; };
|
||||||
@ -1178,7 +1171,6 @@
|
|||||||
370F4FE127CC16CB001B35DC /* libuchardet.0.0.7.dylib in Frameworks */,
|
370F4FE127CC16CB001B35DC /* libuchardet.0.0.7.dylib in Frameworks */,
|
||||||
370F4FDB27CC16CB001B35DC /* libswscale.6.4.100.dylib in Frameworks */,
|
370F4FDB27CC16CB001B35DC /* libswscale.6.4.100.dylib in Frameworks */,
|
||||||
370F4FDC27CC16CB001B35DC /* libavutil.57.17.100.dylib in Frameworks */,
|
370F4FDC27CC16CB001B35DC /* libavutil.57.17.100.dylib in Frameworks */,
|
||||||
3703205A27D2BAE9007A0CB8 /* Sparkle in Frameworks */,
|
|
||||||
370F4FE327CC16CB001B35DC /* libbrotlicommon.1.dylib in Frameworks */,
|
370F4FE327CC16CB001B35DC /* libbrotlicommon.1.dylib in Frameworks */,
|
||||||
3703205827D2BAE4007A0CB8 /* Siesta in Frameworks */,
|
3703205827D2BAE4007A0CB8 /* Siesta in Frameworks */,
|
||||||
370F4FD127CC16CB001B35DC /* libavfilter.8.24.100.dylib in Frameworks */,
|
370F4FD127CC16CB001B35DC /* libavfilter.8.24.100.dylib in Frameworks */,
|
||||||
@ -1703,7 +1695,6 @@
|
|||||||
37BE0BD826A214500092E2DB /* macOS */ = {
|
37BE0BD826A214500092E2DB /* macOS */ = {
|
||||||
isa = PBXGroup;
|
isa = PBXGroup;
|
||||||
children = (
|
children = (
|
||||||
37BE7AF227601DBF00DBECED /* Updates */,
|
|
||||||
374C0542272496E4009BDDBE /* AppDelegate.swift */,
|
374C0542272496E4009BDDBE /* AppDelegate.swift */,
|
||||||
37BE0BDB26A2367F0092E2DB /* AppleAVPlayerView.swift */,
|
37BE0BDB26A2367F0092E2DB /* AppleAVPlayerView.swift */,
|
||||||
37BE0BD926A214630092E2DB /* AppleAVPlayerViewController.swift */,
|
37BE0BD926A214630092E2DB /* AppleAVPlayerViewController.swift */,
|
||||||
@ -1719,16 +1710,6 @@
|
|||||||
path = macOS;
|
path = macOS;
|
||||||
sourceTree = "<group>";
|
sourceTree = "<group>";
|
||||||
};
|
};
|
||||||
37BE7AF227601DBF00DBECED /* Updates */ = {
|
|
||||||
isa = PBXGroup;
|
|
||||||
children = (
|
|
||||||
37C90AF2275F9D5D0015EAF7 /* CheckForUpdatesView.swift */,
|
|
||||||
37C90AF0275F9D450015EAF7 /* UpdaterModel.swift */,
|
|
||||||
37BE7AF02760013C00DBECED /* UpdatesSettings.swift */,
|
|
||||||
);
|
|
||||||
path = Updates;
|
|
||||||
sourceTree = "<group>";
|
|
||||||
};
|
|
||||||
37C7A9022679058300E721B4 /* Extensions */ = {
|
37C7A9022679058300E721B4 /* Extensions */ = {
|
||||||
isa = PBXGroup;
|
isa = PBXGroup;
|
||||||
children = (
|
children = (
|
||||||
@ -2091,7 +2072,6 @@
|
|||||||
name = "Yattee (macOS)";
|
name = "Yattee (macOS)";
|
||||||
packageProductDependencies = (
|
packageProductDependencies = (
|
||||||
3703205727D2BAE4007A0CB8 /* Siesta */,
|
3703205727D2BAE4007A0CB8 /* Siesta */,
|
||||||
3703205927D2BAE9007A0CB8 /* Sparkle */,
|
|
||||||
3703205B27D2BAF3007A0CB8 /* SwiftyJSON */,
|
3703205B27D2BAF3007A0CB8 /* SwiftyJSON */,
|
||||||
3703205D27D2BB12007A0CB8 /* SDWebImageWebPCoder */,
|
3703205D27D2BB12007A0CB8 /* SDWebImageWebPCoder */,
|
||||||
3703205F27D2BB16007A0CB8 /* SDWebImageSwiftUI */,
|
3703205F27D2BB16007A0CB8 /* SDWebImageSwiftUI */,
|
||||||
@ -2265,7 +2245,6 @@
|
|||||||
37FB2847272207F000A57617 /* XCRemoteSwiftPackageReference "SDWebImageWebPCoder" */,
|
37FB2847272207F000A57617 /* XCRemoteSwiftPackageReference "SDWebImageWebPCoder" */,
|
||||||
37FB285227220D8400A57617 /* XCRemoteSwiftPackageReference "SDWebImagePINPlugin" */,
|
37FB285227220D8400A57617 /* XCRemoteSwiftPackageReference "SDWebImagePINPlugin" */,
|
||||||
3765917827237D07009F956E /* XCRemoteSwiftPackageReference "PINCache" */,
|
3765917827237D07009F956E /* XCRemoteSwiftPackageReference "PINCache" */,
|
||||||
37C90AED275F9CC00015EAF7 /* XCRemoteSwiftPackageReference "Sparkle" */,
|
|
||||||
37ABBC53284FDACE003DC934 /* XCRemoteSwiftPackageReference "SDWebImage" */,
|
37ABBC53284FDACE003DC934 /* XCRemoteSwiftPackageReference "SDWebImage" */,
|
||||||
);
|
);
|
||||||
productRefGroup = 37D4B0CA2671614900C925CA /* Products */;
|
productRefGroup = 37D4B0CA2671614900C925CA /* Products */;
|
||||||
@ -2719,7 +2698,6 @@
|
|||||||
3788AC2826F6840700F6BAA9 /* FavoriteItemView.swift in Sources */,
|
3788AC2826F6840700F6BAA9 /* FavoriteItemView.swift in Sources */,
|
||||||
378AE93A274EDFAF006A4EE1 /* Badge+Backport.swift in Sources */,
|
378AE93A274EDFAF006A4EE1 /* Badge+Backport.swift in Sources */,
|
||||||
37599F35272B44000087F250 /* FavoritesModel.swift in Sources */,
|
37599F35272B44000087F250 /* FavoritesModel.swift in Sources */,
|
||||||
37C90AF3275F9D5D0015EAF7 /* CheckForUpdatesView.swift in Sources */,
|
|
||||||
37F64FE526FE70A60081B69E /* RedrawOnModifier.swift in Sources */,
|
37F64FE526FE70A60081B69E /* RedrawOnModifier.swift in Sources */,
|
||||||
3795593727B08538007FF8F4 /* StreamControl.swift in Sources */,
|
3795593727B08538007FF8F4 /* StreamControl.swift in Sources */,
|
||||||
37FFC441272734C3009FFD26 /* Throttle.swift in Sources */,
|
37FFC441272734C3009FFD26 /* Throttle.swift in Sources */,
|
||||||
@ -2737,7 +2715,6 @@
|
|||||||
37BC50AD2778BCBA00510953 /* HistoryModel.swift in Sources */,
|
37BC50AD2778BCBA00510953 /* HistoryModel.swift in Sources */,
|
||||||
37030FF827B0347C00ECDDAA /* MPVPlayerView.swift in Sources */,
|
37030FF827B0347C00ECDDAA /* MPVPlayerView.swift in Sources */,
|
||||||
378E50FC26FE8B9F00F49626 /* Instance.swift in Sources */,
|
378E50FC26FE8B9F00F49626 /* Instance.swift in Sources */,
|
||||||
37BE7AF12760013C00DBECED /* UpdatesSettings.swift in Sources */,
|
|
||||||
37169AA32729D98A0011DE61 /* InstancesBridge.swift in Sources */,
|
37169AA32729D98A0011DE61 /* InstancesBridge.swift in Sources */,
|
||||||
37B044B826F7AB9000E1419D /* SettingsView.swift in Sources */,
|
37B044B826F7AB9000E1419D /* SettingsView.swift in Sources */,
|
||||||
3765788A2685471400D4EA09 /* Playlist.swift in Sources */,
|
3765788A2685471400D4EA09 /* Playlist.swift in Sources */,
|
||||||
@ -2760,7 +2737,6 @@
|
|||||||
372915E72687E3B900F5A35B /* Defaults.swift in Sources */,
|
372915E72687E3B900F5A35B /* Defaults.swift in Sources */,
|
||||||
37C3A242272359900087A57A /* Double+Format.swift in Sources */,
|
37C3A242272359900087A57A /* Double+Format.swift in Sources */,
|
||||||
37B795912771DAE0001CF27B /* OpenURLHandler.swift in Sources */,
|
37B795912771DAE0001CF27B /* OpenURLHandler.swift in Sources */,
|
||||||
37C90AF1275F9D450015EAF7 /* UpdaterModel.swift in Sources */,
|
|
||||||
37DD87C8271C9CFE0027CBF9 /* PlayerStreams.swift in Sources */,
|
37DD87C8271C9CFE0027CBF9 /* PlayerStreams.swift in Sources */,
|
||||||
376578922685490700D4EA09 /* PlaylistsView.swift in Sources */,
|
376578922685490700D4EA09 /* PlaylistsView.swift in Sources */,
|
||||||
371114F027B951B800C2EF7B /* ToggleBackendButton.swift in Sources */,
|
371114F027B951B800C2EF7B /* ToggleBackendButton.swift in Sources */,
|
||||||
@ -3958,14 +3934,6 @@
|
|||||||
minimumVersion = 0.1.3;
|
minimumVersion = 0.1.3;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
37C90AED275F9CC00015EAF7 /* XCRemoteSwiftPackageReference "Sparkle" */ = {
|
|
||||||
isa = XCRemoteSwiftPackageReference;
|
|
||||||
repositoryURL = "https://github.com/sparkle-project/Sparkle";
|
|
||||||
requirement = {
|
|
||||||
branch = 2.x;
|
|
||||||
kind = branch;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
37D4B19B2671817900C925CA /* XCRemoteSwiftPackageReference "SwiftyJSON" */ = {
|
37D4B19B2671817900C925CA /* XCRemoteSwiftPackageReference "SwiftyJSON" */ = {
|
||||||
isa = XCRemoteSwiftPackageReference;
|
isa = XCRemoteSwiftPackageReference;
|
||||||
repositoryURL = "https://github.com/SwiftyJSON/SwiftyJSON.git";
|
repositoryURL = "https://github.com/SwiftyJSON/SwiftyJSON.git";
|
||||||
@ -4006,11 +3974,6 @@
|
|||||||
package = 3797757B268922D100DD52A8 /* XCRemoteSwiftPackageReference "siesta" */;
|
package = 3797757B268922D100DD52A8 /* XCRemoteSwiftPackageReference "siesta" */;
|
||||||
productName = Siesta;
|
productName = Siesta;
|
||||||
};
|
};
|
||||||
3703205927D2BAE9007A0CB8 /* Sparkle */ = {
|
|
||||||
isa = XCSwiftPackageProductDependency;
|
|
||||||
package = 37C90AED275F9CC00015EAF7 /* XCRemoteSwiftPackageReference "Sparkle" */;
|
|
||||||
productName = Sparkle;
|
|
||||||
};
|
|
||||||
3703205B27D2BAF3007A0CB8 /* SwiftyJSON */ = {
|
3703205B27D2BAF3007A0CB8 /* SwiftyJSON */ = {
|
||||||
isa = XCSwiftPackageProductDependency;
|
isa = XCSwiftPackageProductDependency;
|
||||||
package = 37D4B19B2671817900C925CA /* XCRemoteSwiftPackageReference "SwiftyJSON" */;
|
package = 37D4B19B2671817900C925CA /* XCRemoteSwiftPackageReference "SwiftyJSON" */;
|
||||||
|
@ -90,15 +90,6 @@
|
|||||||
"version" : "1.5.2"
|
"version" : "1.5.2"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"identity" : "sparkle",
|
|
||||||
"kind" : "remoteSourceControl",
|
|
||||||
"location" : "https://github.com/sparkle-project/Sparkle",
|
|
||||||
"state" : {
|
|
||||||
"branch" : "2.x",
|
|
||||||
"revision" : "2c81393ec25a463c393f4a04ae4405571df0291d"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"identity" : "swift-log",
|
"identity" : "swift-log",
|
||||||
"kind" : "remoteSourceControl",
|
"kind" : "remoteSourceControl",
|
||||||
|
@ -1,10 +0,0 @@
|
|||||||
import SwiftUI
|
|
||||||
|
|
||||||
struct CheckForUpdatesView: View {
|
|
||||||
@EnvironmentObject<UpdaterModel> private var updater
|
|
||||||
|
|
||||||
var body: some View {
|
|
||||||
Button("Check For Updates…", action: updater.checkForUpdates)
|
|
||||||
.disabled(!updater.canCheckForUpdates)
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,41 +0,0 @@
|
|||||||
import Defaults
|
|
||||||
import Sparkle
|
|
||||||
import SwiftUI
|
|
||||||
|
|
||||||
final class UpdaterModel: ObservableObject {
|
|
||||||
@Published var canCheckForUpdates = false
|
|
||||||
|
|
||||||
private let updaterController: SPUStandardUpdaterController
|
|
||||||
private let updaterDelegate = UpdaterDelegate()
|
|
||||||
|
|
||||||
init() {
|
|
||||||
updaterController = SPUStandardUpdaterController(
|
|
||||||
startingUpdater: true,
|
|
||||||
updaterDelegate: updaterDelegate,
|
|
||||||
userDriverDelegate: nil
|
|
||||||
)
|
|
||||||
|
|
||||||
updaterController.updater.publisher(for: \.canCheckForUpdates)
|
|
||||||
.assign(to: &$canCheckForUpdates)
|
|
||||||
}
|
|
||||||
|
|
||||||
func checkForUpdates() {
|
|
||||||
updaterController.checkForUpdates(nil)
|
|
||||||
}
|
|
||||||
|
|
||||||
var automaticallyChecksForUpdates: Bool {
|
|
||||||
updaterController.updater.automaticallyChecksForUpdates
|
|
||||||
}
|
|
||||||
|
|
||||||
func setAutomaticallyChecksForUpdates(_ value: Bool) {
|
|
||||||
updaterController.updater.automaticallyChecksForUpdates = value
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
final class UpdaterDelegate: NSObject, SPUUpdaterDelegate {
|
|
||||||
@Default(.enableBetaChannel) private var enableBetaChannel
|
|
||||||
|
|
||||||
func allowedChannels(for _: SPUUpdater) -> Set<String> {
|
|
||||||
Set(enableBetaChannel ? ["beta"] : [])
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,37 +0,0 @@
|
|||||||
import Defaults
|
|
||||||
import SwiftUI
|
|
||||||
|
|
||||||
struct UpdatesSettings: View {
|
|
||||||
@EnvironmentObject<UpdaterModel> private var updater
|
|
||||||
|
|
||||||
@State private var automaticallyChecksForUpdates = false
|
|
||||||
@Default(.enableBetaChannel) private var enableBetaChannel
|
|
||||||
|
|
||||||
var body: some View {
|
|
||||||
Section(header: SettingsHeader(text: "Updates")) {
|
|
||||||
Toggle("Check automatically", isOn: $automaticallyChecksForUpdates)
|
|
||||||
Toggle("Enable beta channel", isOn: $enableBetaChannel)
|
|
||||||
}
|
|
||||||
.onAppear {
|
|
||||||
automaticallyChecksForUpdates = updater.automaticallyChecksForUpdates
|
|
||||||
}
|
|
||||||
.onChange(of: automaticallyChecksForUpdates) { _ in
|
|
||||||
updater.setAutomaticallyChecksForUpdates(automaticallyChecksForUpdates)
|
|
||||||
}
|
|
||||||
.frame(maxWidth: .infinity, alignment: .leading)
|
|
||||||
|
|
||||||
Spacer()
|
|
||||||
|
|
||||||
Text("Yattee \(YatteeApp.version) (build \(YatteeApp.build))")
|
|
||||||
.foregroundColor(.secondary)
|
|
||||||
|
|
||||||
CheckForUpdatesView()
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
struct UpdatesSettings_Previews: PreviewProvider {
|
|
||||||
static var previews: some View {
|
|
||||||
UpdatesSettings()
|
|
||||||
.injectFixtureEnvironmentObjects()
|
|
||||||
}
|
|
||||||
}
|
|
Loading…
Reference in New Issue
Block a user