/
githubmirror
/
Files
Обзор
Документация
Войти
/
githubmirror
/
Files
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
src/Files.App/Actions/Open/OpenSettingsAction.cs
41 строка
1 KB
yair100
Feature: Replaced Settings Dialog with page (#18410)
23 апр 2026, 23:59
Не верифицирован
23 апр 2026, 23:59
65e4bf8
Код
Авторство
О чём код?
// Copyright (c) Files Community // Licensed under the MIT License. namespace Files.App.Actions { [GeneratedRichCommand] internal sealed partial class OpenSettingsAction : BaseUIAction, IAction { private readonly IContentPageContext context = Ioc.Default.GetRequiredService<IContentPageContext>(); public string Label => Strings.Settings.GetLocalizedResource(); public string Description => Strings.OpenSettingsDescription.GetLocalizedResource(); public ActionCategory Category => ActionCategory.Open; public HotKey HotKey => new(Keys.OemComma, KeyModifiers.Ctrl); public RichGlyph Glyph => new(themedIconStyle: "App.ThemedIcons.Settings"); public Task ExecuteAsync(object? parameter = null) { var settingsPage = (parameter as SettingsNavigationParams)?.PageKind.ToString(); return settingsPage is not null ? NavigationHelpers.AddNewTabByParamAsync( typeof(ShellPanesPage), new PaneNavigationArguments() { LeftPaneNavPathParam = "Settings", LeftPaneSelectItemParam = settingsPage, }) : NavigationHelpers.OpenPathInNewTab("Settings", true); } } }