Skip to content

Commit 7fb52e6

Browse files
committed
- Add User Setting Folder in about
- Adjust ToggleSwitch VisualFocus
1 parent 90416c1 commit 7fb52e6

File tree

4 files changed

+45
-14
lines changed

4 files changed

+45
-14
lines changed

Flow.Launcher/Languages/en.xaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -280,6 +280,9 @@
280280
<system:String x:Key="clearlogfolder">Clear Logs</system:String>
281281
<system:String x:Key="clearlogfolderMessage">Are you sure you want to delete all logs?</system:String>
282282
<system:String x:Key="welcomewindow">Wizard</system:String>
283+
<system:String x:Key="userdatapath">User Data Location</system:String>
284+
<system:String x:Key="userdatapathToolTip">Installed plugins and user settings are saved in the User data folder. This location may vary depending on whether you are in portable mode or not.</system:String>
285+
<system:String x:Key="userdatapathButton">Open Folder</system:String>
283286

284287
<!-- FileManager Setting Dialog -->
285288
<system:String x:Key="fileManagerWindow">Select File Manager</system:String>

Flow.Launcher/Resources/CustomControlTemplate.xaml

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1702,6 +1702,21 @@
17021702
</Setter>
17031703
</Style>
17041704

1705+
<Style x:Key="{x:Static SystemParameters.FocusVisualStyleKey}">
1706+
<Setter Property="Control.Template">
1707+
<Setter.Value>
1708+
<ControlTemplate>
1709+
<Border
1710+
Margin="-3"
1711+
BorderBrush="{DynamicResource Color05B}"
1712+
BorderThickness="2"
1713+
CornerRadius="5"
1714+
SnapsToDevicePixels="true" />
1715+
</ControlTemplate>
1716+
</Setter.Value>
1717+
</Setter>
1718+
</Style>
1719+
17051720
<!-- - Custom Toggle Switch from modern wpf for left label -->
17061721
<system:TimeSpan x:Key="RepositionDelay">0:0:0.033</system:TimeSpan>
17071722
<KeyTime x:Key="RepositionDuration">0:0:0.367</KeyTime>
@@ -1716,7 +1731,7 @@
17161731
<Setter Property="FontFamily" Value="{DynamicResource ContentControlThemeFontFamily}" />
17171732
<Setter Property="FontSize" Value="{DynamicResource ControlContentThemeFontSize}" />
17181733
<Setter Property="FocusVisualStyle" Value="{DynamicResource {x:Static SystemParameters.FocusVisualStyleKey}}" />
1719-
<Setter Property="ui:FocusVisualHelper.FocusVisualMargin" Value="-7,-3,-7,-3" />
1734+
<Setter Property="ui:FocusVisualHelper.FocusVisualMargin" Value="-43,-3,-4,-3" />
17201735
<Setter Property="Template">
17211736
<Setter.Value>
17221737
<ControlTemplate TargetType="ui:ToggleSwitch">

Flow.Launcher/SettingPages/ViewModels/SettingsPaneAboutViewModel.cs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,15 @@ private void OpenSettingsFolder()
8080
PluginManager.API.OpenDirectory(Path.Combine(DataLocation.DataDirectory(), Constant.Settings));
8181
}
8282

83+
[RelayCommand]
84+
private void OpenParentOfSettingsFolder(object parameter)
85+
{
86+
string settingsFolderPath = Path.Combine(DataLocation.DataDirectory(), Constant.Settings);
87+
string parentFolderPath = Path.GetDirectoryName(settingsFolderPath);
88+
PluginManager.API.OpenDirectory(parentFolderPath);
89+
}
90+
91+
8392
[RelayCommand]
8493
private void OpenLogsFolder()
8594
{

Flow.Launcher/SettingPages/Views/SettingsPaneAbout.xaml

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@
2626
Text="{DynamicResource about}"
2727
TextAlignment="left" />
2828

29-
3029
<cc:Card
3130
Title="{Binding Version}"
3231
Icon="&#xe946;"
@@ -54,6 +53,17 @@
5453
<cc:HyperLink Text="{DynamicResource releaseNotes}" Uri="{Binding ReleaseNotes}" />
5554
</cc:Card>
5655

56+
57+
<cc:Card
58+
Title="{DynamicResource userdatapath}"
59+
Margin="0 14 0 0"
60+
Icon="&#xEC25;;"
61+
Sub="{DynamicResource userdatapathToolTip}">
62+
<StackPanel Orientation="Horizontal">
63+
<Button Command="{Binding OpenParentOfSettingsFolderCommand}" Content="{DynamicResource userdatapathButton}" />
64+
</StackPanel>
65+
</cc:Card>
66+
5767
<cc:Card
5868
Title="{DynamicResource website}"
5969
Margin="0 14 0 0"
@@ -63,28 +73,22 @@
6373
Margin="0 0 12 0"
6474
Text="{DynamicResource website}"
6575
Uri="{Binding Website}" />
66-
<cc:HyperLink Text="{DynamicResource github}" Uri="{Binding Github}" />
67-
</StackPanel>
68-
</cc:Card>
69-
70-
<cc:Card Title="{DynamicResource documentation}" Icon="&#xe82f;">
71-
<StackPanel Orientation="Horizontal">
7276
<cc:HyperLink
7377
Margin="0 0 12 0"
7478
Text="{DynamicResource documentation}"
7579
Uri="{Binding Documentation}" />
76-
<cc:HyperLink Text="{DynamicResource website}" Uri="{Binding Website}" />
80+
<cc:HyperLink Text="{DynamicResource github}" Uri="{Binding Github}" />
7781
</StackPanel>
7882
</cc:Card>
7983

80-
<cc:Card
81-
Title="{DynamicResource icons}"
82-
Margin="0 14 0 0"
83-
Icon="&#xE8FE;">
84+
<cc:Card Title="{DynamicResource icons}" Icon="&#xE8FE;">
8485
<cc:HyperLink Text="icons8.com" Uri="https://icons8.com/" />
8586
</cc:Card>
8687

87-
<cc:Card Title="{DynamicResource devtool}" Icon="&#xf12b;">
88+
<cc:Card
89+
Title="{DynamicResource devtool}"
90+
Margin="0 12 0 0"
91+
Icon="&#xf12b;">
8892
<StackPanel Orientation="Horizontal">
8993
<Button
9094
Margin="0 0 12 0"

0 commit comments

Comments
 (0)