Added free for bitmaps + stub for bitmap paint.

This commit is contained in:
Michael Jumper 2012-01-03 13:04:50 -08:00
parent c1a9d84028
commit 04625d4492
3 changed files with 13 additions and 2 deletions

View File

@ -57,5 +57,7 @@ typedef struct guac_rdp_bitmap {
} guac_rdp_bitmap; } guac_rdp_bitmap;
void guac_rdp_bitmap_new(rdpContext* context, rdpBitmap* bitmap); void guac_rdp_bitmap_new(rdpContext* context, rdpBitmap* bitmap);
void guac_rdp_bitmap_paint(rdpContext* context, rdpBitmap* bitmap);
void guac_rdp_bitmap_free(rdpContext* context, rdpBitmap* bitmap);
#endif #endif

View File

@ -74,8 +74,8 @@ boolean rdp_freerdp_pre_connect(freerdp* instance) {
bitmap = xnew(rdpBitmap); bitmap = xnew(rdpBitmap);
bitmap->size = sizeof(guac_rdp_bitmap); bitmap->size = sizeof(guac_rdp_bitmap);
bitmap->New = guac_rdp_bitmap_new; bitmap->New = guac_rdp_bitmap_new;
/* bitmap->Free = guac_rdp_bitmap_free; */ bitmap->Free = guac_rdp_bitmap_free;
/* bitmap->Paint = guac_rdp_bitmap_paint; */ bitmap->Paint = guac_rdp_bitmap_paint;
/* bitmap->Decompress = guac_rdp_bitmap_decompress; */ /* bitmap->Decompress = guac_rdp_bitmap_decompress; */
/* bitmap->SetSurface = guac_rdp_bitmap_setsurface; */ /* bitmap->SetSurface = guac_rdp_bitmap_setsurface; */
graphics_register_bitmap(context->graphics, bitmap); graphics_register_bitmap(context->graphics, bitmap);

View File

@ -95,3 +95,12 @@ void guac_rdp_bitmap_new(rdpContext* context, rdpBitmap* bitmap) {
} }
void guac_rdp_bitmap_paint(rdpContext* context, rdpBitmap* bitmap) {
/* STUB */
}
void guac_rdp_bitmap_free(rdpContext* context, rdpBitmap* bitmap) {
guac_client* client = ((rdp_freerdp_context*) context)->client;
guac_client_free_buffer(client, ((guac_rdp_bitmap*) bitmap)->layer);
}