Skip to content

Commit

Permalink
Fix GPO in settings
Browse files Browse the repository at this point in the history
  • Loading branch information
Aaron-Junker committed Jan 19, 2025
1 parent b73a204 commit 1d1142a
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,17 @@
IsEnabled="{x:Bind Mode=OneWay, Path=ViewModel.IsFileActionsMenuEnabledGpoConfigured, Converter={StaticResource BoolNegationConverter}}">
<ToggleSwitch x:Uid="ToggleSwitch" IsOn="{x:Bind Mode=TwoWay, Path=ViewModel.FileActionsMenuIsEnabled}" />
</tkcontrols:SettingsCard>
<InfoBar
x:Uid="GPO_SettingIsManaged"
IsClosable="False"
IsOpen="{x:Bind ViewModel.IsFileActionsMenuEnabledGpoConfigured, Mode=OneWay}"
IsTabStop="{x:Bind ViewModel.IsFileActionsMenuEnabledGpoConfigured, Mode=OneWay}"
Severity="Informational">
<InfoBar.IconSource>
<FontIconSource FontFamily="{StaticResource SymbolThemeFontFamily}" Glyph="&#xE72E;" />
</InfoBar.IconSource>
</InfoBar>

<tkcontrols:SettingsCard
x:Uid="Activation_Shortcut"
HeaderIcon="{ui:FontIcon Glyph=&#xEDA7;}"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public FileActionsMenuViewModel(ISettingsRepository<FileActionsMenuSettings> mod
// set the callback functions value to handle outgoing IPC message.
SendConfigMSG = ipcMSGCallBackFunc;

_fileActionsMenuEnabledGpoRuleConfiguration = GPOWrapper.GetConfiguredSvgPreviewEnabledValue();
_fileActionsMenuEnabledGpoRuleConfiguration = GPOWrapper.GetConfiguredFileActionsMenuEnabledValue();
if (_fileActionsMenuEnabledGpoRuleConfiguration == GpoRuleConfigured.Disabled || _fileActionsMenuEnabledGpoRuleConfiguration == GpoRuleConfigured.Enabled)
{
// Get the enabled state from GPO.
Expand Down

0 comments on commit 1d1142a

Please sign in to comment.