aboutsummaryrefslogtreecommitdiff
path: root/Src/omBrowser/ifc_omdebugconfig.h
blob: 0c2fd4b030134e48c76f5725ae8362fa769d884f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
#ifndef NULLSOFT_WINAMP_OMBROWSER_DEBUG_CONFIG_INTERFACE_HEADER
#define NULLSOFT_WINAMP_OMBROWSER_DEBUG_CONFIG_INTERFACE_HEADER

#if defined(_MSC_VER) && (_MSC_VER >= 1020)
#pragma once
#endif

// {07057926-4DCD-4686-AE81-F74AE36B931B}
static const GUID IFC_OmDebugConfig = 
{ 0x7057926, 0x4dcd, 0x4686, { 0xae, 0x81, 0xf7, 0x4a, 0xe3, 0x6b, 0x93, 0x1b } };

#define CFGID_DEBUG_FILTERMENU		0		// param = (ULONG_PTR)(BOOL)fFilter
#define CFGID_DEBUG_SCRIPTERROR		1		// param = (ULONG_PTR)(BOOL)fShow
#define CFGID_DEBUG_SCRIPTDEBUGGER	2		// param = (ULONG_PTR)(BOOL)fShow
#define CFGID_DEBUG_BROWSERPATH		3		// param = (ULONG_PTR)(LPCWSTR)pszPath

#include <bfc/dispatch.h>

class __declspec(novtable) ifc_omdebugconfig : public Dispatchable
{
protected:
	ifc_omdebugconfig() {}
	~ifc_omdebugconfig() {}

public:
	
	HRESULT GetMenuFilterEnabled(void);
	HRESULT GetScriptErrorEnabled(void);
	HRESULT GetScriptDebuggerEnabled(void);
	HRESULT GetBrowserPath(LPWSTR pszBuffer, INT cchBufferMax);

	HRESULT EnableMenuFilter(BOOL fEnable);
	HRESULT EnableScriptError(BOOL fEnable);
	HRESULT EnableScriptDebugger(BOOL fEnable);
	HRESULT SetBrowserPath(LPCWSTR pszPath);

public:
	DISPATCH_CODES
	{
		API_GETMENUFILTERENABLED			= 10,
		API_GETSCRIPTERRORENABLED		= 20,
		API_GETSCRIPTDEBUGGERENABLED	= 30,
		API_GETBROWSERPATH				= 40,

		API_ENABLEMENUFILTER				= 110,
		API_ENABLESCRIPTERROR			= 120,
		API_ENABLESCRIPTDEBUGGER		= 130,
		API_SETBROWSERPATH				= 140,
	};
};

inline HRESULT ifc_omdebugconfig::GetMenuFilterEnabled(void)
{
	return _call(API_GETMENUFILTERENABLED, (HRESULT)E_NOTIMPL);
}

inline HRESULT ifc_omdebugconfig::GetScriptErrorEnabled(void)
{
	return _call(API_GETSCRIPTERRORENABLED, (HRESULT)E_NOTIMPL);
}

inline HRESULT ifc_omdebugconfig::GetScriptDebuggerEnabled(void)
{
	return _call(API_GETSCRIPTDEBUGGERENABLED, (HRESULT)E_NOTIMPL);
}

inline HRESULT ifc_omdebugconfig::GetBrowserPath(LPWSTR pszBuffer, INT cchBufferMax)
{
	return _call(API_GETBROWSERPATH, (HRESULT)E_NOTIMPL, pszBuffer, cchBufferMax); 
}

inline HRESULT ifc_omdebugconfig::EnableMenuFilter(BOOL fEnable)
{
	return _call(API_ENABLEMENUFILTER, (HRESULT)E_NOTIMPL, fEnable);
}

inline HRESULT ifc_omdebugconfig::EnableScriptError(BOOL fEnable)
{
	return _call(API_ENABLESCRIPTERROR, (HRESULT)E_NOTIMPL, fEnable);
}

inline HRESULT ifc_omdebugconfig::EnableScriptDebugger(BOOL fEnable)
{
	return _call(API_ENABLESCRIPTDEBUGGER, (HRESULT)E_NOTIMPL, fEnable);
}

inline HRESULT ifc_omdebugconfig::SetBrowserPath(LPCWSTR pszPath)
{
	return _call(API_SETBROWSERPATH, (HRESULT)E_NOTIMPL, pszPath);
}

#endif // NULLSOFT_WINAMP_OMBROWSER_DEBUG_CONFIG_INTERFACE_HEADER