Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
11/18/15 16:33:27 (8 years ago)
Author:
jkarder
Message:

#2116: merged r13014, r13244 and r13245 into stable

File:
1 edited

Legend:

Unmodified
Added
Removed
  • stable/HeuristicLab.Operators.Views.GraphVisualization.Views/3.3/OperatorGraphView.cs

    r12009 r13258  
    2525using System.Windows.Forms;
    2626using HeuristicLab.Core;
     27using HeuristicLab.Core.Views;
    2728using HeuristicLab.MainForm;
    2829using HeuristicLab.MainForm.WindowsForms;
     
    140141          if (shapeInfo != null) {
    141142            IOperator op = this.VisualizationInfo.GetOperatorForShapeInfo(shapeInfo);
    142             IContentView view = MainFormManager.MainForm.ShowContent(op);
    143             if (view != null) {
    144               view.ReadOnly = this.ReadOnly;
    145               view.Locked = this.Locked;
     143            IOperatorGraphOperator graphOp = op as IOperatorGraphOperator;
     144
     145            Control c = this;
     146            BreadcrumbViewHost vh;
     147
     148            do {
     149              c = c.Parent;
     150              vh = c as BreadcrumbViewHost;
     151            } while ((vh == null || !vh.EnableBreadcrumbs) && c != null);
     152
     153            if (graphOp != null && vh != null) {
     154              vh.AddBreadcrumbs(vh.Content);
     155              vh.AddBreadcrumb(graphOp.Name, graphOp.OperatorGraph);
     156              vh.Content = graphOp.OperatorGraph;
     157              vh.ReadOnly = ReadOnly;
     158              vh.Locked = Locked;
     159            } else {
     160              IContentView view = MainFormManager.MainForm.ShowContent(op);
     161              if (view != null) {
     162                view.ReadOnly = ReadOnly;
     163                view.Locked = Locked;
     164              }
    146165            }
     166
    147167            HandledMouseEventArgs eventArgs = e as HandledMouseEventArgs;
    148168            if (eventArgs != null)
Note: See TracChangeset for help on using the changeset viewer.