Use serde to serialize responses (#96)

This commit is contained in:
TrueDoctor
2021-05-07 02:47:38 -07:00
committed by Keavon Chambers
parent 9ad5f4ce78
commit 721a442b75
13 changed files with 99 additions and 45 deletions
+4 -3
View File
@@ -1,14 +1,15 @@
use crate::LayerId;
use serde::{Deserialize, Serialize};
use std::fmt;
#[derive(Debug, Clone)]
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct LayerPanelEntry {
pub name: String,
pub visible: bool,
pub layer_type: LayerType,
}
#[derive(Debug, Clone)]
#[derive(Debug, Clone, Serialize, Deserialize)]
pub enum LayerType {
Folder,
Shape,
@@ -25,7 +26,7 @@ impl fmt::Display for LayerType {
}
}
#[derive(Debug, Clone)]
#[derive(Debug, Clone, Serialize, Deserialize)]
#[repr(C)]
// TODO - Make Copy when possible
pub enum DocumentResponse {