call painter funcs, not orders
This commit is contained in:
parent
992dbfa7b3
commit
79557c9cc6
@ -21,8 +21,10 @@
|
||||
#if !defined(FILE_H)
|
||||
#define FILE_H
|
||||
|
||||
int file_read_sections(int fd, struct list* names);
|
||||
int file_read_section(int fd, char* section, struct list* names,
|
||||
struct list* values);
|
||||
int
|
||||
file_read_sections(int fd, struct list* names);
|
||||
int
|
||||
file_read_section(int fd, char* section, struct list* names,
|
||||
struct list* values);
|
||||
|
||||
#endif
|
||||
|
@ -31,13 +31,21 @@ struct list
|
||||
int auto_free;
|
||||
};
|
||||
|
||||
struct list* list_create(void);
|
||||
void list_delete(struct list* self);
|
||||
void list_add_item(struct list* self, long item);
|
||||
long list_get_item(struct list* self, int index);
|
||||
void list_clear(struct list* self);
|
||||
int list_index_of(struct list* self, long item);
|
||||
void list_remove_item(struct list* self, int index);
|
||||
void list_insert_item(struct list* self, int index, long item);
|
||||
struct list*
|
||||
list_create(void);
|
||||
void
|
||||
list_delete(struct list* self);
|
||||
void
|
||||
list_add_item(struct list* self, long item);
|
||||
long
|
||||
list_get_item(struct list* self, int index);
|
||||
void
|
||||
list_clear(struct list* self);
|
||||
int
|
||||
list_index_of(struct list* self, long item);
|
||||
void
|
||||
list_remove_item(struct list* self, int index);
|
||||
void
|
||||
list_insert_item(struct list* self, int index, long item);
|
||||
|
||||
#endif
|
||||
|
@ -24,6 +24,8 @@
|
||||
#if !defined(PARSE_H)
|
||||
#define PARSE_H
|
||||
|
||||
#include "arch.h"
|
||||
|
||||
#if defined(L_ENDIAN)
|
||||
#elif defined(B_ENDIAN)
|
||||
#else
|
||||
|
@ -221,6 +221,12 @@ int APP_CC
|
||||
xrdp_painter_draw_text(struct xrdp_painter* self,
|
||||
struct xrdp_bitmap* bitmap,
|
||||
int x, int y, char* text);
|
||||
int APP_CC
|
||||
xrdp_painter_copy(struct xrdp_painter* self,
|
||||
struct xrdp_bitmap* src,
|
||||
struct xrdp_bitmap* dst,
|
||||
int x, int y, int cx, int cy,
|
||||
int srcx, int srcy, int opcode);
|
||||
|
||||
/* xrdp_font.c */
|
||||
struct xrdp_font* APP_CC
|
||||
|
@ -126,11 +126,12 @@ server_screen_blt(struct xrdp_mod* mod, int x, int y, int cx, int cy,
|
||||
int srcx, int srcy)
|
||||
{
|
||||
struct xrdp_wm* wm;
|
||||
struct xrdp_painter* p;
|
||||
|
||||
wm = (struct xrdp_wm*)mod->wm;
|
||||
libxrdp_orders_init(wm->session);
|
||||
libxrdp_orders_screen_blt(wm->session, x, y, cx, cy, srcx, srcy, 0xcc, 0);
|
||||
libxrdp_orders_send(wm->session);
|
||||
p = (struct xrdp_painter*)mod->painter;
|
||||
xrdp_painter_copy(p, wm->screen, wm->screen, x, y, cx, cy,
|
||||
srcx, srcy, 12);
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -141,11 +142,12 @@ server_paint_rect(struct xrdp_mod* mod, int x, int y, int cx, int cy,
|
||||
{
|
||||
struct xrdp_wm* wm;
|
||||
struct xrdp_bitmap* b;
|
||||
struct xrdp_painter* p;
|
||||
|
||||
wm = (struct xrdp_wm*)mod->wm;
|
||||
p = (struct xrdp_painter*)mod->painter;
|
||||
b = xrdp_bitmap_create_with_data(cx, cy, wm->screen->bpp, data, wm);
|
||||
xrdp_painter_draw_bitmap((struct xrdp_painter*)mod->painter,
|
||||
wm->screen, b, x, y, cx, cy);
|
||||
xrdp_painter_draw_bitmap(p, wm->screen, b, x, y, cx, cy);
|
||||
xrdp_bitmap_delete(b);
|
||||
return 0;
|
||||
}
|
||||
|
@ -614,3 +614,30 @@ xrdp_painter_draw_text(struct xrdp_painter* self,
|
||||
g_free(data);
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
int APP_CC
|
||||
xrdp_painter_copy(struct xrdp_painter* self,
|
||||
struct xrdp_bitmap* src,
|
||||
struct xrdp_bitmap* dst,
|
||||
int x, int y, int cx, int cy,
|
||||
int srcx, int srcy, int opcode)
|
||||
{
|
||||
if (self == 0 || src == 0 || dst == 0)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* todo data */
|
||||
|
||||
if (dst->type == WND_TYPE_BITMAP)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
if (src == dst && opcode == 12 && src->wm->screen == src)
|
||||
{
|
||||
libxrdp_orders_screen_blt(dst->wm->session, x, y, cx, cy,
|
||||
srcx, srcy, 12, 0);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user