summaryrefslogtreecommitdiffstats
path: root/xorg/X11R7.6/rdp/rdpPolyPoint.c
diff options
context:
space:
mode:
authorLaxmikant Rashinkar <LK.Rashinkar@gmail.com>2012-09-22 18:12:40 -0700
committerLaxmikant Rashinkar <LK.Rashinkar@gmail.com>2012-09-22 18:12:40 -0700
commit42a56cd33ed83a399784958ae4e5490ed21b0b7c (patch)
tree7ed89b3d716ae6765f0a7831c34d5ed6e7ff2177 /xorg/X11R7.6/rdp/rdpPolyPoint.c
parent70d535211bd5708b4547a5e2f8bfaa21b1d66746 (diff)
downloadxrdp-proprietary-42a56cd33ed83a399784958ae4e5490ed21b0b7c.tar.gz
xrdp-proprietary-42a56cd33ed83a399784958ae4e5490ed21b0b7c.zip
o Previous merge had too many issues. Hence all files in .../xorg/X11R7.6/rdp were copied
from master branch and then astyle was run on the files
Diffstat (limited to 'xorg/X11R7.6/rdp/rdpPolyPoint.c')
-rw-r--r--xorg/X11R7.6/rdp/rdpPolyPoint.c52
1 files changed, 39 insertions, 13 deletions
diff --git a/xorg/X11R7.6/rdp/rdpPolyPoint.c b/xorg/X11R7.6/rdp/rdpPolyPoint.c
index 7ab89106..7c65b602 100644
--- a/xorg/X11R7.6/rdp/rdpPolyPoint.c
+++ b/xorg/X11R7.6/rdp/rdpPolyPoint.c
@@ -100,25 +100,40 @@ rdpPolyPoint(DrawablePtr pDrawable, GCPtr pGC, int mode,
for (i = 0; i < npt; i++)
{
- pDstWnd = (WindowPtr)pDrawable;
+ pts[i].x = pDrawable->x + in_pts[i].x;
+ pts[i].y = pDrawable->y + in_pts[i].y;
- if (pDstWnd->viewable)
+ if (i == 0)
{
- post_process = 1;
+ total_box.x1 = pts[0].x;
+ total_box.y1 = pts[0].y;
+ total_box.x2 = pts[0].x;
+ total_box.y2 = pts[0].y;
+ }
+ else
+ {
+ if (pts[i].x < total_box.x1)
+ {
+ total_box.x1 = pts[i].x;
+ }
- if (g_do_dirty_ons)
+ if (pts[i].y < total_box.y1)
{
- LLOGLN(0, ("rdpPolyPoint: gettig dirty"));
- g_screenPriv.is_dirty = 1;
- pDirtyPriv = &g_screenPriv;
- dirty_type = RDI_IMGLL;
+ total_box.y1 = pts[i].y;
}
- else
+
+ if (pts[i].x > total_box.x2)
{
- rdpup_get_screen_image_rect(&id);
- got_id = 1;
+ total_box.x2 = pts[i].x;
+ }
+
+ if (pts[i].y > total_box.y2)
+ {
+ total_box.y2 = pts[i].y;
}
}
+
+ /* todo, use this total_box */
}
/* do original call */
@@ -164,8 +179,19 @@ rdpPolyPoint(DrawablePtr pDrawable, GCPtr pGC, int mode,
if (pDstWnd->viewable)
{
post_process = 1;
- rdpup_get_screen_image_rect(&id);
- got_id = 1;
+
+ if (g_do_dirty_ons)
+ {
+ LLOGLN(0, ("rdpPolyPoint: gettig dirty"));
+ g_screenPriv.is_dirty = 1;
+ pDirtyPriv = &g_screenPriv;
+ dirty_type = RDI_IMGLL;
+ }
+ else
+ {
+ rdpup_get_screen_image_rect(&id);
+ got_id = 1;
+ }
}
}
}