2017-08-12 07:17:33 +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.
|
2017-08-12 07:17:33 +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
|
2017-08-12 07:17:33 +00:00
|
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
inline MTPbool MTP_bool(bool v) {
|
|
|
|
return v ? MTP_boolTrue() : MTP_boolFalse();
|
|
|
|
}
|
|
|
|
|
|
|
|
inline bool mtpIsTrue(const MTPBool &v) {
|
|
|
|
return v.type() == mtpc_boolTrue;
|
|
|
|
}
|
|
|
|
inline bool mtpIsFalse(const MTPBool &v) {
|
|
|
|
return !mtpIsTrue(v);
|
|
|
|
}
|