Files
coco df489d5640 a
2026-07-03 16:05:30 +08:00

72 lines
2.4 KiB
C++

// opcreatesptframe.cpp : implementation file
//
#include "stdafx.h"
#include "geomative.h"
#include "opcreatesptframe.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// COpCreateSptFrame
IMPLEMENT_DYNCREATE(COpCreateSptFrame, CFrameWnd)
COpCreateSptFrame::COpCreateSptFrame()
{
}
COpCreateSptFrame::~COpCreateSptFrame()
{
}
BEGIN_MESSAGE_MAP(COpCreateSptFrame, CFrameWnd)
//{{AFX_MSG_MAP(COpCreateSptFrame)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// COpCreateSptFrame message handlers
BOOL COpCreateSptFrame::OnCreateClient(LPCREATESTRUCT lpcs, CCreateContext* pContext)
{
// TODO: Add your specialized code here and/or call the base class
CRect rect;
if (VAL_ZERO == m_firstSplitter.GetSafeHwnd())
{
GetClientRect(rect);
m_firstSplitter.CreateStatic(this, 1, 2);
VERIFY(m_firstSplitter.CreateView(SPL_VIEW_ROW_0, SPL_VIEW_COL_0, RUNTIME_CLASS(COpCreateSptRecListView), CSize((rect.right-rect.left)/6, rect.bottom-rect.top), pContext));
m_pOpCreateSptRecListView = static_cast<COpCreateSptRecListView*>(m_firstSplitter.GetPane(SPL_VIEW_ROW_0, SPL_VIEW_COL_0));
ASSERT(m_pOpCreateSptRecListView != NULL);
// m_pOpCreateSptRecListView->OnInitialUpdate();
// m_secondSplitter.CreateStatic(&m_firstSplitter, 2, 1, WS_CHILD | WS_VISIBLE, m_firstSplitter.IdFromRowCol(SPL_VIEW_ROW_0, SPL_VIEW_ROW_1));
VERIFY(m_firstSplitter.CreateView(SPL_VIEW_ROW_0, SPL_VIEW_COL_1, RUNTIME_CLASS(COpCreateSptView), CSize((rect.right-rect.left)/6*5, (rect.bottom-rect.top)/4*3), pContext));
m_pOpCreateSptView = static_cast<COpCreateSptView*>(m_firstSplitter.GetPane(SPL_VIEW_ROW_0, SPL_VIEW_COL_1));
ASSERT(m_pOpCreateSptView != NULL);
// m_pOpCreateSptView->OnInitialUpdate();
// VERIFY(m_secondSplitter.CreateView(SPL_VIEW_ROW_1, SPL_VIEW_COL_0, RUNTIME_CLASS(COpCreateSptInfoView), CSize((rect.right-rect.left)/6*5, (rect.bottom-rect.top)/4), pContext));
// m_pOpCreateSptInfoView = static_cast<COpCreateSptInfoView*>(m_secondSplitter.GetPane(SPL_VIEW_ROW_1, SPL_VIEW_COL_0));
// ASSERT(m_pOpCreateSptInfoView != NULL);
// m_pOpCreateSptInfoView->OnInitialUpdate();
// m_secondSplitter.RecalcLayout();
m_firstSplitter.RecalcLayout();
m_pOpCreateSptView->SetFocus();
}
return CFrameWnd::OnCreateClient(lpcs, pContext);
}