Refactor out git status into FileName component

Integrate file name component into the editor's tab content
This commit is contained in:
Mikayla Maki 2023-05-13 02:26:45 -07:00
parent e1c1100c7b
commit 41bef2e444
No known key found for this signature in database
6 changed files with 98 additions and 26 deletions

View file

@ -578,6 +578,15 @@ pub struct ComponentHost<V: View, C: Component<V>> {
view_type: PhantomData<V>,
}
impl<V: View, C: Component<V>> ComponentHost<V, C> {
pub fn new(c: C) -> Self {
Self {
component: c,
view_type: PhantomData,
}
}
}
impl<V: View, C: Component<V>> Deref for ComponentHost<V, C> {
type Target = C;