/
githubmirror
/
PowerToys
Обзор
Документация
Войти
/
githubmirror
/
PowerToys
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
src/modules/cmdpal/ext/SamplePagesExtension/SampleExtension.cs
41 строка
1 KB
Mike Griese
Rename the `[Ee]xts` dir to `ext` (#38852)
15 апр 2025, 14:07
Не верифицирован
15 апр 2025, 14:07
2b5181b
Код
Авторство
О чём код?
// Copyright (c) Microsoft Corporation // The Microsoft Corporation licenses this file to you under the MIT license. // See the LICENSE file in the project root for more information. using System; using System.Runtime.InteropServices; using System.Threading; using Microsoft.CommandPalette.Extensions; namespace SamplePagesExtension; [ComVisible(true)] [Guid("6112D28D-6341-45C8-92C3-83ED55853A9F")] [ComDefaultInterface(typeof(IExtension))] public sealed partial class SampleExtension : IExtension, IDisposable { private readonly ManualResetEvent _extensionDisposedEvent; private readonly SamplePagesCommandsProvider _provider = new(); public SampleExtension(ManualResetEvent extensionDisposedEvent) { this._extensionDisposedEvent = extensionDisposedEvent; } public object GetProvider(ProviderType providerType) { switch (providerType) { case ProviderType.Commands: return _provider; default: return null; } } public void Dispose() { this._extensionDisposedEvent.Set(); } }