]> granicus.if.org Git - handbrake/commitdiff
WinGui: Move the Queue Recovery option from the source panel to the Queue Menu. ...
authorsr55 <sr55.hb@outlook.com>
Fri, 25 Jan 2019 21:08:39 +0000 (21:08 +0000)
committersr55 <sr55.hb@outlook.com>
Sun, 27 Jan 2019 20:46:41 +0000 (20:46 +0000)
win/CS/HandBrakeWPF/Controls/SourceSelection.xaml
win/CS/HandBrakeWPF/Properties/Resources.Designer.cs
win/CS/HandBrakeWPF/Properties/Resources.resx
win/CS/HandBrakeWPF/ViewModels/MainViewModel.cs
win/CS/HandBrakeWPF/Views/MainView.xaml

index f3cecdbe3899ce66c9fb6e10c4288e8ea194ea7f..0e4925748bdfacfab1d2faec20ce0dcacc5875cc 100644 (file)
                 </ListBox.ItemTemplate>\r
             </ListBox>\r
 \r
-            <Button Grid.Row="5"  AutomationProperties.Name="{x:Static Properties:Resources.SourceSelection_QueueArchiveRecovery}" Style="{StaticResource {x:Static ToolBar.ButtonStyleKey}}" \r
-                    cal:Message.Attach="[Event Click] = [Action RecoverQueue]" Visibility="{Binding QueueRecoveryArchivesExist, Converter={StaticResource BooleanToVisibilityConverter}}"\r
-                    Margin="20,15,0,0" Padding="8" HorizontalAlignment="Left" BorderBrush="DarkGray" BorderThickness="0,1,0,0">\r
-                <StackPanel Orientation="Horizontal" MinWidth="100">\r
-                    <Image Source="../Views/Images/Queue.png" Width="32" />\r
-                    <StackPanel Orientation="Vertical">\r
-                        <TextBlock Text="{x:Static Properties:Resources.SourceSelection_QueueArchiveRecovery}" VerticalAlignment="Center" Margin="5,0,0,0" />\r
-                        <TextBlock Text="{x:Static Properties:Resources.SourceSelection_QueueArchiveRecoveryDesc}" VerticalAlignment="Center" Margin="5,0,0,0" />\r
-                    </StackPanel>\r
-                </StackPanel>\r
-            </Button>\r
-\r
             <!-- Cancel Window -->\r
             <StackPanel Grid.Row="7" Orientation="Horizontal" HorizontalAlignment="Right" Margin="0,10,2,10">\r
                 <Button cal:Message.Attach="[Event Click] = [Action CloseSourceSelection]" Content="Cancel" Padding="8,2" />\r
index f90e41d43f324fb536909ea4f58e59adc46b4f70..bebf83f6fdee70c340111d94fd4fd3bd4ac94753 100644 (file)
@@ -4449,7 +4449,7 @@ namespace HandBrakeWPF.Properties {
         }
         
         /// <summary>
-        ///   Looks up a localized string similar to Queue Recovery.
+        ///   Looks up a localized string similar to Recover Queue Files.
         /// </summary>
         public static string SourceSelection_QueueArchiveRecovery {
             get {
index b0fc5a89128519ce50077b0ca476555bdc545321..89ec0714c7c7ffb2a882e028ec849cf30e2bcefe 100644 (file)
@@ -1610,7 +1610,7 @@ This will not affect your current settings in the Subtitle tab.</value>
     <value>Open a folder with one or more files.</value>\r
   </data>\r
   <data name="SourceSelection_QueueArchiveRecovery" xml:space="preserve">\r
-    <value>Queue Recovery</value>\r
+    <value>Recover Queue Files</value>\r
   </data>\r
   <data name="SourceSelection_QueueArchiveRecoveryDesc" xml:space="preserve">\r
     <value>A previous queue archive is available. </value>\r
index 9d07343a76be7ca7cf2c4e5e48d80d182fcd1651..3d2130edbc68ca127bce0910812cf51a684380ed 100644 (file)
@@ -2109,6 +2109,11 @@ namespace HandBrakeWPF.ViewModels
             }\r
         }\r
 \r
+        public bool CanRecoverQueue()\r
+        {\r
+            return this.QueueRecoveryArchivesExist;\r
+        }\r
+\r
         public void RecoverQueue()\r
         {\r
             QueueRecoveryHelper.ResetArchives();\r
index 3abfa7d5cf366b4283cb06e7068c2464b3564d34..8948c03e3ddb64975c0456fbe23f5a75f6992f8f 100644 (file)
                     <MenuItem Command="{Binding QueueCommand}" CommandParameter="{x:Static menu:QueueCommandParams.ClearSelected}" Header="{x:Static Properties:Resources.QueueView_ClearSelected}" Visibility="{Binding IsQueueShowingInLine, Converter={StaticResource boolToVisConverter}, ConverterParameter=false}" />\r
                     <Separator Visibility="{Binding IsQueueShowingInLine, Converter={StaticResource boolToVisConverter}, ConverterParameter=false}" />\r
                     <MenuItem Command="{Binding QueueCommand}" CommandParameter="{x:Static menu:QueueCommandParams.Export}" Header="{x:Static Properties:Resources.QueueView_Export}" Visibility="{Binding IsQueueShowingInLine, Converter={StaticResource boolToVisConverter}, ConverterParameter=false}" />\r
+                    <Separator />\r
+                    <MenuItem x:Name="queueRecoveryMenuItem" Header="{x:Static Properties:Resources.SourceSelection_QueueArchiveRecovery}" cal:Message.Attach="[Event Click] = [Action RecoverQueue]" />\r
+\r
                 </MenuItem>\r
 \r
                 <MenuItem Header="{x:Static Properties:Resources.MainView_HelpMenu}">\r