aboutsummaryrefslogtreecommitdiff
path: root/include/Body.hpp
diff options
context:
space:
mode:
authordec05eba <dec05eba@protonmail.com>2021-05-22 13:37:07 +0200
committerdec05eba <dec05eba@protonmail.com>2021-05-22 13:37:07 +0200
commit398eeeca691a14dd883c33fde16de55fe1ed6a4f (patch)
treebb7383d6899ce759563c6303934deac82b279d90 /include/Body.hpp
parentb1860b675c3be3433bc370b4d53480722d529b95 (diff)
Fix 4chan and other html plugins for ubuntu, make movement smooth with 60fps as well, readd updateGeometry
Diffstat (limited to 'include/Body.hpp')
-rw-r--r--include/Body.hpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/include/Body.hpp b/include/Body.hpp
index e74d459..2d18bdd 100644
--- a/include/Body.hpp
+++ b/include/Body.hpp
@@ -280,8 +280,6 @@ namespace QuickMedia {
int get_previous_visible_item(int start_index);
// Returns -1 if not found
int get_next_visible_item(int start_index);
- float get_offset_to_first_visible_item(sf::Vector2f body_size);
- float get_offset_to_last_visible_item(sf::Vector2f body_size);
private:
enum class DirtyState {
FALSE,
@@ -289,6 +287,12 @@ namespace QuickMedia {
FORCE_TRUE
};
+ enum class TargetSetState {
+ NOT_SET,
+ SET,
+ APPLIED
+ };
+
Program *program;
int selected_item;
int prev_selected_item;
@@ -338,6 +342,7 @@ namespace QuickMedia {
bool render_selected_item_bg = true;
float item_background_target_pos_y = 0.0f;
float item_background_target_height = 0.0f;
+ TargetSetState target_y_set = TargetSetState::NOT_SET;
// TODO: Instead of using this, add functions for modifying |items| and apply the filter on those new items
DirtyState items_dirty = DirtyState::FALSE;
std::string current_filter;