![]() |
pPane->SetEnable ? |
Post Reply ![]() |
Author | |
jimmy ![]() Senior Member ![]() Joined: 11 November 2003 Location: Austria Status: Offline Points: 516 |
![]() ![]() ![]() ![]() ![]() Posted: 03 June 2008 at 5:31am |
Hello,
Is there a way to disable only the Child Window of a pane and not the pane. SetEnable(xtpPaneEnableActions) or SetEnable(xtpPaneDisable) does not work for this. also chang enum variable m_bEnable to m_eEnable. i use v11.1.3 Jimmy |
|
![]() |
|
mgampi ![]() Senior Member ![]() ![]() Joined: 14 July 2003 Status: Offline Points: 1201 |
![]() ![]() ![]() ![]() ![]() |
Hi;
I did it by just calling GetChild->EnableWindow().
|
|
Martin Product: Xtreme Toolkit v 22.1.0, new Projects v 24.0.0 Platform: Windows 10 v 22H2 (64bit) Language: VC++ 2022 |
|
![]() |
|
jimmy ![]() Senior Member ![]() Joined: 11 November 2003 Location: Austria Status: Offline Points: 516 |
![]() ![]() ![]() ![]() ![]() |
Yes, i also do this, but on some action (save our project change title of a View ) the pane manager get a OnSizeParent, and in this function, the pane manager enable the child.
Jimmy |
|
![]() |
|
jimmy ![]() Senior Member ![]() Joined: 11 November 2003 Location: Austria Status: Offline Points: 516 |
![]() ![]() ![]() ![]() ![]() |
My solution
class CExXTPDockingPane : public CXTPDockingPane { public: CExXTPDockingPane(CXTPDockingPaneLayout* pLayout) : CXTPDockingPane(pLayout) { } virtual void OnSizeParent(CWnd* pParent, CRect rect, LPVOID lParam) { if (GetChild() == NULL || GetChild()->IsWindowEnabled()) { __super::OnSizeParent(pParent, rect, lParam); return; } // Child is Disabled // Save current state XTPXTPDockingPaneEnableOptions eSave = m_bEnabled; m_bEnabled = xtpPaneEnableActions; __super::OnSizeParent(pParent, rect, lParam); m_bEnabled = eSave; } }; Jimmy |
|
![]() |
|
mgampi ![]() Senior Member ![]() ![]() Joined: 14 July 2003 Status: Offline Points: 1201 |
![]() ![]() ![]() ![]() ![]() |
Hi;
I believe that enabling the pane in OnSizeParent() is definitely a bug. I would report this to codejock support...
|
|
Martin Product: Xtreme Toolkit v 22.1.0, new Projects v 24.0.0 Platform: Windows 10 v 22H2 (64bit) Language: VC++ 2022 |
|
![]() |
|
Oleg ![]() Admin Group ![]() Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
![]() ![]() ![]() ![]() ![]() |
Hi,
Actually I think SetEnable(xtpPaneEnableActions) have to work. At least you can try
SetEnable(xtpPaneEnableActions) + GetChild->EnableWindow
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
jimmy ![]() Senior Member ![]() Joined: 11 November 2003 Location: Austria Status: Offline Points: 516 |
![]() ![]() ![]() ![]() ![]() |
Hi Oleg,
But SetEnable(xtpPaneEnableActions) will not work correct. Panes will get gray (disable) , and i can't switch between Panes. Jimmy |
|
![]() |
|
Oleg ![]() Admin Group ![]() Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
![]() ![]() ![]() ![]() ![]() |
hmm. I see your point now.
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
jimmy ![]() Senior Member ![]() Joined: 11 November 2003 Location: Austria Status: Offline Points: 516 |
![]() ![]() ![]() ![]() ![]() |
Why there is EnableWindow(m_hWndChild) in OnSizeParent ?
Jimmy |
|
![]() |
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 |