Files
Upsilon/apps/sequence/list/sequence_toolbox.h
Émilie Feral 7406e0d775 [apps][escher] Do not forget to delete dynamic objects when reassigning
then or destructing them

Change-Id: If2b4de460163bf187152389e419d87329b83fc39
2017-03-07 15:03:11 +01:00

31 lines
927 B
C++

#ifndef SEQUENCE_SEQUENCE_TOOLBOX_H
#define SEQUENCE_SEQUENCE_TOOLBOX_H
#include "../../math_toolbox.h"
namespace Sequence {
class SequenceToolbox : public MathToolbox {
public:
SequenceToolbox();
~SequenceToolbox();
bool handleEvent(Ion::Events::Event event) override;
int numberOfRows() override;
HighlightCell * reusableCell(int index, int type) override;
void willDisplayCellForIndex(HighlightCell * cell, int index) override;
KDCoordinate rowHeight(int j) override;
int typeAtLocation(int i, int j) override;
void setExtraCells(const char * sequenceName, int recurrenceDepth);
private:
bool selectAddedCell(int selectedRow);
int mathToolboxIndex(int index);
constexpr static KDCoordinate k_addedRowHeight = 20;
ExpressionTableCell m_addedCells[k_maxNumberOfDisplayedRows];
Poincare::ExpressionLayout * m_addedCellLayout[k_maxNumberOfDisplayedRows];
int m_numberOfAddedCells;
};
}
#endif