Remove the last of the major todos
This commit is contained in:
parent
ed263a7b5c
commit
9ce7ef8949
17 changed files with 73 additions and 267 deletions
|
@ -167,15 +167,6 @@ impl DockPosition {
|
|||
}
|
||||
}
|
||||
|
||||
// todo!()
|
||||
// fn to_resize_handle_side(self) -> HandleSide {
|
||||
// match self {
|
||||
// Self::Left => HandleSide::Right,
|
||||
// Self::Bottom => HandleSide::Top,
|
||||
// Self::Right => HandleSide::Left,
|
||||
// }
|
||||
// }
|
||||
|
||||
pub fn axis(&self) -> Axis {
|
||||
match self {
|
||||
Self::Left | Self::Right => Axis::Horizontal,
|
||||
|
@ -186,8 +177,6 @@ impl DockPosition {
|
|||
|
||||
struct PanelEntry {
|
||||
panel: Arc<dyn PanelHandle>,
|
||||
// todo!()
|
||||
// context_menu: View<ContextMenu>,
|
||||
_subscriptions: [Subscription; 2],
|
||||
}
|
||||
|
||||
|
@ -265,12 +254,6 @@ impl Dock {
|
|||
self.is_open
|
||||
}
|
||||
|
||||
// todo!()
|
||||
// pub fn has_focus(&self, cx: &WindowContext) -> bool {
|
||||
// self.visible_panel()
|
||||
// .map_or(false, |panel| panel.has_focus(cx))
|
||||
// }
|
||||
|
||||
pub fn panel<T: Panel>(&self) -> Option<View<T>> {
|
||||
self.panel_entries
|
||||
.iter()
|
||||
|
@ -417,16 +400,8 @@ impl Dock {
|
|||
}),
|
||||
];
|
||||
|
||||
// todo!()
|
||||
// let dock_view_id = cx.view_id();
|
||||
self.panel_entries.push(PanelEntry {
|
||||
panel: Arc::new(panel),
|
||||
// todo!()
|
||||
// context_menu: cx.add_view(|cx| {
|
||||
// let mut menu = ContextMenu::new(dock_view_id, cx);
|
||||
// menu.set_position_mode(OverlayPositionMode::Local);
|
||||
// menu
|
||||
// }),
|
||||
_subscriptions: subscriptions,
|
||||
});
|
||||
cx.notify()
|
||||
|
@ -618,7 +593,6 @@ impl PanelButtons {
|
|||
|
||||
impl Render for PanelButtons {
|
||||
fn render(&mut self, cx: &mut ViewContext<Self>) -> impl IntoElement {
|
||||
// todo!()
|
||||
let dock = self.dock.read(cx);
|
||||
let active_index = dock.active_panel_index;
|
||||
let is_open = dock.is_open;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue