aboutsummaryrefslogtreecommitdiff
path: root/src/Body.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/Body.cpp')
-rw-r--r--src/Body.cpp24
1 files changed, 21 insertions, 3 deletions
diff --git a/src/Body.cpp b/src/Body.cpp
index adb774c..9eb3c98 100644
--- a/src/Body.cpp
+++ b/src/Body.cpp
@@ -315,6 +315,15 @@ namespace QuickMedia {
for(size_t i = 0; i < items.size(); ++i) {
if(body_item->get_timestamp() > items[i]->get_timestamp()) {
items.insert(items.begin() + i, std::move(body_item));
+ /*
+ if((int)i <= selected_item) {
+ if(attach_side == AttachSide::TOP)
+ selected_item -= 1;
+ else
+ selected_item += 1;
+ clamp_selection();
+ }
+ */
return i;
}
}
@@ -328,6 +337,15 @@ namespace QuickMedia {
for(size_t i = 0; i < items.size(); ++i) {
if(body_item->get_timestamp() < items[i]->get_timestamp()) {
items.insert(items.begin() + i, std::move(body_item));
+ /*
+ if((int)i <= selected_item) {
+ if(attach_side == AttachSide::TOP)
+ selected_item -= 1;
+ else
+ selected_item += 1;
+ clamp_selection();
+ }
+ */
return i;
}
}
@@ -1631,19 +1649,19 @@ namespace QuickMedia {
if(item->author_text) {
item->author_text->set_position(text_pos);
item->author_text->draw(window);
- text_offset_y += item->author_text->getHeight();
+ text_offset_y += item->author_text->getHeight() + std::floor(5.0f * get_config().scale);
}
if(item->title_text) {
item->title_text->set_position(text_pos + mgl::vec2f(0.0f, text_offset_y));
item->title_text->draw(window);
- text_offset_y += item->title_text->getHeight();
+ text_offset_y += item->title_text->getHeight() + std::floor(5.0f * get_config().scale);
}
if(item->description_text) {
item->description_text->set_position(text_pos + mgl::vec2f(0.0f, text_offset_y));
item->description_text->draw(window);
- text_offset_y += item->description_text->getHeight();
+ text_offset_y += item->description_text->getHeight() + std::floor(5.0f * get_config().scale);
}
const float gradient_height = 5.0f;