Last change
on this file since 3052 was
2924,
checked in by swagner, 15 years ago
|
Operator architecture refactoring (#95)
- implemented reviewers' comments on version r2917.
|
File size:
1.3 KB
|
Rev | Line | |
---|
[2818] | 1 | using HeuristicLab.Collections;
|
---|
[2655] | 2 | using HeuristicLab.MainForm;
|
---|
| 3 |
|
---|
| 4 | namespace HeuristicLab.Core.Views {
|
---|
[2917] | 5 | [View("VariableCollection View")]
|
---|
[2655] | 6 | [Content(typeof(VariableCollection), true)]
|
---|
[2727] | 7 | [Content(typeof(IObservableKeyedCollection<string, IVariable>), false)]
|
---|
[2687] | 8 | public partial class VariableCollectionView : NamedItemCollectionView<IVariable> {
|
---|
[2655] | 9 | /// <summary>
|
---|
| 10 | /// Initializes a new instance of <see cref="VariablesScopeView"/> with caption "Variables Scope View".
|
---|
| 11 | /// </summary>
|
---|
| 12 | public VariableCollectionView() {
|
---|
| 13 | InitializeComponent();
|
---|
| 14 | Caption = "VariableCollection";
|
---|
[2924] | 15 | itemsGroupBox.Text = "Variables";
|
---|
[2655] | 16 | }
|
---|
| 17 | /// <summary>
|
---|
| 18 | /// Initializes a new instance of <see cref="VariablesScopeView"/> with
|
---|
| 19 | /// the given <paramref name="scope"/>.
|
---|
| 20 | /// </summary>
|
---|
| 21 | /// <remarks>Calls <see cref="VariablesScopeView()"/>.</remarks>
|
---|
| 22 | /// <param name="scope">The scope whose variables should be represented visually.</param>
|
---|
[2727] | 23 | public VariableCollectionView(IObservableKeyedCollection<string, IVariable> content)
|
---|
[2655] | 24 | : this() {
|
---|
[2727] | 25 | Content = content;
|
---|
[2655] | 26 | }
|
---|
[2687] | 27 |
|
---|
| 28 | protected override IVariable CreateItem() {
|
---|
| 29 | IVariable item = new Variable();
|
---|
| 30 | item.Name = GetUniqueName(item.Name);
|
---|
| 31 | return item;
|
---|
| 32 | }
|
---|
[2655] | 33 | }
|
---|
| 34 | }
|
---|
Note: See
TracBrowser
for help on using the repository browser.