mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-03-19 22:00:28 +01:00
[apps/shared] Functions cache clears on change
Added several triggers to clear the cache when the function's type, range or content is changed. Change-Id: I4f49a90bb6571e335a4a601723d7715b8de1e25e
This commit is contained in:
committed by
Émilie Feral
parent
552dca9494
commit
a9c633a540
@@ -125,6 +125,8 @@ void ContinuousFunction::setPlotType(PlotType newPlotType, Poincare::Preferences
|
||||
|
||||
recordData()->setPlotType(newPlotType);
|
||||
|
||||
cache()->clear();
|
||||
|
||||
// Recompute the layouts
|
||||
m_model.tidy();
|
||||
|
||||
@@ -251,10 +253,12 @@ float ContinuousFunction::tMax() const {
|
||||
|
||||
void ContinuousFunction::setTMin(float tMin) {
|
||||
recordData()->setTMin(tMin);
|
||||
cache()->clear();
|
||||
}
|
||||
|
||||
void ContinuousFunction::setTMax(float tMax) {
|
||||
recordData()->setTMax(tMax);
|
||||
cache()->clear();
|
||||
}
|
||||
|
||||
void * ContinuousFunction::Model::expressionAddress(const Ion::Storage::Record * record) const {
|
||||
@@ -347,6 +351,11 @@ Poincare::Expression ContinuousFunction::sumBetweenBounds(double start, double e
|
||||
* the derivative table. */
|
||||
}
|
||||
|
||||
Ion::Storage::Record::ErrorStatus ContinuousFunction::setContent(const char * c, Poincare::Context * context) {
|
||||
cache()->clear();
|
||||
return ExpressionModelHandle::setContent(c, context);
|
||||
}
|
||||
|
||||
template Coordinate2D<float> ContinuousFunction::templatedApproximateAtParameter<float>(float, Poincare::Context *) const;
|
||||
template Coordinate2D<double> ContinuousFunction::templatedApproximateAtParameter<double>(double, Poincare::Context *) const;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user