mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-26 23:13:00 +02:00
cc_draw: add simple debug facility
not perfect, since the borders can be overdrawn afterwards
but still pretty useful
Origin commit data
------------------
Branch: ni/coolstream
Commit: 73c7885e72
Author: Stefan Seyfried <seife@tuxbox-git.slipkontur.de>
Date: 2017-12-26 (Tue, 26 Dec 2017)
------------------
This commit was generated by Migit
This commit is contained in:
committed by
vanhofen
parent
db32ea5437
commit
286445cb07
@@ -31,6 +31,9 @@
|
||||
#include <system/debug.h>
|
||||
extern CPictureViewer * g_PicViewer;
|
||||
|
||||
/* export CCDRAW_DEBUG to paint red lines around all elements */
|
||||
static bool CCDraw_debug = !!(getenv("CCDRAW_DEBUG"));
|
||||
|
||||
CCDraw::CCDraw() : COSDFader(g_settings.theme.menu_Content_alpha)
|
||||
{
|
||||
frameBuffer = CFrameBuffer::getInstance();
|
||||
@@ -551,6 +554,8 @@ void CCDraw::paintFbItems(bool do_save_bg)
|
||||
if (fbtype == CC_FBDATA_TYPE_BACKGROUND){
|
||||
frameBuffer->paintBackgroundBoxRel(fbdata.x, fbdata.y, fbdata.dx, fbdata.dy);
|
||||
v_fbdata[i].is_painted = true;
|
||||
if (CCDraw_debug)
|
||||
frameBuffer->paintBoxFrame(fbdata.x, fbdata.y, fbdata.dx, fbdata.dy, 1, COL_RED);
|
||||
continue;
|
||||
}
|
||||
}
|
||||
@@ -684,6 +689,8 @@ void CCDraw::paintFbItems(bool do_save_bg)
|
||||
}
|
||||
}
|
||||
}
|
||||
if (CCDraw_debug)
|
||||
frameBuffer->paintBoxFrame(fbdata.x, fbdata.y, fbdata.dx, fbdata.dy, 1, COL_RED);
|
||||
}
|
||||
|
||||
//set is_painted attribut. if any layer was painted set it to true;
|
||||
|
Reference in New Issue
Block a user