From a8bb955813b33891155b01810a3a8d758b0a3fbc Mon Sep 17 00:00:00 2001 From: vanhofen Date: Wed, 20 Feb 2013 23:53:55 +0100 Subject: [PATCH] upnpbrowser.cpp: center horizontally Origin commit data ------------------ Branch: ni/coolstream Commit: https://github.com/neutrino-images/ni-neutrino/commit/5a4722ab84843fb093ba46cb778db05e2b1bd42e Author: vanhofen Date: 2013-02-20 (Wed, 20 Feb 2013) Origin message was: ------------------ - upnpbrowser.cpp: center horizontally ------------------ No further description and justification available within origin commit message! ------------------ This commit was generated by Migit --- src/gui/upnpbrowser.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/gui/upnpbrowser.cpp b/src/gui/upnpbrowser.cpp index f88f9a49c..be46fe341 100644 --- a/src/gui/upnpbrowser.cpp +++ b/src/gui/upnpbrowser.cpp @@ -127,7 +127,7 @@ int CUpnpBrowserGui::exec(CMenuTarget* parent, const std::string & /*actionKey*/ #endif m_LastMode=(CNeutrinoApp::getInstance()->getLastMode()); - m_width=(g_settings.screen_EndX - g_settings.screen_StartX) - ConnectLineBox_Width; + m_width=(g_settings.screen_EndX - g_settings.screen_StartX) - 2*ConnectLineBox_Width; m_height = (g_settings.screen_EndY - g_settings.screen_StartY); m_sheight = g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->getHeight(); @@ -140,7 +140,9 @@ int CUpnpBrowserGui::exec(CMenuTarget* parent, const std::string & /*actionKey*/ m_listmaxshow = (m_height - m_info_height - m_title_height - m_theight - 2*m_buttonHeight) / (m_fheight); m_height = m_theight + m_info_height + m_title_height + 2*m_buttonHeight + m_listmaxshow * m_fheight; // recalc height - m_x=getScreenStartX( m_width + ConnectLineBox_Width ) + ConnectLineBox_Width; + m_x=getScreenStartX( m_width ); + if (m_x < ConnectLineBox_Width) + m_x = ConnectLineBox_Width; m_y=getScreenStartY( m_height ); // Stop sectionsd