diff options
| author | Itamar Reis Peixoto <itamar@ispbrasil.com.br> | 2010-11-19 17:18:15 -0200 |
|---|---|---|
| committer | Itamar Reis Peixoto <itamar@ispbrasil.com.br> | 2010-11-20 22:13:49 -0200 |
| commit | 759757435eb4d437e91c64fced55f58fd61e6c7a (patch) | |
| tree | 2f13166e27d85f0932ee7a4ff2f10c0bbd174f70 /xrdp/xrdp_bitmap.c | |
| parent | 83edc21992cce552e1b71146db308d94547fc2bb (diff) | |
| download | xrdp-proprietary-759757435eb4d437e91c64fced55f58fd61e6c7a.tar.gz xrdp-proprietary-759757435eb4d437e91c64fced55f58fd61e6c7a.zip | |
xrdp comestic patch from "Alessandro Briosi" <tsdogs@briosix.org>
Diffstat (limited to 'xrdp/xrdp_bitmap.c')
| -rw-r--r-- | xrdp/xrdp_bitmap.c | 27 |
1 files changed, 21 insertions, 6 deletions
diff --git a/xrdp/xrdp_bitmap.c b/xrdp/xrdp_bitmap.c index 4ed4a230..df2f9e51 100644 --- a/xrdp/xrdp_bitmap.c +++ b/xrdp/xrdp_bitmap.c @@ -1190,10 +1190,10 @@ xrdp_bitmap_invalidate(struct xrdp_bitmap* self, struct xrdp_rect* rect) xrdp_painter_fill_rect(painter, self, self->width - 1, 0, 1, self->height); /* black left line */ painter->fg_color = self->wm->black; - xrdp_painter_fill_rect(painter, self, 1, 1, 1, self->height - 2); + xrdp_painter_fill_rect(painter, self, 1, 1, 1, self->height - 3); /* black top line */ painter->fg_color = self->wm->black; - xrdp_painter_fill_rect(painter, self, 1, 1, self->width - 2, 1); + xrdp_painter_fill_rect(painter, self, 1, 1, self->width - 3, 1); /* draw text */ painter->fg_color = self->wm->black; if (self->password_char != 0) @@ -1267,10 +1267,10 @@ xrdp_bitmap_invalidate(struct xrdp_bitmap* self, struct xrdp_rect* rect) xrdp_painter_fill_rect(painter, self, self->width - 1, 0, 1, self->height); /* black left line */ painter->fg_color = self->wm->black; - xrdp_painter_fill_rect(painter, self, 1, 1, 1, self->height - 2); + xrdp_painter_fill_rect(painter, self, 1, 1, 1, self->height - 3); /* black top line */ painter->fg_color = self->wm->black; - xrdp_painter_fill_rect(painter, self, 1, 1, self->width - 2, 1); + xrdp_painter_fill_rect(painter, self, 1, 1, self->width - 3, 1); /* draw text */ if (self->parent->focused_control == self) { @@ -1287,13 +1287,28 @@ xrdp_bitmap_invalidate(struct xrdp_bitmap* self, struct xrdp_rect* rect) y = 2; w = (self->width - x) - 2; h = self->height - 4; + /* looks better with a background around */ + painter->fg_color = self->wm->grey; + xrdp_painter_fill_rect(painter, self, x, y, w, h); if (self->state == BUTTON_STATE_UP) /* 0 */ { - xrdp_bitmap_draw_button(self, painter, x, y, w, h, 0); + xrdp_bitmap_draw_button(self, painter, x+1, y+1, w-1, h-1, 0); } else { - xrdp_bitmap_draw_button(self, painter, x, y, w, h, 1); + xrdp_bitmap_draw_button(self, painter, x+1, y+1, w-1, h-1, 1); + } + /* draw the arrow */ + w = w / 2; + x = x + (w / 2) + 1; + h = (h / 2) + 2; + y = y + (h / 2) + 1; + painter->fg_color = self->wm->black; + for (i=w; i>0; i=i-2) + { + xrdp_painter_fill_rect(painter, self, x, y, i, 1); + y++; + x = x + 1; } } else if (self->type == WND_TYPE_SPECIAL) /* 8 special */ |
