XTPCustomDrawReportPaintManager.cpp
上传用户:szled88
上传日期:2015-04-09
资源大小:43957k
文件大小:2k
源码类别:

对话框与窗口

开发平台:

Visual C++

  1. // XTPCustomDrawReportPaintManager.cpp: implementation of the CXTPCustomDrawReportPaintManager class.
  2. //
  3. // This file is a part of the XTREME TOOLKIT PRO MFC class library.
  4. // (c)1998-2008 Codejock Software, All Rights Reserved.
  5. //
  6. // THIS SOURCE FILE IS THE PROPERTY OF CODEJOCK SOFTWARE AND IS NOT TO BE
  7. // RE-DISTRIBUTED BY ANY MEANS WHATSOEVER WITHOUT THE EXPRESSED WRITTEN
  8. // CONSENT OF CODEJOCK SOFTWARE.
  9. //
  10. // THIS SOURCE CODE CAN ONLY BE USED UNDER THE TERMS AND CONDITIONS OUTLINED
  11. // IN THE XTREME TOOLKIT PRO LICENSE AGREEMENT. CODEJOCK SOFTWARE GRANTS TO
  12. // YOU (ONE SOFTWARE DEVELOPER) THE LIMITED RIGHT TO USE THIS SOFTWARE ON A
  13. // SINGLE COMPUTER.
  14. //
  15. // CONTACT INFORMATION:
  16. // support@codejock.com
  17. // http://www.codejock.com
  18. //
  19. /////////////////////////////////////////////////////////////////////////////
  20. #include "stdafx.h"
  21. #include "XTPCustomDrawReportPaintManager.h"
  22. #include "CustomDrawReportDlg.h"
  23. //////////////////////////////////////////////////////////////////////
  24. // Construction/Destruction
  25. //////////////////////////////////////////////////////////////////////
  26. CXTPCustomDrawReportPaintManager::CXTPCustomDrawReportPaintManager(CCustomDrawReportDlg* pParent) 
  27. : m_pParent(pParent)
  28. {
  29. }
  30. CXTPCustomDrawReportPaintManager::~CXTPCustomDrawReportPaintManager()
  31. {
  32. }
  33. int CXTPCustomDrawReportPaintManager::GetRowHeight(CDC* pDC, CXTPReportRow* pRow)
  34. {
  35. if(m_pParent)
  36. return m_pParent->GetRowHeight(pDC, pRow);
  37. return CXTPReportPaintManager::GetRowHeight(pDC, pRow);
  38. }
  39. void CXTPCustomDrawReportPaintManager::DrawItemCaption(XTP_REPORTRECORDITEM_DRAWARGS* pDrawArgs, XTP_REPORTRECORDITEM_METRICS* pMetrics)
  40. {
  41. if(m_pParent && m_pParent->DrawItem(pDrawArgs, pMetrics))
  42. return;
  43. CXTPReportPaintManager::DrawItemCaption(pDrawArgs, pMetrics);
  44. }