Changeset 15914 for branches/2839_HiveProjectManagement/HeuristicLab.Clients.Hive.JobManager/3.3/Views
- Timestamp:
- 04/23/18 14:44:04 (7 years ago)
- Location:
- branches/2839_HiveProjectManagement/HeuristicLab.Clients.Hive.JobManager/3.3/Views
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2839_HiveProjectManagement/HeuristicLab.Clients.Hive.JobManager/3.3/Views/HiveResourceSelector.cs
r15913 r15914 46 46 private const string NEW_SELECTION_TAG = " [new selection]"; 47 47 private const string CHANGED_SELECTION_TAG = " [changed selection]"; 48 private const string ADDED_SELECTION_TAG = " [added selection]"; 49 private const string REMOVED_SELECTION_TAG = " [removed selection]"; 50 private const string INCLUDED_TAG = " [included]"; 51 private const string ADDED_INCLUDE_TAG = " [added include]"; 52 private const string REMOVED_INCLUDE_TAG = " [removed include]"; 48 53 49 54 private readonly HashSet<TreeNode> mainTreeNodes = new HashSet<TreeNode>(); … … 68 73 private readonly Color selectedBackColor = Color.DodgerBlue; 69 74 private readonly Color selectedForeColor = Color.White; 75 private readonly Color controlTextColor = SystemColors.ControlText; 76 private readonly Color grayTextColor = SystemColors.GrayText; 70 77 71 78 private string currentSearchString; … … 133 140 get { return selectedProject; } 134 141 set { 142 if (selectedProject == value) return; 135 143 lastSelectedProject = selectedProject; 136 if (selectedProject == value) return;137 144 selectedProject = value; 145 146 if (JobId == Guid.Empty || JobId == null) selectedResourceIds = null; 138 147 UpdateResourceTree(); 139 148 ExtractStatistics(); … … 523 532 } else if (newIncludedResources.Select(x => x.Id).Contains(newResource.Id)) { 524 533 newNode.Checked = true; 525 newNode.ForeColor = SystemColors.GrayText;534 newNode.ForeColor = grayTextColor; 526 535 } 527 536 528 537 if (includedResources.Select(x => x.Id).Contains(newResource.Id) && newIncludedResources.Select(x => x.Id).Contains(newResource.Id)) { 529 newNode.Text += " [included]";538 newNode.Text += INCLUDED_TAG; 530 539 } else if (addedIncludes.Select(x => x.Id).Contains(newResource.Id)) { 531 540 newNode.BackColor = addedIncludeColor; 532 newNode.ForeColor = SystemColors.GrayText;533 newNode.Text += " [added include]";541 newNode.ForeColor = grayTextColor; 542 newNode.Text += ADDED_INCLUDE_TAG; 534 543 } else if (removedIncludes.Select(x => x.Id).Contains(newResource.Id)) { 535 544 newNode.BackColor = removedIncludeColor; 536 newNode.Text += " [removed include]";545 newNode.Text += REMOVED_INCLUDE_TAG; 537 546 } 538 547 539 548 if (addedAssignments.Select(x => x.Id).Contains(newResource.Id)) { 540 549 newNode.BackColor = addedAssignmentColor; 541 newNode.ForeColor = SystemColors.ControlText;542 newNode.Text += " [added selection]";550 newNode.ForeColor = controlTextColor; 551 newNode.Text += ADDED_SELECTION_TAG; 543 552 } else if (removedAssignments.Select(x => x.Id).Contains(newResource.Id)) { 544 553 newNode.BackColor = removedAssignmentColor; 545 newNode.ForeColor = SystemColors.ControlText;546 newNode.Text += " [removed selection]";554 newNode.ForeColor = controlTextColor; 555 newNode.Text += REMOVED_SELECTION_TAG; 547 556 } 548 557 -
branches/2839_HiveProjectManagement/HeuristicLab.Clients.Hive.JobManager/3.3/Views/RefreshableHiveJobView.cs
r15913 r15914 411 411 } else { 412 412 HiveClient.StartJob((Exception ex) => ErrorHandling.ShowErrorDialog(this, "Start failed.", ex), Content, new CancellationToken()); 413 UpdateSelectorDialog(); 413 414 } 414 415 } … … 473 474 } 474 475 }, null); 476 UpdateSelectorDialog(); 475 477 } 476 478 … … 480 482 Content, 481 483 new CancellationToken()); 484 UpdateSelectorDialog(); 482 485 } 483 486 … … 515 518 return HiveServiceLocator.Instance.CallHiveService(s => s.GetProject(projectId)); 516 519 } 520 521 private void UpdateSelectorDialog() { 522 if(hiveResourceSelectorDialog != null) { 523 hiveResourceSelectorDialog = null; 524 //hiveResourceSelectorDialog.JobId = Content.Job.Id; 525 //hiveResourceSelectorDialog.SelectedProjectId = Content.Job.ProjectId; 526 //hiveResourceSelectorDialog.SelectedResourceIds = Content.Job.ResourceIds; 527 } 528 } 517 529 #endregion 518 530
Note: See TracChangeset
for help on using the changeset viewer.