server: add server update callback registration.

This commit is contained in:
Vic Lee 2011-08-23 20:37:08 +08:00
parent ca52da15cd
commit b7ee3be2d9
3 changed files with 19 additions and 0 deletions

View File

@ -242,6 +242,8 @@ freerdp_peer* freerdp_peer_new(int sockfd)
client->input = peer->rdp->input;
client->update = peer->rdp->update;
update_register_server_callbacks(client->update);
transport_attach(peer->rdp->transport, sockfd);
peer->rdp->transport->recv_callback = peer_recv_callback;

View File

@ -216,6 +216,21 @@ void update_reset_state(rdpUpdate* update)
update->order_info.orderType = ORDER_TYPE_PATBLT;
}
static void update_begin_paint(rdpUpdate* update)
{
update_reset_state(update);
}
static void update_end_paint(rdpUpdate* update)
{
}
void update_register_server_callbacks(rdpUpdate* update)
{
update->BeginPaint = update_begin_paint;
update->EndPaint = update_end_paint;
}
rdpUpdate* update_new(rdpRdp* rdp)
{
rdpUpdate* update;

View File

@ -43,4 +43,6 @@ void update_read_bitmap(rdpUpdate* update, STREAM* s, BITMAP_UPDATE* bitmap_upda
void update_read_palette(rdpUpdate* update, STREAM* s, PALETTE_UPDATE* palette_update);
void update_recv(rdpUpdate* update, STREAM* s);
void update_register_server_callbacks(rdpUpdate* update);
#endif /* __UPDATE_H */