|
// PdfPadView.cpp : implementation of the CPdfPadView class
//
#include "stdafx.h"
#include "PdfPad.h"
#include "PdfPadDoc.h"
#include "PdfPadView.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CPdfPadView
IMPLEMENT_DYNCREATE(CPdfPadView, CEditView)
BEGIN_MESSAGE_MAP(CPdfPadView, CEditView)
//{{AFX_MSG_MAP(CPdfPadView)
ON_WM_SIZE()
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CPdfPadView construction/destruction
CPdfPadView::CPdfPadView()
{
// TODO: add construction code here
}
CPdfPadView::~CPdfPadView()
{
}
BOOL CPdfPadView::PreCreateWindow(CREATESTRUCT& cs)
{
// TODO: Modify the Window class or styles here by modifying
// the CREATESTRUCT cs
BOOL bPreCreated = CEditView::PreCreateWindow(cs);
cs.style &= ~(ES_AUTOHSCROLL|WS_HSCROLL); // Enable word-wrapping
return bPreCreated;
}
/////////////////////////////////////////////////////////////////////////////
// CPdfPadView drawing
void CPdfPadView::OnDraw(CDC* pDC)
{
CPdfPadDoc* pDoc = GetDocument();
ASSERT_VALID(pDoc);
// TODO: add draw code for native data here
}
/////////////////////////////////////////////////////////////////////////////
// CPdfPadView diagnostics
#ifdef _DEBUG
void CPdfPadView::AssertValid() const
{
CEditView::AssertValid();
}
void CPdfPadView::Dump(CDumpContext& dc) const
{
CEditView::Dump(dc);
}
CPdfPadDoc* CPdfPadView::GetDocument() // non-debug version is inline
{
ASSERT(m_pDocument->IsKindOf(RUNTIME_CLASS(CPdfPadDoc)));
return (CPdfPadDoc*)m_pDocument;
}
#endif //_DEBUG
/////////////////////////////////////////////////////////////////////////////
// CPdfPadView message handlers
void CPdfPadView::OnSize(UINT nType, int cx, int cy)
{
// CWnd* pWndChild = GetWindow(GW_CHILD);
// if (!pWndChild)
// return;
// CRect rect;
// GetClientRect(&rect);
// pWndChild->SetWindowPos(NULL,0,0,rect.Width(),rect.Height(),
// SWP_NOZORDER|SWP_NOMOVE);
CEditView::OnSize(nType, cx, cy);
}
|
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.
Settled in the beautiful city of Kochi in India.
Started working in VC++, dotnet in the hometown from 2003 after searching hard for some position in research in robotics and Aritificial Interlligence.