Hi,
My company has been evaluating a number of different docking frameworks to use in our product, and for the most part, your control suits our needs the best. However, we are finding that your control is noticeably slower when changing the active tab inside a TabbedMdiContainer compared to the native WPF tab control and a competitor's control (set up as close to identically as possible).
To be clear: we have 9 DockingWindows docked in a TabbedMdiContainer. The first time we click on each of the tabs they are slow to load, as is expected, especially for the tabs containing more complex views (the WPF tab control and your competitors are also slow). However, the second time we click on each of the tabs, the built-in WPF tab control and some of the competing docking managers are very fast; your control, in comparison, has a noticeable delay for the more complex views.The delay is less than the first time the tabs are visited, but still slow compared to the alternatives.
I am already setting ItemContainerRetentionMode="Wrapped".
This seems similar to a problem reported a number of years ago: http://www.actiprosoftware.com/community/thread/20403/switching-between-tabs-in-a-docking-window-is#101446
I have included the xaml and code behind that I am using to construct the DockSite.
Any help would be greatly appreciated, as otherwise we will need to choose a different control.
Thanks a lot!
View
<docking:DockSite x:Name="DockSite"
ToolWindowsTabPlacement="Top"
CanDocumentWindowsRaft="True"
IsLiveSplittingEnabled="True"
WindowDragged="DockSite_OnWindowDragged"
WindowClosed="DockSite_OnWindowClosed"
CanDocumentWindowsEditTitles="True"
ItemContainerRetentionMode="Wrapped"
DocumentItemsSource="{Binding RHSViewModelMap}"
WindowRegistered="DockSite_OnWindowRegistered">
<docking:DockSite.Resources>
<ResourceDictionary>
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="DataTemplates.xaml"/>
</ResourceDictionary.MergedDictionaries>
</ResourceDictionary>
</docking:DockSite.Resources>
<docking:Workspace>
<docking:TabbedMdiHost>
<docking:TabbedMdiContainer>
</docking:TabbedMdiContainer>
</docking:TabbedMdiHost>
</docking:Workspace>
</docking:DockSite>
Code Behind:
private void DockSite_OnWindowRegistered(object sender, DockingWindowEventArgs e)
{
DockSite dockSite = sender as DockSite;
if (dockSite == null)
return;
// Ensure the DockingWindow exists and is generated for an item
DockingWindow dockingWindow = e.Window;
if (dockingWindow == null || !dockingWindow.IsContainerForItem)
return;
dockingWindow.Title = ((INamedViewModel) dockingWindow.DataContext).Name;
if (!dockingWindow.IsOpen)
{
dockingWindow.MoveToMdi(dockSite);
}
}
[Modified 10 years ago]