From 5465c09cd108e37720dbad139de98bdcf5dfe8bf Mon Sep 17 00:00:00 2001 From: dec05eba Date: Mon, 19 Apr 2021 16:13:55 +0200 Subject: Move tab code to separate class, fix upload time missing for certain manga plugins, fix touch room click messed up --- src/SearchBar.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'src/SearchBar.cpp') diff --git a/src/SearchBar.cpp b/src/SearchBar.cpp index 63515bd..fa119a6 100644 --- a/src/SearchBar.cpp +++ b/src/SearchBar.cpp @@ -167,10 +167,13 @@ namespace QuickMedia { sf::Vector2f texture_size_f(texture_size.x, texture_size.y); sf::Vector2f new_size = wrap_to_size(texture_size_f, sf::Vector2f(200.0f, one_line_height)); plugin_logo_sprite.setScale(get_ratio(texture_size_f, new_size)); - plugin_logo_sprite.setPosition(25.0f, padding_top + vertical_pos + rect_height * 0.5f - plugin_logo_sprite.getTexture()->getSize().y * plugin_logo_sprite.getScale().y * 0.5f); - offset_x = 25.0f + new_size.x + 25.0f; + plugin_logo_sprite.setPosition(10.0f, padding_top + vertical_pos + rect_height * 0.5f - plugin_logo_sprite.getTexture()->getSize().y * plugin_logo_sprite.getScale().y * 0.5f); + offset_x = 10.0f + new_size.x + 10.0f; + } else { + offset_x = 10.0f; } - const float width = std::floor(window_size.x - offset_x - 25.0f); + + const float width = std::floor(window_size.x - offset_x - 10.0f); background.setSize(sf::Vector2f(width, rect_height)); shade.setSize(sf::Vector2f(window_size.x, padding_top + rect_height + padding_bottom)); -- cgit v1.2.3