diff --git a/Flow.Launcher/App.xaml b/Flow.Launcher/App.xaml
index b8e2a1cfe..76a613c3f 100644
--- a/Flow.Launcher/App.xaml
+++ b/Flow.Launcher/App.xaml
@@ -24,6 +24,7 @@
+
diff --git a/Flow.Launcher/SettingPages/Views/General.xaml b/Flow.Launcher/SettingPages/Views/General.xaml
index 5af28e7d3..01f30c584 100644
--- a/Flow.Launcher/SettingPages/Views/General.xaml
+++ b/Flow.Launcher/SettingPages/Views/General.xaml
@@ -11,14 +11,6 @@
d:DesignWidth="800"
Style="{DynamicResource SettingPageBasic}"
mc:Ignorable="d">
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Flow.Launcher/ViewModel/SettingWindowViewModel.cs b/Flow.Launcher/ViewModel/SettingWindowViewModel.cs
index aa16e7cb7..087cc345c 100644
--- a/Flow.Launcher/ViewModel/SettingWindowViewModel.cs
+++ b/Flow.Launcher/ViewModel/SettingWindowViewModel.cs
@@ -107,6 +107,10 @@ namespace Flow.Launcher.ViewModel
}
public CultureInfo Culture => CultureInfo.DefaultThreadCurrentCulture;
+ private Internationalization _translater => InternationalizationManager.Instance;
+ public string AlwaysPreviewToolTip =>
+ string.Format(_translater.GetTranslation("AlwaysPreviewToolTip"), Settings.PreviewHotkey);
+
public bool StartFlowLauncherOnSystemStartup
{
@@ -191,109 +195,7 @@ namespace Flow.Launcher.ViewModel
}
}
- #region general
-
- // todo a better name?
- public class LastQueryMode : BaseModel
- {
- public string Display { get; set; }
- public Infrastructure.UserSettings.LastQueryMode Value { get; set; }
- }
-
- private List _lastQueryModes = new List();
-
- public List LastQueryModes
- {
- get
- {
- if (_lastQueryModes.Count == 0)
- {
- _lastQueryModes = InitLastQueryModes();
- }
-
- return _lastQueryModes;
- }
- }
-
- private List InitLastQueryModes()
- {
- var modes = new List();
- var enums = (Infrastructure.UserSettings.LastQueryMode[])Enum.GetValues(
- typeof(Infrastructure.UserSettings.LastQueryMode));
- foreach (var e in enums)
- {
- var key = $"LastQuery{e}";
- var display = _translater.GetTranslation(key);
- var m = new LastQueryMode { Display = display, Value = e, };
- modes.Add(m);
- }
-
- return modes;
- }
-
- private void UpdateLastQueryModeDisplay()
- {
- foreach (var item in LastQueryModes)
- {
- item.Display = _translater.GetTranslation($"LastQuery{item.Value}");
- }
- }
-
- public string Language
- {
- get
- {
- return Settings.Language;
- }
- set
- {
- InternationalizationManager.Instance.ChangeLanguage(value);
-
- if (InternationalizationManager.Instance.PromptShouldUsePinyin(value))
- ShouldUsePinyin = true;
-
- UpdateLastQueryModeDisplay();
- }
- }
-
- public bool ShouldUsePinyin
- {
- get
- {
- return Settings.ShouldUsePinyin;
- }
- set
- {
- Settings.ShouldUsePinyin = value;
- }
- }
-
- public List QuerySearchPrecisionStrings
- {
- get
- {
- var precisionStrings = new List();
-
- var enumList = Enum.GetValues(typeof(SearchPrecisionScore)).Cast().ToList();
-
- enumList.ForEach(x => precisionStrings.Add(x.ToString()));
-
- return precisionStrings;
- }
- }
-
- public List OpenResultModifiersList => new List
- {
- KeyConstant.Alt, KeyConstant.Ctrl, $"{KeyConstant.Ctrl}+{KeyConstant.Alt}"
- };
-
- private Internationalization _translater => InternationalizationManager.Instance;
- public List Languages => _translater.LoadAvailableLanguages();
- public IEnumerable MaxResultsRange => Enumerable.Range(2, 16);
-
- public string AlwaysPreviewToolTip =>
- string.Format(_translater.GetTranslation("AlwaysPreviewToolTip"), Settings.PreviewHotkey);
-
+
public string TestProxy()
{
var proxyServer = Settings.Proxy.Server;
@@ -340,8 +242,6 @@ namespace Flow.Launcher.ViewModel
}
}
- #endregion
-
#region plugin
public static string Plugin => @"https://github.com/Flow-Launcher/Flow.Launcher.PluginsManifest";