Source code of Windows XP (NT5)
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.

39 lines
1001 B

  1. //-------------------------------------------------------------------
  2. // I P C T R L . H
  3. //
  4. // IP Address control helper class declaration
  5. //-------------------------------------------------------------------
  6. #pragma once
  7. #include "ncstring.h"
  8. class IpControl
  9. {
  10. public:
  11. IpControl();
  12. ~IpControl();
  13. // Implementation
  14. public:
  15. BOOL Create(HWND hParent, UINT nId);
  16. operator HWND() {AssertH(m_hIpAddress); return m_hIpAddress;}
  17. BOOL IsBlank();
  18. void SetFocusField(DWORD dwField);
  19. void SetFieldRange(DWORD dwField, DWORD dwMin, DWORD dwMax);
  20. void ClearAddress();
  21. void SetAddress(DWORD adwAddress[4]);
  22. void SetAddress(DWORD dw1, DWORD dw2, DWORD dw3, DWORD dw4);
  23. void SetAddress(PCWSTR szString);
  24. void GetAddress(DWORD adwAddress[4]);
  25. void GetAddress(DWORD * dw1, DWORD * dw2, DWORD * dw3, DWORD * dw4);
  26. void GetAddress(tstring * pstrAddress);
  27. LRESULT SendMessage(UINT uMsg, WPARAM wParam, LPARAM lParam);
  28. private:
  29. HWND m_hIpAddress;
  30. };