From 2d1f007e7586b7745380060a506ba351a609aa3a Mon Sep 17 00:00:00 2001 From: dec05eba Date: Fri, 3 Jul 2020 18:32:16 +0200 Subject: Allow changing the placeholder text, fix dmenu empty search selection --- include/SearchBar.hpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'include/SearchBar.hpp') diff --git a/include/SearchBar.hpp b/include/SearchBar.hpp index 6222da4..0cffff5 100644 --- a/include/SearchBar.hpp +++ b/include/SearchBar.hpp @@ -16,7 +16,7 @@ namespace QuickMedia { class SearchBar { public: - SearchBar(sf::Font &font, sf::Texture &plugin_logo); + SearchBar(sf::Font &font, sf::Texture &plugin_logo, const std::string &placeholder); void draw(sf::RenderWindow &window, bool draw_shadow = true); void update(); void onWindowResize(const sf::Vector2f &window_size); @@ -45,6 +45,7 @@ namespace QuickMedia { sf::RectangleShape background_shadow; sf::RectangleShape shade; sf::Sprite plugin_logo_sprite; + std::string placeholder_str; bool show_placeholder; bool updated_search; bool updated_autocomplete; -- cgit v1.2.3