www.pudn.com > WinInet.rar > InetDownloadDlg.h


// InetDownloadDlg.h : header file 
// 
 
#if !defined(AFX_INETDOWNLOADDLG_H__DF17AB67_AA34_11D6_9259_F8EB1584697E__INCLUDED_) 
#define AFX_INETDOWNLOADDLG_H__DF17AB67_AA34_11D6_9259_F8EB1584697E__INCLUDED_ 
 
#if _MSC_VER > 1000 
#pragma once 
#endif // _MSC_VER > 1000 
 
///////////////////////////////////////////////////////////////////////////// 
// CInetDownloadDlg dialog 
 
class CInetDownloadDlg : public CDialog 
{ 
// Construction 
public: 
	LRESULT OnThreadStatus(WPARAM wParam,LPARAM lParam); 
	LRESULT OnThreadProgress(WPARAM wParam,LPARAM lParam); 
	LRESULT OnThreadEnd(WPARAM wParam,LPARAM lParam); 
	CWinThread* m_pThread; 
	static UINT DownloadURLFile(LPVOID  pParam); 
	static UINT DownloadURLFile2(LPVOID  pParam); 
	CInetDownloadDlg(CWnd* pParent = NULL);	// standard constructor 
 
// Dialog Data 
	//{{AFX_DATA(CInetDownloadDlg) 
	enum { IDD = IDD_INETDOWNLOAD_DIALOG }; 
	CButton	m_buttonDownload2; 
	CProgressCtrl	m_progressBar; 
	CEdit	m_editStatus; 
	CButton	m_buttonDownload; 
	CString	m_strURL; 
	CString	m_strLocalDir; 
	//}}AFX_DATA 
 
	// ClassWizard generated virtual function overrides 
	//{{AFX_VIRTUAL(CInetDownloadDlg) 
	protected: 
	virtual void DoDataExchange(CDataExchange* pDX);	// DDX/DDV support 
	//}}AFX_VIRTUAL 
public: 
 
// Implementation 
protected: 
	HICON m_hIcon; 
 
	// Generated message map functions 
	//{{AFX_MSG(CInetDownloadDlg) 
	virtual BOOL OnInitDialog(); 
	afx_msg void OnPaint(); 
	afx_msg HCURSOR OnQueryDragIcon(); 
	afx_msg void OnDownload(); 
	afx_msg void OnDownload2(); 
	//}}AFX_MSG 
	DECLARE_MESSAGE_MAP() 
}; 
	struct DLPARAM{ 
		CString strURL;//URL资源 
		CString strLocalDir;//放置下载文件的本地目录。 
		CInetDownloadDlg* pMainWnd;//对话框指针 
		HWND hwnd; 
	}; 
 
//{{AFX_INSERT_LOCATION}} 
// Microsoft Visual C++ will insert additional declarations immediately before the previous line. 
 
#endif // !defined(AFX_INETDOWNLOADDLG_H__DF17AB67_AA34_11D6_9259_F8EB1584697E__INCLUDED_)