Compare commits
2 Commits
75b6b1dc4d
...
1580d30d72
| Author | SHA1 | Date | |
|---|---|---|---|
| 1580d30d72 | |||
| 0dacaf19b9 |
+1
-1
@@ -485,7 +485,7 @@
|
||||
TextChanged="TbSettingsCustomerSenderAddress_OnTextChanged"
|
||||
x:Name="TbSettingsCustomerSenderAddress" />
|
||||
</Grid>
|
||||
<Grid ColumnDefinitions="150,*,Auto">
|
||||
<Grid ColumnDefinitions="150,*,Auto" x:Name="GrdCSVDividerButtonsAndTb">
|
||||
<Label Content="CSV-Trennzeichen" />
|
||||
<TextBox Grid.Column="1" Watermark=","
|
||||
HorizontalAlignment="Stretch" Margin="0,0,5,0"
|
||||
|
||||
@@ -28,6 +28,7 @@ public partial class MainWindow : Window
|
||||
Logger.Log($"Session on {DateTime.Now:G}");
|
||||
Logger.Log("Initializing...");
|
||||
InitializeComponent();
|
||||
SetSettingsCustomerEnabledState(false);
|
||||
//Hide();
|
||||
|
||||
var s = new StartupWindow();
|
||||
@@ -484,6 +485,7 @@ public partial class MainWindow : Window
|
||||
|
||||
private void LstSettingsCustomers_OnSelectionChanged(object? sender, SelectionChangedEventArgs e)
|
||||
{
|
||||
SetSettingsCustomerEnabledState(false);
|
||||
if (LstSettingsCustomers.SelectedIndex < 0) return;
|
||||
Settings._instance.customers.current =
|
||||
((Customer)LstSettingsCustomers.SelectedItems[0]);
|
||||
@@ -498,9 +500,19 @@ public partial class MainWindow : Window
|
||||
TbSettingsCustomerPatchInfo.Text = Settings._instance.customers.current.patch.ToString();
|
||||
else
|
||||
TbSettingsCustomerPatchInfo.Text = "";
|
||||
SetSettingsCustomerEnabledState();
|
||||
//}
|
||||
}
|
||||
|
||||
private void SetSettingsCustomerEnabledState(bool enable = true)
|
||||
{
|
||||
List<Object> nboom = new() { BtnSettingsImportCustomerAddressPatch, GrdCSVDividerButtonsAndTb, TbSettingsCustomerDescription, TbSettingsCustomerName, BtnDeleteCustomer, TbSettingsCustomerSenderAddress};
|
||||
foreach (var obj in nboom)
|
||||
{
|
||||
(obj as Control).IsEnabled = enable;
|
||||
}
|
||||
}
|
||||
|
||||
private async void EditButton_Click(object? sender, RoutedEventArgs e)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(_selectedWikiFilePath))
|
||||
|
||||
Reference in New Issue
Block a user