本文整理汇总了C#中AvalonDock.DockingManager.Show方法的典型用法代码示例。如果您正苦于以下问题:C# DockingManager.Show方法的具体用法?C# DockingManager.Show怎么用?C# DockingManager.Show使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类AvalonDock.DockingManager
的用法示例。
在下文中一共展示了DockingManager.Show方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Show
/// <summary>
/// Show <see cref="DocumentContent"/> as tabbed document inside the provided <see cref="DockingManager"/>
/// </summary>
/// <param name="manager">Docking manager target</param>
/// <param name="showAsFloatingWindow">True if document should be shown inside a floating window (<see cref="DocumentFloatingWindow"/>)</param>
public void Show(DockingManager manager, bool showAsFloatingWindow)
{
if (Manager != null && Manager != manager)
throw new InvalidOperationException("Please remove the content from previous DockingManager (using the Close method)");
if (!CanExecuteCommand(ManagedContentCommands.Show))
throw new InvalidOperationException("This operation can be executed in this state");
manager.Show(this, showAsFloatingWindow);
manager.Documents.Add(this);
}
示例2: ShowAsDocument
/// <summary>
/// Show as <see cref="DockableContent"/> as a tabbed document under the provided <see cref="DockingManager"/>
/// </summary>
public void ShowAsDocument(DockingManager manager)
{
if (Manager != null && Manager != manager)
throw new InvalidOperationException("Please remove the content from previous DockingManager (using the Close method)");
//Manager = manager;
if (manager == null && !CanExecuteCommand(DockableContentCommands.ShowAsDocument))
throw new InvalidOperationException("This operation can be executed in this state");
manager.Show(this, DockableContentState.Document);
}
示例3: ShowAsFloatingWindow
/// <summary>
/// Show the content ad floating window
/// </summary>
/// <param name="dockableWindow">True if the resulting floating window can the be re-docked to the docking manager.</param>
public void ShowAsFloatingWindow(DockingManager manager, bool dockableWindow)
{
if (Manager != null && Manager != manager)
throw new InvalidOperationException("Please remove the content from previous DockingManager (using the Close method)");
//Manager = manager;
if (manager == null)
{
if (dockableWindow &&
!CanExecuteCommand(DockableContentCommands.DockableFloatingWindow))
throw new InvalidOperationException("This operation can be executed in this state");
if (!dockableWindow &&
!CanExecuteCommand(DockableContentCommands.FloatingWindow))
throw new InvalidOperationException("This operation can be executed in this state");
}
manager.Show(this, dockableWindow ? DockableContentState.DockableWindow : DockableContentState.FloatingWindow);
}
示例4: Show
/// <summary>
/// Show <see cref="DockableContent"/> as docked pane
/// </summary>
public void Show(DockingManager manager, AnchorStyle desideredAnchor)
{
if (Manager != null && Manager != manager)
throw new InvalidOperationException("Please remove the content from previous DockingManager (using the Close method)");
if (manager == null && !CanExecuteCommand(ManagedContentCommands.Show))
throw new InvalidOperationException("This operation can be executed in this state");
if (State == DockableContentState.Docked)
{
//if already shown as docked content just activate it
Activate();
}
else
{
if (SavedStateAndPosition != null && State == DockableContentState.Hidden)
manager.Show(this, SavedStateAndPosition.State, desideredAnchor);
else
manager.Show(this, DockableContentState.Docked, desideredAnchor);
}
}