Hi,
We are currently implementing the Docking control in our application. As a service to the user
we want to save the current layout when the applications exits and load it when the user starts
the application again.
We have a document panel that shows the open documents of the user and a empty
document with an icon in the header that, when a user clicks it, creates a new document
(like Internet Explorer 7 - 8 tab panel). We do this by registering for the SelectionChanged
event of the RadPaneGroup.
The problem is that, when we use the LoadLayout method, the SelectionChanged event doesn't
get registered/fired either using XAML or hooking it up in the codebehind.
Have you got any suggestions? A trimmed version of the code is listed below.
Kind regards,
Jerome
We are currently implementing the Docking control in our application. As a service to the user
we want to save the current layout when the applications exits and load it when the user starts
the application again.
We have a document panel that shows the open documents of the user and a empty
document with an icon in the header that, when a user clicks it, creates a new document
(like Internet Explorer 7 - 8 tab panel). We do this by registering for the SelectionChanged
event of the RadPaneGroup.
The problem is that, when we use the LoadLayout method, the SelectionChanged event doesn't
get registered/fired either using XAML or hooking it up in the codebehind.
Have you got any suggestions? A trimmed version of the code is listed below.
Kind regards,
Jerome
<radDock:RadDocking x:Name="DockingScreen"> |
<radDock:RadDocking.DocumentHost> |
<radDock:RadSplitContainer> |
<radDock:RadPaneGroup x:Name="DocumentPane" SelectionChanged="DocumentPane_SelectionChanged" > |
<radDock:RadDocumentPane x:Name="NewTab" CanFloat="False" CanUserClose="False" CanUserPin="False" HeaderTemplate="{StaticResource NewTabStyle}" radDock:RadDocking.SerializationTag="NewTabPanel" /> |
</radDock:RadPaneGroup> |
</radDock:RadSplitContainer> |
</radDock:RadDocking.DocumentHost> |
</radDock:RadDocking x:Name="DockingScreen"> |
private void DocumentPane_SelectionChanged ( object sender, RoutedEventArgs e ) |
{ |
if ( ( ( RadPaneGroup ) sender ).SelectedPane != null ) |
{ |
if ( ( ( RadPaneGroup ) sender ).SelectedPane.Name == "NewTab" ) |
{ |
// Logic to add new document |
} |
} |
} |