New commit review flow in project diff view (#25229)
Closes #ISSUE Release Notes: - N/A --------- Co-authored-by: Nate Butler <iamnbutler@gmail.com>
This commit is contained in:
parent
6b9397c380
commit
4871d3c9e7
18 changed files with 982 additions and 480 deletions
|
@ -52,6 +52,24 @@ impl Tooltip {
|
|||
}
|
||||
}
|
||||
|
||||
pub fn for_action_title_in(
|
||||
title: impl Into<SharedString>,
|
||||
action: &dyn Action,
|
||||
focus_handle: &FocusHandle,
|
||||
) -> impl Fn(&mut Window, &mut App) -> AnyView {
|
||||
let title = title.into();
|
||||
let action = action.boxed_clone();
|
||||
let focus_handle = focus_handle.clone();
|
||||
move |window, cx| {
|
||||
cx.new(|cx| Self {
|
||||
title: title.clone(),
|
||||
meta: None,
|
||||
key_binding: KeyBinding::for_action_in(action.as_ref(), &focus_handle, window, cx),
|
||||
})
|
||||
.into()
|
||||
}
|
||||
}
|
||||
|
||||
pub fn for_action(
|
||||
title: impl Into<SharedString>,
|
||||
action: &dyn Action,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue