2021-06-09 23:44:49 +02:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include <memory>
|
2021-06-25 00:18:56 +02:00
|
|
|
#include <components/ble/weather/WeatherService.h>
|
2021-06-09 23:44:49 +02:00
|
|
|
#include "Screen.h"
|
|
|
|
#include "ScreenList.h"
|
|
|
|
|
|
|
|
namespace Pinetime {
|
|
|
|
namespace Applications {
|
|
|
|
class DisplayApp;
|
|
|
|
|
|
|
|
namespace Screens {
|
|
|
|
class Weather : public Screen {
|
|
|
|
public:
|
2021-06-25 00:18:56 +02:00
|
|
|
explicit Weather(DisplayApp* app, Pinetime::Controllers::WeatherService& weather);
|
|
|
|
|
2021-06-09 23:44:49 +02:00
|
|
|
~Weather() override;
|
2021-06-25 00:18:56 +02:00
|
|
|
|
2021-11-28 14:33:06 +01:00
|
|
|
void Refresh() override;
|
2021-06-25 00:18:56 +02:00
|
|
|
|
2021-06-09 23:44:49 +02:00
|
|
|
bool OnButtonPushed() override;
|
2021-06-25 00:18:56 +02:00
|
|
|
|
2021-06-09 23:44:49 +02:00
|
|
|
bool OnTouchEvent(TouchEvents event) override;
|
|
|
|
|
|
|
|
private:
|
|
|
|
bool running = true;
|
|
|
|
|
|
|
|
Pinetime::Controllers::DateTime& dateTimeController;
|
2021-06-25 00:18:56 +02:00
|
|
|
Controllers::WeatherService& weatherService;
|
2021-06-09 23:44:49 +02:00
|
|
|
|
|
|
|
ScreenList<5> screens;
|
2021-06-25 00:18:56 +02:00
|
|
|
|
|
|
|
std::unique_ptr<Screen> CreateScreenTemperature();
|
|
|
|
|
2021-06-09 23:44:49 +02:00
|
|
|
std::unique_ptr<Screen> CreateScreen2();
|
2021-06-25 00:18:56 +02:00
|
|
|
|
2021-06-09 23:44:49 +02:00
|
|
|
std::unique_ptr<Screen> CreateScreen3();
|
2021-06-25 00:18:56 +02:00
|
|
|
|
2021-06-09 23:44:49 +02:00
|
|
|
std::unique_ptr<Screen> CreateScreen4();
|
2021-06-25 00:18:56 +02:00
|
|
|
|
2021-06-09 23:44:49 +02:00
|
|
|
std::unique_ptr<Screen> CreateScreen5();
|
|
|
|
};
|
|
|
|
}
|
|
|
|
}
|
2021-11-28 14:33:06 +01:00
|
|
|
}
|