private:
HDC m_hdc;
+
+ DECLARE_NO_COPY_CLASS(ScreenHDC)
};
// the same as ScreenHDC but for memory DCs: creates the HDC in ctor and
{
public:
MemoryHDC() { m_hdc = ::CreateCompatibleDC(NULL); }
- ~MemoryHDC() { ::DeleteObject(m_hdc); }
+ ~MemoryHDC() { ::DeleteDC(m_hdc); }
operator HDC() const { return m_hdc; }
private:
HDC m_hdc;
+
+ DECLARE_NO_COPY_CLASS(MemoryHDC)
};
// a class which selects a GDI object into a DC in its ctor and deselects in
private:
HDC m_hdc;
HGDIOBJ m_hgdiobj;
+
+ DECLARE_NO_COPY_CLASS(SelectInHDC)
};
// ---------------------------------------------------------------------------