mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 10:04:49 +00:00
eliminate GCC4 warnings
svn path=/trunk/; revision=15225
This commit is contained in:
parent
267f11a8b4
commit
7313b15dbd
4 changed files with 28 additions and 10 deletions
|
@ -17,7 +17,7 @@ TARGET_INSTALLDIR := system32
|
|||
TARGET_CFLAGS := \
|
||||
-D__USE_W32API -DWIN32 -D_ROS_ \
|
||||
-D_WIN32_IE=0x0600 -D_WIN32_WINNT=0x0501 -DWINVER=0x0500 \
|
||||
-DUNICODE -fexceptions -Wall \
|
||||
-DUNICODE -fexceptions -Wall -Wno-unused-value \
|
||||
-I../../../include/expat
|
||||
|
||||
TARGET_CPPFLAGS := $(TARGET_CFLAGS)
|
||||
|
|
|
@ -8,7 +8,7 @@ CC = gcc
|
|||
CXX = g++
|
||||
LINK = g++
|
||||
|
||||
CFLAGS = -DWIN32 -D_WIN32_IE=0x0600 -D_WIN32_WINNT=0x0501 -DWINVER=0x0500 -fexceptions -Wall -I. -I$(EXPAT_INC)
|
||||
CFLAGS = -DWIN32 -D_WIN32_IE=0x0600 -D_WIN32_WINNT=0x0501 -DWINVER=0x0500 -fexceptions -Wall -Wno-unused-value -I. -I$(EXPAT_INC)
|
||||
RCFLAGS = -DWIN32 -D__WINDRES__
|
||||
LFLAGS = -Wl,--subsystem,windows
|
||||
|
||||
|
|
|
@ -10,7 +10,7 @@ CC = gcc
|
|||
CXX = g++
|
||||
LINK = g++
|
||||
|
||||
CFLAGS = -DWIN32 -D_WIN32_IE=0x0600 -D_WIN32_WINNT=0x0501 -DWINVER=0x0500 -fexceptions -Wall -I. -I$(EXPAT_INC)
|
||||
CFLAGS = -DWIN32 -D_WIN32_IE=0x0600 -D_WIN32_WINNT=0x0501 -DWINVER=0x0500 -fexceptions -Wall -Wno-unused-value -I. -I$(EXPAT_INC)
|
||||
RCFLAGS = -DWIN32 -D__WINDRES__
|
||||
LFLAGS = -Wl,--subsystem,windows
|
||||
|
||||
|
|
|
@ -115,25 +115,38 @@ template<typename BASE> struct IComSrvQI : public BASE
|
|||
{
|
||||
}
|
||||
|
||||
STDMETHODIMP QueryInterface(REFIID riid, LPVOID* ppv) {*ppv=0;
|
||||
if (IsEqualIID(riid, _uuid_base) ||
|
||||
IsEqualIID(riid, IID_IUnknown)) {*ppv=static_cast<BASE*>(this); this->AddRef(); return S_OK;}
|
||||
return E_NOINTERFACE;}
|
||||
STDMETHODIMP QueryInterface(REFIID riid, LPVOID* ppv)
|
||||
{
|
||||
*ppv = NULL;
|
||||
|
||||
if (IsEqualIID(riid, _uuid_base) || IsEqualIID(riid, IID_IUnknown))
|
||||
{*ppv=static_cast<BASE*>(this); this->AddRef(); return S_OK;}
|
||||
|
||||
return E_NOINTERFACE;
|
||||
}
|
||||
|
||||
protected:
|
||||
IComSrvQI() {}
|
||||
virtual ~IComSrvQI() {}
|
||||
|
||||
REFIID _uuid_base;
|
||||
};
|
||||
|
||||
template<> struct IComSrvQI<IUnknown> : public IUnknown
|
||||
{
|
||||
STDMETHODIMP QueryInterface(REFIID riid, LPVOID* ppv) {*ppv=0;
|
||||
if (IsEqualIID(riid, IID_IUnknown)) {*ppv=this; AddRef(); return S_OK;}
|
||||
return E_NOINTERFACE;}
|
||||
STDMETHODIMP QueryInterface(REFIID riid, LPVOID* ppv)
|
||||
{
|
||||
*ppv = NULL;
|
||||
|
||||
if (IsEqualIID(riid, IID_IUnknown))
|
||||
{*ppv=this; AddRef(); return S_OK;}
|
||||
|
||||
return E_NOINTERFACE;
|
||||
}
|
||||
|
||||
protected:
|
||||
IComSrvQI<IUnknown>() {}
|
||||
virtual ~IComSrvQI<IUnknown>() {}
|
||||
};
|
||||
|
||||
|
||||
|
@ -455,6 +468,8 @@ protected:
|
|||
|
||||
struct DWebBrowserEvents2IF
|
||||
{
|
||||
virtual ~DWebBrowserEvents2IF() {}
|
||||
|
||||
virtual void StatusTextChange(const BStr& text)
|
||||
{}
|
||||
|
||||
|
@ -594,6 +609,9 @@ protected:
|
|||
// MinGW defines a wrong FixedDWebBrowserEvents2 interface with virtual functions for DISPID calls, so we use our own, corrected version:
|
||||
interface FixedDWebBrowserEvents2 : public IDispatch
|
||||
{
|
||||
#ifdef __GNUC__
|
||||
virtual ~FixedDWebBrowserEvents2() {}
|
||||
#endif
|
||||
};
|
||||
|
||||
struct ANSUNC DWebBrowserEvents2Impl : public SimpleComObject,
|
||||
|
|
Loading…
Reference in a new issue