Files
Upsilon/apps/graph/list/function_cell.cpp
Émilie Feral 47a02344c2 [apps/graph/list] Modify the controller of functions to use a table view instead of a list view
Change-Id: I3767de865ef07761eb80310cfe80d6eb60821bb0
2016-09-30 17:12:32 +02:00

34 lines
755 B
C++

#include "function_cell.h"
constexpr KDColor FunctionCell::k_evenLineBackgroundColor;
constexpr KDColor FunctionCell::k_oddLineBackgroundColor;
constexpr KDColor FunctionCell::k_selectedLineBackgroundColor;
constexpr KDColor FunctionCell::k_desactiveTextColor;
FunctionCell::FunctionCell() :
ChildlessView(),
m_highlighted(false),
m_even(false),
m_function(nullptr)
{
}
void FunctionCell::setEven(bool even) {
m_even = even;
markRectAsDirty(bounds());
}
void FunctionCell::setFunction(Graph::Function * f) {
m_function = f;
markRectAsDirty(bounds());
}
void FunctionCell::setHighlighted(bool highlight) {
m_highlighted = highlight;
markRectAsDirty(bounds());
}
Graph::Function * FunctionCell::function() {
return m_function;
}