Author: ssawant Date: Sun Jun 4 17:33:06 2017 New Revision: 74915 URL: http://svn.reactos.org/svn/reactos?rev=74915&view=rev Log: [QCKLNCH] -Added .rgs script and other files to facilitate component registration.
Added: branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/qcklnch.rc (with props) branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/rgs/ branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/rgs/qcklnch.rgs (with props) Modified: branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/CMakeLists.txt branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/CQuickLaunchBand.cpp branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/CQuickLaunchBand.h branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/qcklnch.cpp Modified: branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/CMakeLists.txt URL: http://svn.reactos.org/svn/reactos/branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/CMakeLists.txt?rev=74915&r1=74914&r2=74915&view=diff ============================================================================== --- branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/CMakeLists.txt [iso-8859-1] (original) +++ branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/CMakeLists.txt [iso-8859-1] Sun Jun 4 17:33:06 2017 @@ -16,6 +16,7 @@ add_library(qcklnch SHARED qcklnch.cpp + qcklnch.rc CQuickLaunchBand.cpp ${CMAKE_CURRENT_BINARY_DIR}/qcklnch.def) Modified: branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/CQuickLaunchBand.cpp URL: http://svn.reactos.org/svn/reactos/branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/CQuickLaunchBand.cpp?rev=74915&r1=74914&r2=74915&view=diff ============================================================================== --- branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/CQuickLaunchBand.cpp [iso-8859-1] (original) +++ branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/CQuickLaunchBand.cpp [iso-8859-1] Sun Jun 4 17:33:06 2017 @@ -13,6 +13,20 @@ // {260CB95D-4544-44F6-A079-575BAA60B72F} static const GUID CLSID_QuickLaunchBand = { 0x260cb95d, 0x4544, 0x44f6, { 0xa0, 0x79, 0x57, 0x5b, 0xaa, 0x60, 0xb7, 0x2f } }; +//RegComCat function +HRESULT RegisterComCat() +{ + ICatRegister *pcr; + HRESULT hr = CoCreateInstance(CLSID_StdComponentCategoriesMgr, NULL, CLSCTX_INPROC_SERVER, IID_ICatRegister, (void**)&pcr); + if (SUCCEEDED(hr)) + { + CATID catid = CATID_DeskBand; + hr = pcr->RegisterClassImplCategories(CLSID_QuickLaunchBand, 1, &catid); + pcr->Release(); + } + return hr; +} + //CQuickLaunchBand CQuickLaunchBand::CQuickLaunchBand() : @@ -59,9 +73,9 @@ IN REFIID riid, OUT VOID **ppvSite) { - /*TRACE("CQuickLaunchBand::GetSite(0x%p,0x%p)\n", riid, ppvSite); - - if (m_Site != NULL) + TRACE("CQuickLaunchBand::GetSite(0x%p,0x%p)\n", riid, ppvSite); + + /* if (m_Site != NULL) { return m_Site->QueryInterface(riid, ppvSite); } @@ -117,8 +131,7 @@ IN DWORD dwViewMode, IN OUT DESKBANDINFO *pdbi) { - //TRACE("CQuickLaunchBand::GetBandInfo(0x%x,0x%x,0x%p) hWnd=0x%p\n", dwBandID, dwViewMode, pdbi, m_hWnd); - + TRACE("CQuickLaunchBand::GetBandInfo(0x%x,0x%x,0x%p) hWnd=0x%p\n", dwBandID, dwViewMode, pdbi, m_hWnd); return E_FAIL; } @@ -127,14 +140,14 @@ HRESULT STDMETHODCALLTYPE CQuickLaunchBand::SetClient( IN IUnknown *punkClient) { - /*TRACE("IDeskBar::SetClient(0x%p)\n", punkClient);*/ + TRACE("IDeskBar::SetClient(0x%p)\n", punkClient); return E_NOTIMPL; } HRESULT STDMETHODCALLTYPE CQuickLaunchBand::GetClient( OUT IUnknown **ppunkClient) { - /*TRACE("IDeskBar::GetClient(0x%p)\n", ppunkClient);*/ + TRACE("IDeskBar::GetClient(0x%p)\n", ppunkClient); return E_NOTIMPL; } @@ -155,7 +168,7 @@ { TRACE("CQuickLaunchBand::GetClassID(0x%p)\n", pClassID); /* We're going to return the (internal!) CLSID of the task band interface */ - //*pClassID = CLSID_ITaskBand; + *pClassID = CLSID_QuickLaunchBand; return S_OK; } @@ -168,7 +181,7 @@ HRESULT STDMETHODCALLTYPE CQuickLaunchBand::Load( IN IStream *pStm) { - //TRACE("CQuickLaunchBand::Load called\n"); + TRACE("CQuickLaunchBand::Load called\n"); /* Nothing to do */ return S_OK; } @@ -200,7 +213,7 @@ IN LPARAM lParam, OUT LRESULT *plrResult) { - //TRACE("CQuickLaunchBand: IWinEventHandler::ProcessMessage(0x%p, 0x%x, 0x%p, 0x%p, 0x%p)\n", hWnd, uMsg, wParam, lParam, plrResult); + TRACE("CQuickLaunchBand: IWinEventHandler::ProcessMessage(0x%p, 0x%x, 0x%p, 0x%p, 0x%p)\n", hWnd, uMsg, wParam, lParam, plrResult); return E_NOTIMPL; } @@ -252,18 +265,3 @@ return E_NOTIMPL; } - - - - - -/*****************************************************************************/ - - /* HRESULT STDMETHODCALLTYPE Initialize(IN OUT ITrayWindow *tray, HWND hWndStartButton) - { - m_Tray = tray; - m_BandID = (DWORD) -1; - m_hWndStartButton = hWndStartButton; - return S_OK; - } -*/ Modified: branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/CQuickLaunchBand.h URL: http://svn.reactos.org/svn/reactos/branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/CQuickLaunchBand.h?rev=74915&r1=74914&r2=74915&view=diff ============================================================================== --- branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/CQuickLaunchBand.h [iso-8859-1] (original) +++ branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/CQuickLaunchBand.h [iso-8859-1] Sun Jun 4 17:33:06 2017 @@ -8,6 +8,8 @@ #pragma once extern const GUID CLSID_QuickLaunchBand; + +HRESULT RegisterComCat(); class CQuickLaunchBand : public CComCoClass<CQuickLaunchBand, &CLSID_QuickLaunchBand>, @@ -147,7 +149,8 @@ ); //***************************************************************************************************** - + + DECLARE_REGISTRY_RESOURCEID(1001) DECLARE_NOT_AGGREGATABLE(CQuickLaunchBand) DECLARE_PROTECT_FINAL_CONSTRUCT() Modified: branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/qcklnch.cpp URL: http://svn.reactos.org/svn/reactos/branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/qcklnch.cpp?rev=74915&r1=74914&r2=74915&view=diff ============================================================================== --- branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/qcklnch.cpp [iso-8859-1] (original) +++ branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/qcklnch.cpp [iso-8859-1] Sun Jun 4 17:33:06 2017 @@ -13,7 +13,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(qcklnch); BEGIN_OBJECT_MAP(ObjectMap) - //OBJECT_ENTRY(CLSID_QuickLaunchBand, CQuickLaunchBand) + OBJECT_ENTRY(CLSID_QuickLaunchBand, CQuickLaunchBand) END_OBJECT_MAP() HINSTANCE g_hInstance; @@ -45,7 +45,12 @@ STDAPI DllRegisterServer(void) { - return g_Module.DllRegisterServer(FALSE); + HRESULT hr = g_Module.DllRegisterServer(FALSE); + + if (FAILED(hr)) + return hr; + else + return RegisterComCat(); } STDAPI Added: branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/qcklnch.rc URL: http://svn.reactos.org/svn/reactos/branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/qcklnch.rc?rev=74915 ============================================================================== --- branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/qcklnch.rc (added) +++ branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/qcklnch.rc [iso-8859-1] Sun Jun 4 17:33:06 2017 @@ -0,0 +1,10 @@ +#include <windef.h> +#include <winuser.h> +#include <commctrl.h> + +LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL + +1001 REGISTRY "rgs/qcklnch.rgs" + +#include <reactos/manifest_dll.rc> + Propchange: branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/qcklnch.rc ------------------------------------------------------------------------------ svn:eol-style = native Added: branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/rgs/qcklnch.rgs URL: http://svn.reactos.org/svn/reactos/branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/rgs/qcklnch.rgs?rev=74915 ============================================================================== --- branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/rgs/qcklnch.rgs (added) +++ branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/rgs/qcklnch.rgs [iso-8859-1] Sun Jun 4 17:33:06 2017 @@ -0,0 +1,13 @@ +HKCR +{ + NoRemove CLSID + { + ForceRemove {260CB95D-4544-44F6-A079-575BAA60B72F} = s 'QuickLaunchBand' + { + InprocServer32 = s '%MODULE%' + { + val ThreadingModel = s 'Apartment' + } + } + } +} Propchange: branches/GSoC_2017/shellext/reactos/dll/shellext/qcklnch/rgs/qcklnch.rgs ------------------------------------------------------------------------------ svn:eol-style = native