:)
Here's my header:
#pragma once
#include "HashableRect.h"
class ImageGroup;
// This class implements a cached bitmap of a given OZO_XXX zorder layer.
class OverlayCachedLayer
{
public:
OverlayCachedLayer(void);
virtual ~OverlayCachedLayer(void);
// Draws this cached layer onto the given dc.
void draw(HDC dcHandle);
// Locks for drawing.
HDC lock(void);
// Unlocks from drawing.
void unlock(void)
// Updates the dimension of the overlay canvas.
void setDimensions(const CSize& dimensions);
private:
// The bitmap used to provide flicker-free update of the canvas.
ImageGroup* m_offscreen;
// Map of rects that need to be redrawn.
// This is a hash table to make sure all rects are unique --- this has
// the nice side-effect that if an overlay makes its rect dirty a
// successive number of times and does not move, only one dirty
// rect will be stored.
// The bool values mean nothing.
CMap<HashableRect, const HashableRect&, bool, bool> m_dirtyRectMap;
};
If I click on unlock() and do Create Implementation, I get:
void
OverlayCachedLayer::unlock(const CSize& dimensions)
{
}
Note that the parameters are wrong --- taken from the wrong function.
Thanks,
swine