Add recent media, part of #53
This commit is contained in:
parent
fd1df4f098
commit
0169cccfa2
6 changed files with 144 additions and 9 deletions
|
|
@ -5,6 +5,7 @@ use cosmic::{
|
|||
theme,
|
||||
};
|
||||
use serde::{Deserialize, Serialize};
|
||||
use std::collections::VecDeque;
|
||||
|
||||
pub const CONFIG_VERSION: u64 = 1;
|
||||
|
||||
|
|
@ -38,3 +39,18 @@ impl Default for Config {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Clone, CosmicConfigEntry, Debug, Deserialize, Eq, PartialEq, Serialize)]
|
||||
pub struct ConfigState {
|
||||
pub recent_files: VecDeque<url::Url>,
|
||||
pub recent_folders: VecDeque<url::Url>,
|
||||
}
|
||||
|
||||
impl Default for ConfigState {
|
||||
fn default() -> Self {
|
||||
Self {
|
||||
recent_files: VecDeque::new(),
|
||||
recent_folders: VecDeque::new(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue