CollectionControlDialog
Inheritance: System.Windows.Window, System.Windows.Markup.IComponentConnector
コード例 #1
0
        private void CollectionControlButton_Click(object sender, RoutedEventArgs e)
        {
            var collectionControlDialog = new CollectionControlDialog();

            collectionControlDialog.ItemsSource     = this.ItemsSource;
            collectionControlDialog.NewItemTypes    = this.NewItemTypes;
            collectionControlDialog.ItemsSourceType = this.ItemsSourceType;
            collectionControlDialog.IsReadOnly      = this.IsReadOnly;
            collectionControlDialog.ShowDialog();
        }
コード例 #2
0
        private void CollectionControlButton_Click(object sender, RoutedEventArgs e)
        {
            var collectionControlDialog = new CollectionControlDialog();
            var binding = new Binding("ItemsSource")
            {
                Source = this, Mode = BindingMode.TwoWay
            };

            BindingOperations.SetBinding(collectionControlDialog, CollectionControlDialog.ItemsSourceProperty, binding);
            collectionControlDialog.NewItemTypes    = this.NewItemTypes;
            collectionControlDialog.ItemsSourceType = this.ItemsSourceType;
            collectionControlDialog.IsReadOnly      = this.IsReadOnly;
            collectionControlDialog.ShowDialog();
        }
コード例 #3
0
        private void CollectionControlButton_Click(object sender, RoutedEventArgs e)
        {
            var collectionControlDialog = new CollectionControlDialog();
            var binding = new Binding("ItemsSource")
            {
                Source = this, Mode = BindingMode.TwoWay
            };

            BindingOperations.SetBinding(collectionControlDialog, CollectionControlDialog.ItemsSourceProperty, binding);
            collectionControlDialog.NewItemTypes      = this.NewItemTypes;
            collectionControlDialog.ItemsSourceType   = this.ItemsSourceType;
            collectionControlDialog.IsReadOnly        = this.IsReadOnly;
            collectionControlDialog.EditorDefinitions = this.EditorDefinitions;
            var collectionUpdated = collectionControlDialog.ShowDialog();

            if (collectionUpdated.HasValue && collectionUpdated.Value)
            {
                this.RaiseEvent(new RoutedEventArgs(CollectionControlButton.CollectionUpdatedEvent, this));
            }
        }
コード例 #4
0
 private void CollectionControlButton_Click( object sender, RoutedEventArgs e )
 {
   CollectionControlDialog collectionControlDialog = new CollectionControlDialog();
   collectionControlDialog.ItemsSource = this.ItemsSource;
   collectionControlDialog.NewItemTypes = this.NewItemTypes;
   collectionControlDialog.ItemsSourceType = this.ItemsSourceType;
   collectionControlDialog.IsReadOnly = this.IsReadOnly;
   collectionControlDialog.ShowDialog();
 }