mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
Update labels for setting view model when culture info changes
This commit is contained in:
parent
b9e0669c46
commit
af3aaa8ce7
2 changed files with 8 additions and 5 deletions
|
|
@ -1,4 +1,4 @@
|
||||||
using Flow.Launcher.Plugin.Explorer.Helper;
|
using Flow.Launcher.Plugin.Explorer.Helper;
|
||||||
using Flow.Launcher.Plugin.Explorer.Search;
|
using Flow.Launcher.Plugin.Explorer.Search;
|
||||||
using Flow.Launcher.Plugin.Explorer.Search.Everything;
|
using Flow.Launcher.Plugin.Explorer.Search.Everything;
|
||||||
using Flow.Launcher.Plugin.Explorer.ViewModels;
|
using Flow.Launcher.Plugin.Explorer.ViewModels;
|
||||||
|
|
@ -11,6 +11,7 @@ using System.Threading.Tasks;
|
||||||
using System.Windows.Controls;
|
using System.Windows.Controls;
|
||||||
using Flow.Launcher.Plugin.Explorer.Exceptions;
|
using Flow.Launcher.Plugin.Explorer.Exceptions;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
|
using System.Globalization;
|
||||||
|
|
||||||
namespace Flow.Launcher.Plugin.Explorer
|
namespace Flow.Launcher.Plugin.Explorer
|
||||||
{
|
{
|
||||||
|
|
@ -97,6 +98,12 @@ namespace Flow.Launcher.Plugin.Explorer
|
||||||
return Context.API.GetTranslation("plugin_explorer_plugin_description");
|
return Context.API.GetTranslation("plugin_explorer_plugin_description");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void OnCultureInfoChanged(CultureInfo newCulture)
|
||||||
|
{
|
||||||
|
// Update labels for setting view model
|
||||||
|
EverythingSortOptionLocalized.UpdateLabels(viewModel.AllEverythingSortOptions);
|
||||||
|
}
|
||||||
|
|
||||||
private static void FillQuickAccessLinkNames()
|
private static void FillQuickAccessLinkNames()
|
||||||
{
|
{
|
||||||
// Legacy version does not have names for quick access links, so we fill them with the path name.
|
// Legacy version does not have names for quick access links, so we fill them with the path name.
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,6 @@ using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Windows;
|
using System.Windows;
|
||||||
using System.Windows.Controls;
|
using System.Windows.Controls;
|
||||||
using Flow.Launcher.Plugin.Explorer.Search.Everything;
|
|
||||||
using Flow.Launcher.Plugin.Explorer.Search.QuickAccessLinks;
|
using Flow.Launcher.Plugin.Explorer.Search.QuickAccessLinks;
|
||||||
using Flow.Launcher.Plugin.Explorer.ViewModels;
|
using Flow.Launcher.Plugin.Explorer.ViewModels;
|
||||||
using DataFormats = System.Windows.DataFormats;
|
using DataFormats = System.Windows.DataFormats;
|
||||||
|
|
@ -39,9 +38,6 @@ namespace Flow.Launcher.Plugin.Explorer.Views
|
||||||
QuickAccessExpander,
|
QuickAccessExpander,
|
||||||
ExcludedPathsExpander
|
ExcludedPathsExpander
|
||||||
};
|
};
|
||||||
|
|
||||||
// Update labels on initialization to update on language change
|
|
||||||
EverythingSortOptionLocalized.UpdateLabels(_viewModel.AllEverythingSortOptions);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void AccessLinkDragDrop(string containerName, DragEventArgs e)
|
private void AccessLinkDragDrop(string containerName, DragEventArgs e)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue