From 157e4b428aca17ca6df4ad4b7c500625015b9d9d Mon Sep 17 00:00:00 2001 From: John Scipione Date: Tue, 10 Jun 2014 00:29:47 -0400 Subject: [PATCH] Tracker: Replace max_c() with std::max() --- src/kits/tracker/ContainerWindow.cpp | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/src/kits/tracker/ContainerWindow.cpp b/src/kits/tracker/ContainerWindow.cpp index bcead8e260..859e649c98 100644 --- a/src/kits/tracker/ContainerWindow.cpp +++ b/src/kits/tracker/ContainerWindow.cpp @@ -62,6 +62,7 @@ All rights reserved. #include #include +#include #include #include "Attributes.h" @@ -1142,15 +1143,16 @@ BContainerWindow::FrameResized(float, float) // and we have resized over the bottom right corner of the extent BPoint scroll(B_ORIGIN); if (offsetX < 0 && PoseView()->Bounds().right > extent.right - && Bounds().Width() > fPreviousBounds.Width()) - scroll.x - = max_c(fPreviousBounds.Width() - Bounds().Width(), offsetX); + && Bounds().Width() > fPreviousBounds.Width()) { + scroll.x = std::max(fPreviousBounds.Width() - Bounds().Width(), + offsetX); + } if (offsetY < 0 && PoseView()->Bounds().bottom > extent.bottom - && Bounds().Height() > fPreviousBounds.Height()) - scroll.y - = max_c(fPreviousBounds.Height() - Bounds().Height(), - offsetY); + && Bounds().Height() > fPreviousBounds.Height()) { + scroll.y = std::max(fPreviousBounds.Height() - Bounds().Height(), + offsetY); + } if (scroll != B_ORIGIN) PoseView()->ScrollBy(scroll.x, scroll.y);