some more structure
This commit is contained in:
@@ -1,11 +1,13 @@
|
||||
using Pilz.Plugins.Advanced;
|
||||
using OwnChar.App.Desktop.Api;
|
||||
using Pilz.Plugins.Advanced;
|
||||
using Pilz.Plugins.Advanced.UI.Telerik;
|
||||
using System;
|
||||
using System.Windows.Forms;
|
||||
using Telerik.WinControls.UI;
|
||||
|
||||
namespace OwnChar.App.Desktop.UI.Windows
|
||||
{
|
||||
public partial class MainWindow : RadForm
|
||||
public partial class MainWindow : RadTabbedForm
|
||||
{
|
||||
public MainWindowApi Api { get; }
|
||||
|
||||
@@ -16,6 +18,21 @@ namespace OwnChar.App.Desktop.UI.Windows
|
||||
PluginFeatureController.Instance.Features.Get(FeatureCodes.MainTab).InsertItemsTo(radMenuItem2.Items, customClickHandler: MainTabItem_Clicked);
|
||||
}
|
||||
|
||||
public class MainWindowApi(MainWindow mainWindow) : IMainWindowApi
|
||||
{
|
||||
public MainWindow MainWindow { get; } = mainWindow;
|
||||
|
||||
public void CloseTab(Control content)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
public void OpenTab(Control content)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
|
||||
private void MainTabItem_Clicked(object? sender, EventArgs e)
|
||||
{
|
||||
//if (sender is RadMenuItem item && item.Tag is PluginModule module)
|
||||
|
||||
@@ -1,23 +0,0 @@
|
||||
using OwnChar.App.Desktop.Api;
|
||||
using System;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace OwnChar.App.Desktop.UI.Windows;
|
||||
|
||||
public partial class MainWindow
|
||||
{
|
||||
public class MainWindowApi(MainWindow mainWindow) : IMainWindowApi
|
||||
{
|
||||
public MainWindow MainWindow { get; } = mainWindow;
|
||||
|
||||
public void CloseTab(Control content)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
public void OpenTab(Control content)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user