protected override void BuildTemplate(TemplateBuilder builder)
 {
     builder
     .AddBinding(_window._textBoxName, _name.BindToTextBox())
     .AddBinding(_window._textBoxDescription, _description.BindToTextBox())
     .AddBinding(_window._comboBoxMode, _mode.BindToComboBox(ModeSelection));
 }
Exemplo n.º 2
0
 protected override void BuildTemplate(TemplateBuilder builder)
 {
     builder
     .AddBinding(_window._comboBoxModel, _model.BindToComboBox(_dbMapper.GetModelTypeSelection()))
     .AddBinding(_window._textBoxName, _name.BindToTextBox())
     .AddBinding(_window._textBoxDbName, _dbName.BindToTextBox())
     .AddBinding(_window._textBoxDescription, _description.BindToTextBox());
 }
Exemplo n.º 3
0
 protected override void BuildTemplate(TemplateBuilder builder)
 {
     builder
     .AddBinding(_window._comboBoxForeignKey, _foreignKey.BindToComboBox(_dbMapper.GetFkSelection(_dbTable)))
     .AddBinding(_window._comboBoxRefTable, _refTable.BindToComboBox(_refTableSelection))
     .AddBinding(_window._textBoxName, _name.BindToTextBox())
     .AddBinding(_window._textBoxDescription, _description.BindToTextBox())
     .AddBinding(_window._comboBoxDeleteRule, _deleteRule.BindToComboBox(GetRuleSelection()))
     .AddBinding(_window._comboBoxUpdateRule, _updateRule.BindToComboBox(GetRuleSelection()));
 }
 protected override void BuildTemplate(TemplateBuilder builder)
 {
     builder
     .GridRows("Auto", "Auto")
     .GridColumns("5*", "4*")
     .GridLineX(new GridPoint(0, 2), 1)
     .Layout(Orientation.Vertical)
     .WithFrozenTop(1)
     .AddBinding(_window._comboBoxDbSessionProvider, _dbSessionProvider.BindToComboBox(DbSessionProviderTypeSelection))
     .AddBinding(_window._checkBoxShowDbLog, _showDbLog.BindToCheckBox())
     .AddBinding(0, 0, _.DataSetMethod.BindToColumnHeader())
     .AddBinding(1, 0, _.DbTableProperty.BindToColumnHeader())
     .AddBinding(0, 1, _.DataSetMethod.BindToTextBlock(p => string.Format("{0}()", p.GetValue(_.DataSetMethod).Name)))
     .AddBinding(1, 1, _.DbTableProperty.BindToComboBox(_.DbTablePropertySelection));
 }
Exemplo n.º 5
0
 protected override void BuildTemplate(TemplateBuilder builder)
 {
     builder.GridRows("Auto", "Auto")
     .GridColumns("20", "*", "*")
     .Layout(Orientation.Vertical)
     .GridLineX(new GridPoint(1, 1), 2)
     .GridLineX(new GridPoint(1, 2), 2)
     .GridLineY(new GridPoint(1, 1), 1)
     .WithFrozenTop(1)
     .AddBinding(1, 0, this.BindToTextBlock(_.Parameter.DisplayName))
     .AddBinding(2, 0, this.BindToTextBlock(_.Column.DisplayName))
     .AddBinding(0, 1, _.BindToRowHeader().WithStyle(RowHeader.Styles.Flat))
     .AddBinding(1, 1, _.Parameter.BindToTextBlock())
     .AddBinding(2, 1, _.Column.BindToComboBox(_.ColumnSelection))
     .AddBinding(_window._comboBoxPkType, _fkType.BindToComboBox(_modelMapper.GetKeyTypeSelection()))
     .AddBinding(_window._textBoxFkName, _fkName.BindToTextBox());
     ;
 }
Exemplo n.º 6
0
        public void AddBinding <T>(TemplateBuilder <T> builder, Scalar <INamedTypeSymbol> resourceType, Scalar <IPropertySymbol> resourceProperty, Scalar <string> message)
            where T : TemplateBuilder <T>
        {
            var resourceTypeValue = resourceType.Value;

            builder.AddBinding(_comboBoxResourceType, resourceType.BindToComboBox(GetResourceTypeSelection(resourceTypeValue)).ApplyRefresh((v, p) =>
            {
                Refresh(resourceType.Value != null);
            }));
            if (resourceTypeValue != null)
            {
                builder.AddBinding(_comboBoxResourceProperty, resourceProperty.BindToComboBox(GetResourcePropertySelection(resourceTypeValue)));
            }
            else
            {
                _comboBoxResourceType.IsEnabled = false;
            }
            builder.AddBinding(_textBoxMessage, message.BindToTextBox());
        }
Exemplo n.º 7
0
 protected override void BuildTemplate(TemplateBuilder builder)
 {
     builder
     .AddBinding(_window._comboBoxDbSessionProvider, _dbSessionProvider.BindToComboBox(DbSessionProviderTypeSelection))
     .AddBinding(_window._checkBoxShowLog, _showLog.BindToCheckBox());
 }