mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-03-18 21:30:38 +01:00
[apps/calculation] EditExpressionController accesses subview directly
This commit is contained in:
committed by
Émilie Feral
parent
63ab8710b9
commit
167827f0e4
@@ -54,7 +54,7 @@ void EditExpressionController::insertTextBody(const char * text) {
|
||||
|
||||
void EditExpressionController::didBecomeFirstResponder() {
|
||||
int lastRow = m_calculationStore->numberOfCalculations() > 0 ? m_calculationStore->numberOfCalculations()-1 : 0;
|
||||
m_historyController->scrollToCell(0, lastRow);
|
||||
m_contentView.mainView()->scrollToCell(0, lastRow);
|
||||
m_contentView.expressionField()->setEditing(true, false);
|
||||
Container::activeApp()->setFirstResponder(m_contentView.expressionField());
|
||||
}
|
||||
|
||||
@@ -223,10 +223,6 @@ int HistoryController::typeAtLocation(int i, int j) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
void HistoryController::scrollToCell(int i, int j) {
|
||||
m_selectableTableView.scrollToCell(i, j);
|
||||
}
|
||||
|
||||
bool HistoryController::calculationAtIndexToggles(int index) {
|
||||
Context * context = App::app()->localContext();
|
||||
return index >= 0 && index < m_calculationStore->numberOfCalculations() && calculationAtIndex(index)->displayOutput(context) == Calculation::DisplayOutput::ExactAndApproximateToggle;
|
||||
|
||||
@@ -31,7 +31,6 @@ public:
|
||||
KDCoordinate rowHeight(int j) override;
|
||||
int typeAtLocation(int i, int j) override;
|
||||
void tableViewDidChangeSelection(SelectableTableView * t, int previousSelectedCellX, int previousSelectedCellY, bool withinTemporarySelection = false) override;
|
||||
void scrollToCell(int i, int j);
|
||||
private:
|
||||
int storeIndex(int i) { return numberOfRows() - i - 1; }
|
||||
Shared::ExpiringPointer<Calculation> calculationAtIndex(int i);
|
||||
|
||||
Reference in New Issue
Block a user