From 15d9ce7e03c6c8b6ee7b4e09c615c69a1680673e Mon Sep 17 00:00:00 2001 From: "[CST] Focus" Date: Wed, 27 Nov 2013 15:55:15 +0400 Subject: [PATCH] cc_item_progressbar.cpp: for advanced paint, replace paintShapes with paintBoxRel: too much overhead to replace single paintBoxRel call Origin commit data ------------------ Branch: ni/coolstream Commit: https://github.com/neutrino-images/ni-neutrino/commit/9897b9045caac927a3a0390bcdc8ea1f0089f9e2 Author: [CST] Focus Date: 2013-11-27 (Wed, 27 Nov 2013) ------------------ This commit was generated by Migit --- src/gui/components/cc_item_progressbar.cpp | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/src/gui/components/cc_item_progressbar.cpp b/src/gui/components/cc_item_progressbar.cpp index 06debd8ae..03f29ca12 100644 --- a/src/gui/components/cc_item_progressbar.cpp +++ b/src/gui/components/cc_item_progressbar.cpp @@ -76,7 +76,6 @@ CProgressBar::CProgressBar( const int x_pos, const int y_pos, const int w, const void CProgressBar::initVarProgressbar() { //CComponentsItem - initVarItem(); cc_item_type = CC_ITEMTYPE_PROGRESSBAR; //CProgressBar @@ -214,7 +213,8 @@ void CProgressBar::paintAdvanced() for (j = 0; j < hcnt; j++) { int sh_x = pb_x + i * itemw; int sh_y = py + j * itemh; - paintShapes(sh_x, sh_y, pointx, pointy, color); + //paintShapes(sh_x, sh_y, pointx, pointy, color); + frameBuffer->paintBoxRel(sh_x, sh_y, pointx, pointy, color); } } step = yw - rd - 1; @@ -230,7 +230,8 @@ void CProgressBar::paintAdvanced() for (j = 0; j < hcnt; j++) { int sh_x = pb_x + i * itemw; int sh_y = py + j * itemh; - paintShapes(sh_x, sh_y, pointx, pointy, color); + //paintShapes(sh_x, sh_y, pointx, pointy, color); + frameBuffer->paintBoxRel(sh_x, sh_y, pointx, pointy, color); } } off = diff; @@ -248,7 +249,8 @@ void CProgressBar::paintAdvanced() for (j = 0; j < hcnt; j++) { int sh_x = pb_x + i * itemw; int sh_y = py + j * itemh; - paintShapes(sh_x, sh_y, pointx, pointy, color); + //paintShapes(sh_x, sh_y, pointx, pointy, color); + frameBuffer->paintBoxRel(sh_x, sh_y, pointx, pointy, color); } } } @@ -256,7 +258,8 @@ void CProgressBar::paintAdvanced() for (j = 0; j < hcnt; j++) { int sh_x = pb_x + i * itemw; int sh_y = py + j * itemh; - paintShapes(sh_x, sh_y, pointx, pointy, pb_passive_col); //fill passive + //paintShapes(sh_x, sh_y, pointx, pointy, pb_passive_col); //fill passive + frameBuffer->paintBoxRel(sh_x, sh_y, pointx, pointy, pb_passive_col); } } }