And a few more todos

This commit is contained in:
Mikayla 2024-01-09 16:31:12 -08:00
parent 9ce7ef8949
commit e786e22121
No known key found for this signature in database
5 changed files with 14 additions and 18 deletions

View file

@ -12,7 +12,7 @@ use serde::Deserialize;
use std::sync::Arc;
use ui::{prelude::*, Button};
const HANDLE_HITBOX_SIZE: f32 = 4.0;
pub const HANDLE_HITBOX_SIZE: f32 = 4.0;
const HORIZONTAL_MIN_SIZE: f32 = 80.;
const VERTICAL_MIN_SIZE: f32 = 100.;
@ -268,15 +268,6 @@ impl Member {
)
})
.into_any()
// let el = div()
// .flex()
// .flex_1()
// .gap_px()
// .w_full()
// .h_full()
// .bg(cx.theme().colors().editor)
// .children();
}
Member::Axis(axis) => axis
.render(

View file

@ -852,6 +852,10 @@ impl Workspace {
&self.right_dock
}
pub fn is_edited(&self) -> bool {
self.window_edited
}
pub fn add_panel<T: Panel>(&mut self, panel: View<T>, cx: &mut ViewContext<Self>) {
let dock = match panel.position(cx) {
DockPosition::Left => &self.left_dock,
@ -2055,7 +2059,7 @@ impl Workspace {
_ => bounding_box.center(),
};
let distance_to_next = 8.; //todo(pane dividers styling)
let distance_to_next = pane_group::HANDLE_HITBOX_SIZE;
let target = match direction {
SplitDirection::Left => {