Index: branches/HeuristicLab.TimeSeries/HeuristicLab.Clients.Hive.JobManager/3.3/Views/RefreshableHiveJobView.Designer.cs
===================================================================
--- branches/HeuristicLab.TimeSeries/HeuristicLab.Clients.Hive.JobManager/3.3/Views/RefreshableHiveJobView.Designer.cs	(revision 7268)
+++ branches/HeuristicLab.TimeSeries/HeuristicLab.Clients.Hive.JobManager/3.3/Views/RefreshableHiveJobView.Designer.cs	(revision 7460)
@@ -25,12 +25,11 @@
     private void InitializeComponent() {
       this.components = new System.ComponentModel.Container();
-      this.tabControl = new System.Windows.Forms.TabControl();
+      this.tabControl = new HeuristicLab.MainForm.WindowsForms.DragOverTabControl();
       this.tasksTabPage = new System.Windows.Forms.TabPage();
-      this.jobsTreeView = new HeuristicLab.Clients.Hive.Views.HiveTaskItemTreeView();
+      this.jobsTreeView = new HeuristicLab.Clients.Hive.Views.ExperimentManager.HiveTaskItemTreeView();
       this.permissionTabPage = new System.Windows.Forms.TabPage();
       this.refreshPermissionsButton = new System.Windows.Forms.Button();
       this.hiveExperimentPermissionListView = new HeuristicLab.Clients.Hive.JobManager.Views.HiveJobPermissionListView();
       this.runsTabPage = new System.Windows.Forms.TabPage();
-      this.runCollectionViewHost = new HeuristicLab.MainForm.WindowsForms.ViewHost();
       this.stateTabPage = new System.Windows.Forms.TabPage();
       this.stateLogViewHost = new HeuristicLab.MainForm.WindowsForms.ViewHost();
@@ -58,4 +57,5 @@
       this.calculatingLabel = new System.Windows.Forms.Label();
       this.jobsLabel = new System.Windows.Forms.Label();
+      this.runCollectionViewHost = new HeuristicLab.MainForm.WindowsForms.ViewHost();
       this.tabControl.SuspendLayout();
       this.tasksTabPage.SuspendLayout();
@@ -106,5 +106,5 @@
       this.jobsTreeView.ReadOnly = false;
       this.jobsTreeView.Size = new System.Drawing.Size(704, 420);
-      this.jobsTreeView.TabIndex = 4;
+      this.jobsTreeView.TabIndex = 0;
       this.jobsTreeView.DragDrop += new System.Windows.Forms.DragEventHandler(this.jobsTreeView_DragDrop);
       this.jobsTreeView.DragEnter += new System.Windows.Forms.DragEventHandler(this.jobsTreeView_DragEnter);
@@ -124,5 +124,5 @@
       // refreshPermissionsButton
       // 
-      this.refreshPermissionsButton.Image = HeuristicLab.Common.Resources.VSImageLibrary.Refresh;
+      this.refreshPermissionsButton.Image = ((System.Drawing.Image)(resources.GetObject("refreshPermissionsButton.Image")));
       this.refreshPermissionsButton.Location = new System.Drawing.Point(3, 3);
       this.refreshPermissionsButton.Name = "refreshPermissionsButton";
@@ -158,20 +158,4 @@
       this.runsTabPage.Text = "Runs";
       this.runsTabPage.UseVisualStyleBackColor = true;
-      // 
-      // runCollectionViewHost
-      // 
-      this.runCollectionViewHost.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
-                  | System.Windows.Forms.AnchorStyles.Left)
-                  | System.Windows.Forms.AnchorStyles.Right)));
-      this.runCollectionViewHost.Caption = "View";
-      this.runCollectionViewHost.Content = null;
-      this.runCollectionViewHost.Enabled = false;
-      this.runCollectionViewHost.Location = new System.Drawing.Point(3, 3);
-      this.runCollectionViewHost.Name = "runCollectionViewHost";
-      this.runCollectionViewHost.ReadOnly = false;
-      this.runCollectionViewHost.Size = new System.Drawing.Size(703, 420);
-      this.runCollectionViewHost.TabIndex = 2;
-      this.runCollectionViewHost.ViewsLabelVisible = true;
-      this.runCollectionViewHost.ViewType = null;
       // 
       // stateTabPage
@@ -227,5 +211,5 @@
       // 
       this.startButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
-      this.startButton.Image = HeuristicLab.Common.Resources.VSImageLibrary.Play;
+      this.startButton.Image = ((System.Drawing.Image)(resources.GetObject("startButton.Image")));
       this.startButton.Location = new System.Drawing.Point(0, 536);
       this.startButton.Name = "startButton";
@@ -239,5 +223,5 @@
       // 
       this.stopButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
-      this.stopButton.Image = HeuristicLab.Common.Resources.VSImageLibrary.Stop;
+      this.stopButton.Image = ((System.Drawing.Image)(resources.GetObject("stopButton.Image")));
       this.stopButton.Location = new System.Drawing.Point(60, 536);
       this.stopButton.Name = "stopButton";
@@ -252,5 +236,5 @@
       this.resetButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
       this.resetButton.Enabled = false;
-      this.resetButton.Image = HeuristicLab.Common.Resources.VSImageLibrary.Restart;
+      this.resetButton.Image = ((System.Drawing.Image)(resources.GetObject("resetButton.Image")));
       this.resetButton.Location = new System.Drawing.Point(90, 536);
       this.resetButton.Name = "resetButton";
@@ -284,5 +268,5 @@
       this.pauseButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
       this.pauseButton.Enabled = false;
-      this.pauseButton.Image = HeuristicLab.Common.Resources.VSImageLibrary.Pause;
+      this.pauseButton.Image = ((System.Drawing.Image)(resources.GetObject("pauseButton.Image")));
       this.pauseButton.Location = new System.Drawing.Point(30, 536);
       this.pauseButton.Name = "pauseButton";
@@ -309,5 +293,5 @@
       this.resourceNamesTextBox.Name = "resourceNamesTextBox";
       this.resourceNamesTextBox.Size = new System.Drawing.Size(415, 20);
-      this.resourceNamesTextBox.TabIndex = 2;
+      this.resourceNamesTextBox.TabIndex = 14;
       this.resourceNamesTextBox.Validated += new System.EventHandler(this.resourceNamesTextBox_Validated);
       // 
@@ -328,10 +312,10 @@
       this.nameTextBox.Name = "nameTextBox";
       this.nameTextBox.Size = new System.Drawing.Size(501, 20);
-      this.nameTextBox.TabIndex = 1;
+      this.nameTextBox.TabIndex = 21;
       this.nameTextBox.Validated += new System.EventHandler(this.nameTextBox_Validated);
       // 
       // refreshButton
       // 
-      this.refreshButton.Image = HeuristicLab.Common.Resources.VSImageLibrary.Refresh;
+      this.refreshButton.Image = ((System.Drawing.Image)(resources.GetObject("refreshButton.Image")));
       this.refreshButton.Location = new System.Drawing.Point(3, 0);
       this.refreshButton.Name = "refreshButton";
@@ -349,5 +333,5 @@
       this.isPrivilegedCheckBox.Name = "isPrivilegedCheckBox";
       this.isPrivilegedCheckBox.Size = new System.Drawing.Size(72, 17);
-      this.isPrivilegedCheckBox.TabIndex = 3;
+      this.isPrivilegedCheckBox.TabIndex = 26;
       this.isPrivilegedCheckBox.Text = "Privileged";
       this.toolTip.SetToolTip(this.isPrivilegedCheckBox, "If checked, the task will be executed in a privileged sandbox on the slave.");
@@ -435,4 +419,20 @@
       this.jobsLabel.TabIndex = 0;
       this.jobsLabel.Text = "Waiting:";
+      // 
+      // runCollectionViewHost
+      // 
+      this.runCollectionViewHost.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
+                  | System.Windows.Forms.AnchorStyles.Left)
+                  | System.Windows.Forms.AnchorStyles.Right)));
+      this.runCollectionViewHost.Caption = "View";
+      this.runCollectionViewHost.Content = null;
+      this.runCollectionViewHost.Enabled = false;
+      this.runCollectionViewHost.Location = new System.Drawing.Point(3, 3);
+      this.runCollectionViewHost.Name = "runCollectionViewHost";
+      this.runCollectionViewHost.ReadOnly = false;
+      this.runCollectionViewHost.Size = new System.Drawing.Size(703, 420);
+      this.runCollectionViewHost.TabIndex = 2;
+      this.runCollectionViewHost.ViewsLabelVisible = true;
+      this.runCollectionViewHost.ViewType = null;
       // 
       // RefreshableHiveJobView
@@ -483,5 +483,5 @@
     private Core.Views.LogView logView;
     private System.Windows.Forms.TabPage tasksTabPage;
-    private HeuristicLab.Clients.Hive.Views.HiveTaskItemTreeView jobsTreeView;
+    private HeuristicLab.Clients.Hive.Views.ExperimentManager.HiveTaskItemTreeView jobsTreeView;
     private System.Windows.Forms.Label nameLabel;
     private System.Windows.Forms.TextBox nameTextBox;
Index: branches/HeuristicLab.TimeSeries/HeuristicLab.Clients.Hive.JobManager/3.3/Views/RefreshableHiveJobView.cs
===================================================================
--- branches/HeuristicLab.TimeSeries/HeuristicLab.Clients.Hive.JobManager/3.3/Views/RefreshableHiveJobView.cs	(revision 7268)
+++ branches/HeuristicLab.TimeSeries/HeuristicLab.Clients.Hive.JobManager/3.3/Views/RefreshableHiveJobView.cs	(revision 7460)
@@ -1,5 +1,5 @@
 ﻿#region License Information
 /* HeuristicLab
- * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ * Copyright (C) 2002-2011 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
  *
  * This file is part of HeuristicLab.
@@ -24,5 +24,4 @@
 using System.Linq;
 using System.Threading;
-using System.Threading.Tasks;
 using System.Windows.Forms;
 using HeuristicLab.Clients.Hive.Views;
@@ -114,5 +113,4 @@
         logView.Content = null;
         refreshAutomaticallyCheckBox.Checked = false;
-        logView.Content = null;
         runCollectionViewHost.Content = null;
       } else {
@@ -302,5 +300,12 @@
     }
     private void Content_ExceptionOccured(object sender, EventArgs<Exception> e) {
-      throw e.Value;
+      if (InvokeRequired)
+        Invoke(new EventHandler<EventArgs<Exception>>(Content_ExceptionOccured), sender, e);
+      else {
+        //don't show the error dialog when downloading tasks, the HiveClient will throw an exception and the dialog will be shown then
+        if (sender.GetType() != typeof(ConcurrentTaskDownloader<ItemTask>) && sender.GetType() != typeof(TaskDownloader)) {
+          ErrorHandling.ShowErrorDialog(this, e.Value);
+        }
+      }
     }
     private void Content_StateLogListChanged(object sender, EventArgs e) {
@@ -318,4 +323,5 @@
       }
     }
+
 
     private void UpdateStateLogList() {
@@ -336,58 +342,15 @@
       if (nameTextBox.Text.Trim() == string.Empty) {
         MessageBox.Show("Please enter a name for the job before uploading it!", "HeuristicLab Hive Job Manager", MessageBoxButtons.OK, MessageBoxIcon.Information);
-      } else if (Content.ExecutionState == ExecutionState.Paused) {
-        var task = System.Threading.Tasks.Task.Factory.StartNew(ResumeJobAsync, Content);
-        task.ContinueWith((t) => {
-          FinishProgressView();
-          MessageBox.Show("An error occured resuming the job. See the log for more information.", "HeuristicLab Hive Job Manager", MessageBoxButtons.OK, MessageBoxIcon.Error);
-          Content.Log.LogException(t.Exception);
-        }, TaskContinuationOptions.OnlyOnFaulted);
       } else {
         HiveClient.StartJob((Exception ex) => ErrorHandling.ShowErrorDialog(this, "Start failed.", ex), Content, new CancellationToken());
       }
     }
-
     private void pauseButton_Click(object sender, EventArgs e) {
-      var task = System.Threading.Tasks.Task.Factory.StartNew(PauseJobAsync, Content);
-      task.ContinueWith((t) => {
-        FinishProgressView();
-        MessageBox.Show("An error occured pausing the job. See the log for more information.", "HeuristicLab Hive Job Manager", MessageBoxButtons.OK, MessageBoxIcon.Error);
-        Content.Log.LogException(t.Exception);
-      }, TaskContinuationOptions.OnlyOnFaulted);
-    }
-
+      HiveClient.PauseJob(Content);
+    }
     private void stopButton_Click(object sender, EventArgs e) {
-      var task = System.Threading.Tasks.Task.Factory.StartNew(StopJobAsync, Content);
-      task.ContinueWith((t) => {
-        FinishProgressView();
-        MessageBox.Show("An error occured stopping the job. See the log for more information.", "HeuristicLab Hive Job Manager", MessageBoxButtons.OK, MessageBoxIcon.Error);
-        Content.Log.LogException(t.Exception);
-      }, TaskContinuationOptions.OnlyOnFaulted);
+      HiveClient.StopJob(Content);
     }
     private void resetButton_Click(object sender, EventArgs e) { }
-
-    private void PauseJobAsync(object job) {
-      IProgress prog = new Progress();
-      prog.Status = "Pausing job...";
-      SetProgressView(prog);
-      HiveClient.PauseJob((RefreshableJob)job);
-      FinishProgressView();
-    }
-
-    private void StopJobAsync(object job) {
-      IProgress prog = new Progress();
-      prog.Status = "Stopping job...";
-      SetProgressView(prog);
-      HiveClient.StopJob((RefreshableJob)job);
-      FinishProgressView();
-    }
-
-    private void ResumeJobAsync(object job) {
-      IProgress prog = new Progress();
-      prog.Status = "Resuming job...";
-      SetProgressView(prog);
-      HiveClient.ResumeJob((RefreshableJob)job);
-      FinishProgressView();
-    }
 
     private void nameTextBox_Validated(object sender, EventArgs e) {
@@ -428,4 +391,6 @@
       }
     }
+
+
     #endregion
 
@@ -435,5 +400,5 @@
         startButton.Enabled = pauseButton.Enabled = stopButton.Enabled = resetButton.Enabled = false;
       } else {
-        startButton.Enabled = Content.IsControllable && Content.HiveTasks != null && Content.HiveTasks.Count > 0 && (Content.ExecutionState == ExecutionState.Prepared || Content.ExecutionState == ExecutionState.Paused);
+        startButton.Enabled = Content.IsControllable && Content.HiveTasks != null && Content.HiveTasks.Count > 0 && Content.ExecutionState == ExecutionState.Prepared;
         pauseButton.Enabled = Content.IsControllable && Content.ExecutionState == ExecutionState.Started;
         stopButton.Enabled = Content.IsControllable && Content.ExecutionState == ExecutionState.Started;
@@ -457,36 +422,15 @@
 
     private void SetProgressView() {
-      if (InvokeRequired) {
-        Invoke(new Action(SetProgressView));
-      } else {
-        if (progressView == null) {
-          progressView = new ProgressView(this, Content.Progress);
-        } else {
-          progressView.Progress = Content.Progress;
-        }
-      }
-    }
-
-    private void SetProgressView(IProgress progress) {
-      if (InvokeRequired) {
-        Invoke(new Action<IProgress>(SetProgressView), progress);
-      } else {
-        if (progressView == null) {
-          progressView = new ProgressView(this, progress);
-        } else {
-          progressView.Progress = progress;
-        }
-      }
+      if (progressView == null) {
+        progressView = new ProgressView(this, Content.Progress);
+      }
+      progressView.Progress = Content.Progress;
     }
 
     private void FinishProgressView() {
-      if (InvokeRequired) {
-        Invoke(new Action(FinishProgressView));
-      } else {
-        if (progressView != null) {
-          progressView.Finish();
-          progressView = null;
-          SetEnabledStateOfControls();
-        }
+      if (progressView != null) {
+        progressView.Finish();
+        progressView = null;
+        SetEnabledStateOfControls();
       }
     }
@@ -533,5 +477,5 @@
       if (tabControl.SelectedTab == permissionTabPage) {
         if (!Content.IsSharable) {
-          MessageBox.Show("Unable to load permissions. You have insufficient access privileges.", "HeuristicLab Hive Job Manager", MessageBoxButtons.OK, MessageBoxIcon.Information);
+          MessageBox.Show("Unable to load tab. You have insufficient access privileges.");
           tabControl.SelectedTab = tasksTabPage;
         }
