2014-05-30 08:53:19 +00:00
|
|
|
/*
|
|
|
|
This file is part of Telegram Desktop,
|
2018-01-03 10:23:14 +00:00
|
|
|
the official desktop application for the Telegram messaging service.
|
2014-05-30 08:53:19 +00:00
|
|
|
|
2018-01-03 10:23:14 +00:00
|
|
|
For license and copyright information please follow this link:
|
|
|
|
https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
|
2014-05-30 08:53:19 +00:00
|
|
|
*/
|
2016-03-24 08:57:11 +00:00
|
|
|
|
2014-05-30 08:53:19 +00:00
|
|
|
#define __HUGE
|
2016-04-14 13:03:03 +00:00
|
|
|
|
|
|
|
// Fix Google Breakpad build for Mac App Store version
|
|
|
|
#ifdef Q_OS_MAC
|
|
|
|
#define __STDC_FORMAT_MACROS
|
|
|
|
#endif // Q_OS_MAC
|
2016-02-01 10:12:37 +00:00
|
|
|
|
|
|
|
#ifdef __cplusplus
|
2016-01-21 06:58:58 +00:00
|
|
|
|
2016-04-01 08:50:02 +00:00
|
|
|
#include <cmath>
|
|
|
|
|
2016-04-14 13:03:03 +00:00
|
|
|
// False positive warning in clang for QMap member function value:
|
|
|
|
// const T QMap<Key, T>::value(const Key &akey, const T &adefaultValue)
|
|
|
|
// fires with "Returning address of local temporary object" which is not true.
|
|
|
|
#ifdef __clang__
|
|
|
|
#pragma clang diagnostic push
|
|
|
|
#pragma clang diagnostic ignored "-Wreturn-stack-address"
|
2018-05-10 08:13:13 +00:00
|
|
|
#elif defined _MSC_VER && _MSC_VER >= 1914 // __clang__
|
|
|
|
#pragma warning(push)
|
|
|
|
#pragma warning(disable:4180)
|
|
|
|
#endif // __clang__ || _MSC_VER >= 1914
|
2016-04-14 13:03:03 +00:00
|
|
|
|
2016-02-27 19:39:51 +00:00
|
|
|
#include <QtCore/QtCore>
|
2016-04-14 13:03:03 +00:00
|
|
|
|
|
|
|
#ifdef __clang__
|
|
|
|
#pragma clang diagnostic pop
|
2018-05-10 08:13:13 +00:00
|
|
|
#elif defined _MSC_VER && _MSC_VER >= 1914 // __clang__
|
|
|
|
#pragma warning(pop)
|
|
|
|
#endif // __clang__ || _MSC_VER >= 1914
|
2016-04-14 13:03:03 +00:00
|
|
|
|
2016-08-31 17:58:46 +00:00
|
|
|
#ifdef OS_MAC_STORE
|
|
|
|
#define MAC_USE_BREAKPAD
|
|
|
|
#endif // OS_MAC_STORE
|
|
|
|
|
2014-05-30 08:53:19 +00:00
|
|
|
#include <QtWidgets/QtWidgets>
|
2016-02-27 19:39:51 +00:00
|
|
|
#include <QtNetwork/QtNetwork>
|
2014-05-30 08:53:19 +00:00
|
|
|
|
2017-08-13 16:17:16 +00:00
|
|
|
#include <array>
|
|
|
|
#include <vector>
|
|
|
|
#include <set>
|
|
|
|
#include <map>
|
2018-01-25 14:19:14 +00:00
|
|
|
#include <unordered_map>
|
2018-04-09 17:48:29 +00:00
|
|
|
#include <unordered_set>
|
2017-08-13 16:17:16 +00:00
|
|
|
#include <algorithm>
|
|
|
|
#include <memory>
|
2018-09-21 16:28:46 +00:00
|
|
|
#include <optional>
|
2017-11-24 21:05:14 +00:00
|
|
|
|
2017-11-19 14:37:07 +00:00
|
|
|
#include <range/v3/all.hpp>
|
2017-08-17 09:06:26 +00:00
|
|
|
|
|
|
|
// Ensures/Expects.
|
|
|
|
#include <gsl/gsl_assert>
|
|
|
|
|
|
|
|
// Redefine Ensures/Expects by our own assertions.
|
|
|
|
#include "base/assertion.h"
|
|
|
|
|
2017-08-13 16:17:16 +00:00
|
|
|
#include <gsl/gsl>
|
2017-09-20 18:40:23 +00:00
|
|
|
#include <rpl/rpl.h>
|
2017-12-17 18:41:34 +00:00
|
|
|
#include <crl/crl.h>
|
2017-09-20 18:40:23 +00:00
|
|
|
|
2017-08-14 12:47:46 +00:00
|
|
|
#include "base/variant.h"
|
2017-08-14 10:38:23 +00:00
|
|
|
#include "base/optional.h"
|
2017-08-14 12:47:46 +00:00
|
|
|
#include "base/algorithm.h"
|
2017-09-04 11:40:02 +00:00
|
|
|
#include "base/flat_set.h"
|
|
|
|
#include "base/flat_map.h"
|
2018-06-04 15:35:11 +00:00
|
|
|
#include "base/weak_ptr.h"
|
2017-09-04 11:40:02 +00:00
|
|
|
|
2018-07-30 20:34:23 +00:00
|
|
|
#include "base/basic_types.h"
|
2016-09-29 11:37:16 +00:00
|
|
|
#include "logs.h"
|
|
|
|
#include "core/utils.h"
|
2014-05-30 08:53:19 +00:00
|
|
|
#include "config.h"
|
|
|
|
|
2016-03-23 18:43:12 +00:00
|
|
|
#include "mtproto/facade.h"
|
2014-05-30 08:53:19 +00:00
|
|
|
|
2016-04-21 17:57:29 +00:00
|
|
|
#include "ui/style/style_core.h"
|
2016-10-28 12:44:28 +00:00
|
|
|
#include "styles/palette.h"
|
2016-04-21 17:57:29 +00:00
|
|
|
#include "styles/style_basic.h"
|
|
|
|
|
2016-04-07 18:05:28 +00:00
|
|
|
#include "ui/animation.h"
|
2016-11-07 11:24:19 +00:00
|
|
|
#include "ui/twidget.h"
|
2018-10-23 09:44:42 +00:00
|
|
|
#include "ui/image/image_location.h"
|
2016-04-14 11:00:23 +00:00
|
|
|
#include "ui/text/text.h"
|
2014-05-30 08:53:19 +00:00
|
|
|
|
2017-09-26 11:49:16 +00:00
|
|
|
#include "data/data_types.h"
|
2014-05-30 08:53:19 +00:00
|
|
|
#include "app.h"
|
2016-05-31 09:46:31 +00:00
|
|
|
#include "facades.h"
|
2016-02-01 10:12:37 +00:00
|
|
|
|
2016-03-24 12:57:10 +00:00
|
|
|
#endif // __cplusplus
|