feat(applet): impl ToString for PanelType
This commit is contained in:
parent
e9aa969e61
commit
fec71fdda4
1 changed files with 10 additions and 0 deletions
|
|
@ -49,6 +49,16 @@ pub enum PanelType {
|
|||
Other(String),
|
||||
}
|
||||
|
||||
impl ToString for PanelType {
|
||||
fn to_string(&self) -> String {
|
||||
match self {
|
||||
Self::Panel => "Panel".to_string(),
|
||||
Self::Dock => "Dock".to_string(),
|
||||
Self::Other(other) => other.clone(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl From<String> for PanelType {
|
||||
fn from(value: String) -> Self {
|
||||
match value.as_str() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue