Originally posted by: jiahang_liu
I cann't run this main project in debug version(vc++ 6.0) correctly!
I has rebuilded all sub-project.
Originally posted by: Bruce Thai
To Conway and all Codeguru,
I am frustrated about the buttons
in the docked dialog is disabled.
Is there any way to enable it at
the start/create dialog phrase?
Your help or suggestion is appreciated.
Thanks,
Bruce
Originally posted by: Birch Champeon
When multiple controls are docked in the same row I would like to make it so the user can only resize them to a certain point - so at least a small part of that dialog will show. Has anyone done this? Any tips on where I should look in the code?
Also I have added grippers to my docked dialogs. If anyone is interested in the code email me.
Birch
ReplyOriginally posted by: WangJun
// have to set the style here
CRect Rectx;
// calculate a sensible default rectangle if that's what the
// the rectangle specifies the default floating size.
m_VertDockSize.cx = m_HorzDockSize.cy * 3 / 2;
Wang Jun
Using Resizable Docking Window VC6 you might get a Debug Assertion!
In fact I corrected it by the method as belows:
BOOL CMRCSizeControlBar::Create( LPCTSTR lpszClassName, LPCTSTR lpszWindowName, DWORD dwStyle, const
RECT& rect, CWnd* pParentWnd, UINT nID, CCreateContext* pContext)
{
ASSERT(pParentWnd != NULL);
m_dwStyle = dwStyle;
Rectx = rect;
// user wanted...
if (memcmp(&rect, &CFrameWnd::rectDefault, sizeof(RECT)) == 0)
{
pParentWnd->GetClientRect(&Rectx);
CSize def;
def.cx = Rectx.right / 2;
def.cy = Rectx.bottom / 4;
Rectx.left = Rectx.right - def.cx;
Rectx.top = Rectx.bottom - def.cy;
}
m_FloatSize = Rectx.Size();
// set default values for the docked sizes, based on this size.
m_HorzDockSize.cx = m_FloatSize.cx;
m_HorzDockSize.cy = m_FloatSize.cy / 2;
m_VertDockSize.cy = m_HorzDockSize.cx * 2 / 3;
// save the style,Please Add the follow line here
//1998.11.12 Wangjun
SetBarStyle(dwStyle & CBRS_ALL);
return CControlBar::Create(lpszClassName, lpszWindowName,
dwStyle,Rectx, pParentWnd, nID, pContext);
}
That's all!
Yokohama,Japan
Originally posted by: Cliff Rowley
Well done - it's a nice piece of work ;)
ReplyOriginally posted by: Birch Champeon
To change the extension dll to always do this:
Open the mrcext\framewnd.cpp file.
Go to the FloatControlBarInMDIChild function.
Just before the line (near the end of the function)
Enter these lines:
The next time you choose "float on desktop" the box will be in the MDI window.
Great controls, Mark,
Run the example Docktest. If you right click on the ListBox bar entitled "size bar" you will see
an option to "float on desktop". This is very useful at times, but I found that for my purposes I
wanted to float the window in the MDIClient window of my application with the other views.
pDockBar->DockControlBar(pBar);
CMDIFrameWnd* pWnd = (CMDIFrameWnd*) AfxGetMainWnd();
CWnd* pChildWnd = FromHandle(pWnd -> m_hWndMDIClient);
pDockFrame->SetParent(pChildWnd);
THANKS,
Birch
Originally posted by: Richard Leeds
One possible solution to the message routing problems described in Mark
Conway's article is to override the various window classes' OnCmdMsg
function, and thus override the routing.
You'd need to do this in at least the CMainFrame class, and probably in
the docking window class (CMRCSizeControlBar etc) as well.
This would allow the use of automatic routing from a menu bar item to
the active view, be it in a docking or a frame window.
Please bear in mind that I haven't actually tried this, it may well not
work / crash your PC / cause World War III to break out / all of the
above :-)
The help files seem fairly good on this topic BTW.