feat(desktop_entries): Allow selecting gpu/secondary actions on COSMIC

This commit is contained in:
Victoria Brekenfeld 2024-02-01 16:03:03 +01:00 committed by GitHub
parent 0205007463
commit 091581c362
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 692 additions and 229 deletions

View file

@ -54,6 +54,7 @@ pub struct ContextOption {
pub enum GpuPreference {
Default,
NonDefault,
SpecificIdx(u32),
}
#[derive(Debug, Clone, Deserialize, Serialize)]
@ -84,6 +85,8 @@ pub enum PluginResponse {
DesktopEntry {
path: PathBuf,
gpu_preference: GpuPreference,
#[serde(skip_serializing_if = "Option::is_none", default)]
action_name: Option<String>,
},
/// Update the text in the launcher.
Fill(String),
@ -156,6 +159,7 @@ pub enum Response {
DesktopEntry {
path: PathBuf,
gpu_preference: GpuPreference,
action_name: Option<String>,
},
// The frontend should clear its search results and display a new list.
Update(Vec<SearchResult>),