[graph] Fix GraphController with new Poincare API

This commit is contained in:
Émilie Feral
2018-09-06 14:17:50 +02:00
parent 6c1df5ffe8
commit 1d92883aed

View File

@@ -44,7 +44,7 @@ float GraphController::interestingXRange() {
TextFieldDelegateApp * myApp = (TextFieldDelegateApp *)app();
for (int i = 0; i < functionStore()->numberOfActiveFunctions(); i++) {
Function * f = functionStore()->activeFunctionAtIndex(i);
float fRange = f->expression(myApp->localContext())->characteristicXRange(*(myApp->localContext()), Preferences::sharedPreferences()->angleUnit());
float fRange = f->expression(myApp->localContext()).characteristicXRange(*(myApp->localContext()), Preferences::sharedPreferences()->angleUnit());
if (!std::isnan(fRange)) {
characteristicRange = fRange > characteristicRange ? fRange : characteristicRange;
}