From 12fff7408ea7539d778a641bbf1746693d30ee2a Mon Sep 17 00:00:00 2001 From: Nicolas Werner Date: Tue, 27 Oct 2020 17:45:28 +0100 Subject: Optimize build --- src/Cache.h | 28 ++++++++-------------------- 1 file changed, 8 insertions(+), 20 deletions(-) (limited to 'src/Cache.h') diff --git a/src/Cache.h b/src/Cache.h index 98e6cb75..4c4f7071 100644 --- a/src/Cache.h +++ b/src/Cache.h @@ -28,11 +28,18 @@ #include #endif -#include +#include +#include +#include +#include #include "CacheCryptoStructs.h" #include "CacheStructs.h" +namespace mtx::responses { +struct Notifications; +} + namespace cache { void init(const QString &user_id); @@ -94,8 +101,6 @@ getRoomVersion(lmdb::txn &txn, lmdb::dbi &statesdb); std::vector getMembers(const std::string &room_id, std::size_t startIndex = 0, std::size_t len = 30); -void -saveState(const mtx::responses::Sync &res); bool isInitialized(); @@ -128,9 +133,6 @@ setCurrentFormat(); bool runMigrations(); -std::map -roomMessages(); - QMap getTimelineMentions(); @@ -182,22 +184,8 @@ saveImage(const QString &url, const QByteArray &data); RoomInfo singleRoomInfo(const std::string &room_id); -std::vector -roomsWithStateUpdates(const mtx::responses::Sync &res); -std::vector -roomsWithTagUpdates(const mtx::responses::Sync &res); std::map getRoomInfo(const std::vector &rooms); -inline std::map -roomUpdates(const mtx::responses::Sync &sync) -{ - return getRoomInfo(roomsWithStateUpdates(sync)); -} -inline std::map -roomTagUpdates(const mtx::responses::Sync &sync) -{ - return getRoomInfo(roomsWithTagUpdates(sync)); -} //! Calculates which the read status of a room. //! Whether all the events in the timeline have been read. -- cgit 1.5.1