mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-30 08:51:04 +02:00
Merge branch 'master' into pu/fb-setmode
Origin commit data
------------------
Commit: b46f566e2a
Author: Michael Liebmann <tuxcode.bbg@gmail.com>
Date: 2017-04-17 (Mon, 17 Apr 2017)
This commit is contained in:
@@ -68,7 +68,7 @@ CComponentsForm::CComponentsForm( const int x_pos, const int y_pos, const int w,
|
|||||||
page_count = 1;
|
page_count = 1;
|
||||||
cur_page = 0;
|
cur_page = 0;
|
||||||
sb = NULL;
|
sb = NULL;
|
||||||
w_sb = 15;
|
w_sb = SCROLLBAR_WIDTH;
|
||||||
|
|
||||||
page_scroll_mode = PG_SCROLL_M_UP_DOWN_KEY;
|
page_scroll_mode = PG_SCROLL_M_UP_DOWN_KEY;
|
||||||
|
|
||||||
@@ -375,6 +375,7 @@ void CComponentsForm::paintCCItems()
|
|||||||
if (cc_parent){
|
if (cc_parent){
|
||||||
this_x = auto_x = cc_xr;
|
this_x = auto_x = cc_xr;
|
||||||
this_y = auto_y = cc_yr;
|
this_y = auto_y = cc_yr;
|
||||||
|
w_parent_frame = cc_parent->getFrameThickness();
|
||||||
}
|
}
|
||||||
|
|
||||||
//init and handle scrollbar
|
//init and handle scrollbar
|
||||||
@@ -482,7 +483,7 @@ void CComponentsForm::paintCCItems()
|
|||||||
//Is it too wide or too high, it will be shortened and displayed in the log.
|
//Is it too wide or too high, it will be shortened and displayed in the log.
|
||||||
//This should be avoid!
|
//This should be avoid!
|
||||||
//checkwidth and adapt if required
|
//checkwidth and adapt if required
|
||||||
int right_frm = (cc_parent ? cc_xr : x) + this_w - 2*fr_thickness;
|
int right_frm = (cc_parent ? cc_xr : x) + this_w/* - 2*fr_thickness*/;
|
||||||
int right_item = cc_item->getRealXPos() + w_item;
|
int right_item = cc_item->getRealXPos() + w_item;
|
||||||
int w_diff = right_item - right_frm;
|
int w_diff = right_item - right_frm;
|
||||||
int new_w = w_item - w_diff;
|
int new_w = w_item - w_diff;
|
||||||
|
@@ -59,8 +59,8 @@ CComponentsFrmClock::CComponentsFrmClock( const int& x_pos,
|
|||||||
{
|
{
|
||||||
cc_item_type = CC_ITEMTYPE_FRM_CLOCK;
|
cc_item_type = CC_ITEMTYPE_FRM_CLOCK;
|
||||||
|
|
||||||
x = x_pos;
|
x = cc_xr = x_old = x_pos;
|
||||||
y = y_pos;
|
y = cc_yr = y_old = y_pos;
|
||||||
|
|
||||||
shadow = shadow_mode;
|
shadow = shadow_mode;
|
||||||
shadow_w = OFFSET_SHADOW;
|
shadow_w = OFFSET_SHADOW;
|
||||||
@@ -84,8 +84,8 @@ CComponentsFrmClock::CComponentsFrmClock( const int& x_pos,
|
|||||||
initClockFont(0, g_Font[SNeutrinoSettings::FONT_TYPE_MENU_TITLE]->getHeight());
|
initClockFont(0, g_Font[SNeutrinoSettings::FONT_TYPE_MENU_TITLE]->getHeight());
|
||||||
|
|
||||||
//init general clock dimensions
|
//init general clock dimensions
|
||||||
height = cl_font->getHeight();
|
height = height_old= cl_font->getHeight();
|
||||||
width = cl_font->getRenderWidth(cl_format_str);
|
width = width_old = cl_font->getRenderWidth(cl_format_str);
|
||||||
|
|
||||||
//set default text background behavior
|
//set default text background behavior
|
||||||
cc_txt_save_screen = false;
|
cc_txt_save_screen = false;
|
||||||
@@ -429,9 +429,9 @@ void CComponentsFrmClock::setHeight(const int& h)
|
|||||||
int f_height = cl_font->getHeight();
|
int f_height = cl_font->getHeight();
|
||||||
if (h != f_height){
|
if (h != f_height){
|
||||||
dprintf(DEBUG_DEBUG, "\033[33m[CComponentsFrmClock]\t[%s - %d], font height is different than current height [%d], using [%d] ...\033[0m\n", __func__, __LINE__, h, f_height);
|
dprintf(DEBUG_DEBUG, "\033[33m[CComponentsFrmClock]\t[%s - %d], font height is different than current height [%d], using [%d] ...\033[0m\n", __func__, __LINE__, h, f_height);
|
||||||
CCDraw::setHeight(f_height);
|
CComponentsItem::setHeight(f_height);
|
||||||
}else
|
}else
|
||||||
CCDraw::setHeight(h);
|
CComponentsItem::setHeight(h);
|
||||||
initCCLockItems();
|
initCCLockItems();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -443,9 +443,9 @@ void CComponentsFrmClock::setWidth(const int& w)
|
|||||||
int f_width = cl_font->getRenderWidth(cl_format_str);
|
int f_width = cl_font->getRenderWidth(cl_format_str);
|
||||||
if (w != f_width){
|
if (w != f_width){
|
||||||
dprintf(DEBUG_NORMAL, "\033[33m[CComponentsFrmClock]\t[%s - %d], font width is different than current width [%d], using [%d] ...\033[0m\n", __func__, __LINE__, w, f_width);
|
dprintf(DEBUG_NORMAL, "\033[33m[CComponentsFrmClock]\t[%s - %d], font width is different than current width [%d], using [%d] ...\033[0m\n", __func__, __LINE__, w, f_width);
|
||||||
CCDraw::setWidth(f_width);
|
CComponentsItem::setWidth(f_width);
|
||||||
}else
|
}else
|
||||||
CCDraw::setWidth(w);
|
CComponentsItem::setWidth(w);
|
||||||
initCCLockItems();
|
initCCLockItems();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -413,7 +413,6 @@ void CComponentsHeader::initClock()
|
|||||||
|
|
||||||
//set clock form properties
|
//set clock form properties
|
||||||
if (cch_cl_obj){
|
if (cch_cl_obj){
|
||||||
cch_cl_obj->setYPos(cch_items_y);
|
|
||||||
cch_cl_obj->setHeight(height);
|
cch_cl_obj->setHeight(height);
|
||||||
|
|
||||||
//disallow paint of clock, if disabled and exit method
|
//disallow paint of clock, if disabled and exit method
|
||||||
@@ -475,7 +474,7 @@ void CComponentsHeader::initCaption()
|
|||||||
int clock_w = cch_cl_enable ? cch_cl_obj->getWidth() : 0;
|
int clock_w = cch_cl_enable ? cch_cl_obj->getWidth() : 0;
|
||||||
|
|
||||||
//set x position of clock
|
//set x position of clock
|
||||||
cch_cl_obj->setXPos(width - buttons_w - clock_w - cch_offset);
|
cch_cl_obj->setXPos(width - buttons_w - clock_w);
|
||||||
|
|
||||||
//set required width of caption object
|
//set required width of caption object
|
||||||
cc_text_w -= (clock_w + cch_offset);
|
cc_text_w -= (clock_w + cch_offset);
|
||||||
|
@@ -34,7 +34,7 @@
|
|||||||
#include <zapit/include/zapit/frontend_c.h>
|
#include <zapit/include/zapit/frontend_c.h>
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
|
|
||||||
#define SB_MIN_HEIGHT 12
|
#define SB_MIN_HEIGHT OFFSET_INNER_MID
|
||||||
#define REF_PERCENT_TXT "100% "
|
#define REF_PERCENT_TXT "100% "
|
||||||
|
|
||||||
using namespace std;
|
using namespace std;
|
||||||
@@ -55,8 +55,8 @@ void CSignalBar::initVarSigBar(const int& xpos, const int& ypos, const int& w, c
|
|||||||
|
|
||||||
corner_rad = 0;
|
corner_rad = 0;
|
||||||
corner_type = 0;
|
corner_type = 0;
|
||||||
append_x_offset = 2;
|
append_x_offset = OFFSET_INNER_MIN;
|
||||||
append_y_offset = 2;
|
append_y_offset = OFFSET_INNER_MIN;
|
||||||
|
|
||||||
sb_scale_height = -1;
|
sb_scale_height = -1;
|
||||||
dy_font = CNeutrinoFonts::getInstance();
|
dy_font = CNeutrinoFonts::getInstance();
|
||||||
@@ -330,7 +330,7 @@ void CSignalBox::initSignalItems()
|
|||||||
sbar->setScaleHeight(scale_h);
|
sbar->setScaleHeight(scale_h);
|
||||||
sbar->enableTboxSaveScreen(cc_txt_save_screen);
|
sbar->enableTboxSaveScreen(cc_txt_save_screen);
|
||||||
|
|
||||||
snrbar->setDimensionsAll(vertical ? sbar_x : CC_APPEND, vertical ? CC_APPEND : 1, sbar_w, sbar_h);
|
snrbar->setDimensionsAll(vertical ? sbar_x : sbar->getXPos() + sbar->getWidth() + append_x_offset, vertical ? sbar->getYPos() + sbar->getHeight() + append_y_offset : 1, sbar_w, sbar_h);
|
||||||
snrbar->setFrontEnd(sbx_frontend);
|
snrbar->setFrontEnd(sbx_frontend);
|
||||||
snrbar->setTextColor(sbx_caption_color);
|
snrbar->setTextColor(sbx_caption_color);
|
||||||
snrbar->setActiveColor(sbx_active_color);
|
snrbar->setActiveColor(sbx_active_color);
|
||||||
|
@@ -205,7 +205,7 @@ void CComponentsWindow::initHeader()
|
|||||||
//set header properties //TODO: assigned properties with internal header objekt have no effect!
|
//set header properties //TODO: assigned properties with internal header objekt have no effect!
|
||||||
if (ccw_head){
|
if (ccw_head){
|
||||||
ccw_head->setWidth(width-2*fr_thickness);
|
ccw_head->setWidth(width-2*fr_thickness);
|
||||||
ccw_head->setPos(0, 0);
|
ccw_head->setPos(fr_thickness, fr_thickness);
|
||||||
ccw_head->setIcon(ccw_icon_name);
|
ccw_head->setIcon(ccw_icon_name);
|
||||||
ccw_head->setCaption(ccw_caption, ccw_align_mode, ccw_col_head_text);
|
ccw_head->setCaption(ccw_caption, ccw_align_mode, ccw_col_head_text);
|
||||||
ccw_head->setContextButton(ccw_buttons);
|
ccw_head->setContextButton(ccw_buttons);
|
||||||
@@ -223,8 +223,8 @@ void CComponentsWindow::initFooter()
|
|||||||
if (ccw_footer){
|
if (ccw_footer){
|
||||||
if (ccw_h_footer)
|
if (ccw_h_footer)
|
||||||
ccw_footer->setHeight(ccw_h_footer);
|
ccw_footer->setHeight(ccw_h_footer);
|
||||||
ccw_footer->setPos(0, cc_yr + height - ccw_footer->getHeight()- fr_thickness);
|
ccw_footer->setPos(cc_xr + fr_thickness, cc_yr + height - ccw_footer->getHeight()- fr_thickness);
|
||||||
ccw_footer->setWidth(width-2*fr_thickness);
|
ccw_footer->setWidth(width/*-2*fr_thickness*/);
|
||||||
ccw_footer->enableShadow(false/*shadow*/);
|
ccw_footer->enableShadow(false/*shadow*/);
|
||||||
ccw_footer->setCorner(corner_rad-fr_thickness, CORNER_BOTTOM);
|
ccw_footer->setCorner(corner_rad-fr_thickness, CORNER_BOTTOM);
|
||||||
ccw_footer->setButtonFont(ccw_button_font);
|
ccw_footer->setButtonFont(ccw_button_font);
|
||||||
|
Reference in New Issue
Block a user