diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/Body.hpp | 6 | ||||
-rw-r--r-- | include/SearchBar.hpp | 1 |
2 files changed, 5 insertions, 2 deletions
diff --git a/include/Body.hpp b/include/Body.hpp index 0b0fca4..e74d459 100644 --- a/include/Body.hpp +++ b/include/Body.hpp @@ -198,9 +198,9 @@ namespace QuickMedia { int get_index_by_body_item(BodyItem *body_item); void select_first_item(); - void select_last_item(); + void select_last_item(bool reset_prev_select = false); void clear_items(); - void prepend_items(BodyItems new_items); + void prepend_items_reverse(BodyItems new_items); void append_items(BodyItems new_items); void insert_item_by_timestamp(std::shared_ptr<BodyItem> body_item); void insert_items_by_timestamps(BodyItems new_items); @@ -240,6 +240,8 @@ namespace QuickMedia { void set_page_scroll(float scroll); float get_page_scroll() const { return page_scroll; } + // This is the item we can see the start of + bool is_first_item_fully_visible() const { return first_item_fully_visible; } // This is the item we can see the end of bool is_last_item_fully_visible() const { return last_item_fully_visible; } bool is_body_full_with_items() const { return items_cut_off; } diff --git a/include/SearchBar.hpp b/include/SearchBar.hpp index 4fc19e9..027f534 100644 --- a/include/SearchBar.hpp +++ b/include/SearchBar.hpp @@ -40,6 +40,7 @@ namespace QuickMedia { float getBottomWithoutShadow() const; std::string get_text() const; + bool is_empty() const; TextUpdateCallback onTextUpdateCallback; TextSubmitCallback onTextSubmitCallback; |