diff options
author | kamel5 <vdr.kamel5 (at) gmx (dot) net> | 2021-01-09 14:18:08 +0100 |
---|---|---|
committer | kamel5 <vdr.kamel5 (at) gmx (dot) net> | 2021-01-09 14:18:33 +0100 |
commit | 180fe711f5193741155602dc146fb59ec95d8500 (patch) | |
tree | 3663d5fc4cfe28973097f9eac7dd563df8b79c57 | |
parent | 86fe497b629b79bc07ddc726341a42c9c9e02b00 (diff) | |
download | skin-nopacity-180fe711f5193741155602dc146fb59ec95d8500.tar.gz skin-nopacity-180fe711f5193741155602dc146fb59ec95d8500.tar.bz2 |
Fix for gcc11
-rw-r--r-- | displaymenu.c | 2 | ||||
-rw-r--r-- | displaymessage.c | 2 | ||||
-rw-r--r-- | displayreplay.c | 8 | ||||
-rw-r--r-- | displaytracks.c | 2 | ||||
-rw-r--r-- | displayvolume.c | 2 | ||||
-rw-r--r-- | menuitem.c | 16 | ||||
-rw-r--r-- | textwindow.c | 2 |
7 files changed, 17 insertions, 17 deletions
diff --git a/displaymenu.c b/displaymenu.c index 0302e8f..8a00bd9 100644 --- a/displaymenu.c +++ b/displaymenu.c @@ -728,7 +728,7 @@ void cNopacityDisplayMenu::Action(void) { while (Running()) { uint64_t Now = cTimeMs::Now(); cPixmap::Lock(); - double t = min(double(Now - Start) / FadeTime, 1.0); + double t = std::min(double(Now - Start) / FadeTime, 1.0); int Alpha = t * ALPHA_OPAQUE; menuView->SetPixmapAlpha(Alpha); for (cNopacityMenuItem *item = menuItems.First(); Running() && item; item = menuItems.Next(item)) { diff --git a/displaymessage.c b/displaymessage.c index f2c9c65..e435dde 100644 --- a/displaymessage.c +++ b/displaymessage.c @@ -91,7 +91,7 @@ void cNopacityDisplayMessage::Action(void) { while (Running()) { uint64_t Now = cTimeMs::Now(); cPixmap::Lock(); - double t = min(double(Now - Start) / FadeTime, 1.0); + double t = std::min(double(Now - Start) / FadeTime, 1.0); int Alpha = t * ALPHA_OPAQUE; pixmapBackground->SetAlpha(Alpha); pixmap->SetAlpha(Alpha); diff --git a/displayreplay.c b/displayreplay.c index 6e42cea..4f7f268 100644 --- a/displayreplay.c +++ b/displayreplay.c @@ -317,9 +317,9 @@ void cNopacityDisplayReplay::SetRecording(const cRecording *Recording) { pixmapInfo2->Fill(clrTransparent); pixmapInfo2->DrawText(cPoint(geoManager->replayHeaderHeight/2, - max((geoManager->replayInfo2Height - - fontManager->replayText->Height())/2 - 10, - 0)), + std::max((geoManager->replayInfo2Height + - fontManager->replayText->Height()) / 2 - 10, + 0)), *info2, Theme.Color(clrReplayDescription), clrTransparent, @@ -496,7 +496,7 @@ void cNopacityDisplayReplay::Action(void) { while (Running()) { uint64_t Now = cTimeMs::Now(); cPixmap::Lock(); - double t = min(double(Now - Start) / FadeTime, 1.0); + double t = std::min(double(Now - Start) / FadeTime, 1.0); int Alpha = t * ALPHA_OPAQUE; if (!modeOnly) { int alphaBack = (100 - config.GetValue("channelBackgroundTransparency"))*Alpha/100; diff --git a/displaytracks.c b/displaytracks.c index 7c2a1e1..f403e26 100644 --- a/displaytracks.c +++ b/displaytracks.c @@ -178,7 +178,7 @@ void cNopacityDisplayTracks::Action(void) { while (Running()) { uint64_t Now = cTimeMs::Now(); cPixmap::Lock(); - double t = min(double(Now - Start) / FadeTime, 1.0); + double t = std::min(double(Now - Start) / FadeTime, 1.0); int Alpha = t * ALPHA_OPAQUE; pixmapContainer->SetAlpha(Alpha); pixmapHeader->SetAlpha(Alpha); diff --git a/displayvolume.c b/displayvolume.c index 1661e02..7c1181a 100644 --- a/displayvolume.c +++ b/displayvolume.c @@ -142,7 +142,7 @@ void cNopacityDisplayVolume::Action(void) { while (Running()) { uint64_t Now = cTimeMs::Now(); cPixmap::Lock(); - double t = min(double(Now - Start) / FadeTime, 1.0); + double t = std::min(double(Now - Start) / FadeTime, 1.0); int Alpha = t * ALPHA_OPAQUE; pixmapBackground->SetAlpha(Alpha); pixmapProgressBar->SetAlpha(Alpha); @@ -377,7 +377,7 @@ int cNopacityMainMenuItem::CheckScrollable(bool hasIcon) { int textWidth = font->Width(*menuEntry); if ((numberWidth + textWidth) > (width - spaceLeft)) { scrollable = true; - totalTextWidth = max(numberWidth + textWidth, totalTextWidth); + totalTextWidth = std::max(numberWidth + textWidth, totalTextWidth); strEntryFull = strEntry.c_str(); strEntry = CutText(strEntry, width - spaceLeft - numberWidth, font); } @@ -491,7 +491,7 @@ int cNopacityScheduleMenuItem::CheckScrollable(bool hasIcon) { if (font->Width(strTitle.c_str()) > (width - spaceLeft)) { scrollable = true; scrollTitle = true; - totalTextWidth = max(font->Width(strTitle.c_str()), totalTextWidth); + totalTextWidth = std::max(font->Width(strTitle.c_str()), totalTextWidth); strTitleFull = strTitle.c_str(); strSubTitleFull = strSubTitle.c_str(); strTitle = CutText(strTitle, width - spaceLeft, font); @@ -503,7 +503,7 @@ int cNopacityScheduleMenuItem::CheckScrollable(bool hasIcon) { strSubTitleFull = strSubTitle.c_str(); } scrollSubTitle = true; - totalTextWidth = max(fontSmall->Width(strSubTitle.c_str()), totalTextWidth); + totalTextWidth = std::max(fontSmall->Width(strSubTitle.c_str()), totalTextWidth); strSubTitle = CutText(strSubTitle, width - spaceLeft, fontSmall); } return totalTextWidth; @@ -716,7 +716,7 @@ int cNopacityChannelMenuItem::CheckScrollable(bool hasIcon) { int totalTextWidth = width - spaceLeft; if (font->Width(strEntry.c_str()) > (width - spaceLeft)) { scrollable = true; - totalTextWidth = max(font->Width(strEntry.c_str()), totalTextWidth); + totalTextWidth = std::max(font->Width(strEntry.c_str()), totalTextWidth); strEntryFull = strEntry.c_str(); strEntry = CutText(strEntry, width - spaceLeft, font); } else @@ -724,7 +724,7 @@ int cNopacityChannelMenuItem::CheckScrollable(bool hasIcon) { if (fontSmall->Width(strEpgInfo.c_str()) > (width - spaceLeft)) { scrollable = true; - totalTextWidth = max(fontSmall->Width(strEpgInfo.c_str()), totalTextWidth); + totalTextWidth = std::max(fontSmall->Width(strEpgInfo.c_str()), totalTextWidth); strEpgInfoFull = strEpgInfo.c_str(); strEpgInfo = CutText(strEpgInfo, width - spaceLeft, fontSmall); } else @@ -974,7 +974,7 @@ int cNopacityTimerMenuItem::CheckScrollable(bool hasIcon) { int totalTextWidth = width - spaceLeft; if (font->Width(strEntry.c_str()) > (width - spaceLeft)) { scrollable = true; - totalTextWidth = max(font->Width(strEntry.c_str()), totalTextWidth); + totalTextWidth = std::max(font->Width(strEntry.c_str()), totalTextWidth); strEntryFull = strEntry.c_str(); strEntry = CutText(strEntry, width - spaceLeft, font); } @@ -1198,7 +1198,7 @@ int cNopacityRecordingMenuItem::CheckScrollableRecording(void) { strRecNameFull = strRecName.c_str(); if (font->Width(strRecName.c_str()) + iconWidth > (width - spaceLeft)) { scrollable = true; - totalTextWidth = max(font->Width(strRecName.c_str()) + iconWidth, totalTextWidth); + totalTextWidth = std::max(font->Width(strRecName.c_str()) + iconWidth, totalTextWidth); strRecName = CutText(strRecName, width - spaceLeft - iconWidth, font); } return totalTextWidth; @@ -1210,7 +1210,7 @@ int cNopacityRecordingMenuItem::CheckScrollableFolder(void) { strRecNameFull = strRecName.c_str(); if (font->Width(strRecName.c_str()) > (width - spaceLeft)) { scrollable = true; - totalTextWidth = max(font->Width(strRecName.c_str()), totalTextWidth); + totalTextWidth = std::max(font->Width(strRecName.c_str()), totalTextWidth); strRecName = CutText(strRecName, width - spaceLeft, font); } return totalTextWidth; diff --git a/textwindow.c b/textwindow.c index 16327ea..7e46714 100644 --- a/textwindow.c +++ b/textwindow.c @@ -446,7 +446,7 @@ void cNopacityTextWindow::Action(void) { while (Running()) { uint64_t Now = cTimeMs::Now(); cPixmap::Lock(); - double t = min(double(Now - Start) / FadeTime, 1.0); + double t = std::min(double(Now - Start) / FadeTime, 1.0); int Alpha = t * ALPHA_OPAQUE; pixmapBackground->SetAlpha(Alpha); pixmap->SetAlpha(Alpha); |