feat: Add Radio context type to backend playback context system
This commit is contained in:
1 parent
04cd97385a
commit
ba4f7af909
2 files changed
+3
No files matched your search
@@ -29,6 +29,7 @@ pub fn set_playback_context(
|
||||
"home_list" => ContextType::HomeList,
|
||||
"favorites" => ContextType::Favorites,
|
||||
"local_library" => ContextType::LocalLibrary,
|
||||
"radio" => ContextType::Radio,
|
||||
_ => return Err(format!("Invalid context type: {}", context_type)),
|
||||
};
|
||||
|
||||
|
||||
@@ -23,6 +23,7 @@ pub enum ContextType {
|
||||
HomeList,
|
||||
Favorites,
|
||||
LocalLibrary,
|
||||
Radio,
|
||||
}
|
||||
|
||||
/// Source of the content (Qobuz or Local Library)
|
||||
@@ -122,6 +123,7 @@ impl PlaybackContext {
|
||||
ContextType::HomeList => "Home List",
|
||||
ContextType::Favorites => "Favorites",
|
||||
ContextType::LocalLibrary => "Local Library",
|
||||
ContextType::Radio => "Radio",
|
||||
};
|
||||
format!("{} · {}", type_str, self.label)
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user