ShowBitmapView.h
上传用户:turtfrt
上传日期:2022-06-23
资源大小:36k
文件大小:2k
源码类别:

图片显示

开发平台:

Visual C++

  1. // ShowBitmapView.h : interface of the CShowBitmapView class
  2. //
  3. /////////////////////////////////////////////////////////////////////////////
  4. #if !defined(AFX_SHOWBITMAPVIEW_H__659EE9B9_20AF_4E07_BE5A_F945CF2BDF1E__INCLUDED_)
  5. #define AFX_SHOWBITMAPVIEW_H__659EE9B9_20AF_4E07_BE5A_F945CF2BDF1E__INCLUDED_
  6. #if _MSC_VER > 1000
  7. #pragma once
  8. #endif // _MSC_VER > 1000
  9. class CShowBitmapView : public CView
  10. {
  11. protected: // create from serialization only
  12. CShowBitmapView();
  13. DECLARE_DYNCREATE(CShowBitmapView)
  14. // Attributes
  15. public:
  16. CShowBitmapDoc* GetDocument();
  17. // Operations
  18. public:
  19. // Overrides
  20. // ClassWizard generated virtual function overrides
  21. //{{AFX_VIRTUAL(CShowBitmapView)
  22. public:
  23. virtual void OnDraw(CDC* pDC);  // overridden to draw this view
  24. virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
  25. protected:
  26. virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
  27. virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
  28. virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);
  29. //}}AFX_VIRTUAL
  30. // Implementation
  31. public:
  32. void ShowBitmap(CString BmpName);
  33. BOOL ShowJpgGif(CDC* pDC,CString strPath, int x, int y);
  34. CBitmap m_bitmap;
  35. CString extname;
  36. CString BmpName;
  37. int state;
  38. virtual ~CShowBitmapView();
  39. #ifdef _DEBUG
  40. virtual void AssertValid() const;
  41. virtual void Dump(CDumpContext& dc) const;
  42. #endif
  43. protected:
  44. // Generated message map functions
  45. protected:
  46. //{{AFX_MSG(CShowBitmapView)
  47. afx_msg void OnFileOpen();
  48. //}}AFX_MSG
  49. DECLARE_MESSAGE_MAP()
  50. };
  51. #ifndef _DEBUG  // debug version in ShowBitmapView.cpp
  52. inline CShowBitmapDoc* CShowBitmapView::GetDocument()
  53.    { return (CShowBitmapDoc*)m_pDocument; }
  54. #endif
  55. /////////////////////////////////////////////////////////////////////////////
  56. //{{AFX_INSERT_LOCATION}}
  57. // Microsoft Visual C++ will insert additional declarations immediately before the previous line.
  58. #endif // !defined(AFX_SHOWBITMAPVIEW_H__659EE9B9_20AF_4E07_BE5A_F945CF2BDF1E__INCLUDED_)