/*
Copyright 1997 David Coppit.  Permission to use and modify this code for
research purposes is granted to provided that this copyright statement retained
in all derivative software.

Many thanks to Dietmar Kuehl <Dietmar.Kuehl@uni-konstanz.de> for his help.
Some of this code is based on his streams examples at:
http://www.informatik.uni-konstanz.de/~kuehl/c++/iostream/
 
This file, along with winbuff.cpp, PromptDialog.h, and PromptDialog.cpp
implement a Windows MFC compatible text-based input window for cout and cin.  A
tutorial and more information can be found at
http://www.coppit.org/soft_eng/winbuf/index.html
*/

#include "StdAfx.h"
#include "resource.h"

// PromptDialog.h : header file
//

/////////////////////////////////////////////////////////////////////////////
// PromptDialog dialog

class PromptDialog : public CDialog
{
// Construction
public:
	PromptDialog(CWnd* pParent = NULL);   // standard constructor
	PromptDialog(CView* pParent);   // standard constructor
	void PutText(CString text);
	void WaitForOK();
	BOOL Create();

	// Used to indicate whether a button has been clicked.
	int OKClicked;
	int CancelClicked;

// Dialog Data
	//{{AFX_DATA(PromptDialog)
	enum { IDD = IDD_DIALOG1 };
	CEdit	m_ViewControl;
	CString	m_displaytext;
	CString	m_strEdit1;
	//}}AFX_DATA


// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(PromptDialog)
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
	//}}AFX_VIRTUAL

// Implementation
protected:

	// Generated message map functions
	//{{AFX_MSG(PromptDialog)
	virtual void OnOK();
	virtual void OnCancel();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
private:
	CView* m_pView;
};
