diff options
author | dec05eba <dec05eba@protonmail.com> | 2021-05-29 15:03:39 +0200 |
---|---|---|
committer | dec05eba <dec05eba@protonmail.com> | 2021-05-29 15:03:39 +0200 |
commit | 11cc8e1209e99d394febfde0696b94dd69972e4a (patch) | |
tree | 3cca90618b043662e72f009ca1e304375d8b3096 /include | |
parent | 2a364f52f194c853f2cb62122bf84039ab3e1117 (diff) |
Work on body swipe, fix body scrolling being jerky with touch
Diffstat (limited to 'include')
-rw-r--r-- | include/Body.hpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/Body.hpp b/include/Body.hpp index a7b0045..388d825 100644 --- a/include/Body.hpp +++ b/include/Body.hpp @@ -268,6 +268,7 @@ namespace QuickMedia { sf::Shader *thumbnail_mask_shader; AttachSide attach_side = AttachSide::TOP; bool title_mark_urls = false; + bool swiping_enabled = false; std::function<void()> on_top_reached = nullptr; std::function<void()> on_bottom_reached = nullptr; @@ -336,6 +337,9 @@ namespace QuickMedia { sf::Vector2f mouse_scroll_accel; sf::Vector2f body_pos; sf::Vector2f body_size; + double body_swipe_x = 0.0; + bool body_swipe_move_right = false; + bool grabbed_left_side = false; float selected_item_height = 0.0f; std::shared_ptr<BodyItem> clicked_body_item = nullptr; RoundedRectangle item_background; |