[calculation] Change name: simple_list_controller -->

expressions_list_controller
This commit is contained in:
Émilie Feral
2019-12-27 10:04:34 +01:00
committed by Léa Saviot
parent 7abe8e2e4d
commit 70ce133b4c
5 changed files with 19 additions and 19 deletions

View File

@@ -11,12 +11,12 @@ app_calculation_src = $(addprefix apps/calculation/,\
additional_outputs/complex_model.cpp \
additional_outputs/complex_list_controller.cpp \
additional_outputs/expression_with_equal_sign_view.cpp \
additional_outputs/expressions_list_controller.cpp \
additional_outputs/illustrated_list_controller.cpp \
additional_outputs/integer_list_controller.cpp \
additional_outputs/scrollable_input_exact_approximate_expressions_cell.cpp \
additional_outputs/list_controller.cpp \
additional_outputs/rational_list_controller.cpp \
additional_outputs/simple_list_controller.cpp \
additional_outputs/trigonometry_graph_cell.cpp \
additional_outputs/trigonometry_list_controller.cpp \
additional_outputs/trigonometry_model.cpp \

View File

@@ -1,31 +1,31 @@
#include "simple_list_controller.h"
#include "expressions_list_controller.h"
#include "../app.h"
using namespace Poincare;
namespace Calculation {
/* Simple list controller */
/* Expressions list controller */
SimpleListController::SimpleListController(Responder * parentResponder) :
ExpressionsListController::ExpressionsListController(Responder * parentResponder) :
ListController(parentResponder),
m_cells{}
{
}
void SimpleListController::didEnterResponderChain(Responder * previousFirstResponder) {
void ExpressionsListController::didEnterResponderChain(Responder * previousFirstResponder) {
selectCellAtLocation(0, 0);
}
int SimpleListController::reusableCellCount(int type) {
int ExpressionsListController::reusableCellCount(int type) {
return k_maxNumberOfCells;
}
HighlightCell * SimpleListController::reusableCell(int index, int type) {
HighlightCell * ExpressionsListController::reusableCell(int index, int type) {
return &m_cells[index];
}
KDCoordinate SimpleListController::rowHeight(int j) {
KDCoordinate ExpressionsListController::rowHeight(int j) {
Layout l = layoutAtIndex(j);
if (l.isUninitialized()) {
return 0;
@@ -33,7 +33,7 @@ KDCoordinate SimpleListController::rowHeight(int j) {
return l.layoutSize().height() + 2 * Metric::CommonSmallMargin + Metric::CellSeparatorThickness;
}
void SimpleListController::willDisplayCellForIndex(HighlightCell * cell, int index) {
void ExpressionsListController::willDisplayCellForIndex(HighlightCell * cell, int index) {
ExpressionTableCellWithPointer * myCell = static_cast<ExpressionTableCellWithPointer *>(cell);
myCell->setLayout(layoutAtIndex(index));
myCell->setAccessoryMessage(messageAtIndex(index));

View File

@@ -1,5 +1,5 @@
#ifndef CALCULATION_ADDITIONAL_OUTPUTS_SIMPLE_LIST_CONTROLLER_H
#define CALCULATION_ADDITIONAL_OUTPUTS_SIMPLE_LIST_CONTROLLER_H
#ifndef CALCULATION_ADDITIONAL_OUTPUTS_EXPRESSIONS_LIST_CONTROLLER_H
#define CALCULATION_ADDITIONAL_OUTPUTS_EXPRESSIONS_LIST_CONTROLLER_H
#include <escher.h>
#include <poincare/expression.h>
@@ -8,9 +8,9 @@
namespace Calculation {
class SimpleListController : public ListController {
class ExpressionsListController : public ListController {
public:
SimpleListController(Responder * parentResponder);
ExpressionsListController(Responder * parentResponder);
// Responder
void didEnterResponderChain(Responder * previousFirstResponder) override;

View File

@@ -1,14 +1,14 @@
#ifndef CALCULATION_ADDITIONAL_OUTPUTS_INTEGER_LIST_CONTROLLER_H
#define CALCULATION_ADDITIONAL_OUTPUTS_INTEGER_LIST_CONTROLLER_H
#include "simple_list_controller.h"
#include "expressions_list_controller.h"
namespace Calculation {
class IntegerListController : public SimpleListController {
class IntegerListController : public ExpressionsListController {
public:
IntegerListController() :
SimpleListController(nullptr) {}
ExpressionsListController(nullptr) {}
//ListViewDataSource
int numberOfRows() const override;

View File

@@ -1,14 +1,14 @@
#ifndef CALCULATION_ADDITIONAL_OUTPUTS_RATIONAL_LIST_CONTROLLER_H
#define CALCULATION_ADDITIONAL_OUTPUTS_RATIONAL_LIST_CONTROLLER_H
#include "simple_list_controller.h"
#include "expressions_list_controller.h"
namespace Calculation {
class RationalListController : public SimpleListController {
class RationalListController : public ExpressionsListController {
public:
RationalListController() :
SimpleListController(nullptr) {}
ExpressionsListController(nullptr) {}
//ListViewDataSource
int numberOfRows() const override;