From b701c345fb49090917c3f98af0c6fb1e67bbd84a Mon Sep 17 00:00:00 2001 From: Thilo Graf Date: Thu, 21 Jan 2016 10:24:58 +0100 Subject: [PATCH] CCDraw: remove clean up after restored screen It seems not always useful to clean up everything after hide(). For more control in some cases an separate clean up with clearSavedScreen() should be more flexible. --- src/gui/components/cc_draw.cpp | 7 ------- 1 file changed, 7 deletions(-) diff --git a/src/gui/components/cc_draw.cpp b/src/gui/components/cc_draw.cpp index a43e0e461..0b2a4456e 100644 --- a/src/gui/components/cc_draw.cpp +++ b/src/gui/components/cc_draw.cpp @@ -620,8 +620,6 @@ void CCDraw::paintFbItems(bool do_save_bg) void CCDraw::hide() { - bool restored = false; - //restore saved screen background of item if available for(size_t i =0; i< v_fbdata.size() ;i++) { if (v_fbdata[i].fbdata_type == CC_FBDATA_TYPE_BGSCREEN){ @@ -629,14 +627,9 @@ void CCDraw::hide() //restore screen from backround layer frameBuffer->waitForIdle("CCDraw::hide()"); frameBuffer->RestoreScreen(v_fbdata[i].x, v_fbdata[i].y, v_fbdata[i].dx, v_fbdata[i].dy, v_fbdata[i].pixbuf); - restored = true; } } } - //cleanup background layer, but only if restore was required - if (restored) - clearSavedScreen(); - is_painted = false; firstPaint = true; }