mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-01-18 16:27:34 +01:00
[apps/stats] Add option fill with formula (does nothing)
This commit is contained in:
@@ -14,6 +14,7 @@ Deviation = "Varianz"
|
||||
DisplayValues = "Werte anzeigen"
|
||||
ExitExamMode1 = "Wollen Sie den Testmodus "
|
||||
ExitExamMode2 = "verlassen?"
|
||||
FillWithFormula = "Fill with formula"
|
||||
ForbiddenValue = "Verbotener Wert"
|
||||
FunctionColumn = "0(0) Spalte"
|
||||
FunctionOptions = "Optionen Funktion"
|
||||
|
||||
@@ -14,6 +14,7 @@ Deviation = "Variance"
|
||||
DisplayValues = "Display values"
|
||||
ExitExamMode1 = "Exit the exam "
|
||||
ExitExamMode2 = "mode?"
|
||||
FillWithFormula = "Fill with formula"
|
||||
ForbiddenValue = "Forbidden value"
|
||||
FunctionColumn = "0(0) column"
|
||||
FunctionOptions = "Function options"
|
||||
|
||||
@@ -14,6 +14,7 @@ Deviation = "Varianza"
|
||||
DisplayValues = "Visualizar los valores"
|
||||
ExitExamMode1 = "Salir del modo "
|
||||
ExitExamMode2 = "examen ?"
|
||||
FillWithFormula = "Fill with formula"
|
||||
ForbiddenValue = "Valor prohibido"
|
||||
FunctionColumn = "Columna 0(0)"
|
||||
FunctionOptions = "Opciones de la funcion"
|
||||
|
||||
@@ -14,6 +14,7 @@ Deviation = "Variance"
|
||||
DisplayValues = "Afficher les valeurs"
|
||||
ExitExamMode1 = "Voulez-vous sortir "
|
||||
ExitExamMode2 = "du mode examen ?"
|
||||
FillWithFormula = "Fill with formula"
|
||||
ForbiddenValue = "Valeur interdite"
|
||||
FunctionColumn = "Colonne 0(0)"
|
||||
FunctionOptions = "Options de la fonction"
|
||||
|
||||
@@ -14,6 +14,7 @@ Deviation = "Variancia"
|
||||
DisplayValues = "Exibir os valores"
|
||||
ExitExamMode1 = "Voce quer sair do modo de "
|
||||
ExitExamMode2 = "exame ?"
|
||||
FillWithFormula = "Fill with formula"
|
||||
ForbiddenValue = "Valor proibida"
|
||||
FunctionColumn = "Coluna 0(0)"
|
||||
FunctionOptions = "Opcoes de funcao"
|
||||
|
||||
@@ -14,10 +14,14 @@ StoreController::StoreController(Responder * parentResponder, FloatPairStore * s
|
||||
ButtonRowDelegate(header, nullptr),
|
||||
m_editableCells{},
|
||||
m_store(store),
|
||||
m_storeParameterController(this, store)
|
||||
m_storeParameterController(this, store, this)
|
||||
{
|
||||
}
|
||||
|
||||
void StoreController::displayFormulaInput() {
|
||||
|
||||
}
|
||||
|
||||
bool StoreController::textFieldDidFinishEditing(TextField * textField, const char * text, Ion::Events::Event event) {
|
||||
AppsContainer * appsContainer = ((TextFieldDelegateApp *)app())->container();
|
||||
Context * globalContext = appsContainer->globalContext();
|
||||
|
||||
@@ -13,6 +13,8 @@ class StoreController : public EditableCellTableViewController, public ButtonRow
|
||||
public:
|
||||
StoreController(Responder * parentResponder, FloatPairStore * store, ButtonRowController * header);
|
||||
|
||||
void displayFormulaInput();
|
||||
|
||||
// TextFieldDelegate
|
||||
bool textFieldDidFinishEditing(TextField * textField, const char * text, Ion::Events::Event event) override;
|
||||
|
||||
@@ -57,6 +59,7 @@ protected:
|
||||
StoreParameterController m_storeParameterController;
|
||||
private:
|
||||
bool cellShouldBeTransparent(int i, int j);
|
||||
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
@@ -1,17 +1,20 @@
|
||||
#include "store_parameter_controller.h"
|
||||
#include "store_controller.h"
|
||||
#include <assert.h>
|
||||
|
||||
namespace Shared {
|
||||
|
||||
StoreParameterController::StoreParameterController(Responder * parentResponder, FloatPairStore * store) :
|
||||
StoreParameterController::StoreParameterController(Responder * parentResponder, FloatPairStore * store, StoreController * storeController) :
|
||||
ViewController(parentResponder),
|
||||
m_deleteColumn(I18n::Message::ClearColumn),
|
||||
m_fillWithFormula(I18n::Message::FillWithFormula),
|
||||
#if COPY_IMPORT_LIST
|
||||
m_copyColumn(I18n::Message::CopyColumnInList),
|
||||
m_importList(I18n::Message::ImportList),
|
||||
#endif
|
||||
m_selectableTableView(this, this, this),
|
||||
m_store(store),
|
||||
m_storeController(storeController),
|
||||
m_xColumnSelected(true),
|
||||
m_series(0)
|
||||
{
|
||||
@@ -40,12 +43,20 @@ bool StoreParameterController::handleEvent(Ion::Events::Event event) {
|
||||
stack->pop();
|
||||
return true;
|
||||
}
|
||||
case 1:
|
||||
{
|
||||
m_storeController->displayFormulaInput();
|
||||
StackViewController * stack = ((StackViewController *)parentResponder());
|
||||
stack->pop();
|
||||
return true;
|
||||
}
|
||||
|
||||
#if COPY_IMPORT_LIST
|
||||
/* TODO: implement copy column and import list */
|
||||
case 1:
|
||||
return true;
|
||||
case 2:
|
||||
return true;
|
||||
case 3:
|
||||
return true;
|
||||
#endif
|
||||
default:
|
||||
assert(false);
|
||||
@@ -58,7 +69,7 @@ bool StoreParameterController::handleEvent(Ion::Events::Event event) {
|
||||
HighlightCell * StoreParameterController::reusableCell(int index) {
|
||||
assert(index >= 0);
|
||||
assert(index < k_totalNumberOfCell);
|
||||
HighlightCell * cells[] = {&m_deleteColumn};// {&m_deleteColumn, &m_copyColumn, &m_importList};
|
||||
HighlightCell * cells[] = {&m_deleteColumn, &m_fillWithFormula};// {&m_deleteColumn, &m_fillWithFormula, &m_copyColumn, &m_importList};
|
||||
return cells[index];
|
||||
}
|
||||
|
||||
|
||||
@@ -7,9 +7,11 @@
|
||||
|
||||
namespace Shared {
|
||||
|
||||
class StoreController;
|
||||
|
||||
class StoreParameterController : public ViewController, public SimpleListViewDataSource, public SelectableTableViewDataSource {
|
||||
public:
|
||||
StoreParameterController(Responder * parentResponder, FloatPairStore * store);
|
||||
StoreParameterController(Responder * parentResponder, FloatPairStore * store, StoreController * storeController);
|
||||
void selectXColumn(bool xColumnSelected) { m_xColumnSelected = xColumnSelected; }
|
||||
void selectSeries(int series) { m_series = series; }
|
||||
View * view() override { return &m_selectableTableView; }
|
||||
@@ -22,15 +24,17 @@ public:
|
||||
int reusableCellCount() override { return k_totalNumberOfCell; }
|
||||
private:
|
||||
#if COPY_IMPORT_LIST
|
||||
constexpr static int k_totalNumberOfCell = 3;
|
||||
constexpr static int k_totalNumberOfCell = 4;
|
||||
MessageTableCellWithChevron m_copyColumn;
|
||||
MessageTableCellWithChevron m_importList;
|
||||
#else
|
||||
constexpr static int k_totalNumberOfCell = 1;
|
||||
constexpr static int k_totalNumberOfCell = 2;
|
||||
#endif
|
||||
MessageTableCell m_deleteColumn;
|
||||
MessageTableCell m_fillWithFormula;
|
||||
SelectableTableView m_selectableTableView;
|
||||
FloatPairStore * m_store;
|
||||
StoreController * m_storeController;
|
||||
bool m_xColumnSelected;
|
||||
int m_series;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user