36 lines
870 B
C#
36 lines
870 B
C#
using System.IO;
|
|
using System.Windows;
|
|
|
|
namespace DrillTools
|
|
{
|
|
public enum StartupAction
|
|
{
|
|
None,
|
|
AdjustToolOrder,
|
|
ExportHoleCount
|
|
}
|
|
|
|
public partial class StartupSelectionWindow : Window
|
|
{
|
|
public StartupAction SelectedAction { get; private set; } = StartupAction.None;
|
|
|
|
public StartupSelectionWindow(string filePath)
|
|
{
|
|
InitializeComponent();
|
|
DataContext = new { FileName = Path.GetFileName(filePath) };
|
|
}
|
|
|
|
private void AdjustToolOrder_Click(object sender, RoutedEventArgs e)
|
|
{
|
|
SelectedAction = StartupAction.AdjustToolOrder;
|
|
Close();
|
|
}
|
|
|
|
private void ExportHoleCount_Click(object sender, RoutedEventArgs e)
|
|
{
|
|
SelectedAction = StartupAction.ExportHoleCount;
|
|
Close();
|
|
}
|
|
}
|
|
}
|