mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-09-02 18:31:12 +02:00
Merge branch 'master' of https://github.com/tuxbox-neutrino/gui-neutrino into ni/tuxbox
Origin commit data
------------------
Commit: 116e4325c8
Author: vanhofen <vanhofen@gmx.de>
Date: 2016-12-22 (Thu, 22 Dec 2016)
This commit is contained in:
@@ -92,10 +92,7 @@ void CComponentsText::initVarText( const int x_pos, const int y_pos, const int w
|
||||
width = width_old = w;
|
||||
height = height_old = h;
|
||||
|
||||
/* we need a minimal borderwith of 1px because the edge-smoothing
|
||||
(or fontrenderer?) otherwise will paint single pixels outside the
|
||||
defined area. e.g. 'j' is leaving such residues */
|
||||
ct_text_Hborder = 1;
|
||||
ct_text_Hborder = 0;
|
||||
ct_text_Vborder = 0;
|
||||
|
||||
shadow = shadow_mode;
|
||||
|
@@ -281,6 +281,7 @@ CTimerList::CTimerList()
|
||||
timerNew_message = "";
|
||||
timerNew_pluginName = "";
|
||||
httpConnectTimeout = 3;
|
||||
changed = false;
|
||||
|
||||
/* most probable default */
|
||||
saved_dispmode = (int)CVFD::MODE_TVRADIO;
|
||||
|
@@ -34,6 +34,7 @@
|
||||
#include <neutrino.h>
|
||||
#include <gui/infoclock.h>
|
||||
#include <driver/neutrinofonts.h>
|
||||
#include <system/debug.h>
|
||||
|
||||
using namespace std;
|
||||
|
||||
@@ -264,9 +265,23 @@ CVolumeHelper::CVolumeHelper()
|
||||
|
||||
frameBuffer = CFrameBuffer::getInstance();
|
||||
|
||||
CNeutrinoApp::getInstance()->OnAfterSetupFonts.connect(sigc::mem_fun(this, &CVolumeHelper::resetFont));
|
||||
|
||||
Init();
|
||||
}
|
||||
|
||||
void CVolumeHelper::resetFont()
|
||||
{
|
||||
if (vb_font){
|
||||
vb_font = NULL;
|
||||
dprintf(DEBUG_INFO, "\033[33m[CVolumeHelper][%s - %d] reset vb font \033[0m\n", __func__, __LINE__);
|
||||
}
|
||||
if (clock_font){
|
||||
clock_font = NULL;
|
||||
dprintf(DEBUG_INFO, "\033[33m[CVolumeHelper][%s - %d] reset clock font \033[0m\n", __func__, __LINE__);
|
||||
}
|
||||
}
|
||||
|
||||
void CVolumeHelper::Init(Font* font)
|
||||
{
|
||||
|
||||
@@ -289,10 +304,7 @@ void CVolumeHelper::initInfoClock(Font* font)
|
||||
else
|
||||
clock_font = font;
|
||||
}
|
||||
else {
|
||||
if (font != NULL)
|
||||
clock_font = font;
|
||||
}
|
||||
|
||||
digit_offset = (clock_font)->getDigitOffset();
|
||||
digit_h = (clock_font)->getDigitHeight();
|
||||
int t1 = (clock_font)->getMaxDigitWidth();
|
||||
|
@@ -108,6 +108,7 @@ class CVolumeHelper
|
||||
Font* clock_font;
|
||||
CFrameBuffer *frameBuffer;
|
||||
|
||||
void resetFont();
|
||||
void Init(Font* font=NULL);
|
||||
void initVolBarSize();
|
||||
void initMuteIcon();
|
||||
|
@@ -65,7 +65,7 @@ CHintBox::CHintBox( const neutrino_locale_t Caption,
|
||||
const char * const Picon,
|
||||
const int& header_buttons,
|
||||
const int& text_mode,
|
||||
const int& indent): CComponentsWindow( 1, 1, width,
|
||||
const int& indent): CComponentsWindow( 0, 0, width,
|
||||
HINTBOX_MIN_HEIGHT,
|
||||
Caption,
|
||||
string(Icon == NULL ? "" : Icon),
|
||||
@@ -82,7 +82,7 @@ CHintBox::CHintBox( const char * const Caption,
|
||||
const char * const Picon,
|
||||
const int& header_buttons,
|
||||
const int& text_mode,
|
||||
const int& indent):CComponentsWindow( 1, 1, width,
|
||||
const int& indent):CComponentsWindow( 0, 0, width,
|
||||
HINTBOX_MIN_HEIGHT,
|
||||
Caption,
|
||||
string(Icon == NULL ? "" : Icon),
|
||||
@@ -99,7 +99,7 @@ CHintBox::CHintBox( const neutrino_locale_t Caption,
|
||||
const char * const Picon,
|
||||
const int& header_buttons,
|
||||
const int& text_mode,
|
||||
const int& indent):CComponentsWindow( 1, 1, width,
|
||||
const int& indent):CComponentsWindow( 0, 0, width,
|
||||
HINTBOX_MIN_HEIGHT,
|
||||
Caption,
|
||||
string(Icon == NULL ? "" : Icon),
|
||||
@@ -116,7 +116,7 @@ CHintBox::CHintBox( const char * const Caption,
|
||||
const char * const Picon,
|
||||
const int& header_buttons,
|
||||
const int& text_mode,
|
||||
const int& indent):CComponentsWindow( 1, 1, width,
|
||||
const int& indent):CComponentsWindow( 0, 0, width,
|
||||
HINTBOX_MIN_HEIGHT,
|
||||
Caption,
|
||||
string(Icon == NULL ? "" : Icon),
|
||||
|
@@ -222,7 +222,7 @@ class CTextBox : public sigc::trackable
|
||||
int getLines(){return(m_nNrOfLines);}
|
||||
|
||||
/**
|
||||
* Returns maximal width of passed text
|
||||
* Returns width of largest line from passed text
|
||||
* @param[in] text
|
||||
* @li exepts type std::string
|
||||
* @param[in] font
|
||||
@@ -233,9 +233,10 @@ class CTextBox : public sigc::trackable
|
||||
static int getMaxLineWidth(const std::string& text, Font* font);
|
||||
|
||||
/**
|
||||
* Returns internal defined maximal line width of an existent CTextBox instance.
|
||||
* Returns internal defined largest line width of an existant CTextBox instance.
|
||||
* @return width of largest line as int
|
||||
* @see static version getMaxLineWidth()
|
||||
* setText(), parameter: max_width
|
||||
*/
|
||||
int getMaxLineWidth() {return(m_nMaxTextWidth);}
|
||||
|
||||
|
Reference in New Issue
Block a user