Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Docking Pane
  New Posts New Posts RSS Feed - DockingPane is not correct
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

DockingPane is not correct

 Post Reply Post Reply
Author
Message
zjroland View Drop Down
Groupie
Groupie


Joined: 09 December 2006
Status: Offline
Points: 42
Post Options Post Options   Thanks (0) Thanks(0)   Quote zjroland Quote  Post ReplyReply Direct Link To This Post Topic: DockingPane is not correct
    Posted: 14 January 2007 at 10:22am
I have a DockingPane, it's a CXTResizeFormView(resource is a dialog),when it slide out ,it look like:
below is the code:
 
IMPLEMENT_DYNCREATE(CPaneSearch, CXTResizeFormView)CPaneSearch::CPaneSearch()
 : CXTResizeFormView(CPaneSearch::IDD)
{
 m_bInitialized = FALSE;
}
CPaneSearch::~CPaneSearch()
{
}

void CPaneSearch::DoDataExchange(CDataExchange* pDX)
{
 CXTResizeFormView::DoDataExchange(pDX);
}


BEGIN_MESSAGE_MAP(CPaneSearch, CXTResizeFormView)

END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CPaneSearch diagnostics

#ifdef _DEBUG
void CPaneSearch::AssertValid() const
{
 CXTResizeFormView::AssertValid();
}

void CPaneSearch::Dump(CDumpContext& dc) const
{
 CXTResizeFormView::Dump(dc);
}
#endif //_DEBUG


/////////////////////////////////////////////////////////////////////////////
// CPaneSearch message handlers

void CPaneSearch::OnInitialUpdate()
{
 CXTResizeFormView::OnInitialUpdate();

 SetScaleToFitSize(CSize(1, 1));
 
 if (m_bInitialized)
  return;

 //SetResize(IDC_BUTTON_REPLACEALL, SZ_TOP_RIGHT, SZ_TOP_RIGHT);
 m_bInitialized = TRUE;
}

BOOL CPaneSearch::PreCreateWindow(CREATESTRUCT& cs)
{
 cs.style |= WS_CLIPCHILDREN|WS_CLIPSIBLINGS;

 return CXTResizeFormView::PreCreateWindow(cs);
}


BOOL CPaneSearch::PreTranslateMessage(MSG* pMsg)
{
 if (pMsg->message == WM_KEYDOWN || pMsg->message == WM_SYSKEYDOWN)
 {
  if ((::GetFocus() == m_hWnd) || (::GetParent(::GetFocus()) == m_hWnd) || (::GetParent(::GetParent(::GetFocus())) == m_hWnd))
  {
   if (IsDialogMessage(pMsg))
    return TRUE;
  }
 }
 return CXTResizeFormView::PreTranslateMessage(pMsg);
}

 

Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 14 January 2007 at 11:03am
Hi,
Problem in Group boxes. try to subclass them to CXTResizeGroupBox:
 
CXTResizeGroupBox m_groupSort;
...
m_groupSort.SubclassDlgItem(IDC_GBOX_SORT, this);
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
zjroland View Drop Down
Groupie
Groupie


Joined: 09 December 2006
Status: Offline
Points: 42
Post Options Post Options   Thanks (0) Thanks(0)   Quote zjroland Quote  Post ReplyReply Direct Link To This Post Posted: 15 January 2007 at 8:48am
It's OK now, Thank you Oleg !!!
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.125 seconds.