qTox  Version: nightly | Commit: bc751c8e1cac455f9690654fcfe0f560d2d7dfdd
status.h
Go to the documentation of this file.
1 /*
2  Copyright © 2019 by The qTox Project Contributors
3 
4  This file is part of qTox, a Qt-based graphical interface for Tox.
5 
6  qTox is libre software: you can redistribute it and/or modify
7  it under the terms of the GNU General Public License as published by
8  the Free Software Foundation, either version 3 of the License, or
9  (at your option) any later version.
10 
11  qTox is distributed in the hope that it will be useful,
12  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  GNU General Public License for more details.
15 
16  You should have received a copy of the GNU General Public License
17  along with qTox. If not, see <http://www.gnu.org/licenses/>.
18 */
19 
20 #include <QString>
21 #include <QPixmap>
22 
23 #pragma once
24 
25 namespace Status
26 {
27  // Status::Status is weird, but Status is a fitting name for both the namespace and enum class..
28  enum class Status
29  {
30  Online = 0,
31  Away,
32  Busy,
33  Offline,
34  Blocked,
36  };
37 
38  QString getIconPath(Status status, bool event = false);
39  QString getTitle(Status status);
40  QString getAssetSuffix(Status status);
41  bool isOnline(Status status);
42 }
Status::Status::Offline
@ Offline
Status::Status::Busy
@ Busy
Status::getIconPath
QString getIconPath(Status status, bool event)
Definition: status.cpp:72
Status::Status::Online
@ Online
Status
Definition: status.cpp:29
Status::Status::Blocked
@ Blocked
Status::Status::Away
@ Away
Status::getTitle
QString getTitle(Status status)
Definition: status.cpp:31
Status::Status::Negotiating
@ Negotiating
Status::getAssetSuffix
QString getAssetSuffix(Status status)
Definition: status.cpp:52
Status::isOnline
bool isOnline(Status status)
Definition: status.cpp:83