Home » Developing U++ » UppHub » Docking: BUG + FEATURE: Disable Close completely
Re: Title() Bug [message #26660 is a reply to message #26643] |
Tue, 18 May 2010 12:50 |
mrjt
Messages: 705 Registered: March 2007 Location: London
|
Contributor |
|
|
Hmmm. The way you've got your GUI set-up doesn't isn't really fit how the Docking package was designed. The idea is that you use it to dock windows around a client area showing something useful.
Some solutions occur to me:
- Why not put one of your DockableCtrls into the client area? You might have to Deregister it first (maybe not though) and then just add it with SizePos.
- If you need the user to be able to drag into/out of the client area, I think you could do by inheriting from DockWindow and overloading ContainerDragStart/Move/End. I'm sure there would be complications though.
- You could use SetFrameSize to fill the clioent area. The main problem here is working out which frame(s) to expand (which is opartly why I didn't implement it when I looked at the problem yesterday).
Regarding your suggested changes:
DockAllowed changes: I've added these, though modified the implementation slightly. I've also added them to DockWindow.
Animation change: I've added the extra options to DockConfig, so the user can now turn the different animations on/off themselves.
TabDockGroup: I can see you point, but there are two problems:
- TabDockGroup is used by a menu in DockMenu
- What if the programmer wants to dock a group but still respect the DockAllow settings?
To solve this I've added 2 new functions that do what you want: ForceDockGroup and ForceTabDockGroup.
And if you are trying to save/restore states I suggest you use Save/LoadLayout, it should work much better.
TabDragged: This is more complicated. I can see where you're coming from but doing this would introduce an inconsistency to the interface: The user would not be able to drag individual tabs out, but they could drag the whole container (including tabs that couldn't be put back).
Besides that I don't think I like the behaviour. If what you want is to lock some DockableCtrls into particular positions that could be better accomplished in another way, maybe by a setting in DockableCtrl?
I've committed my changes to the SVN and also left you a little present in Docking.h. Hope it helps
[Updated on: Tue, 18 May 2010 12:54] Report message to a moderator
|
|
|
Goto Forum:
Current Time: Wed Apr 24 21:24:35 CEST 2024
Total time taken to generate the page: 0.01628 seconds
|