mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-26 15:02:56 +02:00
- menue.cpp: CMenuWidget::paint() - consider icon width
git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-beta@1752 e54a6e83-5905-42d5-8d5c-058d10e6a962
This commit is contained in:
@@ -745,8 +745,17 @@ void CMenuWidget::paint()
|
||||
height = wanted_height;
|
||||
width = min_width;
|
||||
|
||||
int wi, hi;
|
||||
for (unsigned int i= 0; i< items.size(); i++) {
|
||||
int tmpw = items[i]->getWidth() + 10 + 10; /* 10 pixels to the left and right of the text */
|
||||
wi = 0;
|
||||
if (!items[i]->iconName_Info_right.empty()) {
|
||||
frameBuffer->getIconSize(items[i]->iconName_Info_right.c_str(), &wi, &hi);
|
||||
if ((wi > 0) && (hi > 0))
|
||||
wi += 10;
|
||||
else
|
||||
wi = 0;
|
||||
}
|
||||
int tmpw = items[i]->getWidth() + 10 + 10 + wi; /* 10 pixels to the left and right of the text */
|
||||
if (tmpw > width)
|
||||
width = tmpw;
|
||||
}
|
||||
|
Reference in New Issue
Block a user