mirror of
https://github.com/yattee/yattee.git
synced 2026-05-13 02:45:03 +00:00
Use menu picker style for tvOS view options sheets
This commit is contained in:
@@ -55,7 +55,7 @@ struct ViewOptionsSheet: View {
|
|||||||
.pickerStyle(.segmented)
|
.pickerStyle(.segmented)
|
||||||
|
|
||||||
if layout == .list {
|
if layout == .list {
|
||||||
Picker("viewOptions.rowSize", selection: $rowStyle) {
|
PlatformMenuPicker(String(localized: "viewOptions.rowSize"), selection: $rowStyle) {
|
||||||
Text("viewOptions.rowSize.compact").tag(VideoRowStyle.compact)
|
Text("viewOptions.rowSize.compact").tag(VideoRowStyle.compact)
|
||||||
Text("viewOptions.rowSize.regular").tag(VideoRowStyle.regular)
|
Text("viewOptions.rowSize.regular").tag(VideoRowStyle.regular)
|
||||||
Text("viewOptions.rowSize.large").tag(VideoRowStyle.large)
|
Text("viewOptions.rowSize.large").tag(VideoRowStyle.large)
|
||||||
@@ -76,7 +76,7 @@ struct ViewOptionsSheet: View {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if let channelStripSize = channelStripSize {
|
if let channelStripSize = channelStripSize {
|
||||||
Picker("viewOptions.channelStrip", selection: channelStripSize) {
|
PlatformMenuPicker(String(localized: "viewOptions.channelStrip"), selection: channelStripSize) {
|
||||||
ForEach(ChannelStripSize.allCases, id: \.self) { size in
|
ForEach(ChannelStripSize.allCases, id: \.self) { size in
|
||||||
Text(size.displayName).tag(size)
|
Text(size.displayName).tag(size)
|
||||||
}
|
}
|
||||||
@@ -112,7 +112,7 @@ struct ViewOptionsSheet: View {
|
|||||||
|
|
||||||
// List-specific options
|
// List-specific options
|
||||||
if layout == .list {
|
if layout == .list {
|
||||||
Picker("viewOptions.rowSize", selection: $rowStyle) {
|
PlatformMenuPicker(String(localized: "viewOptions.rowSize"), selection: $rowStyle) {
|
||||||
Text("viewOptions.rowSize.compact").tag(VideoRowStyle.compact)
|
Text("viewOptions.rowSize.compact").tag(VideoRowStyle.compact)
|
||||||
Text("viewOptions.rowSize.regular").tag(VideoRowStyle.regular)
|
Text("viewOptions.rowSize.regular").tag(VideoRowStyle.regular)
|
||||||
Text("viewOptions.rowSize.large").tag(VideoRowStyle.large)
|
Text("viewOptions.rowSize.large").tag(VideoRowStyle.large)
|
||||||
@@ -143,7 +143,7 @@ struct ViewOptionsSheet: View {
|
|||||||
|
|
||||||
// Channel Strip (subscriptions only)
|
// Channel Strip (subscriptions only)
|
||||||
if let channelStripSize = channelStripSize {
|
if let channelStripSize = channelStripSize {
|
||||||
Picker("viewOptions.channelStrip", selection: channelStripSize) {
|
PlatformMenuPicker(String(localized: "viewOptions.channelStrip"), selection: channelStripSize) {
|
||||||
ForEach(ChannelStripSize.allCases, id: \.self) { size in
|
ForEach(ChannelStripSize.allCases, id: \.self) { size in
|
||||||
Text(size.displayName).tag(size)
|
Text(size.displayName).tag(size)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ struct MediaBrowserViewOptionsSheet: View {
|
|||||||
Form {
|
Form {
|
||||||
Section {
|
Section {
|
||||||
Toggle("mediaBrowser.viewOptions.showOnlyPlayable", isOn: $showOnlyPlayable)
|
Toggle("mediaBrowser.viewOptions.showOnlyPlayable", isOn: $showOnlyPlayable)
|
||||||
Picker("mediaBrowser.viewOptions.sortBy", selection: $sortOrder) {
|
PlatformMenuPicker(String(localized: "mediaBrowser.viewOptions.sortBy"), selection: $sortOrder) {
|
||||||
ForEach(availableSortOptions) { order in
|
ForEach(availableSortOptions) { order in
|
||||||
Label(order.displayName, systemImage: order.systemImage)
|
Label(order.displayName, systemImage: order.systemImage)
|
||||||
.tag(order)
|
.tag(order)
|
||||||
|
|||||||
@@ -135,7 +135,7 @@ struct ManageChannelsView: View {
|
|||||||
|
|
||||||
// List-specific options
|
// List-specific options
|
||||||
if layout == .list {
|
if layout == .list {
|
||||||
Picker("viewOptions.rowSize", selection: $rowStyle) {
|
PlatformMenuPicker(String(localized: "viewOptions.rowSize"), selection: $rowStyle) {
|
||||||
Text("viewOptions.rowSize.compact").tag(VideoRowStyle.compact)
|
Text("viewOptions.rowSize.compact").tag(VideoRowStyle.compact)
|
||||||
Text("viewOptions.rowSize.regular").tag(VideoRowStyle.regular)
|
Text("viewOptions.rowSize.regular").tag(VideoRowStyle.regular)
|
||||||
Text("viewOptions.rowSize.large").tag(VideoRowStyle.large)
|
Text("viewOptions.rowSize.large").tag(VideoRowStyle.large)
|
||||||
@@ -160,7 +160,7 @@ struct ManageChannelsView: View {
|
|||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
Picker("manageChannels.sortBy", selection: $sortOrder) {
|
PlatformMenuPicker(String(localized: "manageChannels.sortBy"), selection: $sortOrder) {
|
||||||
Text("manageChannels.sortBy.name").tag(SidebarChannelSort.alphabetical)
|
Text("manageChannels.sortBy.name").tag(SidebarChannelSort.alphabetical)
|
||||||
Text("manageChannels.sortBy.recentlySubscribed").tag(SidebarChannelSort.recentlySubscribed)
|
Text("manageChannels.sortBy.recentlySubscribed").tag(SidebarChannelSort.recentlySubscribed)
|
||||||
Text("manageChannels.sortBy.lastUploaded").tag(SidebarChannelSort.lastUploaded)
|
Text("manageChannels.sortBy.lastUploaded").tag(SidebarChannelSort.lastUploaded)
|
||||||
|
|||||||
@@ -284,7 +284,7 @@ struct SubscriptionsView: View {
|
|||||||
|
|
||||||
// List-specific options
|
// List-specific options
|
||||||
if layout == .list {
|
if layout == .list {
|
||||||
Picker("viewOptions.rowSize", selection: $rowStyle) {
|
PlatformMenuPicker(String(localized: "viewOptions.rowSize"), selection: $rowStyle) {
|
||||||
Text("viewOptions.rowSize.compact").tag(VideoRowStyle.compact)
|
Text("viewOptions.rowSize.compact").tag(VideoRowStyle.compact)
|
||||||
Text("viewOptions.rowSize.regular").tag(VideoRowStyle.regular)
|
Text("viewOptions.rowSize.regular").tag(VideoRowStyle.regular)
|
||||||
Text("viewOptions.rowSize.large").tag(VideoRowStyle.large)
|
Text("viewOptions.rowSize.large").tag(VideoRowStyle.large)
|
||||||
|
|||||||
Reference in New Issue
Block a user