星火微课系统客户端
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. using System.Windows;
  2. using System.Windows.Media;
  3. namespace XHWK.WKTool
  4. {
  5. /// <summary>
  6. /// 最小化工具栏
  7. /// </summary>
  8. public partial class MinToolbar : Window
  9. {
  10. /// <summary>
  11. /// 屏幕宽
  12. /// </summary>
  13. internal double pwidth = SystemParameters.PrimaryScreenWidth;
  14. /// <summary>
  15. /// 屏幕高
  16. /// </summary>
  17. internal double pHeight = SystemParameters.PrimaryScreenHeight;
  18. public MinToolbar()
  19. {
  20. InitializeComponent();
  21. ResizeMode = ResizeMode.NoResize;
  22. Topmost = true;
  23. }
  24. /// <summary>
  25. /// 初始化隐藏工具栏位置颜色
  26. /// </summary>
  27. /// <param name="top"></param>
  28. /// <param name="ColorType"></param>
  29. public void Initialize(double top,double ThisHeight)
  30. {
  31. var desktopWorkingArea = System.Windows.SystemParameters.WorkArea;
  32. Left = desktopWorkingArea.Right - this.Width + 7;
  33. Top = top;
  34. BorderBlack.Background = new SolidColorBrush((Color)ColorConverter.ConvertFromString("#FF638AFF"));
  35. Height = ThisHeight;
  36. //if (ColorType == 0)//Blue
  37. //{
  38. // BorderBlack.Background = new SolidColorBrush((Color)ColorConverter.ConvertFromString("#2D8CF0"));
  39. //}
  40. //else if (ColorType == 1)//Black
  41. //{
  42. // BorderBlack.Background = new SolidColorBrush((Color)ColorConverter.ConvertFromString("#364044"));
  43. //}
  44. //else
  45. //{
  46. // BorderBlack.Background = new SolidColorBrush((Color)ColorConverter.ConvertFromString("#2D8CF0"));
  47. //}
  48. // + 330;
  49. //Console.WriteLine(this.Top + "min");
  50. }
  51. private void buttonMin_MouseEnter(object sender, System.Windows.Input.MouseEventArgs e)
  52. {
  53. this.Hide();
  54. APP.W_ScreenRecordingToolbarWindow.MaxToobar();
  55. }
  56. private void buttonMin_MouseEnter_1(object sender, System.Windows.Input.MouseEventArgs e)
  57. {
  58. }
  59. }
  60. }