Click here to Skip to main content
15,897,187 members
Articles / Desktop Programming / MFC

Unit Test's Reporter

Rate me:
Please Sign up or sign in to vote.
4.86/5 (28 votes)
19 Feb 2006CPOL11 min read 64.8K   2.8K   58  
The article describes an application built to visualise testing processes for the unit test framework of CppUnitLite.
#if !defined(AFX_RGTREECTRL_H__6DE6C0C5_8498_11D4_843E_02608CA1FA7B__INCLUDED_)
#define AFX_RGTREECTRL_H__6DE6C0C5_8498_11D4_843E_02608CA1FA7B__INCLUDED_

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


/**********************************************************************************************
 *                                                                                            *
 *  FILE: RGTreeCtrl.h                                                                        *
 *                                                                                            *
 *  DESCRIPTION:                                                                              *
 *       Declaration of the TreeCtrl class using the template CRGTreeT                        *
 *                                                                                            *
 *  Ren� Greiner                                                                              *
 *		eMail: rene.greiner@gmx.de                                                            *
 *                                                                                            *
 **********************************************************************************************/

// The following ifdef block is the standard way of creating macros which make exporting 
// from a DLL simpler. All files within this DLL are compiled with the RGTREECTRL_EXPORTS
// symbol defined on the command line. this symbol should not be defined on any project
// that uses this DLL. This way any other project whose source files include this file see 
// RGTREECTRL_API functions as being imported from a DLL, wheras this DLL sees symbols
// defined with this macro as being exported.

#pragma once

#ifdef RGTREECTRL_EXPORTS
#define RGTREECTRL_API __declspec(dllexport)
#else
#define RGTREECTRL_API __declspec(dllimport)
#endif

extern "C" RGTREECTRL_API HWND CreateRGTree( DWORD dwStyle, int x, int y, int nWidth, int nHeight, HWND hWndParent, HMENU hMenu, HANDLE hInstance, LPVOID lpParam);

//extern "C" RGTREECTRL_API LRESULT CALLBACK RGTreeWindowProc( HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam);

#ifdef __AFX_H__ // MFC project

/////////////////////////////////////////////////////////////////////////////
// CRGTreeCtrl window ( MFC )

class RGTREECTRL_API CRGTreeCtrl : public CTreeCtrl
{
protected:
	virtual LRESULT WindowProc(UINT message, WPARAM wParam, LPARAM lParam);
	virtual void PreSubclassWindow();
	
	bool m_bCreated;
	
public:
    CRGTreeCtrl();
	
	virtual BOOL Create(DWORD dwStyle, const RECT& rect, CWnd* pParentWnd, UINT nID);
	
	// advanced creation (allows access to extended styles)
	BOOL CreateEx(DWORD dwExStyle, LPCTSTR lpszClassName,
		LPCTSTR lpszWindowName, DWORD dwStyle,
		int x, int y, int nWidth, int nHeight,
		HWND hWndParent, HMENU nIDorHMenu, LPVOID lpParam = NULL);
	
	BOOL CreateEx(DWORD dwExStyle, LPCTSTR lpszClassName,
		LPCTSTR lpszWindowName, DWORD dwStyle,
		const RECT& rect,
		CWnd* pParentWnd, UINT nID,
		LPVOID lpParam = NULL);
};

#endif //__AFX_H__

#endif // !defined(AFX_RGTREECTRL_H__6DE6C0C5_8498_11D4_843E_02608CA1FA7B__INCLUDED_)

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Software Developer (Senior)
Israel Israel
MSc in System Engineering from Tallinn Technical University, Estonia. Currently, I work in a hitech enterprise in Israel.

Comments and Discussions