Commit 90493c6e authored by Volker Krause's avatar Volker Krause

Remove live data update hacks in the timeline model

This is now going through the timeline delegate controller.
parent cfcda926
......@@ -180,8 +180,6 @@ int main(int argc, char **argv)
timelineModel.setHomeCountryIsoCode(settings.homeCountryIsoCode());
timelineModel.setReservationManager(&resMgr);
QObject::connect(&settings, &Settings::homeCountryIsoCodeChanged, &timelineModel, &TimelineModel::setHomeCountryIsoCode);
QObject::connect(&liveDataMgr, &LiveDataManager::arrivalUpdated, &timelineModel, &TimelineModel::dataChangedForReservation);
QObject::connect(&liveDataMgr, &LiveDataManager::departureUpdated, &timelineModel, &TimelineModel::dataChangedForReservation);
WeatherForecastManager weatherForecastMgr;
weatherForecastMgr.setAllowNetworkAccess(settings.weatherForecastEnabled());
......
......@@ -678,8 +678,3 @@ void TimelineModel::tripGroupRemoved(const QString& groupId)
endRemoveRows();
}
}
void TimelineModel::dataChangedForReservation(const QString &resId)
{
batchChanged(resId); // ### this could be done a bit more efficient, as we know this isn't called for time changes
}
......@@ -91,11 +91,6 @@ public:
int todayRow() const;
/** Emit dataChanged() for the row containing @p resId.
* This is used to trigger UI updates e.g. from the LiveDataManager.
*/
void dataChangedForReservation(const QString &resId);
// for unit testing
void setCurrentDateTime(const QDateTime &dt);
QDateTime now() const;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment