コード例 #1
0
ファイル: PaneManager.cs プロジェクト: tritao/flood
 public static void AddPane(Pane pane)
 {
     if(FocusedPaneGroup == null)
     {
         FocusedPaneGroup = new PaneGroup(FocusedContainer);
         FocusedContainer.InsertPanel(FocusedPaneGroup);
     }
     FocusedPaneGroup.AddPane(pane);
 }
コード例 #2
0
ファイル: PaneManager.cs プロジェクト: tritao/flood
 /// <summary>
 /// Move pane to a container relative to targetPaneGroup. 
 /// </summary>
 /// <param name="pane">Pane to be moved</param>
 /// <param name="targetPaneGroup"> </param>
 /// <param name="depth">Refer a parent container of targetPaneGroup, each depth is one parent container away. 
 /// Depth 0 add a PaneContainer in the same container if the container is horizontal, if not
 /// adds the movedPane to a new child vertical container</param>
 /// <param name="moveRigth"> True to move pane to the rigth of targetPaneGroup </param>
 internal static void MovePaneHorizontally(TabButton pane, PaneGroup targetPaneGroup, uint depth, bool moveRigth)
 {
     var container = GetParentContainer(targetPaneGroup);
     if (!container.IsHorizontal)
     {
         var childContainer = new Container(container);
         childContainer.IsHorizontal = true;
         container.ReplacePanel(targetPaneGroup,childContainer,false);
         childContainer.InsertPanel(targetPaneGroup);
         container = childContainer;
     }
     var paneGroup = new PaneGroup(container);
     paneGroup.AddPage(pane);
     container.InsertPanel(paneGroup,targetPaneGroup,!moveRigth);
 }
コード例 #3
0
ファイル: PaneManager.cs プロジェクト: tritao/flood
 /// <summary>
 /// Move pane from the current PaneGroup to the targetPaneGroup. 
 /// </summary>
 /// <param name="pane">Pane to be moved</param>
 /// <param name="targetPaneGroup"></param>
 internal static void MovePane(TabButton pane, PaneGroup targetPaneGroup)
 {
     targetPaneGroup.AddPage(pane);
 }
コード例 #4
0
ファイル: PaneManager.cs プロジェクト: tritao/flood
 internal static void ShowDockHelper(PaneGroup paneGroup)
 {
     if (dockHelper == null || dockHelper.Disposed)
     {
         dockHelper = new DockHelper(paneGroup);
     }
     else
     {
         dockHelper.Parent = paneGroup;
         dockHelper.Invalidate();
     }
     dockHelper.IsHidden = false;
 }