Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AvalonDock: Autohidden Anchorable appears totally invisible after dragging #1551

Open
Shameerpv opened this issue Nov 13, 2019 · 1 comment

Comments

@Shameerpv
Copy link

Shameerpv commented Nov 13, 2019

CanFloat property is set to False in my LayoutAnchorable control . The problem here is if the user try to drag the LayoutAnchorable (which is disabled using property) ,the LayoutAnchorable is getting removed from the pane and not visible anywhere. Is there any quick fix for issue?

<xcad:DockingManager SnapsToDevicePixels="True"
                             AllowMixedOrientation="True"
                             ShowSystemMenu="True"
                             VerticalAlignment="Stretch"
                             HorizontalAlignment="Stretch"
                             Margin="0 4 0 0 ">
            <xcad:LayoutRoot>
                <xcad:LayoutPanel Orientation="Horizontal">
        <xcad:LayoutDocumentPane ShowHeader="False">
                        <xcad:LayoutDocument Title="Indicators">
                            <TextBlock Text="123" />
                        </xcad:LayoutDocument>
                    </xcad:LayoutDocumentPane>
                 
            
                </xcad:LayoutPanel>
              <xcad:LayoutRoot.RightSide>
                    <xcad:LayoutAnchorSide>
                        <xcad:LayoutAnchorGroup >
    <xcad:LayoutAnchorable Title="Messages"                                                   
                                                   AutoHideWidth="300"
                                                   CanClose="False"
                                                   CanFloat="False"
                                                   CanHide="False">
                            <TextBlock Text="123" />
                        </xcad:LayoutAnchorable>
                        </xcad:LayoutAnchorGroup>
                    </xcad:LayoutAnchorSide>
                </xcad:LayoutRoot.LeftSide>
            </xcad:LayoutRoot>
        </xcad:DockingManager>`
```

This issue exists in version 3.5 and 3.6  . It was working finr in version 3.3
@XceedBoucherS
Copy link
Collaborator

Hi,
You are right. Thank you for reporting this. It will be fixed in v3.9.
In the meantime, you can go in file Xceed.Wpf.AvalonDock/DockingManager.cs,
in method StartDraggingFloatingWindowForContent,
and add the following check at the beginning of the method:
if( ( contentModel == null) || !contentModel.CanFloat ) return;

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants