diff --git a/Progrart/App.axaml b/Progrart/App.axaml index ec9b5fc..406ccf8 100644 --- a/Progrart/App.axaml +++ b/Progrart/App.axaml @@ -5,7 +5,6 @@ RequestedThemeVariant="Default"> - diff --git a/Progrart/Controls/TabSystem/TabButton.axaml.cs b/Progrart/Controls/TabSystem/TabButton.axaml.cs index ee4d556..f9cbb75 100644 --- a/Progrart/Controls/TabSystem/TabButton.axaml.cs +++ b/Progrart/Controls/TabSystem/TabButton.axaml.cs @@ -7,6 +7,7 @@ namespace Progrart.Controls.TabSystem; public partial class TabButton : UserControl { public string? Title { get => MainButton.Content as string; set => MainButton.Content = value; } + public string? TooltipText { get => ToolTip.GetTip(MainButton) as string; set => ToolTip.SetTip(MainButton, value); } public ITabPage page; public TabHost Host; public TabButton(ITabPage page, TabHost host) diff --git a/Progrart/Pages/EditorPage.axaml.cs b/Progrart/Pages/EditorPage.axaml.cs index 6ec8f78..c913c73 100644 --- a/Progrart/Pages/EditorPage.axaml.cs +++ b/Progrart/Pages/EditorPage.axaml.cs @@ -25,6 +25,8 @@ public partial class EditorPage : UserControl, ITabPage, IEditorPage if (file is not null) { btn.Title = file.Name; + var path = file.TryGetLocalPath(); + btn.TooltipText = path; } } @@ -43,6 +45,8 @@ public partial class EditorPage : UserControl, ITabPage, IEditorPage if (btn is not null) { btn.Title = file.Name; + var path= file.TryGetLocalPath(); + btn.TooltipText= path; } Task.Run(async () => { diff --git a/Progrart/Pages/ProgrartEditorPage.axaml b/Progrart/Pages/ProgrartEditorPage.axaml new file mode 100644 index 0000000..6ca606c --- /dev/null +++ b/Progrart/Pages/ProgrartEditorPage.axaml @@ -0,0 +1,8 @@ + + + diff --git a/Progrart/Pages/ProgrartEditorPage.axaml.cs b/Progrart/Pages/ProgrartEditorPage.axaml.cs new file mode 100644 index 0000000..99edea9 --- /dev/null +++ b/Progrart/Pages/ProgrartEditorPage.axaml.cs @@ -0,0 +1,13 @@ +using Avalonia; +using Avalonia.Controls; +using Avalonia.Markup.Xaml; + +namespace Progrart; + +public partial class ProgrartEditorPage : UserControl +{ + public ProgrartEditorPage() + { + InitializeComponent(); + } +} \ No newline at end of file diff --git a/Progrart/Views/MainView.axaml b/Progrart/Views/MainView.axaml index 1d483b7..35f8601 100644 --- a/Progrart/Views/MainView.axaml +++ b/Progrart/Views/MainView.axaml @@ -66,7 +66,18 @@ - File Explorer + + + + + + + File Explorer + @@ -85,7 +96,7 @@ - + + diff --git a/Progrart/Views/MainView.axaml.cs b/Progrart/Views/MainView.axaml.cs index 0c726c8..14272cd 100644 --- a/Progrart/Views/MainView.axaml.cs +++ b/Progrart/Views/MainView.axaml.cs @@ -84,6 +84,10 @@ public partial class MainView : UserControl FileContainer.Children.Add(new FileItem(folder)); } }; + FileExplorerCloseButton.Click += (_, _) => + { + LeftPanelToggle.IsChecked = false; + }; LeftPanelToggle.IsChecked = true; } public void Write(string message)