summaryrefslogtreecommitdiff
path: root/glcdskin/object.c
diff options
context:
space:
mode:
Diffstat (limited to 'glcdskin/object.c')
-rw-r--r--glcdskin/object.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/glcdskin/object.c b/glcdskin/object.c
index 7e99092..204b0d4 100644
--- a/glcdskin/object.c
+++ b/glcdskin/object.c
@@ -484,9 +484,9 @@ void cSkinObject::Render(GLCD::cBitmap * screen)
uint16_t xoff = 0;
uint16_t yoff = 0;
if (scalew || scaleh) {
- if (image->Width() < Size().w) {
+ if (image->Width() < (uint16_t)Size().w) {
xoff = (Size().w - image->Width() ) / 2;
- } else if (image->Height() < Size().h) {
+ } else if (image->Height() < (uint16_t)Size().h) {
yoff = (Size().h - image->Height() ) / 2;
}
}