mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-03-24 16:20:49 +01:00
Use std::min and std::max
This commit is contained in:
@@ -1,12 +1,11 @@
|
||||
#include "list_controller.h"
|
||||
#include "../app.h"
|
||||
#include <assert.h>
|
||||
#include <algorithm>
|
||||
|
||||
using namespace Shared;
|
||||
using namespace Poincare;
|
||||
|
||||
static inline KDCoordinate maxCoordinate(KDCoordinate x, KDCoordinate y) { return x > y ? x : y; }
|
||||
|
||||
namespace Sequence {
|
||||
|
||||
ListController::ListController(Responder * parentResponder, ::InputEventHandlerDelegate * inputEventHandlerDelegate, ButtonRowController * header, ButtonRowController * footer) :
|
||||
@@ -55,7 +54,7 @@ KDCoordinate ListController::expressionRowHeight(int j) {
|
||||
return defaultHeight;
|
||||
}
|
||||
KDCoordinate sequenceHeight = layout.layoutSize().height();
|
||||
return maxCoordinate(defaultHeight, sequenceHeight + 2*k_expressionCellVerticalMargin);
|
||||
return std::max(defaultHeight, sequenceHeight + 2*k_expressionCellVerticalMargin);
|
||||
}
|
||||
|
||||
void ListController::willDisplayCellAtLocation(HighlightCell * cell, int i, int j) {
|
||||
|
||||
Reference in New Issue
Block a user