CSystemSettingWnd.h 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. #pragma once
  2. #include "../helper/WndHelper.h"
  3. #include "CDingweiWnd.h"
  4. class CValueWnd;
  5. class CSystemSettingWnd : public CWindowWnd, public INotifyUI, public IMessageFilterUI
  6. {
  7. public:
  8. CSystemSettingWnd(CValueWnd* value)
  9. {
  10. m_valueWnd = value;
  11. }
  12. LPCTSTR GetWindowClassName() const
  13. {
  14. return _T("UISystemSettingFrame");
  15. };
  16. UINT GetClassStyle() const
  17. {
  18. return UI_CLASSSTYLE_DIALOG;
  19. };
  20. void OnFinalMessage(HWND /*hWnd*/)
  21. {
  22. //WindowImplBase::OnFinalMessage(hWnd);
  23. m_pm.RemovePreMessageFilter(this);
  24. delete this;
  25. };
  26. void Init();
  27. void OnPrepare()
  28. {
  29. }
  30. void Notify(TNotifyUI& msg);
  31. void HandleClickMsg(TNotifyUI& msg);
  32. void HandleSelectChangeMsg(TNotifyUI& msg);
  33. void HandleItemSelectMsg(TNotifyUI& msg);
  34. LRESULT OnCreate(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
  35. LRESULT OnNcActivate(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
  36. {
  37. if (::IsIconic(*this))
  38. {
  39. bHandled = FALSE;
  40. }
  41. return (wParam == 0) ? TRUE : FALSE;
  42. }
  43. LRESULT OnNcCalcSize(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
  44. {
  45. return 0;
  46. }
  47. LRESULT OnNcPaint(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
  48. {
  49. return 0;
  50. }
  51. LRESULT OnNcHitTest(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
  52. LRESULT OnSize(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
  53. LRESULT OnKeyDown(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
  54. LRESULT HandleMessage(UINT uMsg, WPARAM wParam, LPARAM lParam);
  55. LRESULT MessageHandler(UINT uMsg, WPARAM wParam, LPARAM lParam, bool& bHandled);
  56. void SetDingweiWnd(std::wstring value, HWND hWnd);
  57. void SetOcrWnd(RECT rect);
  58. CEditUI* GetFocusEdit();
  59. private:
  60. void FindValueWnd(std::wstring value);
  61. void FindDingweiWnd(HWND hWnd);
  62. public:
  63. CPaintManagerUI m_pm;
  64. private:
  65. CValueWnd* m_valueWnd;
  66. int m_nType = 1;
  67. HWND m_DingweiWnd = NULL;
  68. RECT m_ocrRect;
  69. //ÉèÖÿì½Ý¼üÏà¹Ø
  70. UINT m_mod = 0;
  71. UINT m_vk = 0;
  72. bool m_isSet = false;
  73. bool m_is_kuaijiepan_page = false;
  74. int m_kuaijiejian_type = 0;
  75. };