Skip to content

Commit 5c55d29

Browse files
committed
Handle it so that it doesn’t show if the registry is missing.
1 parent 762b267 commit 5c55d29

File tree

1 file changed

+19
-14
lines changed

1 file changed

+19
-14
lines changed

Flow.Launcher/SettingPages/Views/SettingsPaneGeneral.xaml

Lines changed: 19 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@
33
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
44
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
55
xmlns:cc="clr-namespace:Flow.Launcher.Resources.Controls"
6+
xmlns:converters="clr-namespace:Flow.Launcher.Converters"
67
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
78
xmlns:ext="clr-namespace:Flow.Launcher.Resources.MarkupExtensions"
89
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
910
xmlns:settingsViewModels="clr-namespace:Flow.Launcher.SettingPages.ViewModels"
1011
xmlns:ui="http://schemas.modernwpf.com/2019"
11-
xmlns:converters="clr-namespace:Flow.Launcher.Converters"
1212
xmlns:userSettings="clr-namespace:Flow.Launcher.Infrastructure.UserSettings;assembly=Flow.Launcher.Infrastructure"
1313
Title="General"
1414
d:DataContext="{d:DesignInstance settingsViewModels:SettingsPaneGeneralViewModel}"
@@ -32,7 +32,7 @@
3232
Style="{StaticResource PageTitle}"
3333
Text="{DynamicResource general}"
3434
TextAlignment="left" />
35-
35+
3636
<cc:ExCard
3737
Title="{DynamicResource startFlowLauncherOnSystemStartup}"
3838
Margin="0 8 0 0"
@@ -288,27 +288,32 @@
288288
SelectedValue="{Binding Language}"
289289
SelectedValuePath="LanguageCode" />
290290
</cc:Card>
291-
<cc:InfoBar Margin="0 12 0 0"
292-
Title="{DynamicResource KoreanImeTitle}"
293-
Closable="False"
294-
IsIconVisible="True"
295-
Length="Long"
296-
Message="{DynamicResource KoreanImeGuide}"
297-
Type="Warning" />
298-
<cc:CardGroup Margin="0 4 0 0">
291+
<Border Visibility="{Binding KoreanIMERegistryKeyExists, Converter={StaticResource BoolToVisibilityConverter}}">
292+
<cc:InfoBar
293+
Title="{DynamicResource KoreanImeTitle}"
294+
Margin="0 12 0 0"
295+
Closable="False"
296+
IsIconVisible="True"
297+
Length="Long"
298+
Message="{DynamicResource KoreanImeGuide}"
299+
Type="Info"
300+
Visibility="{Binding LegacyKoreanIMEEnabled, Converter={StaticResource BoolToVisibilityConverter}, ConverterParameter=Inverted, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}" />
301+
</Border>
302+
<cc:CardGroup Margin="0 4 0 0" Visibility="{Binding KoreanIMERegistryKeyExists, Converter={StaticResource BoolToVisibilityConverter}}">
299303
<cc:Card
300304
Title="{DynamicResource KoreanImeRegistry}"
301-
Icon="&#xe88b;" Sub="{DynamicResource KoreanImeRegistryTooltip}">
305+
Icon="&#xe88b;"
306+
Sub="{DynamicResource KoreanImeRegistryTooltip}">
302307
<ui:ToggleSwitch
303308
IsOn="{Binding LegacyKoreanIMEEnabled}"
304309
OffContent="{DynamicResource disable}"
305310
OnContent="{DynamicResource enable}" />
306311
</cc:Card>
307312
<cc:Card
308313
Title="{DynamicResource KoreanImeOpenLink}"
309-
Sub="{DynamicResource KoreanImeOpenLinkTooltip}"
310-
Icon="&#xf7b9;">
311-
<Button Content="{DynamicResource KoreanImeOpenLinkButton}" Command="{Binding OpenImeSettingsCommand}"/>
314+
Icon="&#xf7b9;"
315+
Sub="{DynamicResource KoreanImeOpenLinkTooltip}">
316+
<Button Command="{Binding OpenImeSettingsCommand}" Content="{DynamicResource KoreanImeOpenLinkButton}" />
312317
</cc:Card>
313318
</cc:CardGroup>
314319
</VirtualizingStackPanel>

0 commit comments

Comments
 (0)