undid last 2 commits, there are many more cases like this so it's better to fix this problem in a different way in wx/log.h

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@41088 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2006-09-09 13:25:01 +00:00
parent e6113e3a52
commit 9804c4d95c

View File

@@ -335,9 +335,7 @@ inline RECT wxGetWindowRect(HWND hwnd)
RECT rect; RECT rect;
if ( !::GetWindowRect(hwnd, &rect) ) if ( !::GetWindowRect(hwnd, &rect) )
{
wxLogLastError(_T("GetWindowRect")); wxLogLastError(_T("GetWindowRect"));
}
return rect; return rect;
} }
@@ -347,9 +345,7 @@ inline RECT wxGetClientRect(HWND hwnd)
RECT rect; RECT rect;
if ( !::GetClientRect(hwnd, &rect) ) if ( !::GetClientRect(hwnd, &rect) )
{
wxLogLastError(_T("GetClientRect")); wxLogLastError(_T("GetClientRect"));
}
return rect; return rect;
} }
@@ -505,9 +501,7 @@ public:
: m_hdc(hdc) : m_hdc(hdc)
{ {
if ( !::SelectClipRgn(hdc, hrgn) ) if ( !::SelectClipRgn(hdc, hrgn) )
{
wxLogLastError(_T("SelectClipRgn")); wxLogLastError(_T("SelectClipRgn"));
}
} }
~HDCClipper() ~HDCClipper()
@@ -536,9 +530,7 @@ private:
{ {
m_modeOld = ::SetMapMode(hdc, mm); m_modeOld = ::SetMapMode(hdc, mm);
if ( !m_modeOld ) if ( !m_modeOld )
{
wxLogLastError(_T("SelectClipRgn")); wxLogLastError(_T("SelectClipRgn"));
}
} }
~HDCMapModeChanger() ~HDCMapModeChanger()
@@ -567,17 +559,13 @@ public:
{ {
m_hGlobal = ::GlobalAlloc(flags, size); m_hGlobal = ::GlobalAlloc(flags, size);
if ( !m_hGlobal ) if ( !m_hGlobal )
{
wxLogLastError(_T("GlobalAlloc")); wxLogLastError(_T("GlobalAlloc"));
}
} }
~GlobalPtr() ~GlobalPtr()
{ {
if ( m_hGlobal && ::GlobalFree(m_hGlobal) ) if ( m_hGlobal && ::GlobalFree(m_hGlobal) )
{
wxLogLastError(_T("GlobalFree")); wxLogLastError(_T("GlobalFree"));
}
} }
// implicit conversion // implicit conversion
@@ -599,9 +587,7 @@ public:
{ {
m_ptr = GlobalLock(hGlobal); m_ptr = GlobalLock(hGlobal);
if ( !m_ptr ) if ( !m_ptr )
{
wxLogLastError(_T("GlobalLock")); wxLogLastError(_T("GlobalLock"));
}
} }
~GlobalPtrLock() ~GlobalPtrLock()