AvalonDock自动隐藏到窗格的一侧而不是窗口

时间:2010-01-07 18:30:39

标签: wpf docking dockpanel avalondock

我有以下AvalonDock XAML:

<ad:DockingManager Name="DockManager" Background="White">
    <ad:ResizingPanel  Orientation="Horizontal">
        <ad:DockablePane ad:ResizingPanel.ResizeWidth="300" Name="LeftSideBar" SelectedIndex="0">
            <ad:DockableContent Name="Connection" Title="Connection" IsCloseable="False">
                 // Some Stuff
            </ad:DockableContent>
            <ad:DockableContent Name="WIQuery" Title="WI Query" Focusable="True" IsCloseable="False">
                //Some more stuff
            </ad:DockableContent>
        </ad:DockablePane>


        <!--MIDDLE SECTION-->
        <ad:ResizingPanel Orientation="Vertical" MinWidth="50" MinHeight="50">
            <ad:ResizingPanel Orientation="Horizontal" >
                <ad:DocumentPane>
                    <ad:DocumentContent Title="Query Results" IsCloseable="False">
                        <ListBox ScrollViewer.HorizontalScrollBarVisibility="Disabled" Button.Click="PickWorkItem_Click" SelectionMode="Multiple" ItemTemplate="{StaticResource RowTemplate}"  Name="lstQueryResults" SelectionChanged="lstQueryResults_SelectionChanged" >
                            <ListBox.Resources>
                                <Style TargetType="{x:Type ListBoxItem}">
                                    <Style.Resources>
                                        <SolidColorBrush x:Key="{x:Static SystemColors.HighlightTextBrushKey}" Color="Black"/>
                                        <SolidColorBrush x:Key="{x:Static SystemColors.ControlTextBrushKey}" Color="Black"/>
                                    </Style.Resources>
                                    <Style.Triggers>
                                        <DataTrigger Value="True">
                                            <DataTrigger.Binding>
                                                <MultiBinding Converter="{StaticResource DisableWorkItemConverter}">
                                                    <Binding ElementName="MainForm" Path="PickedWorkItemID"/>
                                                    <Binding Path="WorkItemForColumn.Id"/>
                                                </MultiBinding>
                                            </DataTrigger.Binding>
                                            <Setter Property="IsEnabled" Value="False"/>
                                            <Setter Property="loc:Main.IsCurrentItemEnabledChanged" Value="True"/>
                                        </DataTrigger>
                                    </Style.Triggers>
                                </Style>
                            </ListBox.Resources>
                        </ListBox>
                    </ad:DocumentContent>
                </ad:DocumentPane>
                <ad:DockablePane ad:ResizingPanel.ResizeWidth="120" >
                    <ad:DockableContent Title="Query Options" IsCloseable="False" HideOnClose="True">
                        <CheckBox Margin="5" IsChecked="{Binding Path=VisibilityOfWorkItemColumnTitles, Converter={StaticResource VisibilityToBooleanConverter}}" >Show Titles</CheckBox>
                    </ad:DockableContent>
                </ad:DockablePane>
            </ad:ResizingPanel>

            <ad:DockablePane>
                <ad:DockableContent x:Name="WIPadDock" Title="WorkItem Pad" IsCloseable="False">
                    <ScrollViewer x:Name="WIPadCntr" VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Disabled">
                        <dot:ZipperPanel ChildrenPerRow="4" SpacingX="120" SpacingY="10" Name="CanvasPad"  RenderTransformOrigin="0,0"></dot:ZipperPanel>
                    </ScrollViewer>
                </ad:DockableContent>
            </ad:DockablePane>
        </ad:ResizingPanel>

        <!--RIGHT SECTION-->
        <ad:DockablePane MinWidth="50" MinHeight="50" ad:ResizingPanel.ResizeWidth="300"  Name="RightSideBar" SelectedIndex="1">
            <ad:DockableContent Title="Add Links" Name="tabAddLinks" IsCloseable="False">
            </ad:DockableContent>
        </ad:DockablePane>
    </ad:ResizingPanel>
</ad:DockingManager>

项目WIPadDock将最终被折叠。当它折叠时,它移动到窗口的一侧而不是中间窗格。

有没有办法让它站在一边?

以下是一些更清晰的图片:

Pane expanded http://img215.imageshack.us/img215/8725/avalondock1.png

Pane hidden http://img215.imageshack.us/img215/2763/avalondock2.png

0 个答案:

没有答案