1 /* $NetBSD: BINDInstallDlg.h,v 1.4 2014/12/10 04:37:55 christos Exp $ */ 2 3 /* 4 * Portions Copyright (C) 2004, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") 5 * Portions Copyright (C) 2001 Internet Software Consortium. 6 * 7 * Permission to use, copy, modify, and/or distribute this software for any 8 * purpose with or without fee is hereby granted, provided that the above 9 * copyright notice and this permission notice appear in all copies. 10 * 11 * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH 12 * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY 13 * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, 14 * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM 15 * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE 16 * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR 17 * PERFORMANCE OF THIS SOFTWARE. 18 */ 19 20 /* Id: BINDInstallDlg.h,v 1.11 2009/09/01 06:51:47 marka Exp */ 21 22 /* 23 * Copyright (c) 1999-2000 by Nortel Networks Corporation 24 * 25 * Permission to use, copy, modify, and distribute this software for any 26 * purpose with or without fee is hereby granted, provided that the above 27 * copyright notice and this permission notice appear in all copies. 28 * 29 * THE SOFTWARE IS PROVIDED "AS IS" AND NORTEL NETWORKS DISCLAIMS 30 * ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES 31 * OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL NORTEL NETWORKS 32 * BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES 33 * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 34 * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, 35 * ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS 36 * SOFTWARE. 37 */ 38 39 #ifndef BINDINSTALLDLG_H 40 #define BINDINSTALLDLG_H 41 42 class CBINDInstallDlg : public CDialog 43 { 44 public: 45 CBINDInstallDlg(CWnd* pParent = NULL); // standard constructor 46 47 //{{AFX_DATA(CBINDInstallDlg) 48 enum { IDD = IDD_BINDINSTALL_DIALOG }; 49 CString m_targetDir; 50 CString m_version; 51 BOOL m_autoStart; 52 BOOL m_keepFiles; 53 BOOL m_toolsOnly; 54 CString m_current; 55 BOOL m_startOnInstall; 56 //}}AFX_DATA 57 58 // ClassWizard generated virtual function overrides 59 //{{AFX_VIRTUAL(CBINDInstallDlg) 60 protected: 61 virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support 62 //}}AFX_VIRTUAL 63 64 protected: 65 void StartBINDService(); 66 void StopBINDService(); 67 68 void InstallTags(); 69 void UninstallTags(); 70 71 void CreateDirs(); 72 void RemoveDirs(BOOL uninstall); 73 74 void CopyFiles(); 75 void DeleteFiles(BOOL uninstall); 76 77 void RegisterService(); 78 void UpdateService(CString StartName); 79 void UnregisterService(BOOL uninstall); 80 81 void RegisterMessages(); 82 void UnregisterMessages(BOOL uninstall); 83 84 void FailedInstall(); 85 void SetItemStatus(UINT nID, BOOL bSuccess = TRUE); 86 87 void GetCurrentServiceAccountName(); 88 BOOL ValidateServiceAccount(); 89 protected: 90 CString DestDir(int destination); 91 int MsgBox(int id, ...); 92 int MsgBox(int id, UINT type, ...); 93 CString GetErrMessage(DWORD err = -1); 94 BOOL CheckBINDService(); 95 void SetCurrent(int id, ...); 96 void ProgramGroup(BOOL create = TRUE); 97 98 HICON m_hIcon; 99 CString m_defaultDir; 100 CString m_etcDir; 101 CString m_binDir; 102 CString m_winSysDir; 103 BOOL m_installed; 104 CString m_currentDir; 105 BOOL m_accountExists; 106 BOOL m_accountUsed; 107 CString m_currentAccount; 108 CString m_accountName; 109 CString m_accountPasswordConfirm; 110 CString m_accountPassword; 111 BOOL m_serviceExists; 112 113 // Generated message map functions 114 //{{AFX_MSG(CBINDInstallDlg) 115 virtual BOOL OnInitDialog(); 116 afx_msg void OnPaint(); 117 afx_msg HCURSOR OnQueryDragIcon(); 118 afx_msg void OnBrowse(); 119 afx_msg void OnChangeTargetdir(); 120 afx_msg void OnInstall(); 121 afx_msg void OnExit(); 122 afx_msg void OnUninstall(); 123 afx_msg void OnAutoStart(); 124 afx_msg void OnKeepFiles(); 125 afx_msg void OnStartOnInstall(); 126 //}}AFX_MSG 127 DECLARE_MESSAGE_MAP() 128 }; 129 130 #endif 131