diff options
author | JF002 <JF002@users.noreply.github.com> | 2020-10-04 12:21:22 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-04 12:21:22 +0200 |
commit | 39954bbd3afb592a0c3109e3479594183e8d0778 (patch) | |
tree | 58efd04aa38b8dc7989c51fe3c9cdb9a3fb46a54 /src/displayapp/screens/InfiniPaint.h | |
parent | 5adc97702c326d0252df6da75ce4ac244a4b3553 (diff) | |
parent | 6c86d1d9d706706fcb6f214aba8259e61ed68755 (diff) |
Merge pull request #68 from Avamander/patch-1
Rename folders to follow a consistent style
Diffstat (limited to 'src/displayapp/screens/InfiniPaint.h')
-rw-r--r-- | src/displayapp/screens/InfiniPaint.h | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/src/displayapp/screens/InfiniPaint.h b/src/displayapp/screens/InfiniPaint.h new file mode 100644 index 00000000..fb4f979b --- /dev/null +++ b/src/displayapp/screens/InfiniPaint.h @@ -0,0 +1,35 @@ +#pragma once + +#include <cstdint> +#include "Screen.h" +#include <bits/unique_ptr.h> +#include <libs/lvgl/src/lv_core/lv_style.h> +#include <libs/lvgl/src/lv_core/lv_obj.h> +#include <drivers/St7789.h> +#include "displayapp/LittleVgl.h" + +namespace Pinetime { + namespace Applications { + namespace Screens { + + class InfiniPaint : public Screen{ + public: + InfiniPaint(DisplayApp* app, Pinetime::Components::LittleVgl& lvgl); + ~InfiniPaint() override; + + bool Refresh() override; + bool OnButtonPushed() override; + bool OnTouchEvent(TouchEvents event) override; + bool OnTouchEvent(uint16_t x, uint16_t y) override; + + private: + Pinetime::Components::LittleVgl& lvgl; + static constexpr uint16_t width = 10; + static constexpr uint16_t height = 10; + static constexpr uint16_t bufferSize = width*height; + lv_color_t b[bufferSize]; + bool running = true; + }; + } + } +} |