/// <summary> /// Adds a Window to the bar. /// </summary> /// <param name="window">The Window to be added</param> public void addWindow(ODockWindow window) { window.VisibleChanged += Window_VisibleChanged; windowList.Add(window); }
private void launchWindow(ODockWindow window, bool visible = true) { window.Visible = visible; DockContainer.launch(window); WindowManager.addWindow(window); }
/// <summary> /// Add a Window on the Dock Container. /// Please note that the Tag property of the Window will contains the indentification Index, so do not change! /// </summary> /// <param name="window">The Window (ODockWindow control)</param> public void launch(ODockWindow window) { Controls.Add(window); window.Move += Window_Move; window.MoveEnded += Window_MoveEnded; window.VisibleChanged += Window_VisibleChanged; window.ToggleDockable += Window_ToggleDockable; int windowIndex = getAvailableIndex(); windowInfoStruct info = new windowInfoStruct { index = windowIndex, dock = dockMode.Floating, window = window, dockable = true }; windowInfo.Add(info); window.Tag = windowIndex; window.container = this; window.PerformLayout(); window.BringToFront(); }