CMultiPaneFrameWnd Class
The CMultiPaneFrameWnd
class extends CPaneFrameWnd Class. It can support multiple panes. Instead of a single embedded handle to a control bar, CMultiPaneFrameWnd
contains a CPaneContainerManager Class object that enables the user to dock one CMultiPaneFrameWnd
to another and dynamically create multiple floating, tabbed windows.
For more detail see the source code located in the VC\atlmfc\src\mfc folder of your Visual Studio installation.
Syntax
class CMultiPaneFrameWnd : public CPaneFrameWnd
Members
Public Methods
Remarks
Most of the methods in this class override methods in the CPaneFrameWnd Class class.
If a pane uses the AFX_CBRS_AUTO_ROLLUP style and the user docks that pane to a multi-pane frame window, the user can roll up the window regardless of the style settings of the other docked panes.
The framework automatically creates a CMultiPaneFrameWnd
object when the user floats a pane that uses the CBRS_FLOAT_MULTI style.
For information about deriving a class from the CPaneFrameWnd
class and creating it dynamically, see CPaneFrameWnd.
Example
The following example demonstrates how to retrieve a pointer to a CMultiPaneFrameWnd
object. This code snippet is part of the Set Pane Size sample.
// CDockablePane* pBar
CMultiPaneFrameWnd *pParentMiniFrame =
DYNAMIC_DOWNCAST(CMultiPaneFrameWnd, pBar->GetParentMiniFrame());
Inheritance Hierarchy
Requirements
Header: afxMultiPaneFrameWnd.h
CMultiPaneFrameWnd::AddPane
virtual void AddPane(CBasePane* pWnd);
Parameters
[in] pWnd
Remarks
CMultiPaneFrameWnd::AddRecentPane
virtual BOOL AddRecentPane(CDockablePane* pBar);
Parameters
[in] pBar
Return Value
Remarks
CMultiPaneFrameWnd::AdjustLayout
virtual void AdjustLayout();
Remarks
CMultiPaneFrameWnd::AdjustPaneFrames
virtual void AdjustPaneFrames();
Remarks
CMultiPaneFrameWnd::CalcExpectedDockedRect
virtual void CalcExpectedDockedRect(
CWnd* pWndToDock,
CPoint ptMouse,
CRect& rectResult,
BOOL& bDrawTab,
CDockablePane** ppTargetBar);
Parameters
[in] pWndToDock
[in] ptMouse
[in] rectResult
[in] bDrawTab
[in] ppTargetBar
Remarks
CMultiPaneFrameWnd::CanBeAttached
virtual BOOL CanBeAttached() const;
Return Value
Remarks
CMultiPaneFrameWnd::CanBeDockedToPane
virtual BOOL CanBeDockedToPane(const CDockablePane* pDockingBar) const;
Parameters
[in] pDockingBar
Return Value
Remarks
CMultiPaneFrameWnd::CheckGripperVisibility
virtual void CheckGripperVisibility();
Remarks
CMultiPaneFrameWnd::CloseMiniFrame
virtual void CloseMiniFrame();
Remarks
CMultiPaneFrameWnd::ConvertToTabbedDocument
virtual void ConvertToTabbedDocument();
Remarks
CMultiPaneFrameWnd::DockFrame
virtual BOOL DockFrame(
CPaneFrameWnd* pDockedFrame,
AFX_DOCK_METHOD dockMethod);
Parameters
[in] pDockedFrame
[in] dockMethod
Return Value
Remarks
CMultiPaneFrameWnd::DockPane
virtual BOOL DockPane(CDockablePane* pDockedBar);
Parameters
[in] pDockedBar
Return Value
Remarks
CMultiPaneFrameWnd::DockRecentPaneToMainFrame
virtual void DockRecentPaneToMainFrame(CDockablePane* pBar);
Parameters
[in] pBar
Remarks
CMultiPaneFrameWnd::GetCaptionText
virtual CString GetCaptionText();
Return Value
Remarks
CMultiPaneFrameWnd::GetFirstVisiblePane
virtual CWnd* GetFirstVisiblePane() const;
Return Value
Remarks
CMultiPaneFrameWnd::GetPane
virtual CWnd* GetPane() const;
Return Value
Remarks
CMultiPaneFrameWnd::GetPaneContainerManager
Returns a reference to the internal container manager object.
CPaneContainerManager& GetPaneContainerManager();
Return Value
A reference to the internal container manager object.
Remarks
This method can be used to access the internal CPaneContainerManager Class object.
CMultiPaneFrameWnd::GetPaneCount
virtual int GetPaneCount() const;
Return Value
Remarks
CMultiPaneFrameWnd::GetVisiblePaneCount
virtual int GetVisiblePaneCount() const;
Return Value
Remarks
CMultiPaneFrameWnd::InsertPane
virtual BOOL InsertPane(
CBasePane* pControlBar,
CBasePane* pTarget,
BOOL bAfter);
Parameters
[in] pControlBar
[in] pTarget
[in] bAfter
Return Value
Remarks
CMultiPaneFrameWnd::LoadState
virtual BOOL LoadState(
LPCTSTR lpszProfileName = NULL,
UINT uiID = (UINT) -1);
Parameters
[in] lpszProfileName
[in] uiID
Return Value
Remarks
CMultiPaneFrameWnd::OnDockToRecentPos
virtual void OnDockToRecentPos();
Remarks
CMultiPaneFrameWnd::OnKillRollUpTimer
virtual void OnKillRollUpTimer();
Remarks
CMultiPaneFrameWnd::OnPaneRecalcLayout
virtual void OnPaneRecalcLayout();
Remarks
CMultiPaneFrameWnd::OnSetRollUpTimer
virtual void OnSetRollUpTimer();
Remarks
CMultiPaneFrameWnd::OnShowPane
virtual void OnShowPane(
CDockablePane* pBar,
BOOL bShow);
Parameters
[in] pBar
[in] bShow
Remarks
CMultiPaneFrameWnd::PaneFromPoint
virtual CBasePane* PaneFromPoint(
CPoint point,
int nSensitivity,
BOOL bCheckVisibility);
Parameters
[in] point
[in] nSensitivity
[in] bCheckVisibility
Return Value
Remarks
CMultiPaneFrameWnd::RemoveNonValidPanes
virtual void RemoveNonValidPanes();
Remarks
CMultiPaneFrameWnd::RemovePane
virtual void RemovePane(
CBasePane* pBar,
BOOL bDestroy = FALSE,
BOOL bNoDelayedDestroy = TRUE);
Parameters
[in] pBar
[in] bDestroy
[in] bNoDelayedDestroy
Remarks
CMultiPaneFrameWnd::ReplacePane
virtual void ReplacePane(
CBasePane* pBarOrg,
CBasePane* pBarReplaceWith);
Parameters
[in] pBarOrg
[in] pBarReplaceWith
Remarks
CMultiPaneFrameWnd::SaveState
virtual BOOL SaveState(
LPCTSTR lpszProfileName = NULL,
UINT uiID = (UINT) -1);
Parameters
[in] lpszProfileName
[in] uiID
Return Value
Remarks
CMultiPaneFrameWnd::Serialize
virtual void Serialize(CArchive& ar);
Parameters
[in] ar
Remarks
CMultiPaneFrameWnd::SetDockState
virtual void SetDockState(CDockingManager* pDockManager);
Parameters
[in] pDockManager
Remarks
CMultiPaneFrameWnd::SetLastFocusedPane
void SetLastFocusedPane(HWND hwnd);
Parameters
[in] hwnd
Remarks
CMultiPaneFrameWnd::SetPreDockState
virtual BOOL SetPreDockState(
AFX_PREDOCK_STATE preDockState,
CBasePane* pBarToDock = NULL,
AFX_DOCK_METHOD dockMethod = DM_MOUSE);
Parameters
[in] preDockState
[in] pBarToDock
[in] dockMethod
Return Value
Remarks
CMultiPaneFrameWnd::StoreRecentDockSiteInfo
virtual void StoreRecentDockSiteInfo(CPane* pBar);
Parameters
[in] pBar
Remarks
CMultiPaneFrameWnd::StoreRecentTabRelatedInfo
virtual void StoreRecentTabRelatedInfo(
CDockablePane* pDockingBar,
CDockablePane* pTabbedBar);
Parameters
[in] pDockingBar
[in] pTabbedBar