mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-01-18 16:27:34 +01:00
[apps] Factorize isDisplayingEmptyController
Because we can now, it might need to be de-factorized later, if more classes inherit from alternate_empty_nested_menu_controller
This commit is contained in:
@@ -12,7 +12,7 @@ public:
|
|||||||
void viewDidDisappear() override;
|
void viewDidDisappear() override;
|
||||||
protected:
|
protected:
|
||||||
virtual ViewController * emptyViewController() = 0;
|
virtual ViewController * emptyViewController() = 0;
|
||||||
virtual bool isDisplayingEmptyController() = 0;
|
bool isDisplayingEmptyController() { return StackViewController::depth() == 2; }
|
||||||
bool displayEmptyControllerIfNeeded();
|
bool displayEmptyControllerIfNeeded();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -32,7 +32,6 @@ public:
|
|||||||
|
|
||||||
//AlternateEmptyNestedMenuController
|
//AlternateEmptyNestedMenuController
|
||||||
ViewController * emptyViewController() override { return &m_variableBoxEmptyController; }
|
ViewController * emptyViewController() override { return &m_variableBoxEmptyController; }
|
||||||
bool isDisplayingEmptyController() override { return StackViewController::depth() == 2; } //TODO LEA factorize with math toolbox
|
|
||||||
|
|
||||||
/* VariableBoxController */
|
/* VariableBoxController */
|
||||||
void loadFunctionsAndVariables(int scriptIndex, const char * textToAutocomplete, int textToAutocompleteLength);
|
void loadFunctionsAndVariables(int scriptIndex, const char * textToAutocomplete, int textToAutocompleteLength);
|
||||||
|
|||||||
@@ -47,7 +47,6 @@ private:
|
|||||||
const char * extension() const;
|
const char * extension() const;
|
||||||
Ion::Storage::Record recordAtIndex(int rowIndex);
|
Ion::Storage::Record recordAtIndex(int rowIndex);
|
||||||
ViewController * emptyViewController() override;
|
ViewController * emptyViewController() override;
|
||||||
bool isDisplayingEmptyController() override { return StackViewController::depth() == 2; }
|
|
||||||
void resetMemoization();
|
void resetMemoization();
|
||||||
void destroyRecordAtRowIndex(int rowIndex);
|
void destroyRecordAtRowIndex(int rowIndex);
|
||||||
Page m_currentPage;
|
Page m_currentPage;
|
||||||
|
|||||||
Reference in New Issue
Block a user