Fixed position of video window

This commit is contained in:
louis 2013-05-26 11:58:11 +02:00
parent 812fd1b7a5
commit 27e4d459f5
2 changed files with 4 additions and 2 deletions

View File

@ -17,6 +17,8 @@ class cOsdManager {
void deleteOsd() {delete osd;}; void deleteOsd() {delete osd;};
int Width() { return osd->Width(); }; int Width() { return osd->Width(); };
int Height() { return osd->Height(); }; int Height() { return osd->Height(); };
int Top() { return osd->Top(); };
int Left() { return osd->Left(); };
}; };
#endif //__TVGUIDE_OSDMANAGER_H #endif //__TVGUIDE_OSDMANAGER_H

View File

@ -41,8 +41,8 @@ void cStatusHeader::ScaleVideo(void) {
if (tvguideConfig.scaleVideo) { if (tvguideConfig.scaleVideo) {
int height = tvguideConfig.statusHeaderHeight; int height = tvguideConfig.statusHeaderHeight;
int width = height * 16 / 9; int width = height * 16 / 9;
int x = tvguideConfig.osdWidth - width; int x = osdManager.Left() + tvguideConfig.osdWidth - width;
int y = 0; int y = osdManager.Top();
cRect availableRect(x, y, width, height); cRect availableRect(x, y, width, height);
cRect vidWin = cDevice::PrimaryDevice()->CanScaleVideo(availableRect); cRect vidWin = cDevice::PrimaryDevice()->CanScaleVideo(availableRect);
cDevice::PrimaryDevice()->ScaleVideo(vidWin); cDevice::PrimaryDevice()->ScaleVideo(vidWin);