mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-29 08:21:07 +02:00
patch for width logos epilog ;)
git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-experimental@582 e54a6e83-5905-42d5-8d5c-058d10e6a962
Origin commit data
------------------
Branch: ni/coolstream
Commit: a1603ae7c5
Author: Jacek Jendrzej <overx300@gmail.com>
Date: 2010-05-12 (Wed, 12 May 2010)
------------------
This commit was generated by Migit
This commit is contained in:
@@ -81,8 +81,6 @@ extern CBouquetList * RADIOfavList;
|
||||
extern CBouquetList * RADIOallList;
|
||||
extern tallchans allchans;
|
||||
|
||||
#define PIC_W 52
|
||||
#define PIC_H 39
|
||||
|
||||
extern t_channel_id rec_channel_id;
|
||||
extern bool autoshift;
|
||||
@@ -458,7 +456,7 @@ int CChannelList::show()
|
||||
neutrino_msg_data_t data;
|
||||
bool actzap = 0;
|
||||
int res = -1;
|
||||
|
||||
const int pic_h = 39;
|
||||
if (chanlist.empty()) {
|
||||
return res;
|
||||
}
|
||||
@@ -479,7 +477,7 @@ int CChannelList::show()
|
||||
|
||||
theight = g_Font[SNeutrinoSettings::FONT_TYPE_MENU_TITLE]->getHeight();
|
||||
|
||||
theight = std::max(theight, PIC_H);
|
||||
theight = std::max(theight, pic_h);
|
||||
|
||||
frameBuffer->getIconSize(NEUTRINO_ICON_BUTTON_HELP, &icol_w, &icol_h);
|
||||
theight = std::max(theight, icol_h);
|
||||
@@ -1542,9 +1540,12 @@ void CChannelList::showChannelLogo()
|
||||
|
||||
std::string lname;
|
||||
if(g_PicViewer->GetLogoName(chanlist[selected]->channel_id, chanlist[selected]->name, lname, &logo_w, &logo_h)){
|
||||
if(logo_h > PIC_H)
|
||||
logo_h = PIC_H;
|
||||
|
||||
if(logo_h > theight){
|
||||
if((theight/(logo_h-theight))>1){
|
||||
logo_w -= (logo_w/(theight/(logo_h-theight)));
|
||||
}
|
||||
logo_h = theight;
|
||||
}
|
||||
g_PicViewer->DisplayImage(lname, x + width - logo_off - logo_w, y+(theight-logo_h)/2, logo_w, logo_h);
|
||||
}
|
||||
}
|
||||
|
@@ -56,8 +56,6 @@
|
||||
#include <zapit/bouquets.h>
|
||||
|
||||
extern CPictureViewer * g_PicViewer;
|
||||
#define PIC_W 52
|
||||
#define PIC_H 39
|
||||
|
||||
#define ICON_LARGE_WIDTH 26
|
||||
|
||||
@@ -487,12 +485,14 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
|
||||
text2 = epgData.title.substr(text1.length()+ 1, uint(-1) );
|
||||
}
|
||||
|
||||
const int pic_h = 39;
|
||||
|
||||
if (text2 != "")
|
||||
toph = 2 * topboxheight;
|
||||
else
|
||||
toph = topboxheight;
|
||||
if (toph < PIC_H)
|
||||
toph = PIC_H;
|
||||
|
||||
toph = std::max(toph, pic_h);
|
||||
|
||||
sb = oy - toph - botboxheight;
|
||||
|
||||
@@ -581,8 +581,12 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
|
||||
int logo_w = 0;
|
||||
int logo_h = 0;
|
||||
if(g_PicViewer->GetLogoName(channel_id, cit->second.getName(), lname, &logo_w, &logo_h)) {
|
||||
if(logo_h > PIC_H)
|
||||
logo_h = PIC_H;
|
||||
if(logo_h > toph){
|
||||
if((toph/(logo_h-toph))>1){
|
||||
logo_w -= (logo_w/(toph/(logo_h-toph)));
|
||||
}
|
||||
logo_h = toph;
|
||||
}
|
||||
|
||||
g_PicViewer->DisplayImage(lname, sx+10, sy + (toph-logo_h)/2/*5*/, logo_w, logo_h);
|
||||
pic_offx = logo_w + 10;
|
||||
|
@@ -60,8 +60,6 @@ extern t_channel_id live_channel_id;
|
||||
|
||||
#include <algorithm>
|
||||
extern CPictureViewer * g_PicViewer;
|
||||
#define PIC_W 52
|
||||
#define PIC_H 39
|
||||
|
||||
void sectionsd_getEventsServiceKey(t_channel_id serviceUniqueKey, CChannelEventList &eList, char search = 0, std::string search_text = "");
|
||||
bool sectionsd_getActualEPGServiceKey(const t_channel_id uniqueServiceKey, CEPGData * epgdata);
|
||||
@@ -228,24 +226,24 @@ int EventList::exec(const t_channel_id channel_id, const std::string& channelnam
|
||||
iheight = fh;
|
||||
|
||||
int icol_w, icol_h;
|
||||
frameBuffer->getIconSize(NEUTRINO_ICON_BUTTON_RED, &icol_w, &icol_h);
|
||||
if(iheight < icol_h)
|
||||
iheight = icol_h;
|
||||
const int pic_h = 39;
|
||||
|
||||
frameBuffer->getIconSize(NEUTRINO_ICON_BUTTON_RED, &icol_w, &icol_h);
|
||||
|
||||
iheight = std::max(iheight, icol_h);
|
||||
theight = g_Font[SNeutrinoSettings::FONT_TYPE_EVENTLIST_TITLE]->getHeight();
|
||||
|
||||
if(theight < PIC_H) theight = PIC_H;
|
||||
theight = std::max(theight, pic_h);
|
||||
|
||||
int iw, ih;
|
||||
frameBuffer->getIconSize(NEUTRINO_ICON_BUTTON_HELP, &iw, &ih);
|
||||
if(theight < ih)
|
||||
theight = ih;
|
||||
theight = std::max(theight, ih);
|
||||
|
||||
fheight1 = g_Font[SNeutrinoSettings::FONT_TYPE_EVENTLIST_ITEMLARGE]->getHeight();
|
||||
{
|
||||
int h1 = g_Font[SNeutrinoSettings::FONT_TYPE_EVENTLIST_ITEMSMALL]->getHeight();
|
||||
int h2 = g_Font[SNeutrinoSettings::FONT_TYPE_EVENTLIST_DATETIME]->getHeight();
|
||||
fheight2 = (h1 > h2) ? h1 : h2;
|
||||
fheight2 = std::max( h1, h2 );
|
||||
}
|
||||
fheight = fheight1 + fheight2 + 2;
|
||||
fwidth1 = g_Font[SNeutrinoSettings::FONT_TYPE_EVENTLIST_DATETIME]->getRenderWidth("DDD, 00:00, ");
|
||||
@@ -695,8 +693,12 @@ void EventList::paintHead(t_channel_id channel_id, std::string channelname)
|
||||
int logo_w = 0;
|
||||
int logo_h = 0;
|
||||
if(g_PicViewer->GetLogoName(channel_id, channelname, lname, &logo_w, &logo_h)){
|
||||
if(logo_h > PIC_H)
|
||||
logo_h = PIC_H;
|
||||
if(logo_h > theight){
|
||||
if((theight/(logo_h-theight))>1){
|
||||
logo_w -= (logo_w/(theight/(logo_h-theight)));
|
||||
}
|
||||
logo_h = theight;
|
||||
}
|
||||
logo_ok = g_PicViewer->DisplayImage(lname, x+10, y+(theight-logo_h)/2, logo_w, logo_h);
|
||||
}
|
||||
//logo_ok = g_PicViewer->DisplayLogo(channel_id, x+10, y+(theight-PIC_H)/2, PIC_W, PIC_H);
|
||||
|
@@ -69,8 +69,7 @@
|
||||
#include <gui/customcolor.h>
|
||||
|
||||
extern CPictureViewer * g_PicViewer;
|
||||
#define PIC_W 52
|
||||
#define PIC_H 39
|
||||
|
||||
static CProgressBar *timescale;
|
||||
|
||||
#define my_scandir scandir64
|
||||
@@ -592,7 +591,8 @@ void CMovieBrowser::initFrames(void)
|
||||
m_cBoxFrameTitleRel.iWidth = m_cBoxFrame.iWidth;
|
||||
m_cBoxFrameTitleRel.iHeight = m_pcFontTitle->getHeight();
|
||||
|
||||
if(m_cBoxFrameTitleRel.iHeight < PIC_H) m_cBoxFrameTitleRel.iHeight = PIC_H;
|
||||
const int pic_h = 39;
|
||||
m_cBoxFrameTitleRel.iHeight = std::max(m_cBoxFrameTitleRel.iHeight, pic_h);
|
||||
|
||||
m_cBoxFrameBrowserList.iX = m_cBoxFrame.iX;
|
||||
m_cBoxFrameBrowserList.iY = m_cBoxFrame.iY + m_cBoxFrameTitleRel.iHeight;
|
||||
@@ -1195,8 +1195,12 @@ void CMovieBrowser::refreshMovieInfo(void)
|
||||
//g_PicViewer->DisplayLogo(m_movieSelectionHandler->epgEpgId >>16, lx, ly, PIC_W, PIC_H);
|
||||
std::string lname;
|
||||
if(g_PicViewer->GetLogoName(m_movieSelectionHandler->epgEpgId >>16, m_movieSelectionHandler->epgChannel, lname, &logo_w, &logo_h)){
|
||||
if(logo_h > PIC_H)
|
||||
logo_h = PIC_H;
|
||||
if(logo_h > m_cBoxFrameTitleRel.iHeight){
|
||||
if((m_cBoxFrameTitleRel.iHeight/(logo_h-m_cBoxFrameTitleRel.iHeight))>1){
|
||||
logo_w -= (logo_w/(m_cBoxFrameTitleRel.iHeight/(logo_h-m_cBoxFrameTitleRel.iHeight)));
|
||||
}
|
||||
logo_h = m_cBoxFrameTitleRel.iHeight;
|
||||
}
|
||||
lx = m_cBoxFrame.iX+m_cBoxFrameTitleRel.iX+m_cBoxFrameTitleRel.iWidth-logo_w-10;
|
||||
ly = m_cBoxFrameTitleRel.iY+m_cBoxFrame.iY+ (m_cBoxFrameTitleRel.iHeight-logo_h)/2;
|
||||
g_PicViewer->DisplayImage(lname, lx, ly, logo_w, logo_h);
|
||||
|
Reference in New Issue
Block a user