Click here to Skip to main content
12,397,027 members (68,436 online)
Click here to Skip to main content

Stats

709K views
10.2K downloads
310 bookmarked
Posted

Layout Manager for Dialogs, Formviews, DialogBars and PropertyPages

, 4 Aug 2000
A framework to provide automatic layout control for dialogs and forms
#if !defined(AFX_MYDIALOG_H__1C80FFA2_E9D4_11D2_A207_4854E82A1622__INCLUDED_)
#define AFX_MYDIALOG_H__1C80FFA2_E9D4_11D2_A207_4854E82A1622__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// MyDialog.h : Header-Datei
//

/////////////////////////////////////////////////////////////////////////////
// Dialogfeld CMyDialog 
#include "ETSLayout.h"

class CMyDialog : public ETSLayoutDialog
{
// Konstruktion
public:
	CMyDialog(CWnd* pParent = NULL);   // Standardkonstruktor

	/* DialogMgr: Add this: */
	DECLARE_LAYOUT();
	/************************/
	
// Dialogfelddaten
	//{{AFX_DATA(CMyDialog)
	enum { IDD = IDD_DIALOG1 };
		// HINWEIS: Der Klassen-Assistent f�gt hier Datenelemente ein
	//}}AFX_DATA


// �berschreibungen
	// Vom Klassen-Assistenten generierte virtuelle Funktions�berschreibungen
	//{{AFX_VIRTUAL(CMyDialog)
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV-Unterst�tzung
	//}}AFX_VIRTUAL

// Implementierung
protected:

	// Generierte Nachrichtenzuordnungsfunktionen
	//{{AFX_MSG(CMyDialog)
	virtual BOOL OnInitDialog();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};

// this dialog will be sizable horizontally only!
class CMyDialogHorz : public ETSLayoutDialog
{
// Konstruktion
public:
	CMyDialogHorz(CWnd* pParent = NULL);   // Standardkonstruktor

	/* DialogMgr: Add this: */
	DECLARE_LAYOUT();
	/************************/
	
// Dialogfelddaten
	//{{AFX_DATA(CMyDialogHorz)
	enum { IDD = IDD_DIALOG1 };
		// HINWEIS: Der Klassen-Assistent f�gt hier Datenelemente ein
	//}}AFX_DATA


// �berschreibungen
	// Vom Klassen-Assistenten generierte virtuelle Funktions�berschreibungen
	//{{AFX_VIRTUAL(CMyDialogHorz)
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV-Unterst�tzung
	//}}AFX_VIRTUAL

// Implementierung
protected:

	// Generierte Nachrichtenzuordnungsfunktionen
	//{{AFX_MSG(CMyDialogHorz)
	virtual BOOL OnInitDialog();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};


// this dialog will be sizable vertically only!
class CMyDialogVert : public ETSLayoutDialog
{
// Konstruktion
public:
	CMyDialogVert(CWnd* pParent = NULL);   // Standardkonstruktor

	/* DialogMgr: Add this: */
	DECLARE_LAYOUT();
	/************************/
	
// Dialogfelddaten
	//{{AFX_DATA(CMyDialogVert)
	enum { IDD = IDD_DIALOG1 };
		// HINWEIS: Der Klassen-Assistent f�gt hier Datenelemente ein
	//}}AFX_DATA


// �berschreibungen
	// Vom Klassen-Assistenten generierte virtuelle Funktions�berschreibungen
	//{{AFX_VIRTUAL(CMyDialogVert)
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV-Unterst�tzung
	//}}AFX_VIRTUAL

// Implementierung
protected:

	// Generierte Nachrichtenzuordnungsfunktionen
	//{{AFX_MSG(CMyDialogVert)
	virtual BOOL OnInitDialog();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ f�gt unmittelbar vor der vorhergehenden Zeile zus�tzliche Deklarationen ein.

#endif // AFX_MYDIALOG_H__1C80FFA2_E9D4_11D2_A207_4854E82A1622__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 has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here

Share

About the Author

Erwin Tratar
Web Developer
Germany Germany
independant software developer from Germany.
author of Euraconf, an isdn/pabx management software

Programmer since 1991, c/c++/java, started with professional games development, now mainly network, telecommunication and internet stuff

You may also be interested in...

| Advertise | Privacy | Terms of Use | Mobile
Web02 | 2.8.160721.1 | Last Updated 5 Aug 2000
Article Copyright 1999 by Erwin Tratar
Everything else Copyright © CodeProject, 1999-2016
Layout: fixed | fluid