mirror-chatterino2/src/singletons/Toasts.hpp

29 lines
717 B
C++
Raw Normal View History

2018-08-11 12:47:03 +02:00
#pragma once
#include "Application.hpp"
#include "common/Singleton.hpp"
#include <mutex>
namespace chatterino {
class Toasts final : public Singleton
{
public:
Toasts();
virtual void initialize(Settings &settings, Paths &paths) override final;
private:
2018-08-11 12:47:03 +02:00
void updateLiveChannels(const QString &channelName);
void removeFromLiveChannels(const QString &channelName);
bool wasChannelLive(const QString &channelName);
void shouldChannelBeNotified(const QString &channelName);
2018-08-11 12:47:03 +02:00
void sendChannelNotification(const QString &channelName);
void sendWindowsNotification(const QString &channelName);
2018-08-11 12:47:03 +02:00
std::vector<QString> liveChannels;
std::mutex mutex_;
};
} // namespace chatterino