Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion

Left side LMDDockPanel pin problem

I have a a dock site with many dock panels.  The dock panels on the right side behave correctly in regards to the pinning, but the ones on the left side don't.  If I unpin a right side dock panel, it puts it to the right as a sliding popout.  If I click on the pin when it is popped out, it re-pins it back into position.  However, with the dock panels on the left side, once I unpin one of the panels, it correctly puts it to the left side as a sliding popout, but when I attempt to re-pin the panel, it simply closes it back to the side and does not pin itself back again unless I drag it to a new position.

I am pretty sure, but can't confirm, that I think this used to work with 2018.  But with 2019.2 and just updating to 2019.4, it still behaves incorrectly.  I can't see any differences with the dock panels on the left vs the right.  Even moving one of the left panels to right at runtime does not re-pin that panel.

Occasionally it does re-pin the dock panel correctly though, but 99% of the time it doesn't.  I can't consistently find a pattern that makes it work.

In trying to create a demo for you, I created a new project and added left, right and center dock panels.  However, it works fine, but so far it is a simple example as compared with my main app.  So I'm at a loss to know why my main app isn't working correctly.  Any ideas before I dig into it any further that might save me some time?

Comments

  • 5 Comments sorted by Votes Date Added
  • I cannot reproduce this. And since this never was a problem, I have no actual idea of what can be wrong.
  • I found the issue so maybe I can't do what I want to do.  In the dock panels that won't pin itself back again, I have a TTreeView with an OnEnter event that shows a specific tabbed dock panel.  If I remove that dockpanel.show method, then the panel pins fine.  Having the show method causes it to not pin.

    In other words, the treeview is in dock panel 1 and in the treeview OnEnter event I show dock panel 4.  this is because that tree view relates to what's in dock panel 4. I also have another dock panel with a tree view and it shows a different dock panel when entered and likewise it also cannot be re-pined.

    Is the Show method not the right way to do this?  Seems that when the undocked panel is slide open, then OnEnter event occurs for the treeview, but is it really entered a that point?  If so, then maybe Show method is moving focus preventing the click of the pin from being invoked to re-pin the panel?

    Sample demo here:

  • Unfortunately this will not work. You cannot change docking layout (which is implicitly happens when you try to show some panel) while another panel sliding in or out.
  • I changed it to use the TreeView's OnClick event (better anyway) and that does what I want and I can still pin it back.

    Thanks,
    Eric
Sign In or Register to comment.