~aleteoryx/muditaos

ref: 1e8082e02c0868f6d20254e2055c2ae661f722e6 muditaos/module-apps/apps-common/popups/lock-popups/PhoneLockedWindow.hpp -rw-r--r-- 1.2 KiB
1e8082e0 — Wojtek Rzepecki [EGD-7570] Add Alarm Clock status bar indicator 4 years ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
// 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 <AppWindow.hpp>
#include <gui/widgets/Label.hpp>
#include <Translator.hpp>
#include <notifications/NotificationsModel.hpp>
#include <ListView.hpp>

namespace app
{
    class ApplicationDesktop;
}

namespace gui
{
    class PhoneLockedWindow : public AppWindow
    {
      protected:
        gui::Label *time                                            = nullptr;
        gui::Label *dayText                                         = nullptr;
        gui::ListView *notificationsList                            = nullptr;
        std::shared_ptr<gui::NotificationsModel> notificationsModel = nullptr;

        bool processLongReleaseEvent(const InputEvent &inputEvent);

      public:
        PhoneLockedWindow(app::ApplicationCommon *app, const std::string &name);

        bool onInput(const InputEvent &inputEvent) override;
        void onBeforeShow(ShowMode mode, SwitchData *data) override;
        void buildInterface() override;
        status_bar::Configuration configureStatusBar(status_bar::Configuration appConfiguration) override;

        bool updateTime() override;
    };

} /* namespace gui */