blob: 35a788f22263f274b03393c575f25482ddd38395 [file] [log] [blame]
Olivier SOLDANO57442b22017-04-20 11:56:57 -04001/***************************************************************************
Andreas Traczykb8b13ba2018-08-21 16:30:16 -04002 * Copyright (C) 2018 by Savoir-faire Linux *
3 * Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com> *
Olivier SOLDANO57442b22017-04-20 11:56:57 -04004 * *
5 * This program is free software; you can redistribute it and/or modify *
6 * it under the terms of the GNU General Public License as published by *
7 * the Free Software Foundation; either version 3 of the License, or *
8 * (at your option) any later version. *
9 * *
10 * This program is distributed in the hope that it will be useful, *
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13 * GNU General Public License for more details. *
14 * *
15 * You should have received a copy of the GNU General Public License *
16 * along with this program. If not, see <http://www.gnu.org/licenses/>. *
17 **************************************************************************/
Andreas Traczykb8b13ba2018-08-21 16:30:16 -040018#pragma once
Olivier SOLDANO57442b22017-04-20 11:56:57 -040019
Andreas Traczykb8b13ba2018-08-21 16:30:16 -040020#include "api/profile.h"
21#include "smartlistselectorbuttonnotifier.h"
Olivier SOLDANO57442b22017-04-20 11:56:57 -040022
23#include <QWidget>
24
Andreas Traczyk43c08232018-10-31 13:42:09 -040025class ConversationsFilterWidget : public QWidget
26{
27 Q_OBJECT
28
29public:
30 explicit ConversationsFilterWidget(QWidget *parent = 0);
31
32protected:
33 void resizeEvent(QResizeEvent * event);
34
35private:
36 void updateNotifier(lrc::api::profile::Type typeFilter);
Andreas Traczykb8b13ba2018-08-21 16:30:16 -040037 void handleNotifierOverlay(const QString& buttonName,
38 SmartlistSelectorButtonNotifier*& notifier,
Andreas Traczyk43c08232018-10-31 13:42:09 -040039 lrc::api::profile::Type filter);
40 SmartlistSelectorButtonNotifier* unreadMessagesNotifier_{ nullptr };
41 SmartlistSelectorButtonNotifier* pendingInvitesNotifier_{ nullptr };
Andreas Traczykb8b13ba2018-08-21 16:30:16 -040042};