⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 filetranssvrview.h

📁 文件传送协议的服务器端和客户端源码
💻 H
字号:
////////////////////////////////////////////////////////////////////////////
//                                                                        //
//	CopyRight by Tidge, Jan. 15th, 2007									  //
//																		  //
////////////////////////////////////////////////////////////////////////////
// FileTransSvrView.h : interface of the CFileTransSvrView class
//
/////////////////////////////////////////////////////////////////////////////

#if !defined(AFX_FILETRANSSVRVIEW_H__0B6B3C6C_4B18_42A9_8EB2_91A64A45AE5A__INCLUDED_)
#define AFX_FILETRANSSVRVIEW_H__0B6B3C6C_4B18_42A9_8EB2_91A64A45AE5A__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

#include "MainFrm.h"
#define	 WM_THREADMSG	(WM_USER+105)

class CFileTransSvrView : public CFormView
{
protected: // create from serialization only
	CFileTransSvrView();
	DECLARE_DYNCREATE(CFileTransSvrView)

public:
	//{{AFX_DATA(CFileTransSvrView)
	enum { IDD = IDD_FILETRANSSVR_FORM };
	CIPAddressCtrl	m_IpAddress;
	CString	m_Tips;
	//}}AFX_DATA

// Attributes
public:
	CFileTransSvrDoc* GetDocument();

// Operations
public:

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CFileTransSvrView)
	public:
	virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
	virtual void OnInitialUpdate(); // called first time after construct
	virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
	virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
	virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);
	virtual void OnPrint(CDC* pDC, CPrintInfo* pInfo);
	virtual LRESULT WindowProc(UINT message, WPARAM wParam, LPARAM lParam);
	//}}AFX_VIRTUAL

// Implementation
public:
	virtual ~CFileTransSvrView();
#ifdef _DEBUG
	virtual void AssertValid() const;
	virtual void Dump(CDumpContext& dc) const;
#endif

protected:
	static DWORD WINAPI ThreadSelect(LPVOID lpParameter);
// Generated message map functions
protected:
	//{{AFX_MSG(CFileTransSvrView)
	afx_msg void OnStartsvr();
	afx_msg void ThreadRet(WPARAM wParam, LPARAM lParam); 
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
public:
	static char* GetDrivesString();
private:
	static void SendFile(SOCKET socket,int segInfo,CString strPath);
	static long GetFileLength(CString strPath);
	static CString FormatPath(char chPath[],int length);
	static int GetDirectoryString(CString retArrFiles[],CString directoryPath,char *pRet);
};

#ifndef _DEBUG  // debug version in FileTransSvrView.cpp
inline CFileTransSvrDoc* CFileTransSvrView::GetDocument()
   { return (CFileTransSvrDoc*)m_pDocument; }
#endif

/////////////////////////////////////////////////////////////////////////////

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_FILETRANSSVRVIEW_H__0B6B3C6C_4B18_42A9_8EB2_91A64A45AE5A__INCLUDED_)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -