- Timestamp:
- 01/24/13 17:20:07 (12 years ago)
- Location:
- branches/UnloadJobs
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/UnloadJobs/HeuristicLab.Clients.Hive.JobManager/3.3/Views/RefreshableHiveJobView.Designer.cs
r9107 r9188 71 71 this.refreshButton = new System.Windows.Forms.Button(); 72 72 this.isPrivilegedCheckBox = new System.Windows.Forms.CheckBox(); 73 this.UnloadButton = new System.Windows.Forms.Button(); 73 74 this.refreshAutomaticallyCheckBox = new System.Windows.Forms.CheckBox(); 74 75 this.infoGroupBox = new System.Windows.Forms.GroupBox(); … … 91 92 // tabControl 92 93 // 94 this.tabControl.AllowDrop = true; 93 95 this.tabControl.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 94 96 | System.Windows.Forms.AnchorStyles.Left) … … 377 379 this.isPrivilegedCheckBox.CheckedChanged += new System.EventHandler(this.isPrivilegedCheckBox_CheckChanged); 378 380 // 381 // UnloadButton 382 // 383 this.UnloadButton.Image = HeuristicLab.Common.Resources.VSImageLibrary.Disconnect; 384 this.UnloadButton.Location = new System.Drawing.Point(30, 0); 385 this.UnloadButton.Name = "UnloadButton"; 386 this.UnloadButton.Size = new System.Drawing.Size(24, 24); 387 this.UnloadButton.TabIndex = 27; 388 this.toolTip.SetToolTip(this.UnloadButton, "Unload Job"); 389 this.UnloadButton.UseVisualStyleBackColor = true; 390 this.UnloadButton.Click += new System.EventHandler(this.UnloadButton_Click); 391 // 379 392 // refreshAutomaticallyCheckBox 380 393 // 381 394 this.refreshAutomaticallyCheckBox.AutoSize = true; 382 this.refreshAutomaticallyCheckBox.Location = new System.Drawing.Point( 30, 5);395 this.refreshAutomaticallyCheckBox.Location = new System.Drawing.Point(70, 3); 383 396 this.refreshAutomaticallyCheckBox.Name = "refreshAutomaticallyCheckBox"; 384 397 this.refreshAutomaticallyCheckBox.Size = new System.Drawing.Size(127, 17); … … 471 484 // RefreshableHiveJobView 472 485 // 473 this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);474 486 this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Inherit; 487 this.Controls.Add(this.UnloadButton); 475 488 this.Controls.Add(this.searchButton); 476 489 this.Controls.Add(this.isPrivilegedCheckBox); … … 505 518 #endregion 506 519 507 private System.Windows.Forms.TabControl tabControl;508 520 private System.Windows.Forms.Button startButton; 509 521 private System.Windows.Forms.Button stopButton; … … 539 551 private MainForm.WindowsForms.ViewHost runCollectionViewHost; 540 552 private System.Windows.Forms.Button searchButton; 553 private MainForm.WindowsForms.DragOverTabControl tabControl; 554 private System.Windows.Forms.Button UnloadButton; 541 555 542 556 } -
branches/UnloadJobs/HeuristicLab.Clients.Hive.JobManager/3.3/Views/RefreshableHiveJobView.cs
r9173 r9188 187 187 this.refreshButton.Enabled = Content.IsDownloadable && alreadyUploaded && !Content.IsProgressing; 188 188 this.Locked = !Content.IsControllable || Content.ExecutionState == ExecutionState.Started || Content.IsProgressing; 189 190 this.UnloadButton.Enabled = Content.HiveTasks != null && Content.HiveTasks.Count > 0 && alreadyUploaded && !Content.IsProgressing; 189 191 } 190 192 SetEnabledStateOfExecutableButtons(); … … 569 571 } 570 572 } 573 574 private void UnloadButton_Click(object sender, EventArgs e) { 575 Content.Unload(); 576 runCollectionViewHost.Content = null; 577 stateLogViewHost.Content = null; 578 hiveExperimentPermissionListView.Content = null; 579 jobsTreeView.Content = null; 580 581 SetEnabledStateOfControls(); 582 } 571 583 } 572 584 } -
branches/UnloadJobs/HeuristicLab.Clients.Hive.Views/3.3/TreeView/HiveTaskItemTreeView.cs
r9173 r9188 35 35 get { return (ItemCollection<HiveTask>)base.Content; } 36 36 set { base.Content = value; } 37 }38 39 protected override void OnContentChanged() {40 if (Content == null) {41 foreach (var t in Content) {42 t.Dispose();43 }44 }45 base.OnContentChanged();46 37 } 47 38 -
branches/UnloadJobs/HeuristicLab.Clients.Hive/3.3/RefreshableJob.cs
r9173 r9188 610 610 } 611 611 612 public void Unload() { 613 // stop result polling 614 if (refreshAutomatically) 615 RefreshAutomatically = false; 616 DisposeTasks(); 617 hiveTasks = new ItemCollection<HiveTask>(); 618 } 619 612 620 #region IDisposable Members 613 621 public void Dispose() {
Note: See TracChangeset
for help on using the changeset viewer.