1 // WinAfsLoadDlg.h : header file
3 /* Copyright 2000, International Business Machines Corporation and others.
6 This software has been released under the terms of the IBM Public
7 License. For details, see the LICENSE file in the top-level source
8 directory or online at http://www.openafs.org/dl/license10.html
11 #if !defined(AFX_WINAFSLOADDLG_H__75E145B5_F5C0_11D3_A374_00105A6BCA62__INCLUDED_)
12 #define AFX_WINAFSLOADDLG_H__75E145B5_F5C0_11D3_A374_00105A6BCA62__INCLUDED_
16 #endif // _MSC_VER > 1000
23 /////////////////////////////////////////////////////////////////////////////
24 // CWinAfsLoadDlg dialog
28 class CWinAfsLoadDlg : public CDialog
33 CWinAfsLoadDlg(const char *user,const char *pass,CWnd* pParent = NULL); // standard constructor
34 void HandleError(const char *s,BOOL b=TRUE);
35 void BuildDriveList(BOOL newone=FALSE);
36 CList<CString,CString&> m_Drivelist;
37 void OnShowAddMenus();
38 LRESULT OnNotifyReturn(WPARAM wParam, LPARAM lParam);
39 LRESULT OnAfsEvent(WPARAM wParam, LPARAM lParam);
40 BOOL IsGetTokens(){return (!CWINAFSLOADAPP->m_bNoID) && (m_sUsername!="");}
43 //{{AFX_DATA(CWinAfsLoadDlg)
44 enum { IDD = IDD_WINAFSLOAD_DIALOG };
49 CButton m_cAuthenicate;
50 CButton m_cSaveUsername;
51 CListCtrl m_cMountlist;
54 CButton m_cOptionLine;
55 CButton m_cCheckAdvanceDisplay;
62 CString m_sMountDisplay;
65 // ClassWizard generated virtual function overrides
66 //{{AFX_VIRTUAL(CWinAfsLoadDlg)
68 virtual BOOL PreTranslateMessage(MSG* pMsg);
70 virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
71 virtual void PostNcDestroy();
76 CString m_VersionString;
78 CTrayIcon m_trayIcon; // my tray icon
81 BOOL m_bServiceIsActive; //service is active
82 PROCESS_INFORMATION m_procInfo;
85 CString m_sComputername;
86 BOOL TerminateBackground(BOOL bDisplay=TRUE,CString *emsg=NULL);
87 BOOL OnToolTipNotify( UINT id, NMHDR * pNMHDR, LRESULT * pResult );
88 BOOL RegPassword(CString &user,CString &pass,BOOL fetch);
89 CImageList *m_pImagelist;
90 BOOL ProfileData(BOOL put);
91 void AddToList(const char *sDrive,const char *sPath,const char *sShare,const char *sAuto);
92 void ExtractDrive(CString &zdrive,const char *request);
94 BOOL DismountAll(CString &msg,INT mode);
97 BOOL m_bSaveUsername; //TRUE means a click will save, FALSE will mean to clear
98 void UpdateMountDisplay();
99 UINT m_nDirTimer; //Timer for directory update
100 UINT m_nAutTimer; //Timer for authenicate testing
101 BOOL RegLastUser(CString &user,BOOL fetch);
102 void UpdateConnect();
103 UINT m_nShown; //SET according level of warning has occured
105 INT m_seqIndex; //index count for whirling world
106 INT m_seqCount; //count in each sequence
107 INT m_dirCount; //number of 1/2 seconds to wait before checking changes in directory
108 CTransBmp m_bmpWorld; // Bitmap to display, special bit map that does transparent painting
110 BOOL m_bRestartAFSD; //were we suspended???
111 BOOL m_bConnect; //option to automatically start connected
113 CEncript *m_pEncript;
114 sockaddr_in m_sHostIP;
115 OSVERSIONINFO m_OSVersion;
118 (m_OSVersion.dwPlatformId==VER_PLATFORM_WIN32_WINDOWS)
119 && (m_OSVersion.dwMinorVersion==0)
122 void ErrorDisplayState();
123 int m_PowerResumeDelay;
124 void AddMenu(const char *,const char *);
125 void RemoveMenu(const char *);
127 // int m_PowerDelay; //power delay hack
129 // Generated message map functions
130 //{{AFX_MSG(CWinAfsLoadDlg)
131 virtual BOOL OnInitDialog();
132 afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
133 afx_msg void OnPaint();
134 afx_msg void OnConnect();
135 afx_msg void OnCancel();
136 afx_msg void OnCheckadvanced();
137 afx_msg void OnAppOpen();
138 afx_msg void OnChange();
139 afx_msg void OnAdd();
140 afx_msg void OnRemove();
141 afx_msg void OnClickDrivemountlist(NMHDR* pNMHDR, LRESULT* pResult);
142 afx_msg void OnItemchangedDrivemountlist(NMHDR* pNMHDR, LRESULT* pResult);
143 afx_msg BOOL OnQueryEndSession( );
144 afx_msg void OnTimer(UINT nIDEvent);
145 afx_msg void OnAuthenicate();
146 afx_msg void OnDestroy();
147 afx_msg HBRUSH OnCtlColor(CDC* pDC, CWnd* pWnd, UINT nCtlColor);
148 afx_msg void OnShow();
149 afx_msg void OnSuspend();
150 afx_msg void OnResume();
151 afx_msg BOOL OnHelpInfo(HELPINFO* pHelpInfo);
152 afx_msg void OnHelpmain();
153 afx_msg void OnSettings();
155 afx_msg void OnTrayButton0();
156 afx_msg void OnTrayButton1();
157 afx_msg void OnTrayButton2();
158 afx_msg void OnTrayButton3();
159 afx_msg void OnTrayButton4();
160 afx_msg HCURSOR OnQueryDragIcon();
161 afx_msg LRESULT OnPowerBroadcast(WPARAM wParam, LPARAM lParam);
162 afx_msg LRESULT OnErrorMessage(WPARAM wParam, LPARAM lParam);
163 DECLARE_MESSAGE_MAP()
166 //{{AFX_INSERT_LOCATION}}
167 // Microsoft Visual C++ will insert additional declarations immediately before the previous line.
169 #endif // !defined(AFX_WINAFSLOADDLG_H__75E145B5_F5C0_11D3_A374_00105A6BCA62__INCLUDED_)