Render a context menu when right-clicking in project panel

It doesn't currently do anything, but I managed to get it rendering in an absolutely positioned way.
This commit is contained in:
Nathan Sobo
2022-05-26 09:59:25 +02:00
committed by Antonio Scandurra
parent f4d13ef596
commit b110fd5fb7
23 changed files with 260 additions and 91 deletions
+9
View File
@@ -226,6 +226,7 @@ pub struct ProjectPanel {
pub ignored_entry_fade: f32,
pub filename_editor: FieldEditor,
pub indent_width: f32,
pub context_menu: ContextMenu,
}
#[derive(Clone, Debug, Deserialize, Default)]
@@ -239,6 +240,14 @@ pub struct ProjectPanelEntry {
pub icon_spacing: f32,
}
#[derive(Clone, Debug, Deserialize, Default)]
pub struct ContextMenu {
pub width: f32,
#[serde(flatten)]
pub container: ContainerStyle,
pub label: TextStyle,
}
#[derive(Debug, Deserialize, Default)]
pub struct CommandPalette {
pub key: Interactive<ContainedLabel>,