ReactOS 0.4.15-dev-5666-gc548b97
errors.h File Reference
#include <vfwmsgs.h>
Include dependency graph for errors.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define AMOVIEAPI
 
#define VFW_FIRST_CODE   0x200
 
#define MAX_ERROR_TEXT_LEN   160
 
#define AMGetErrorText   WINELIB_NAME_AW(AMGetErrorText)
 

Typedefs

typedef BOOL(WINAPIAMGETERRORTEXTPROCA) (HRESULT, char *, DWORD)
 
typedef BOOL(WINAPIAMGETERRORTEXTPROCW) (HRESULT, WCHAR *, DWORD)
 

Functions

DWORD WINAPI AMGetErrorTextA (HRESULT, LPSTR, DWORD)
 
DWORD WINAPI AMGetErrorTextW (HRESULT, LPWSTR, DWORD)
 

Macro Definition Documentation

◆ AMGetErrorText

#define AMGetErrorText   WINELIB_NAME_AW(AMGetErrorText)

Definition at line 39 of file errors.h.

◆ AMOVIEAPI

#define AMOVIEAPI

Definition at line 26 of file errors.h.

◆ MAX_ERROR_TEXT_LEN

#define MAX_ERROR_TEXT_LEN   160

Definition at line 29 of file errors.h.

◆ VFW_FIRST_CODE

#define VFW_FIRST_CODE   0x200

Definition at line 28 of file errors.h.

Typedef Documentation

◆ AMGETERRORTEXTPROCA

typedef BOOL(WINAPI * AMGETERRORTEXTPROCA) (HRESULT, char *, DWORD)

Definition at line 33 of file errors.h.

◆ AMGETERRORTEXTPROCW

typedef BOOL(WINAPI * AMGETERRORTEXTPROCW) (HRESULT, WCHAR *, DWORD)

Definition at line 34 of file errors.h.

Function Documentation

◆ AMGetErrorTextA()

DWORD WINAPI AMGetErrorTextA ( HRESULT  hr,
LPSTR  buffer,
DWORD  maxlen 
)

Definition at line 307 of file main.c.

308{
309 DWORD res;
311
312 TRACE("(%x,%p,%d)\n", hr, buffer, maxlen);
313 if (!buffer)
314 return 0;
315
316 res = AMGetErrorTextW(hr, errorW, sizeof(errorW)/sizeof(*errorW));
317 return WideCharToMultiByte(CP_ACP, 0, errorW, res, buffer, maxlen, 0, 0);
318}
DWORD WINAPI AMGetErrorTextW(HRESULT hr, LPWSTR buffer, DWORD maxlen)
Definition: main.c:323
#define CP_ACP
Definition: compat.h:109
#define WideCharToMultiByte
Definition: compat.h:111
#define MAX_ERROR_TEXT_LEN
Definition: errors.h:29
unsigned long DWORD
Definition: ntddk_ex.h:95
GLuint res
Definition: glext.h:9613
GLuint buffer
Definition: glext.h:5915
static const WCHAR errorW[]
Definition: htmlevent.c:61
HRESULT hr
Definition: shlfolder.c:183
#define TRACE(s)
Definition: solgame.cpp:4
__wchar_t WCHAR
Definition: xmlstorage.h:180

◆ AMGetErrorTextW()

DWORD WINAPI AMGetErrorTextW ( HRESULT  hr,
LPWSTR  buffer,
DWORD  maxlen 
)

Definition at line 323 of file main.c.

324{
325 unsigned int len;
326 static const WCHAR format[] = {'E','r','r','o','r',':',' ','0','x','%','l','x',0};
328
329 FIXME("(%x,%p,%d) stub\n", hr, buffer, maxlen);
330
331 if (!buffer) return 0;
333 if ((len = strlenW(error)) >= maxlen) return 0;
335 return len;
336}
#define FIXME(fmt,...)
Definition: debug.h:111
#define lstrcpyW
Definition: compat.h:749
GLint GLint GLsizei GLsizei GLsizei GLint GLenum format
Definition: gl.h:1546
GLenum GLsizei len
Definition: glext.h:6722
#define error(str)
Definition: mkdosfs.c:1605
#define strlenW(s)
Definition: unicode.h:28
int WINAPIV wsprintfW(_Out_ LPWSTR, _In_ _Printf_format_string_ LPCWSTR,...)

Referenced by AMGetErrorTextA().