// Copyright (c) 2017-2021, Mudita Sp. z.o.o. All rights reserved. // For licensing, see https://github.com/mudita/MuditaOS/LICENSE.md #pragma once #include "application-calendar/models/EventDetailModel.hpp" #include "windows/AppWindow.hpp" #include "Application.hpp" #include #include #include #include #include namespace gui { class Image; class EventReminderWindow : public gui::AppWindow { private: sys::TimerHandle reminderTimer; protected: std::shared_ptr eventRecord; gui::VBox *body = nullptr; Label *dateLabel = nullptr; Label *timeLabel = nullptr; Label *descriptionLabel = nullptr; Image *topImage = nullptr; Image *bottomImage = nullptr; void startTimer(); void destroyTimer(); void reminderTimerCallback(); void closeReminder(); public: EventReminderWindow(app::Application *app, std::string name); virtual ~EventReminderWindow(); void onClose() override; bool onInput(const gui::InputEvent &inputEvent) override; void rebuild() override; void buildInterface() override; void destroyInterface() override; top_bar::Configuration configureTopBar(top_bar::Configuration appConfiguration) override; auto handleSwitchData(SwitchData *data) -> bool override; }; } /* namespace gui */