From 8929255e9e12e1de9f4e82c267a6bf94947597ba Mon Sep 17 00:00:00 2001 From: Thilo Graf Date: Thu, 30 Oct 2014 12:02:04 +0100 Subject: [PATCH] CComponentsPicture: don't paint image, if is not available --- src/gui/components/cc_item_picture.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/gui/components/cc_item_picture.cpp b/src/gui/components/cc_item_picture.cpp index 37c0daea2..4b755a443 100644 --- a/src/gui/components/cc_item_picture.cpp +++ b/src/gui/components/cc_item_picture.cpp @@ -109,7 +109,7 @@ void CComponentsPicture::setPicture(const char* picture_name) void CComponentsPicture::initCCItem() { if (pic_name.empty()){ - dprintf(DEBUG_NORMAL, "[CComponentsPicture] %s: no image file assigned...\n", __func__); + dprintf(DEBUG_INFO, "[CComponentsPicture] %s - %d : no image file assigned...\n", __func__, __LINE__); return; } @@ -193,6 +193,8 @@ void CComponentsPicture::paintPicture() void CComponentsPicture::paint(bool do_save_bg) { + if (pic_name.empty()) + return; paintInit(do_save_bg); paintPicture(); }