Skip to content

Commit 9f4a3cc

Browse files
committed
Revert "Merge pull request #4042 from 01Dri/feature/history_mode"
This reverts commit 3d9ef2c, reversing changes made to 4fe3b55.
1 parent 308083d commit 9f4a3cc

12 files changed

Lines changed: 61 additions & 266 deletions

File tree

Directory.Build.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project>
22
<PropertyGroup>
33
<AccelerateBuildsInVisualStudio>true</AccelerateBuildsInVisualStudio>
4-
<!-- Workaround https://github.com/dotnet/runtime/issues/109682 -->
4+
<!-- Work around https://github.com/dotnet/runtime/issues/109682 -->
55
<CETCompat>false</CETCompat>
66
</PropertyGroup>
77
</Project>

Flow.Launcher.Infrastructure/UserSettings/Settings.cs

Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
using Flow.Launcher.Infrastructure.Hotkey;
88
using Flow.Launcher.Infrastructure.Logger;
99
using Flow.Launcher.Infrastructure.Storage;
10-
using Flow.Launcher.Localization.Attributes;
1110
using Flow.Launcher.Plugin;
1211
using Flow.Launcher.Plugin.SharedModels;
1312

@@ -515,21 +514,6 @@ public bool ShowAtTopmost
515514
[JsonConverter(typeof(JsonStringEnumConverter))]
516515
public LastQueryMode LastQueryMode { get; set; } = LastQueryMode.Selected;
517516

518-
private HistoryStyle _historyStyle = HistoryStyle.Query;
519-
[JsonConverter(typeof(JsonStringEnumConverter))]
520-
public HistoryStyle HistoryStyle
521-
{
522-
get => _historyStyle;
523-
set
524-
{
525-
if (_historyStyle != value)
526-
{
527-
_historyStyle = value;
528-
OnPropertyChanged();
529-
}
530-
}
531-
}
532-
533517
[JsonConverter(typeof(JsonStringEnumConverter))]
534518
public AnimationSpeeds AnimationSpeed { get; set; } = AnimationSpeeds.Medium;
535519
public int CustomAnimationLength { get; set; } = 360;
@@ -712,14 +696,4 @@ public enum DialogJumpFileResultBehaviours
712696
FullPathOpen,
713697
Directory
714698
}
715-
716-
[EnumLocalize]
717-
public enum HistoryStyle
718-
{
719-
[EnumLocalizeKey(nameof(Localize.queryHistory))]
720-
Query,
721-
722-
[EnumLocalizeKey(nameof(Localize.executedHistory))]
723-
LastOpened
724-
}
725699
}

Flow.Launcher/Flow.Launcher.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@
185185
</Target>
186186

187187
<Target Name="RemoveDuplicateAnalyzers" BeforeTargets="CoreCompile">
188-
<!-- Workaround https://github.com/dotnet/wpf/issues/6792 -->
188+
<!-- Work around https://github.com/dotnet/wpf/issues/6792 -->
189189
<ItemGroup>
190190
<FilteredAnalyzer Include="@(Analyzer-&gt;Distinct())" />
191191
<Analyzer Remove="@(Analyzer)" />

Flow.Launcher/Helper/ResultHelper.cs

Lines changed: 0 additions & 45 deletions
This file was deleted.

Flow.Launcher/Languages/en.xaml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -172,10 +172,6 @@
172172
<system:String x:Key="homePageToolTip">Show home page results when query text is empty.</system:String>
173173
<system:String x:Key="historyResultsForHomePage">Show History Results in Home Page</system:String>
174174
<system:String x:Key="historyResultsCountForHomePage">Maximum History Results Shown in Home Page</system:String>
175-
<system:String x:Key="historyStyle">History Style</system:String>
176-
<system:String x:Key="historyStyleTooltip">Choose the type of history to show in the History and Home Page</system:String>
177-
<system:String x:Key="queryHistory">Query history</system:String>
178-
<system:String x:Key="executedHistory">Last opened history</system:String>
179175
<system:String x:Key="homeToggleBoxToolTip">This can only be edited if plugin supports Home feature and Home Page is enabled.</system:String>
180176
<system:String x:Key="showAtTopmost">Show Search Window at Foremost</system:String>
181177
<system:String x:Key="showAtTopmostToolTip">Overrides other programs' 'Always on Top' setting and displays Flow in the foremost position.</system:String>

Flow.Launcher/MainWindow.xaml.cs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -322,7 +322,6 @@ private void OnLoaded(object sender, RoutedEventArgs e)
322322
break;
323323
case nameof(Settings.ShowHomePage):
324324
case nameof(Settings.ShowHistoryResultsForHomePage):
325-
case nameof(Settings.HistoryStyle):
326325
if (_viewModel.QueryResultsSelected() && string.IsNullOrEmpty(_viewModel.QueryText))
327326
{
328327
_viewModel.QueryResults();
@@ -860,7 +859,7 @@ private void InitializeContextMenu()
860859

861860
public void UpdatePosition()
862861
{
863-
// Initialize call twice to workaround multi-display alignment issue- https://github.com/Flow-Launcher/Flow.Launcher/issues/2910
862+
// Initialize call twice to work around multi-display alignment issue- https://github.com/Flow-Launcher/Flow.Launcher/issues/2910
864863
if (_viewModel.IsDialogJumpWindowUnderDialog())
865864
{
866865
InitializeDialogJumpPosition();
@@ -884,7 +883,7 @@ private async Task PositionResetAsync()
884883

885884
private void InitializePosition()
886885
{
887-
// Initialize call twice to workaround multi-display alignment issue- https://github.com/Flow-Launcher/Flow.Launcher/issues/2910
886+
// Initialize call twice to work around multi-display alignment issue- https://github.com/Flow-Launcher/Flow.Launcher/issues/2910
888887
InitializePositionInner();
889888
InitializePositionInner();
890889
return;

Flow.Launcher/SettingPages/ViewModels/SettingsPaneGeneralViewModel.cs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -147,8 +147,6 @@ public bool PortableMode
147147
public List<LastQueryModeData> LastQueryModes { get; } =
148148
DropdownDataGeneric<LastQueryMode>.GetValues<LastQueryModeData>("LastQuery");
149149

150-
public List<HistoryStyleLocalized> HistoryStyles { get; } = HistoryStyleLocalized.GetValues();
151-
152150
public bool EnableDialogJump
153151
{
154152
get => Settings.EnableDialogJump;
@@ -215,7 +213,6 @@ private void UpdateEnumDropdownLocalizations()
215213
DropdownDataGeneric<SearchWindowAligns>.UpdateLabels(SearchWindowAligns);
216214
DropdownDataGeneric<SearchPrecisionScore>.UpdateLabels(SearchPrecisionScores);
217215
DropdownDataGeneric<LastQueryMode>.UpdateLabels(LastQueryModes);
218-
HistoryStyleLocalized.UpdateLabels(HistoryStyles);
219216
DropdownDataGeneric<DoublePinyinSchemas>.UpdateLabels(DoublePinyinSchemas);
220217
DropdownDataGeneric<DialogJumpWindowPositions>.UpdateLabels(DialogJumpWindowPositions);
221218
DropdownDataGeneric<DialogJumpResultBehaviours>.UpdateLabels(DialogJumpResultBehaviours);

Flow.Launcher/SettingPages/Views/SettingsPaneGeneral.xaml

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -255,22 +255,6 @@
255255
SelectedValuePath="Value" />
256256
</ui:SettingsCard>
257257

258-
<ui:SettingsCard
259-
Margin="0 14 0 0"
260-
Description="{DynamicResource historyStyleTooltip}"
261-
Header="{DynamicResource historyStyle}">
262-
<ui:SettingsCard.HeaderIcon>
263-
<ui:FontIcon Glyph="&#xE81C;" />
264-
</ui:SettingsCard.HeaderIcon>
265-
266-
<ComboBox
267-
MaxWidth="200"
268-
DisplayMemberPath="Display"
269-
ItemsSource="{Binding HistoryStyles}"
270-
SelectedValue="{Binding Settings.HistoryStyle}"
271-
SelectedValuePath="Value" />
272-
</ui:SettingsCard>
273-
274258
<ui:SettingsCard
275259
Margin="0 14 0 0"
276260
Description="{DynamicResource autoRestartAfterChangingToolTip}"

Flow.Launcher/Storage/HistoryItem.cs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
1-
using System;
1+
using System;
22

33
namespace Flow.Launcher.Storage
44
{
5-
[Obsolete("Use LastOpenedHistoryItem instead. This class will be removed in future versions.")]
65
public class HistoryItem
76
{
87
public string Query { get; set; }
@@ -43,4 +42,4 @@ private string DateTimeAgo(DateTime dt)
4342
return string.Empty;
4443
}
4544
}
46-
}
45+
}

Flow.Launcher/Storage/LastOpenedHistoryItem.cs

Lines changed: 0 additions & 31 deletions
This file was deleted.

0 commit comments

Comments
 (0)