From 424b02609fa34175a4e2aadb95e68b3c9c8dc93c Mon Sep 17 00:00:00 2001 From: dec05eba Date: Sat, 21 Apr 2018 04:17:24 +0200 Subject: Fix emoji async download drawing --- include/Cache.hpp | 2 +- include/MessagePart.hpp | 1 + include/ResourceCache.hpp | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/Cache.hpp b/include/Cache.hpp index 89abe2c..59d997a 100644 --- a/include/Cache.hpp +++ b/include/Cache.hpp @@ -24,7 +24,7 @@ namespace dchat }; // @texture is null if @type is DOWNLOADING or FAILED_DOWNLOAD - const sf::Texture *texture; + sf::Texture *texture; Type type; }; diff --git a/include/MessagePart.hpp b/include/MessagePart.hpp index cbb0f26..d0a0a03 100644 --- a/include/MessagePart.hpp +++ b/include/MessagePart.hpp @@ -49,5 +49,6 @@ namespace dchat sf::Sprite sprite; std::string url; + bool dirty; }; } diff --git a/include/ResourceCache.hpp b/include/ResourceCache.hpp index 256e5a4..7361862 100644 --- a/include/ResourceCache.hpp +++ b/include/ResourceCache.hpp @@ -20,6 +20,6 @@ namespace dchat static const sf::Font& getFont(const std::string &filepath); // Throws FailedToLoadResourceException on failure - static const sf::Texture* getTexture(const std::string &filepath); + static sf::Texture* getTexture(const std::string &filepath); }; } -- cgit v1.2.3