mirror of
https://github.com/reactos/reactos.git
synced 2025-08-02 06:55:44 +00:00
[SDK] Define CCoInit in shellutils
This commit is contained in:
parent
8083ef9ad7
commit
d82185f104
7 changed files with 30 additions and 59 deletions
|
@ -722,19 +722,12 @@ static void GetEnvStatus()
|
|||
trace("Show hidden folders: %s\n", g_ShowHidden ? "yes" : "no");
|
||||
}
|
||||
|
||||
struct CCoInit
|
||||
{
|
||||
CCoInit() { hres = CoInitialize(NULL); }
|
||||
~CCoInit() { if (SUCCEEDED(hres)) { CoUninitialize(); } }
|
||||
HRESULT hres;
|
||||
};
|
||||
|
||||
START_TEST(ACListISF)
|
||||
{
|
||||
GetEnvStatus();
|
||||
CCoInit init;
|
||||
ok_hr(init.hres, S_OK);
|
||||
if (!SUCCEEDED(init.hres))
|
||||
ok_hr(init.hr, S_OK);
|
||||
if (!SUCCEEDED(init.hr))
|
||||
{
|
||||
skip("CoInitialize failed\n");
|
||||
return;
|
||||
|
|
|
@ -32,13 +32,6 @@ ULONG DbgPrint(PCH Format,...);
|
|||
#define ok_wstri(x, y) \
|
||||
ok(lstrcmpiW(x, y) == 0, "Wrong string. Expected '%S', got '%S'\n", y, x)
|
||||
|
||||
struct CCoInit
|
||||
{
|
||||
CCoInit() { hres = CoInitialize(NULL); }
|
||||
~CCoInit() { if (SUCCEEDED(hres)) { CoUninitialize(); } }
|
||||
HRESULT hres;
|
||||
};
|
||||
|
||||
|
||||
DEFINE_GUID(IID_IACLCustomMRU, 0xf729fc5e, 0x8769, 0x4f3e, 0xbd, 0xb2, 0xd7, 0xb5, 0x0f, 0xd2, 0x27, 0x5b);
|
||||
static const WCHAR szTestPath[] = L"TESTPATH_BROWSEUI_APITEST";
|
||||
|
@ -551,8 +544,8 @@ test_IACLCustomMRU_TypedURLs() // TypedURLs is special case
|
|||
START_TEST(IACLCustomMRU)
|
||||
{
|
||||
CCoInit init;
|
||||
ok_hex(init.hres, S_OK);
|
||||
if (!SUCCEEDED(init.hres))
|
||||
ok_hex(init.hr, S_OK);
|
||||
if (!SUCCEEDED(init.hr))
|
||||
return;
|
||||
|
||||
test_IACLCustomMRU_Basics();
|
||||
|
|
|
@ -14,20 +14,13 @@
|
|||
#include <stdio.h>
|
||||
#include <shellutils.h>
|
||||
|
||||
struct CCoInit
|
||||
{
|
||||
CCoInit() { hres = CoInitialize(NULL); }
|
||||
~CCoInit() { if (SUCCEEDED(hres)) { CoUninitialize(); } }
|
||||
HRESULT hres;
|
||||
};
|
||||
|
||||
START_TEST(IACLHistory)
|
||||
{
|
||||
CCoInit init;
|
||||
ok_hex(init.hres, S_OK);
|
||||
if (FAILED(init.hres))
|
||||
ok_hex(init.hr, S_OK);
|
||||
if (FAILED(init.hr))
|
||||
{
|
||||
skip("CoInitialize failed with 0x%08lX\n", init.hres);
|
||||
skip("CoInitialize failed with 0x%08lX\n", init.hr);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
#include <atlsimpcoll.h>
|
||||
#include <shlwapi.h>
|
||||
#include <strsafe.h>
|
||||
#include <shellutils.h>
|
||||
|
||||
//#define MANUAL_DEBUGGING
|
||||
|
||||
|
@ -23,13 +24,6 @@
|
|||
#define ok_wstri(x, y) \
|
||||
ok(lstrcmpiW(x, y) == 0, "Wrong string. Expected '%S', got '%S'\n", y, x)
|
||||
|
||||
struct CCoInit
|
||||
{
|
||||
CCoInit() { hr = CoInitialize(NULL); }
|
||||
~CCoInit() { if (SUCCEEDED(hr)) { CoUninitialize(); } }
|
||||
HRESULT hr;
|
||||
};
|
||||
|
||||
// create an EDIT control
|
||||
static HWND MyCreateEditCtrl(INT x, INT y, INT cx, INT cy)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue