public void updateRulesPane(RuleList ruleList) { int ruleNumber = 1; foreach (Rule rule in ruleList.Rules) { RulePane rulePane = getRulePane("Rule" + ruleNumber, rule.Condition, rule.Value); // TODO bepaal naam op basis van formule this.taskPaneControl.RulesStack.newChild(rulePane) .withRemoveButton() .addToBottom(); ruleNumber++; } defaultValueTextBox = new System.Windows.Controls.TextBox(); defaultValueTextBox.Text = ruleList.DefaultValue; defaultValueTextBox.TextChanged += (o, e) => updateFormulaInExcel(); defaultValuePane = VitaLib.src.TitledCollapsablePaneBuilder.create("Default value") .addIndentedChild(defaultValueTextBox) .collapsed(false) .build(); this.taskPaneControl.Stack.Children.Add(defaultValuePane); }
public static TitledCollapsablePaneBuilder create(String title) { CollapsablePane pane = new CollapsablePane(); return(new TitledCollapsablePaneBuilder(pane, title)); }
private TitledCollapsablePaneBuilder(CollapsablePane pane, String title) { this.pane = pane; this.title = title; }