- Timestamp:
- 11/15/12 14:08:11 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Clients.Hive.JobManager/3.3/Views/RefreshableHiveJobView.cs
r8884 r8914 45 45 private ProgressView progressView; 46 46 private HiveResourceSelectorDialog hiveResourceSelectorDialog; 47 private bool SuppressEvents { get; set; } 47 48 48 49 public new RefreshableJob Content { … … 122 123 protected override void OnContentChanged() { 123 124 base.OnContentChanged(); 124 if (Content == null) { 125 nameTextBox.Text = string.Empty; 126 executionTimeTextBox.Text = string.Empty; 127 resourceNamesTextBox.Text = string.Empty; 128 isPrivilegedCheckBox.Checked = false; 129 logView.Content = null; 130 refreshAutomaticallyCheckBox.Checked = false; 131 runCollectionViewHost.Content = null; 132 } else { 133 nameTextBox.Text = Content.Job.Name; 134 executionTimeTextBox.Text = Content.ExecutionTime.ToString(); 135 resourceNamesTextBox.Text = Content.Job.ResourceNames; 136 isPrivilegedCheckBox.Checked = Content.Job.IsPrivileged; 137 refreshAutomaticallyCheckBox.Checked = Content.RefreshAutomatically; 138 logView.Content = Content.Log; 139 runCollectionViewHost.Content = GetAllRunsFromJob(Content); 125 SuppressEvents = true; 126 try { 127 if (Content == null) { 128 nameTextBox.Text = string.Empty; 129 executionTimeTextBox.Text = string.Empty; 130 resourceNamesTextBox.Text = string.Empty; 131 isPrivilegedCheckBox.Checked = false; 132 logView.Content = null; 133 refreshAutomaticallyCheckBox.Checked = false; 134 runCollectionViewHost.Content = null; 135 } else { 136 nameTextBox.Text = Content.Job.Name; 137 executionTimeTextBox.Text = Content.ExecutionTime.ToString(); 138 resourceNamesTextBox.Text = Content.Job.ResourceNames; 139 isPrivilegedCheckBox.Checked = Content.Job.IsPrivileged; 140 refreshAutomaticallyCheckBox.Checked = Content.RefreshAutomatically; 141 logView.Content = Content.Log; 142 runCollectionViewHost.Content = GetAllRunsFromJob(Content); 143 } 144 } 145 finally { 146 SuppressEvents = false; 140 147 } 141 148 hiveExperimentPermissionListView.Content = null; // has to be filled by refresh button … … 428 435 429 436 private void refreshAutomaticallyCheckBox_CheckedChanged(object sender, EventArgs e) { 430 if (Content != null ) Content.RefreshAutomatically = refreshAutomaticallyCheckBox.Checked;437 if (Content != null && !SuppressEvents) Content.RefreshAutomatically = refreshAutomaticallyCheckBox.Checked; 431 438 } 432 439 433 440 private void isPrivilegedCheckBox_Validated(object sender, EventArgs e) { 434 if (Content != null ) Content.Job.IsPrivileged = isPrivilegedCheckBox.Checked;441 if (Content != null && !SuppressEvents) Content.Job.IsPrivileged = isPrivilegedCheckBox.Checked; 435 442 } 436 443
Note: See TracChangeset
for help on using the changeset viewer.