diff --git a/src/Files.App/UserControls/NavigationToolbar.xaml b/src/Files.App/UserControls/NavigationToolbar.xaml index 49eef45dbba0..a44bb56ffa46 100644 --- a/src/Files.App/UserControls/NavigationToolbar.xaml +++ b/src/Files.App/UserControls/NavigationToolbar.xaml @@ -267,13 +267,13 @@ x:Name="Back" AccessKey="B" AccessKeyInvoked="Button_AccessKeyInvoked" - AutomationProperties.FullDescription="{x:Bind ViewModel.Commands.NavigateBack.Description, Mode=OneWay}" - AutomationProperties.Name="{x:Bind ViewModel.Commands.NavigateBack.Label, Mode=OneWay}" - Command="{x:Bind ViewModel.Commands.NavigateBack, Mode=OneWay}" - IsEnabled="{x:Bind ViewModel.Commands.NavigateBack.IsExecutable, Mode=OneWay}" + AutomationProperties.FullDescription="{x:Bind Commands.NavigateBack.Description, Mode=OneWay}" + AutomationProperties.Name="{x:Bind Commands.NavigateBack.Label, Mode=OneWay}" + Command="{x:Bind Commands.NavigateBack, Mode=OneWay}" + IsEnabled="{x:Bind Commands.NavigateBack.IsExecutable, Mode=OneWay}" Style="{StaticResource AddressToolbarButtonStyle}" - ToolTipService.ToolTip="{x:Bind ViewModel.Commands.NavigateBack.LabelWithHotKey, Mode=OneWay}"> - + ToolTipService.ToolTip="{x:Bind Commands.NavigateBack.LabelWithHotKey, Mode=OneWay}"> + - + ToolTipService.ToolTip="{x:Bind Commands.NavigateForward.LabelWithHotKey, Mode=OneWay}"> + - + ToolTipService.ToolTip="{x:Bind Commands.NavigateUp.LabelWithHotKey, Mode=OneWay}"> + @@ -478,13 +478,13 @@ x:Name="ShowSearchButton" AccessKey="I" AccessKeyInvoked="Button_AccessKeyInvoked" - AutomationProperties.Name="{x:Bind ViewModel.Commands.Search.Label}" - Command="{x:Bind ViewModel.Commands.Search, Mode=OneWay}" - IsEnabled="{x:Bind ViewModel.Commands.Search.IsExecutable}" + AutomationProperties.Name="{x:Bind Commands.Search.Label, Mode=OneWay}" + Command="{x:Bind Commands.Search, Mode=OneWay}" + IsEnabled="{x:Bind Commands.Search.IsExecutable, Mode=OneWay}" Style="{StaticResource AddressToolbarButtonStyle}" - ToolTipService.ToolTip="{x:Bind ViewModel.Commands.Search.LabelWithHotKey, Mode=OneWay}" + ToolTipService.ToolTip="{x:Bind Commands.Search.LabelWithHotKey, Mode=OneWay}" Visibility="Collapsed"> - + @@ -495,11 +495,11 @@ Padding="0" x:Load="{x:Bind ViewModel.ShowShelfPaneToggleButton, Mode=OneWay}" AccessKeyInvoked="Button_AccessKeyInvoked" - AutomationProperties.Name="{x:Bind ViewModel.Commands.ToggleShelfPane.Label}" + AutomationProperties.Name="{x:Bind Commands.ToggleShelfPane.Label, Mode=OneWay}" Background="Transparent" BorderBrush="Transparent" IsChecked="{x:Bind Commands.ToggleShelfPane.IsOn, Mode=TwoWay}" - ToolTipService.ToolTip="{x:Bind ViewModel.Commands.ToggleShelfPane.LabelWithHotKey, Mode=OneWay}"> + ToolTipService.ToolTip="{x:Bind Commands.ToggleShelfPane.LabelWithHotKey, Mode=OneWay}"> + ToolTipService.ToolTip="{x:Bind Commands.OpenReleaseNotes.LabelWithHotKey, Mode=OneWay}" + Visibility="{x:Bind Commands.OpenReleaseNotes.IsExecutable, Mode=OneWay}"> - diff --git a/src/Files.App/UserControls/Pane/InfoPane.xaml b/src/Files.App/UserControls/Pane/InfoPane.xaml index bd8df168ea26..9eb077d7b958 100644 --- a/src/Files.App/UserControls/Pane/InfoPane.xaml +++ b/src/Files.App/UserControls/Pane/InfoPane.xaml @@ -205,7 +205,7 @@ x:Name="PreviewErrorText" HorizontalAlignment="Center" VerticalAlignment="Center" - Text="{x:Bind GetLocalizedResource('NoItemSelected')}" + Text="{helpers:ResourceString Name=NoItemSelected}" TextWrapping="WrapWholeWords" /> - + @@ -519,7 +519,7 @@ - + diff --git a/src/Files.App/UserControls/Pane/InfoPane.xaml.cs b/src/Files.App/UserControls/Pane/InfoPane.xaml.cs index a9bedfccd494..7ccfe0fd1be1 100644 --- a/src/Files.App/UserControls/Pane/InfoPane.xaml.cs +++ b/src/Files.App/UserControls/Pane/InfoPane.xaml.cs @@ -52,8 +52,6 @@ public void UpdatePosition(double panelWidth, double panelHeight) } } - private string GetLocalizedResource(string resName) => resName.GetLocalizedResource(); - private void Root_Unloaded(object sender, RoutedEventArgs e) { PreviewControlPresenter.Content = null;