summaryrefslogtreecommitdiffstats
path: root/gui/image.cpp
diff options
context:
space:
mode:
authorDees Troy <dees_troy@teamw.in>2013-10-17 18:43:44 +0200
committerGerrit Code Review <gerrit@198.50.184.117>2013-10-17 18:43:44 +0200
commite6ddddca765a0adc6139633f91a20368cde81de0 (patch)
tree9cf5d0de064a1d1395a28da698a260bb3b99a0c8 /gui/image.cpp
parentRemove trailing spaces on auto generated backup names (diff)
parentAdd conditions support to GUIImage (diff)
downloadandroid_bootable_recovery-e6ddddca765a0adc6139633f91a20368cde81de0.tar
android_bootable_recovery-e6ddddca765a0adc6139633f91a20368cde81de0.tar.gz
android_bootable_recovery-e6ddddca765a0adc6139633f91a20368cde81de0.tar.bz2
android_bootable_recovery-e6ddddca765a0adc6139633f91a20368cde81de0.tar.lz
android_bootable_recovery-e6ddddca765a0adc6139633f91a20368cde81de0.tar.xz
android_bootable_recovery-e6ddddca765a0adc6139633f91a20368cde81de0.tar.zst
android_bootable_recovery-e6ddddca765a0adc6139633f91a20368cde81de0.zip
Diffstat (limited to '')
-rw-r--r--gui/image.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/gui/image.cpp b/gui/image.cpp
index 45d863673..31d9418d3 100644
--- a/gui/image.cpp
+++ b/gui/image.cpp
@@ -25,7 +25,7 @@ extern "C" {
#include "rapidxml.hpp"
#include "objects.hpp"
-GUIImage::GUIImage(xml_node<>* node)
+GUIImage::GUIImage(xml_node<>* node) : Conditional(node)
{
xml_attribute<>* attr;
xml_node<>* child;
@@ -79,6 +79,9 @@ GUIImage::GUIImage(xml_node<>* node)
int GUIImage::Render(void)
{
+ if (!isConditionTrue())
+ return 0;
+
if (isHighlighted && mHighlightImage && mHighlightImage->GetResource()) {
gr_blit(mHighlightImage->GetResource(), 0, 0, mRenderW, mRenderH, mRenderX, mRenderY);
return 0;