Beispiel #1
0
 public SettingsForm()
 {
     InitializeComponent();
     IApplicationSettings settings = new ApplicationSettings();
     _presenter = new SettingsPresenter(this, settings);
     _presenter.Initialize();
 }
Beispiel #2
0
        private void Add(Function aFunction)
        {
            var settings = new ApplicationSettings();
            var aNode = new FunctionNode(aFunction, settings.DisplayFunctionsSignatureAndReturnType);

            Func<FunctionNodeGroup, bool> nodeThatGroupsTheFunction = node => node.Groups(aNode);
            if (_functionsByName.Any(nodeThatGroupsTheFunction))
            {
                _functionsByName.First(nodeThatGroupsTheFunction).Group(aNode);
            }
            else
            {
                var aFunctionGroup = new FunctionNodeGroup(aNode);
                _functionsByName.Add(aFunctionGroup);

                _model.Nodes.Add(aFunctionGroup);
            }
        }