]> granicus.if.org Git - handbrake/commitdiff
WinGui: Minor bug fixes and tidyup in the queue.
authorsr55 <sr55.hb@outlook.com>
Fri, 28 Sep 2018 19:18:26 +0000 (20:18 +0100)
committersr55 <sr55.hb@outlook.com>
Fri, 28 Sep 2018 19:18:26 +0000 (20:18 +0100)
win/CS/HandBrakeWPF/ViewModels/QueueViewModel.cs
win/CS/HandBrakeWPF/Views/Queue/Embedded.xaml
win/CS/HandBrakeWPF/Views/Queue/QueueTwoContent.xaml
win/CS/HandBrakeWPF/Views/Queue/QueueTwoContent.xaml.cs
win/CS/HandBrakeWPF/Views/QueueView.xaml

index aedd89b27d1ac979f8dd19cbbd469c10de9f2fdd..0edc6382223b4d100ffd51adccd714fed438c9a5 100644 (file)
@@ -194,7 +194,7 @@ namespace HandBrakeWPF.ViewModels
 \r
         public string ActivityLog { get; private set; }\r
 \r
-        public bool CanRetryJob => this.SelectedTask != null && this.SelectedTask.Status != QueueItemStatus.Waiting;\r
+        public bool CanRetryJob => this.SelectedTask != null && this.SelectedTask.Status != QueueItemStatus.Waiting && this.SelectedTask.Status != QueueItemStatus.InProgress;\r
 \r
         public bool CanEditJob => this.SelectedTask != null;\r
 \r
@@ -447,6 +447,7 @@ namespace HandBrakeWPF.ViewModels
             task.Status = QueueItemStatus.Waiting;\r
             this.queueProcessor.BackupQueue(null);\r
             this.JobsPending = string.Format(Resources.QueueViewModel_JobsPending, this.queueProcessor.Count);\r
+            this.JobStatus = Resources.QueueViewModel_QueueReady;\r
             this.NotifyOfPropertyChange(() => this.CanRetryJob);\r
         }\r
 \r
@@ -559,7 +560,7 @@ namespace HandBrakeWPF.ViewModels
                 {\r
                     this.RetryJob(task);\r
                 }\r
-            }\r
+            }       \r
         }\r
 \r
         public void ResetAllJobs()\r
@@ -737,7 +738,6 @@ namespace HandBrakeWPF.ViewModels
         {\r
             Execute.OnUIThread(() =>\r
             {\r
-                string jobsPending = string.Format(Resources.Main_JobsPending_addon, this.queueProcessor.Count);\r
                 this.IntermediateProgress = false;\r
 \r
                 if (e.IsSubtitleScan)\r
@@ -748,7 +748,7 @@ namespace HandBrakeWPF.ViewModels
                         e.PercentComplete,\r
                         e.EstimatedTimeLeft,\r
                         e.ElapsedTime,\r
-                        jobsPending);\r
+                        null);\r
 \r
                     this.ProgressValue = e.PercentComplete;\r
                 }\r
@@ -759,7 +759,7 @@ namespace HandBrakeWPF.ViewModels
                 }\r
                 else if (e.IsSearching)\r
                 {\r
-                    this.JobStatus = string.Format(ResourcesUI.MainView_ProgressStatusWithTask, ResourcesUI.MainView_Searching, e.PercentComplete, e.EstimatedTimeLeft, jobsPending);\r
+                    this.JobStatus = string.Format(ResourcesUI.MainView_ProgressStatusWithTask, ResourcesUI.MainView_Searching, e.PercentComplete, e.EstimatedTimeLeft, null);\r
                     this.ProgressValue = e.PercentComplete;\r
                 }\r
                 else\r
@@ -773,7 +773,7 @@ namespace HandBrakeWPF.ViewModels
                             e.AverageFrameRate,\r
                             e.EstimatedTimeLeft,\r
                             e.ElapsedTime,\r
-                            jobsPending);\r
+                            null);\r
                     this.ProgressValue = e.PercentComplete;\r
                 }\r
             });\r
@@ -821,6 +821,7 @@ namespace HandBrakeWPF.ViewModels
             this.IsQueueRunning = false;\r
             this.NotifyOfPropertyChange(() => this.SelectedTask);\r
             this.NotifyOfPropertyChange(() => this.StatsVisible);\r
+            this.NotifyOfPropertyChange(() => this.CanRetryJob);\r
         }\r
 \r
         /// <summary>\r
index ae7ecf37aa1641631d9d0718e18c63e290fd611b..c304f36dbeb425a95770f3ff59cc6c38ceaff7e0 100644 (file)
@@ -14,7 +14,6 @@
         xmlns:helpers="clr-namespace:HandBrakeWPF.Helpers"
         xmlns:Properties="clr-namespace:HandBrakeWPF.Properties"
         xmlns:queue="clr-namespace:HandBrakeWPF.Converters.Queue"
-
         MinWidth="350"
         MinHeight="250"
         TextOptions.TextFormattingMode="Display"
index f43381071e795a9785b63c79befc513c1fcbcbe8..2138bd18003f4c8a1c58bd6fb5d2b238dc9e1420 100644 (file)
                                     </Style>
                                 </StackPanel.Resources>
 
-
                                 <Button>
                                     <Button.Content>
                                         <StackPanel Orientation="Horizontal">
index c98e402b029d26d98928390bd9ff51e52f4b5521..691854b74244606168562049d7a68dbf24b10f4a 100644 (file)
@@ -38,9 +38,9 @@ namespace HandBrakeWPF.Views.Queue
             // Make the view adaptive. 
             if (e.WidthChanged)
             {
-                this.summaryTabControl.Visibility = this.ActualWidth < 650 ? Visibility.Collapsed : Visibility.Visible;
-                this.leftTabPanel.Width = this.ActualWidth < 650 ? new GridLength(this.ActualWidth - 10, GridUnitType.Star) : new GridLength(3, GridUnitType.Star);
-                this.leftTabPanel.MaxWidth = this.ActualWidth < 650 ? 650 : 400;
+                this.summaryTabControl.Visibility = this.ActualWidth < 600 ? Visibility.Collapsed : Visibility.Visible;
+                this.leftTabPanel.Width = this.ActualWidth < 600 ? new GridLength(this.ActualWidth - 10, GridUnitType.Star) : new GridLength(3, GridUnitType.Star);
+                this.leftTabPanel.MaxWidth = this.ActualWidth < 600 ? 650 : 400;
             }
         }
         private void ContextMenu_OnOpened(object sender, RoutedEventArgs e)
index 5a9b3a8367bfc4d8b6d293707fbaeece420632e9..0eddd5c0ff869fe9b6c2056648f9a1784cff71c8 100644 (file)
@@ -18,7 +18,7 @@
         Title="{Binding Title}"\r
         Width="750"\r
         Height="500"\r
-        MinWidth="450"\r
+        MinWidth="400"\r
         MinHeight="300"\r
         WindowStartupLocation="CenterScreen"\r
         TextOptions.TextFormattingMode="Display"\r