dix: add reference count of the resource to ResourceSizeRec

The ResourceSizeRec now contains the number of references to the
resource. For example a Pixmap knows this value and it can be useful
for determining the "weight" of the resource. Typically this value
is 1.

Reviewed-by: Rami Ylimäki <rami.ylimaki@vincit.fi>
Signed-off-by: Erkki Seppälä <erkki.seppala@vincit.fi>
This commit is contained in:
Erkki Seppälä 2010-12-08 17:09:30 +02:00
commit 233eab4d05
4 changed files with 490 additions and 8 deletions

View file

@ -162,6 +162,8 @@ typedef struct {
unsigned long resourceSize;
/* Size attributed to pixmap references from the resource. */
unsigned long pixmapRefSize;
/* Number of references to this resource; typically 1 */
unsigned long refCnt;
} ResourceSizeRec, *ResourceSizePtr;
typedef void (*SizeType)(pointer /*value*/,