private void newUserButton_Click(object sender, RoutedEventArgs e)
 {
     var window = new EditUserWindow(null, user);
     window.Show();
     disableDefaultClose = true;
     Close();
 }
 private void editUserButton_Click(object sender, RoutedEventArgs e)
 {
     if (selectedUser == null)
     {
         MessageBox.Show("Nie wybrano użytkownika!", "Błąd", MessageBoxButton.OK);
     }
     else
     {
         var window = new EditUserWindow(selectedUser, user);
         window.Show();
         disableDefaultClose = true;
         Close();
     }
 }