WeatherService: Remove unused SystemTask reference

This commit is contained in:
Riku Isokoski 2023-03-15 10:19:30 +02:00
parent c7a9b3d7d3
commit 7e15a1e340
3 changed files with 3 additions and 10 deletions

View File

@ -43,7 +43,7 @@ NimbleController::NimbleController(Pinetime::System::SystemTask& systemTask,
alertNotificationClient {systemTask, notificationManager},
currentTimeService {dateTimeController},
musicService {*this},
weatherService {systemTask, dateTimeController},
weatherService {dateTimeController},
navService {systemTask},
batteryInformationService {batteryController},
immediateAlertService {systemTask, notificationManager},

View File

@ -19,7 +19,6 @@
#include <qcbor/qcbor_spiffy_decode.h>
#include "WeatherService.h"
#include "libs/QCBOR/inc/qcbor/qcbor.h"
#include "systemtask/SystemTask.h"
int WeatherCallback(uint16_t /*connHandle*/, uint16_t /*attrHandle*/, struct ble_gatt_access_ctxt* ctxt, void* arg) {
return static_cast<Pinetime::Controllers::WeatherService*>(arg)->OnCommand(ctxt);
@ -27,8 +26,7 @@ int WeatherCallback(uint16_t /*connHandle*/, uint16_t /*attrHandle*/, struct ble
namespace Pinetime {
namespace Controllers {
WeatherService::WeatherService(System::SystemTask& system, DateTime& dateTimeController)
: system(system), dateTimeController(dateTimeController) {
WeatherService::WeatherService(DateTime& dateTimeController) : dateTimeController(dateTimeController) {
nullHeader = &nullTimelineheader;
nullTimelineheader->timestamp = 0;
}

View File

@ -36,15 +36,11 @@
int WeatherCallback(uint16_t connHandle, uint16_t attrHandle, struct ble_gatt_access_ctxt* ctxt, void* arg);
namespace Pinetime {
namespace System {
class SystemTask;
}
namespace Controllers {
class WeatherService {
public:
explicit WeatherService(System::SystemTask& system, DateTime& dateTimeController);
explicit WeatherService(DateTime& dateTimeController);
void Init();
@ -133,7 +129,6 @@ namespace Pinetime {
uint16_t eventHandle {};
Pinetime::System::SystemTask& system;
Pinetime::Controllers::DateTime& dateTimeController;
std::vector<std::unique_ptr<WeatherData::TimelineHeader>> timeline;