3 #include "../apps_container.h" 10 m_calculationHistory{},
11 m_calculationStore(calculationStore)
54 editController->
insertTextBody(calculation->approximateOutputText());
119 if (selectedCell ==
nullptr) {
122 if (previousSelectedCellY == -1) {
124 }
else if (
selectedRow() < previousSelectedCellY) {
126 }
else if (
selectedRow() > previousSelectedCellY) {
140 assert(index < k_maxNumberOfDisplayedRows);
141 return m_calculationHistory[index];
146 return k_maxNumberOfDisplayedRows;
161 KDCoordinate inputHeight = calculation->inputLayout()->size().height();
165 if (calculation->shouldDisplayApproximateOutput(calculationApp->
localContext())) {
176 for (
int k = 0; k < j; k++) {
188 return (result < offsetY || offsetY == 0) ? j : j - 1;
205 for (
int i = 0; i < k_maxNumberOfDisplayedRows; i++) {
212 for (
int i = 0; i < k_maxNumberOfDisplayedRows; i++) {
213 delete m_calculationHistory[i];
214 m_calculationHistory[i] =
nullptr;
void setCalculation(Calculation *calculation)
Calculation * calculationAtIndex(int i)
void willDisplayCellForIndex(HighlightCell *cell, int index) override
HighlightCell * selectedCell()
void deleteCalculationAtIndex(int i)
void tableViewDidChangeSelection(SelectableTableView *t, int previousSelectedCellX, int previousSelectedCellY) override
HistoryController(Responder *parentResponder, CalculationStore *calculationStore)
void didBecomeFirstResponder() override
Responder * parentResponder() const
void setSelectedSubviewType(HistoryViewCell::SubviewType subviewType)
bool selectCellAtLocation(int i, int j, bool setFirstResponder=true)
bool handleEvent(Ion::Events::Event event) override
void scrollToCell(int i, int j)
int indexFromCumulatedHeight(KDCoordinate offsetY) override
virtual Poincare::Context * localContext()
void store(const char *storedText)
void reloadData(bool setFirstResponder=true)
KDCoordinate cumulatedHeightFromIndex(int j) override
static constexpr KDCoordinate k_digitVerticalMargin
void scrollToCell(int i, int j) override
int numberOfRows() override
int numberOfCalculations()
HighlightCell * reusableCell(int index, int type) override
void insertTextBody(const char *text)
SubviewType selectedSubviewType()
View * loadView() override
void willExitResponderChain(Responder *nextFirstResponder) override
SubviewType selectedSubviewType()
void setFirstResponder(Responder *responder)
void unloadView(View *view) override
KDCoordinate rowHeight(int j) override
static Clipboard * sharedClipboard()
OutputExpressionsView * outputView()
void selectCellAtLocation(int i, int j)
int typeAtLocation(int i, int j) override
void setEven(bool even) override
int reusableCellCount(int type) override
constexpr Event Backspace
void reloadCell() override
constexpr KDCoordinate height() const