2018-12-31 20:04:05 +01:00
|
|
|
//
|
2022-12-31 22:28:08 +01:00
|
|
|
// Copyright Aliaksei Levin (levlam@telegram.org), Arseny Smirnov (arseny30@gmail.com) 2014-2023
|
2018-12-31 20:04:05 +01:00
|
|
|
//
|
|
|
|
// Distributed under the Boost Software License, Version 1.0. (See accompanying
|
|
|
|
// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
|
|
|
//
|
|
|
|
#pragma once
|
|
|
|
|
2021-09-08 23:05:59 +02:00
|
|
|
#include "td/utils/common.h"
|
|
|
|
|
2018-12-31 20:04:05 +01:00
|
|
|
namespace td {
|
|
|
|
|
2023-04-25 13:27:58 +02:00
|
|
|
constexpr int32 MTPROTO_LAYER = 159;
|
2019-08-15 17:16:09 +02:00
|
|
|
|
2018-12-31 20:04:05 +01:00
|
|
|
enum class Version : int32 {
|
2020-07-27 16:52:21 +02:00
|
|
|
Initial, // 0
|
2018-12-31 20:04:05 +01:00
|
|
|
StoreFileId,
|
|
|
|
AddKeyHashToSecretChat,
|
|
|
|
AddDurationToAnimation,
|
|
|
|
FixStoreGameWithoutAnimation,
|
2020-07-27 16:52:21 +02:00
|
|
|
AddAccessHashToSecretChat, // 5
|
2018-12-31 20:04:05 +01:00
|
|
|
StoreFileOwnerId,
|
|
|
|
StoreFileEncryptionKey,
|
|
|
|
NetStatsCountDuration,
|
|
|
|
FixWebPageInstantViewDatabase,
|
2020-07-27 16:52:21 +02:00
|
|
|
FixMinUsers, // 10
|
2018-12-31 20:04:05 +01:00
|
|
|
FixPageBlockAudioEmptyFile,
|
|
|
|
AddMessageInvoiceProviderData,
|
2018-01-30 18:06:54 +01:00
|
|
|
AddCaptionEntities,
|
2018-04-09 20:06:37 +02:00
|
|
|
AddVenueType,
|
2020-07-27 16:52:21 +02:00
|
|
|
AddTermsOfService, // 15
|
2018-06-25 23:10:53 +02:00
|
|
|
AddContactVcard,
|
2018-12-25 18:47:37 +01:00
|
|
|
AddMessageUnsupportedVersion,
|
2019-02-06 19:00:00 +01:00
|
|
|
SupportInstantView2_0,
|
2019-04-02 00:05:31 +02:00
|
|
|
AddNotificationGroupInfoMaxRemovedMessageId,
|
2020-08-10 17:37:03 +02:00
|
|
|
SupportMinithumbnails, // 20
|
2019-06-08 11:26:35 +02:00
|
|
|
AddVideoCallsSupport,
|
2019-06-12 13:42:06 +02:00
|
|
|
AddPhotoSizeSource,
|
2019-08-26 19:08:51 +02:00
|
|
|
AddFolders,
|
2020-01-11 01:46:26 +01:00
|
|
|
SupportPolls2_0,
|
2020-07-27 16:52:21 +02:00
|
|
|
AddDiceEmoji, // 25
|
2020-05-29 10:51:51 +02:00
|
|
|
AddAnimationStickers,
|
2020-07-08 21:59:31 +02:00
|
|
|
AddDialogPhotoHasAnimation,
|
2020-08-25 14:09:24 +02:00
|
|
|
AddPhotoProgressiveSizes,
|
2020-10-16 22:08:28 +02:00
|
|
|
AddLiveLocationHeading,
|
2020-10-29 20:25:58 +01:00
|
|
|
AddLiveLocationProximityAlertDistance, // 30
|
2021-03-22 02:03:24 +01:00
|
|
|
SupportBannedChannels,
|
2021-04-16 16:43:51 +02:00
|
|
|
RemovePhotoVolumeAndLocalId,
|
2021-09-03 11:27:59 +02:00
|
|
|
Support64BitIds,
|
2021-10-09 14:04:17 +02:00
|
|
|
AddInviteLinksRequiringApproval,
|
2021-11-10 15:14:00 +01:00
|
|
|
AddKeyboardButtonFlags, // 35
|
2022-04-15 14:30:51 +02:00
|
|
|
AddAudioFlags,
|
2022-05-08 22:54:04 +02:00
|
|
|
UseServerForwardAsCopy,
|
2022-05-19 15:57:11 +02:00
|
|
|
AddMainDialogListPosition,
|
2022-05-25 18:24:40 +02:00
|
|
|
AddVoiceNoteFlags,
|
2022-06-03 15:33:49 +02:00
|
|
|
AddMessageStickerFlags, // 40
|
2022-06-17 18:16:17 +02:00
|
|
|
AddStickerSetListFlags,
|
2022-09-16 16:08:58 +02:00
|
|
|
AddInputInvoiceFlags,
|
2022-10-20 19:35:00 +02:00
|
|
|
AddVideoNoteFlags,
|
2022-11-29 12:02:05 +01:00
|
|
|
AddMessageChatSetTtlFlags,
|
2023-01-06 11:43:46 +01:00
|
|
|
AddMessageMediaSpoiler, // 45
|
|
|
|
MakeParticipantFlags64Bit,
|
2023-02-21 12:58:52 +01:00
|
|
|
AddDocumentFlags,
|
2018-12-31 20:04:05 +01:00
|
|
|
Next
|
|
|
|
};
|
|
|
|
|
|
|
|
enum class DbVersion : int32 {
|
|
|
|
DialogDbCreated = 3,
|
2022-11-09 18:35:22 +01:00
|
|
|
MessageDbMediaIndex,
|
|
|
|
MessageDb30MediaIndex,
|
|
|
|
MessageDbFts,
|
2018-12-31 20:04:05 +01:00
|
|
|
MessagesCallIndex,
|
|
|
|
FixFileRemoteLocationKeyBug,
|
2018-11-28 18:18:50 +01:00
|
|
|
AddNotificationsSupport,
|
2019-08-26 19:08:51 +02:00
|
|
|
AddFolders,
|
2019-12-02 01:33:35 +01:00
|
|
|
AddScheduledMessages,
|
2020-05-03 00:10:54 +02:00
|
|
|
StorePinnedDialogsInBinlog,
|
2020-09-28 14:13:25 +02:00
|
|
|
AddMessageThreadSupport,
|
2022-11-10 17:46:17 +01:00
|
|
|
AddMessageThreadDatabase,
|
2018-12-31 20:04:05 +01:00
|
|
|
Next
|
|
|
|
};
|
|
|
|
|
2018-10-08 15:29:44 +02:00
|
|
|
inline constexpr int32 current_db_version() {
|
2018-12-31 20:04:05 +01:00
|
|
|
return static_cast<int32>(DbVersion::Next) - 1;
|
|
|
|
}
|
|
|
|
|
|
|
|
} // namespace td
|