qTox
Version: nightly | Commit: bc751c8e1cac455f9690654fcfe0f560d2d7dfdd
|
Go to the documentation of this file.
44 std::vector<DateChatLogIdxPair>
getDateIdxs(
const QDate& startDate,
size_t maxDates)
const override;
void loadHistoryIntoSessionChatLog(ChatLogIdx start) const
Unconditionally loads the given index and all future messages that are not in the session chat log in...
ChatLogIdx getNextIdx() const override
void onMessageSent(DispatchedMessageId id, const Message &message)
void onFileTransferRemotePausedUnpaused(const ToxPk &sender, const ToxFile &file, bool paused)
NamedType< int64_t, struct RowIdTag, Orderable > RowId
ChatLogIdx getFirstIdx() const override
The underlying chat log instance may not want to start at 0.
const ChatLogItem & at(ChatLogIdx idx) const override
Returns reference to item at idx.
void onMessageBroken(DispatchedMessageId id, BrokenMessageReason reason)
void onFileTransferBrokenUnbroken(const ToxPk &sender, const ToxFile &file, bool broken)
QMap< DispatchedMessageId, BrokenMessageReason > brokenMessages
QMap< DispatchedMessageId, RowId > dispatchedMessageRowIdMap
QSet< DispatchedMessageId > completedMessages
const Settings & settings
This class represents a Tox Public Key, which is a part of Tox ID.
void ensureIdxInSessionChatLog(ChatLogIdx idx) const
Forces the given index and all future indexes to be in the chatlog.
void handleDispatchedMessage(DispatchedMessageId dispatchId, RowId historyId)
NamedType< size_t, struct SentMessageIdTag, Orderable, Incrementable > DispatchedMessageId
void onMessageReceived(const ToxPk &sender, const Message &message)
void completeMessage(DispatchedMessageId id)
void breakMessage(DispatchedMessageId id, BrokenMessageReason reason)
SessionChatLog sessionChatLog
NamedType< size_t, struct ChatLogIdxTag, Orderable, UnderlyingAddable, UnitlessDifferencable, Incrementable > ChatLogIdx
Interacts with the profile database to save the chat history.
const ICoreIdHandler & coreIdHandler
void onFileUpdated(const ToxPk &sender, const ToxFile &file)
ChatHistory(Friend &f_, History *history_, const ICoreIdHandler &coreIdHandler, const Settings &settings, IMessageDispatcher &messageDispatcher)
void addSystemMessage(const SystemMessage &message) override
Inserts a system message at the end of the chat.
SearchResult searchForward(SearchPos startIdx, const QString &phrase, const ParameterSearch ¶meter) const override
searches forwards through the chat log until phrase is found according to parameter
bool canUseHistory() const
std::vector< DateChatLogIdxPair > getDateIdxs(const QDate &startDate, size_t maxDates) const override
Gets indexes for each new date starting at startDate.
SearchResult searchBackward(SearchPos startIdx, const QString &phrase, const ParameterSearch ¶meter) const override
searches backwards through the chat log until phrase is found according to parameter
ChatLogIdx getInitialChatLogIdx() const
Gets the initial chat log index for a sessionChatLog with 0 items loaded from history....
void onMessageComplete(DispatchedMessageId id)
void dispatchUnsentMessages(IMessageDispatcher &messageDispatcher)
Sends any unsent messages in history to the underlying message dispatcher.