Example #1
0
        void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target)
        {
            switch (connectionId)
            {
            case 1:
                this.Documents = ((AvalonDock.Layout.LayoutDocumentPane)(target));
                return;

            case 2:
                this.Results = ((System.Windows.Controls.DataGrid)(target));
                return;

            case 3:
                this.PropertyGrid = ((Xceed.Wpf.Toolkit.PropertyGrid.PropertyGrid)(target));
                return;
            }
            this._contentLoaded = true;
        }
Example #2
0
        protected override void InternalDock()
        {
            var root = Root as LayoutRoot;
            LayoutDocumentPane documentPane = null;

            if (root.LastFocusedDocument != null &&
                root.LastFocusedDocument != this)
            {
                documentPane = root.LastFocusedDocument.Parent as LayoutDocumentPane;
            }

            if (documentPane == null)
            {
                documentPane = root.Descendents().OfType <LayoutDocumentPane>().FirstOrDefault();
            }


            bool added = false;

            if (root.Manager.LayoutUpdateStrategy != null)
            {
                added = root.Manager.LayoutUpdateStrategy.BeforeInsertDocument(root, this, documentPane);
            }

            if (!added)
            {
                if (documentPane == null)
                {
                    throw new InvalidOperationException("Layout must contains at least one LayoutDocumentPane in order to host documents");
                }

                documentPane.Children.Add(this);
                added = true;
            }

            if (root.Manager.LayoutUpdateStrategy != null)
            {
                root.Manager.LayoutUpdateStrategy.AfterInsertDocument(root, this);
            }


            base.InternalDock();
        }
 public LayoutDocumentPaneGroup(LayoutDocumentPane documentPane)
 {
     Children.Add(documentPane);
 }
        void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target)
        {
            switch (connectionId)
            {
            case 1:
                this.toolsGroup = ((Fluent.RibbonContextualTabGroup)(target));
                return;

            case 2:
                this.buttonLoad = ((Fluent.Button)(target));

            #line 20 "..\..\..\MainWindow.xaml"
                this.buttonLoad.Click += new System.Windows.RoutedEventHandler(this.bookLoadButton_Click);

            #line default
            #line hidden
                return;

            case 3:
                this.buttonSetting = ((Fluent.Button)(target));

            #line 22 "..\..\..\MainWindow.xaml"
                this.buttonSetting.Click += new System.Windows.RoutedEventHandler(this.buttonSetting_Click);

            #line default
            #line hidden
                return;

            case 4:
                this.explorerLoad = ((Fluent.Button)(target));

            #line 23 "..\..\..\MainWindow.xaml"
                this.explorerLoad.Click += new System.Windows.RoutedEventHandler(this.explorerLoad_Click);

            #line default
            #line hidden
                return;

            case 5:
                this.AddNewInstBtn_ = ((Fluent.Button)(target));

            #line 24 "..\..\..\MainWindow.xaml"
                this.AddNewInstBtn_.Click += new System.Windows.RoutedEventHandler(this.AddNewInstBtn__Click);

            #line default
            #line hidden
                return;

            case 6:
                this.BatchControlBtn_ = ((Fluent.Button)(target));

            #line 25 "..\..\..\MainWindow.xaml"
                this.BatchControlBtn_.Click += new System.Windows.RoutedEventHandler(this.BatchControlBtn_Click);

            #line default
            #line hidden
                return;

            case 7:
                this.MROPositionLoadBtn_ = ((Fluent.Button)(target));

            #line 26 "..\..\..\MainWindow.xaml"
                this.MROPositionLoadBtn_.Click += new System.Windows.RoutedEventHandler(this.MROPositionLoadBtn_Click);

            #line default
            #line hidden
                return;

            case 8:
                this.DeltaHedgeMonitorBtn_ = ((Fluent.Button)(target));

            #line 27 "..\..\..\MainWindow.xaml"
                this.DeltaHedgeMonitorBtn_.Click += new System.Windows.RoutedEventHandler(this.DeltaHedgeMonitorBtn_Click);

            #line default
            #line hidden
                return;

            case 9:
                this.ResualtDocking = ((AvalonDock.DockingManager)(target));
                return;

            case 10:
                this.DocumentPaneGroup_ = ((AvalonDock.Layout.LayoutDocumentPaneGroup)(target));
                return;

            case 11:
                this.DocumentPane_ = ((AvalonDock.Layout.LayoutDocumentPane)(target));
                return;

            case 12:
                this.StartDocument_ = ((AvalonDock.Layout.LayoutDocument)(target));
                return;

            case 13:
                this.ouputPane_ = ((AvalonDock.Layout.LayoutDocumentPane)(target));
                return;

            case 14:
                this.ExplorerPaneGroup = ((AvalonDock.Layout.LayoutAnchorablePaneGroup)(target));
                return;

            case 15:
                this.ExplorerPortfolio_ = ((AvalonDock.Layout.LayoutAnchorablePane)(target));
                return;
            }
            this._contentLoaded = true;
        }
 void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target) {
     switch (connectionId)
     {
     case 1:
     this.toolsGroup = ((Fluent.RibbonContextualTabGroup)(target));
     return;
     case 2:
     this.buttonLoad = ((Fluent.Button)(target));
     
     #line 20 "..\..\..\MainWindow.xaml"
     this.buttonLoad.Click += new System.Windows.RoutedEventHandler(this.bookLoadButton_Click);
     
     #line default
     #line hidden
     return;
     case 3:
     this.buttonSetting = ((Fluent.Button)(target));
     
     #line 22 "..\..\..\MainWindow.xaml"
     this.buttonSetting.Click += new System.Windows.RoutedEventHandler(this.buttonSetting_Click);
     
     #line default
     #line hidden
     return;
     case 4:
     this.explorerLoad = ((Fluent.Button)(target));
     
     #line 23 "..\..\..\MainWindow.xaml"
     this.explorerLoad.Click += new System.Windows.RoutedEventHandler(this.explorerLoad_Click);
     
     #line default
     #line hidden
     return;
     case 5:
     this.AddNewInstBtn_ = ((Fluent.Button)(target));
     
     #line 24 "..\..\..\MainWindow.xaml"
     this.AddNewInstBtn_.Click += new System.Windows.RoutedEventHandler(this.AddNewInstBtn__Click);
     
     #line default
     #line hidden
     return;
     case 6:
     this.BatchControlBtn_ = ((Fluent.Button)(target));
     
     #line 25 "..\..\..\MainWindow.xaml"
     this.BatchControlBtn_.Click += new System.Windows.RoutedEventHandler(this.BatchControlBtn_Click);
     
     #line default
     #line hidden
     return;
     case 7:
     this.MROPositionLoadBtn_ = ((Fluent.Button)(target));
     
     #line 26 "..\..\..\MainWindow.xaml"
     this.MROPositionLoadBtn_.Click += new System.Windows.RoutedEventHandler(this.MROPositionLoadBtn_Click);
     
     #line default
     #line hidden
     return;
     case 8:
     this.DeltaHedgeMonitorBtn_ = ((Fluent.Button)(target));
     
     #line 27 "..\..\..\MainWindow.xaml"
     this.DeltaHedgeMonitorBtn_.Click += new System.Windows.RoutedEventHandler(this.DeltaHedgeMonitorBtn_Click);
     
     #line default
     #line hidden
     return;
     case 9:
     this.ResualtDocking = ((AvalonDock.DockingManager)(target));
     return;
     case 10:
     this.DocumentPaneGroup_ = ((AvalonDock.Layout.LayoutDocumentPaneGroup)(target));
     return;
     case 11:
     this.DocumentPane_ = ((AvalonDock.Layout.LayoutDocumentPane)(target));
     return;
     case 12:
     this.StartDocument_ = ((AvalonDock.Layout.LayoutDocument)(target));
     return;
     case 13:
     this.ouputPane_ = ((AvalonDock.Layout.LayoutDocumentPane)(target));
     return;
     case 14:
     this.ExplorerPaneGroup = ((AvalonDock.Layout.LayoutAnchorablePaneGroup)(target));
     return;
     case 15:
     this.ExplorerPortfolio_ = ((AvalonDock.Layout.LayoutAnchorablePane)(target));
     return;
     }
     this._contentLoaded = true;
 }