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.

57 lines
1.8 KiB

  1. // Copyright (c) 1999 Microsoft Corporation. All Rights Reserved.
  2. #if !defined(AFX_PASSDLG_H__6B752DC2_A167_11D1_A5E1_00AA0037E04F__INCLUDED_)
  3. #define AFX_PASSDLG_H__6B752DC2_A167_11D1_A5E1_00AA0037E04F__INCLUDED_
  4. #if _MSC_VER >= 1000
  5. #pragma once
  6. #endif // _MSC_VER >= 1000
  7. // AdminDlg.h : header file
  8. //
  9. #include <atlctl.h>
  10. #include <strmif.h>
  11. #include "resource.h"
  12. #include "msdvdopt.h"
  13. #include "dvdopt.h"
  14. class COptionsDlg;
  15. /////////////////////////////////////////////////////////////////////////////
  16. // CPasswordDlg dialog
  17. class CPasswordDlg : public CDialogImpl<CPasswordDlg>
  18. {
  19. // Construction
  20. public:
  21. BEGIN_MSG_MAP(CPasswordDlg)
  22. MESSAGE_HANDLER(WM_INITDIALOG, OnInitDialog)
  23. MESSAGE_HANDLER(WM_CONTEXTMENU, OnContextMenu)
  24. COMMAND_ID_HANDLER(IDOK, OnOK)
  25. COMMAND_ID_HANDLER(IDCANCEL, OnCancel)
  26. END_MSG_MAP()
  27. CPasswordDlg(IMSDVDAdm* pDvdAdm);
  28. enum { IDD = IDD_CHANGEPASSWD };
  29. typedef enum { PASSWORDDLG_CHANGE=0, PASSWORDDLG_VERIFY} PASSWORDDLG_REASON;
  30. void SetReason(PASSWORDDLG_REASON reason) {m_reason = reason; }
  31. PASSWORDDLG_REASON GetReason() {return m_reason; }
  32. BOOL IsVerified() {return m_bVerified; }
  33. LPTSTR GetPassword() {return m_szPassword; }
  34. // Implementation
  35. protected:
  36. LRESULT OnInitDialog(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
  37. LRESULT OnContextMenu(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
  38. LRESULT OnOK(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled);
  39. LRESULT OnCancel(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled);
  40. CComPtr<IMSDVDAdm> m_pDvdAdm;
  41. PASSWORDDLG_REASON m_reason;
  42. BOOL m_bVerified;
  43. TCHAR m_szPassword[MAX_PASSWD];
  44. };
  45. #endif // !defined(AFX_PASSDLG_H__6B752DC2_A167_11D1_A5E1_00AA0037E04F__INCLUDED_)