progress
This commit is contained in:
+9
-2
@@ -13,7 +13,7 @@ use egui_file::DialogType;
|
||||
use object::ObjectInstance;
|
||||
use template::{FieldType, Template};
|
||||
|
||||
use crate::{explorer::Explorer, note::Note};
|
||||
use crate::{explorer::Explorer, main_editor::MainEditor, note::Note};
|
||||
|
||||
static PROJECT_FOLDER: LazyLock<PathBuf> = LazyLock::new(|| {
|
||||
let mut path = std::env::current_dir().unwrap();
|
||||
@@ -147,14 +147,21 @@ impl eframe::App for Interface {
|
||||
ui.separator();
|
||||
|
||||
let mut to_load: Option<RightPanelContent> = None;
|
||||
let mut load_doc: Option<MainEditor> = None;
|
||||
|
||||
ScrollArea::vertical().show(ui, |ui| {
|
||||
self.explorer.ui(&mut to_load, ui);
|
||||
self.explorer.ui(&mut to_load, &mut load_doc, ui);
|
||||
});
|
||||
|
||||
if let Some(to_load) = to_load {
|
||||
self.right_panel_content = to_load;
|
||||
}
|
||||
|
||||
if let Some(load_doc) = load_doc {
|
||||
self.editor = load_doc;
|
||||
self.editor.show_editor = true;
|
||||
self.editor.show_preview = true;
|
||||
}
|
||||
});
|
||||
|
||||
// Main content area
|
||||
|
||||
Reference in New Issue
Block a user