Files
gjm 164968b62e chore
把非utf8-bom编码的cpp/h文件改为 utf8 bom 编码, msvc识别utf8编码时,如果不是bom格式的,会使用当前cp_oem来解码.
2026-10-04 00:04:20 +08:00

79 lines
2.0 KiB
C++

#pragma once
#include "TImageDrawDC.h"
struct CBlockStruct {
CString m_csTKName;
CString m_csRecord;
CString m_csDesName;
};
class CSlideStatic : public CStatic
{
// Construction
public:
CSlideStatic(const TCHAR* szTKName, const TCHAR* szType);
CSlideStatic();
// Attributes
public:
// Operations
public:
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CSlideStatic)
public:
virtual BOOL PreTranslateMessage(MSG* pMsg);
//}}AFX_VIRTUAL
// Implementation
public:
int m_iColNum; //显示幻灯行数
int m_iRowNum; //显示幻灯列数
CString m_csTKName, m_csTKType;
CString m_csTKAllName, m_csCurDwbName, m_csCurRecord, m_csCurDesName;
CString m_csMoveDesName, m_csMoveRecord;
BOOL m_bOnlyCurType;
int m_iIndex, m_iPage, m_iCurPos;//幻灯片总索引 页号 在当前页中的当前选中位置
virtual ~CSlideStatic();
void OnPgup();
void OnPgdown();
void GoPage(int iPage);
void ResetSource(const TCHAR* szTKName, const TCHAR* szTType, int iIndex = 0, int iPage = 0, int iCurPos = 0);
int TotalPages() { // 0--not ready, >0--OK
int len = (int)m_lstSlide.GetCount();
int total = len>0 ? ((len-1)/(m_iColNum*m_iRowNum)+1) : 0;
return total;
}
CList<CBlockStruct, CBlockStruct&> m_lstSlide;//用于记录所有当前页中幻灯片的信息
CRect m_rectSel; //选中红色矩形框尺寸
// Generated message map functions
protected:
TImageDrawDC m_img;
CRect m_rectStatic; //幻灯片容器坐标
CRect m_rectLeftUpSlide; //幻灯片容器中左上角幻灯片的坐标
BOOL EndOfFile; //显示幻灯是否到结尾
void DisplayStatic(CDC *pDC, CString& strPathSlideName);
void DrawFrame(CRect& cr);
void UpdateRecord();
void EraseFrame();
//{{AFX_MSG(CSlideStatic)
afx_msg void OnPaint();
afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
afx_msg void OnMouseMove(UINT nFlags, CPoint point);
//}}AFX_MSG
virtual INT_PTR OnToolHitTest(CPoint point,TOOLINFO*pTI)const;
DECLARE_MESSAGE_MAP()
};