Skip to content

Commit d04bf9b

Browse files
committed
refactor: 移除依赖项特性编辑器和选择器,简化应用数据结构
feat: 更新构建配置方法,添加菜单配置选项
1 parent cd0c29c commit d04bf9b

File tree

8 files changed

+12
-478
lines changed

8 files changed

+12
-478
lines changed

jkconfig/src/data/app_data.rs

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,6 @@ pub struct AppData {
3030
pub user_data: HashMap<String, String>,
3131
pub temp_data: Option<(String, serde_json::Value)>,
3232
pub elem_hocks: Vec<ElemHock>,
33-
pub features_callback: Option<Arc<dyn Fn() -> Vec<String> + Send + Sync>>,
34-
pub depend_features_callback:
35-
Option<Arc<dyn Fn() -> HashMap<String, Vec<String>> + Send + Sync>>,
3633
}
3734

3835
const DEFAULT_CONFIG_PATH: &str = ".config.toml";
@@ -114,8 +111,6 @@ impl AppData {
114111
needs_save: false,
115112
config: init_value_path.into(),
116113
temp_data: None,
117-
features_callback: None,
118-
depend_features_callback: None,
119114
elem_hocks: Vec::new(),
120115
user_data: HashMap::new(),
121116
})
@@ -156,8 +151,6 @@ impl AppData {
156151
needs_save: false,
157152
config: init_value_path,
158153
temp_data: None,
159-
features_callback: None,
160-
depend_features_callback: None,
161154
elem_hocks: Vec::new(),
162155
user_data: HashMap::new(),
163156
})

jkconfig/src/ui/components/editors/depend_features_editor.rs

Lines changed: 0 additions & 147 deletions
This file was deleted.

jkconfig/src/ui/components/editors/depend_select_editor.rs

Lines changed: 0 additions & 140 deletions
This file was deleted.

jkconfig/src/ui/components/editors/mod.rs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
pub mod array_editor;
2-
pub mod depend_features_editor;
3-
pub mod depend_select_editor;
42
pub mod enum_editor;
53
mod feature_select;
64
pub mod integer_editor;
@@ -10,8 +8,6 @@ pub mod oneof_editor;
108
pub mod string_editor;
119

1210
pub use array_editor::show_array_edit;
13-
pub use depend_features_editor::show_depend_features_editor;
14-
pub use depend_select_editor::show_depend_select;
1511
pub use enum_editor::{show_enum_select, show_list_select};
1612
pub use feature_select::show_feature_select;
1713
pub use integer_editor::show_integer_edit;

0 commit comments

Comments
 (0)