![]() |
Bug in TabClientWnd in 10.4 |
Post Reply
|
| Author | |
danpetitt
Senior Member
Joined: 17 July 2005 Location: United Kingdom Status: Offline Points: 109 |
Post Options
Thanks(0)
Quote Reply
Topic: Bug in TabClientWnd in 10.4Posted: 08 January 2007 at 10:33am |
|
You can no longer turn off tabs in 10.4. You used to be able to detach the mTIClientWnd and the documents still appeared maximised and everything was okay. Now you cant.
For example in VisualStudio sample comment out following lines in MainFrm.cpp:
And run it. The docs are in non-maximised state but cant be moved or maximised.
|
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 08 January 2007 at 4:31pm |
|
Hi,
Comment also code in int CChildFrame::OnCreate(LPCREATESTRUCT lpCreateStruct)
|
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
danpetitt
Senior Member
Joined: 17 July 2005 Location: United Kingdom Status: Offline Points: 109 |
Post Options
Thanks(0)
Quote Reply
Posted: 09 January 2007 at 6:12am |
|
That works a bit better, but if I do this whilst the program is running (i.e. through an Options page) then it doesnt work very nicely at all ... can you give me the steps I should do to achieve this.
Currently I 'detach' the MTIClientWnd if its off, and 'attach' it if its on, and I have wrapped up the code on ChildFrm::OnCreate around a check for the tabs enabled flag.
What else do i need to do?
|
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 09 January 2007 at 10:28am |
|
Hi, Show me code you have now to switch it.
|
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
danpetitt
Senior Member
Joined: 17 July 2005 Location: United Kingdom Status: Offline Points: 109 |
Post Options
Thanks(0)
Quote Reply
Posted: 09 January 2007 at 10:36am |
|
|
|
![]() |
|
danpetitt
Senior Member
Joined: 17 July 2005 Location: United Kingdom Status: Offline Points: 109 |
Post Options
Thanks(0)
Quote Reply
Posted: 10 January 2007 at 9:09am |
|
Any ideas how to solve this?
|
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 10 January 2007 at 9:41am |
|
Hi, problem that if you use Enablegroups option (think it was FALSE in previour releases and was reason why it worked) TabClient automatically remove caption if child windows. SO you have switch it back:
if (m_MTIClientWnd.GetSafeHwnd())
{ m_MTIClientWnd.Detach(); HWND hWnd = ::GetWindow(m_hWndMDIClient, GW_CHILD); while (hWnd) { CWnd::ModifyStyle(hWnd, 0, WS_CAPTION, SWP_FRAMECHANGED); hWnd = ::GetWindow(hWnd, GW_HWNDNEXT); } MDICascade(); } else { HWND hWnd = ::GetWindow(m_hWndMDIClient, GW_CHILD); while (hWnd) { CWnd::ModifyStyle(hWnd, WS_CAPTION, 0, SWP_FRAMECHANGED); hWnd = ::GetWindow(hWnd, GW_HWNDNEXT); } m_MTIClientWnd.Attach(this, TRUE); } RecalcLayout(); ::RedrawWindow(m_MTIClientWnd, 0, 0, RDW_INVALIDATE|RDW_UPDATENOW|RDW_ALLCHILDREN); |
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
Post Reply
|
|
|
Tweet
|
| Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |