PicExportWindow.xaml.cs 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. using ivf_tl_Manage.Converts;
  2. using System;
  3. using System.Collections.Generic;
  4. using System.Linq;
  5. using System.Text;
  6. using System.Threading.Tasks;
  7. using System.Windows;
  8. using System.Windows.Controls;
  9. using System.Windows.Data;
  10. using System.Windows.Documents;
  11. using System.Windows.Input;
  12. using System.Windows.Media;
  13. using System.Windows.Media.Imaging;
  14. using System.Windows.Shapes;
  15. namespace ivf_tl_Manage.Win
  16. {
  17. /// <summary>
  18. /// PicExportWindow.xaml 的交互逻辑
  19. /// </summary>
  20. public partial class PicExportWindow : Window
  21. {
  22. public PicExportWindow(Window w,int picCount)
  23. {
  24. InitializeComponent();
  25. this.Owner = w;
  26. //this.export_Button.Content = $"导出选中图片({picCount}张)";
  27. this.export_Button.Content = $"{KeyToStringConvert.GetLanguageStringByKey("0292")}({picCount}{KeyToStringConvert.GetLanguageStringByKey("0254")})";
  28. if (picCount == 0)
  29. {
  30. this.export_Button.IsEnabled = false ;
  31. }
  32. else
  33. {
  34. this.allExport_Button.IsEnabled = false;
  35. }
  36. this.Closed += (a, b) => w.Activate();
  37. }
  38. private void Cancel_Click(object sender, RoutedEventArgs e)
  39. {
  40. this.DialogResult = false;
  41. return;
  42. }
  43. private void Ok_Click(object sender, RoutedEventArgs e)
  44. {
  45. this.DialogResult = true;
  46. return;
  47. }
  48. }
  49. }