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