From: xwt Date: Fri, 30 Jan 2004 07:40:34 +0000 (+0000) Subject: 2003/10/29 03:48:15 X-Git-Tag: RC3~397 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=3a8f26849dddf669a1a4210d7f61407a834150bc;p=org.ibex.core.git 2003/10/29 03:48:15 darcs-hash:20040130074034-3ac31-08f06f47f3090ca58aff7e4548df20eb5499c2f4.gz --- diff --git a/src/org/xwt/plat/X11.java b/src/org/xwt/plat/X11.java index b8652cb..72751bd 100644 --- a/src/org/xwt/plat/X11.java +++ b/src/org/xwt/plat/X11.java @@ -171,16 +171,16 @@ public class X11 extends POSIX { public void drawPictureAlphaOnly(Picture source, int dx, int dy, int cx1, int cy1, int cx2, int cy2, int rgb) { cx1 = Math.max(dx, cx1); cy1 = Math.max(dy, cy1); - cx2 = Math.min(dx + width, cx2); - cy2 = Math.min(dy + height, cy2); + cx2 = Math.min(dx + source.getWidth(), cx2); + cy2 = Math.min(dy + source.getHeight(), cy2); if (cx1 >= cx2 || cy1 >= cy2) return; slowDrawPicture(source, dx, dy, cx1, cy1, cx2, cy2, rgb, true); } public void drawPicture(Picture source, int dx, int dy, int cx1, int cy1, int cx2, int cy2) { cx1 = Math.max(dx, cx1); cy1 = Math.max(dy, cy1); - cx2 = Math.min(dx + width, cx2); - cy2 = Math.min(dy + height, cy2); + cx2 = Math.min(dx + source.getWidth(), cx2); + cy2 = Math.min(dy + source.getHeight(), cy2); if (cx1 >= cx2 || cy1 >= cy2) return; if (((X11Picture)source).doublebuf != null) fastDrawPicture(source, dx, dy, cx1, cy1, cx2, cy2);