This commit is contained in:
2025-11-17 15:59:49 +01:00
parent d68df750a6
commit fb36f897d6
5 changed files with 11 additions and 6 deletions

View File

@@ -27,10 +27,10 @@ public partial class MainWindow : Window, IMainApi
public MainWindow()
{
DataContext = Model;
InitializeComponent();
GridMain.DataContext = Model;
ButtonWorkspace.ImageSource = AppGlobals.Symbols.GetImageSource(AppSymbols.workspace);
MenuItemWorkspacePreferences.Icon = AppGlobals.Symbols.GetImage(AppSymbols.settings, SymbolSize.Small);
MenuItemSaveWorkspace.Icon = AppGlobals.Symbols.GetImage(AppSymbols.save, SymbolSize.Small);
@@ -124,7 +124,8 @@ public partial class MainWindow : Window, IMainApi
var context = new WorkspaceContext(MainApi, null);
await feature.Configure(context);
await LoadNewWorkspace(context.Workspace, feature);
if (!context.Canceled)
await LoadNewWorkspace(context.Workspace, feature);
}
private async void MenuItemWorkspacePreferences_OnClick(object? sender, RoutedEventArgs e)
@@ -134,7 +135,8 @@ public partial class MainWindow : Window, IMainApi
var context = new WorkspaceContext(MainApi, Model.CurrentWorkspace);
await curWs.Configure(context);
await LoadNewWorkspace(context.Workspace, curWs);
if (!context.Canceled)
await LoadNewWorkspace(context.Workspace, curWs);
}
private async void MenuItemSaveWorkspace_OnClick(object? sender, RoutedEventArgs e)