1 /* 2 * PROJECT: ReactOS browseui 3 * LICENSE: LGPL-2.1-or-later (https://spdx.org/licenses/LGPL-2.1-or-later) 4 * PURPOSE: IShellTaskScheduler implementation 5 * COPYRIGHT: Copyright 2020 Oleg Dubinskiy (oleg.dubinskij30@gmail.com) 6 */ 7 8 #pragma once 9 10 class CShellTaskScheduler : 11 public CComCoClass<CShellTaskScheduler, &CLSID_ShellTaskScheduler>, 12 public CComObjectRootEx<CComMultiThreadModelNoCS>, 13 public IShellTaskScheduler 14 { 15 private: 16 public: 17 CShellTaskScheduler(); 18 ~CShellTaskScheduler(); 19 20 // *** IShellTaskScheduler methods *** 21 STDMETHODIMP AddTask(IRunnableTask *pTask, REFGUID rtoid, DWORD_PTR lParam, DWORD dwPriority) override; 22 STDMETHODIMP RemoveTasks(REFGUID rtoid, DWORD_PTR lParam, BOOL fWaitIfRunning) override; 23 STDMETHODIMP_(UINT) CountTasks(REFGUID rtoid) override; 24 STDMETHODIMP Status(DWORD dwReleaseStatus, DWORD dwThreadTimeout) override; 25 26 public: 27 28 DECLARE_REGISTRY_RESOURCEID(IDR_SHELLTASKSCHEDULER) 29 DECLARE_NOT_AGGREGATABLE(CShellTaskScheduler) 30 31 DECLARE_PROTECT_FINAL_CONSTRUCT() 32 33 BEGIN_COM_MAP(CShellTaskScheduler) 34 COM_INTERFACE_ENTRY_IID(IID_IShellTaskScheduler, IShellTaskScheduler) 35 END_COM_MAP() 36 }; 37