Skip to content

Commit 91f9351

Browse files
authored
Merge branch 'dev' into FixSound
2 parents 597a94c + 6869aee commit 91f9351

File tree

10 files changed

+66
-50
lines changed

10 files changed

+66
-50
lines changed

Flow.Launcher/Resources/Dark.xaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@
5959

6060
<SolidColorBrush x:Key="ThemeHoverButton" Color="#3c3c3c" />
6161
<SolidColorBrush x:Key="PopuBGColor" Color="#202020" />
62+
<SolidColorBrush x:Key="PopupBGColor" Color="#202020" />
6263
<SolidColorBrush x:Key="PopupTextColor" Color="#cfcfcf" />
6364
<SolidColorBrush x:Key="PopupButtonAreaBGColor" Color="#2b2b2b" />
6465
<SolidColorBrush x:Key="PopupButtonAreaBorderColor" Color="#3f3f3f" />

Flow.Launcher/Resources/Light.xaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,9 @@
5151
<SolidColorBrush x:Key="BasicLabelColor" Color="#1b1b1b" />
5252

5353
<SolidColorBrush x:Key="ThemeHoverButton" Color="#f6f6f6" />
54+
<!-- Typo -->
5455
<SolidColorBrush x:Key="PopuBGColor" Color="#ffffff" />
56+
<SolidColorBrush x:Key="PopupBGColor" Color="#ffffff" />
5557
<SolidColorBrush x:Key="PopupTextColor" Color="#1b1b1b" />
5658
<SolidColorBrush x:Key="PopupButtonAreaBGColor" Color="#f3f3f3" />
5759
<SolidColorBrush x:Key="PopupButtonAreaBorderColor" Color="#e5e5e5" />

Flow.Launcher/SettingWindow.xaml

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1932,9 +1932,25 @@
19321932

19331933
<StackPanel Grid.Row="3">
19341934
<Border
1935+
Height="64"
19351936
Margin="0,8,0,0"
1937+
CornerRadius="5 5 0 0"
1938+
Style="{DynamicResource SettingGroupBox}">
1939+
<ItemsControl Style="{StaticResource SettingGrid}">
1940+
<StackPanel Style="{StaticResource TextPanel}">
1941+
<TextBlock Style="{DynamicResource SettingTitleLabel}" Text="{DynamicResource theme}" />
1942+
</StackPanel>
1943+
<TextBlock Style="{StaticResource Glyph}">
1944+
&#xe790;
1945+
</TextBlock>
1946+
</ItemsControl>
1947+
</Border>
1948+
<Border
1949+
Margin="0,0,0,0"
19361950
Padding="0"
19371951
HorizontalAlignment="Stretch"
1952+
BorderThickness="1,0,1,1"
1953+
CornerRadius="0 0 5 5"
19381954
Style="{DynamicResource SettingGroupBox}">
19391955
<ListBox
19401956
Margin="12,12,12,12"
@@ -2448,11 +2464,11 @@
24482464
Width="300"
24492465
Height="35"
24502466
Margin="0,0,0,0"
2451-
ValidateKeyGesture="True"
24522467
HorizontalAlignment="Right"
24532468
HorizontalContentAlignment="Right"
24542469
Loaded="OnPreviewHotkeyControlLoaded"
2455-
LostFocus="OnPreviewHotkeyControlFocusLost" />
2470+
LostFocus="OnPreviewHotkeyControlFocusLost"
2471+
ValidateKeyGesture="True" />
24562472
<TextBlock Style="{StaticResource Glyph}">
24572473
&#xe8a1;
24582474
</TextBlock>

Plugins/Flow.Launcher.Plugin.Explorer/Views/ExplorerSettings.xaml

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@
178178
<RowDefinition />
179179
<RowDefinition />
180180
<RowDefinition />
181-
</Grid.RowDefinitions>
181+
</Grid.RowDefinitions>
182182

183183
<TextBlock
184184
Grid.Row="0"
@@ -291,9 +291,9 @@
291291
Margin="10,15,10,10"
292292
HorizontalAlignment="Left"
293293
VerticalAlignment="Center"
294+
DisplayMemberPath="Description"
294295
ItemsSource="{Binding IndexSearchEngines}"
295-
SelectedItem="{Binding SelectedIndexSearchEngine}"
296-
DisplayMemberPath="Description"/>
296+
SelectedItem="{Binding SelectedIndexSearchEngine}" />
297297
<TextBlock
298298
Grid.Row="1"
299299
Grid.Column="0"
@@ -308,9 +308,9 @@
308308
Margin="10"
309309
HorizontalAlignment="Left"
310310
VerticalAlignment="Center"
311+
DisplayMemberPath="Description"
311312
ItemsSource="{Binding ContentIndexSearchEngines}"
312-
SelectedItem="{Binding SelectedContentSearchEngine}"
313-
DisplayMemberPath="Description"/>
313+
SelectedItem="{Binding SelectedContentSearchEngine}" />
314314
<TextBlock
315315
Grid.Row="2"
316316
Grid.Column="0"
@@ -325,8 +325,8 @@
325325
Margin="10"
326326
HorizontalAlignment="Left"
327327
VerticalAlignment="Center"
328-
ItemsSource="{Binding PathEnumerationEngines}"
329328
DisplayMemberPath="Description"
329+
ItemsSource="{Binding PathEnumerationEngines}"
330330
SelectedItem="{Binding SelectedPathEnumerationEngine}" />
331331
</Grid>
332332
</StackPanel>
@@ -349,13 +349,15 @@
349349
Style="{DynamicResource ExplorerTabItem}">
350350
<StackPanel Margin="10" Orientation="Vertical">
351351
<StackPanel Orientation="Horizontal">
352-
<TextBlock Margin="10"
352+
<TextBlock
353+
Margin="10"
353354
VerticalAlignment="Center"
354-
Text="{DynamicResource flowlauncher_plugin_everything_search_fullpath}"/>
355-
<CheckBox Margin="10"
355+
Text="{DynamicResource flowlauncher_plugin_everything_search_fullpath}"
356+
TextBlock.Foreground="{DynamicResource Color05B}" />
357+
<CheckBox
358+
Margin="10"
356359
VerticalAlignment="Center"
357-
IsChecked="{Binding Settings.EverythingSearchFullPath}">
358-
</CheckBox>
360+
IsChecked="{Binding Settings.EverythingSearchFullPath}" />
359361
</StackPanel>
360362
<StackPanel Orientation="Horizontal">
361363
<Grid Margin="20,10,0,10">

Plugins/Flow.Launcher.Plugin.WebSearch/Languages/en.xaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
<system:String x:Key="flowlauncher_plugin_websearch_delete">Delete</system:String>
1313
<system:String x:Key="flowlauncher_plugin_websearch_edit">Edit</system:String>
1414
<system:String x:Key="flowlauncher_plugin_websearch_add">Add</system:String>
15+
<system:String x:Key="flowlauncher_plugin_websearch_enabled_label">Enabled</system:String>
1516
<system:String x:Key="flowlauncher_plugin_websearch_true">Enabled</system:String>
1617
<system:String x:Key="flowlauncher_plugin_websearch_false">Disabled</system:String>
1718
<system:String x:Key="flowlauncher_plugin_websearch_confirm">Confirm</system:String>

Plugins/Flow.Launcher.Plugin.WebSearch/SearchSource.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,9 @@ public string IconPath
3535
}
3636

3737
public string Url { get; set; }
38+
39+
[JsonIgnore]
40+
public bool Status => Enabled;
3841
public bool Enabled { get; set; }
3942

4043
public SearchSource DeepCopy()

Plugins/Flow.Launcher.Plugin.WebSearch/SearchSourceSetting.xaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
Title="{DynamicResource flowlauncher_plugin_websearch_window_title}"
99
Width="550"
1010
d:DataContext="{d:DesignInstance vm:SearchSourceViewModel}"
11-
Background="{DynamicResource PopuBGColor}"
11+
Background="{DynamicResource PopupBGColor}"
1212
Foreground="{DynamicResource PopupTextColor}"
1313
ResizeMode="NoResize"
1414
SizeToContent="Height"
@@ -179,7 +179,7 @@
179179
HorizontalAlignment="Left"
180180
VerticalAlignment="Center"
181181
FontSize="14"
182-
Text="{DynamicResource flowlauncher_plugin_websearch_enabled}" />
182+
Text="{DynamicResource flowlauncher_plugin_websearch_enabled_label}" />
183183
<CheckBox
184184
Grid.Row="4"
185185
Grid.Column="1"

Plugins/Flow.Launcher.Plugin.WebSearch/SettingsControl.xaml

Lines changed: 4 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -69,23 +69,11 @@
6969
<GridViewColumn
7070
Width="130"
7171
DisplayMemberBinding="{Binding ActionKeyword}"
72-
Header="{DynamicResource flowlauncher_plugin_websearch_action_keyword}">
73-
<GridViewColumn.CellTemplate>
74-
<DataTemplate>
75-
<TextBlock Text="{Binding ActionKeyword}" />
76-
</DataTemplate>
77-
</GridViewColumn.CellTemplate>
78-
</GridViewColumn>
72+
Header="{DynamicResource flowlauncher_plugin_websearch_action_keyword}"/>
7973
<GridViewColumn
8074
Width="350"
8175
DisplayMemberBinding="{Binding Title}"
82-
Header="{DynamicResource flowlauncher_plugin_websearch_title}">
83-
<GridViewColumn.CellTemplate>
84-
<DataTemplate>
85-
<TextBlock Text="{Binding Title}" />
86-
</DataTemplate>
87-
</GridViewColumn.CellTemplate>
88-
</GridViewColumn>
76+
Header="{DynamicResource flowlauncher_plugin_websearch_title}"/>
8977
<GridViewColumn Width="140" Header="{DynamicResource flowlauncher_plugin_websearch_enable}">
9078
<GridViewColumn.CellTemplate>
9179
<DataTemplate>
@@ -94,7 +82,7 @@
9482
<Style TargetType="TextBlock">
9583
<Setter Property="Text" Value="{DynamicResource flowlauncher_plugin_websearch_false}" />
9684
<Style.Triggers>
97-
<DataTrigger Binding="{Binding Enabled, UpdateSourceTrigger=PropertyChanged}" Value="True">
85+
<DataTrigger Binding="{Binding Status, UpdateSourceTrigger=PropertyChanged}" Value="True">
9886
<Setter Property="Text" Value="{DynamicResource flowlauncher_plugin_websearch_true}" />
9987
</DataTrigger>
10088
</Style.Triggers>
@@ -158,7 +146,7 @@
158146
Margin="0,0,8,0"
159147
IsChecked="{Binding Settings.EnableSuggestion}" />
160148
</StackPanel>
161-
<!-- Not sure why binding IsEnabled directly to Settings.EnableWebSaerchSuggestion is not working -->
149+
<!-- Not sure why binding IsEnabled directly to Settings.EnableWebSearchSuggestion is not working -->
162150
</DockPanel>
163151
</Border>
164152
</Grid>

Plugins/Flow.Launcher.Plugin.WebSearch/SettingsControl.xaml.cs

Lines changed: 20 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -96,27 +96,29 @@ private void SortByColumn(object sender, RoutedEventArgs e)
9696
var columnBinding = headerClicked.Column.DisplayMemberBinding as Binding;
9797
var sortBy = columnBinding?.Path.Path ?? headerClicked.Column.Header as string;
9898

99-
Sort(sortBy, direction);
99+
if(sortBy != null) {
100+
Sort(sortBy, direction);
100101

101-
if (direction == ListSortDirection.Ascending)
102-
{
103-
headerClicked.Column.HeaderTemplate =
104-
Resources["HeaderTemplateArrowUp"] as DataTemplate;
105-
}
106-
else
107-
{
108-
headerClicked.Column.HeaderTemplate =
109-
Resources["HeaderTemplateArrowDown"] as DataTemplate;
110-
}
102+
if (direction == ListSortDirection.Ascending)
103+
{
104+
headerClicked.Column.HeaderTemplate =
105+
Resources["HeaderTemplateArrowUp"] as DataTemplate;
106+
}
107+
else
108+
{
109+
headerClicked.Column.HeaderTemplate =
110+
Resources["HeaderTemplateArrowDown"] as DataTemplate;
111+
}
111112

112-
// Remove arrow from previously sorted header
113-
if (_lastHeaderClicked != null && _lastHeaderClicked != headerClicked)
114-
{
115-
_lastHeaderClicked.Column.HeaderTemplate = null;
116-
}
113+
// Remove arrow from previously sorted header
114+
if (_lastHeaderClicked != null && _lastHeaderClicked != headerClicked)
115+
{
116+
_lastHeaderClicked.Column.HeaderTemplate = null;
117+
}
117118

118-
_lastHeaderClicked = headerClicked;
119-
_lastDirection = direction;
119+
_lastHeaderClicked = headerClicked;
120+
_lastDirection = direction;
121+
}
120122
}
121123
private void Sort(string sortBy, ListSortDirection direction)
122124
{

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,8 @@ And you can download <a href="https://github.com/Flow-Launcher/Flow.Launcher/dis
127127

128128
<img src="https://user-images.githubusercontent.com/6903107/144517502-5325de01-d0d9-4c2e-aafb-33c3f5d82f81.png" width="400">
129129
<img src="https://user-images.githubusercontent.com/6903107/144831031-0e01e8ea-3247-4ba4-a7b4-48b0db620bc1.png" width="400">
130-
<img src="https://user-images.githubusercontent.com/6903107/207141710-50bc0e6b-f0f8-4dc2-a136-621a473689d7.png" width="400">
130+
<img src="https://user-images.githubusercontent.com/6903107/222829602-aabb1144-db5c-4250-b5ae-66f8342e4ae4.png" width="400">
131+
131132

132133

133134
### Browser Bookmarks

0 commit comments

Comments
 (0)