Merge commit 'ff0c727ee2129b66a2908e46edc3bc9f7774e834'
This commit is contained in:
commit
e022963e1e
@ -385,12 +385,15 @@ function onOptionsChanged() {
|
||||
}
|
||||
|
||||
var low_memory = false;
|
||||
if (os_linux || os_freebsd || os_openbsd || os_netbsd) {
|
||||
if (os_linux || os_freebsd || os_netbsd) {
|
||||
low_memory = document.getElementById('buildLowMemoryCheckbox').checked;
|
||||
document.getElementById('buildLowMemoryText').innerHTML = 'I have less than ' + (use_clang ? '1.5' : '3.5') +' GB of RAM.' +
|
||||
(low_memory ? ' Now you will need only ' + (use_clang ? '0.5' : '1') +' GB of RAM to build TDLib.' : '');
|
||||
document.getElementById('buildLowMemoryDiv').style.display = 'block';
|
||||
} else {
|
||||
if (os_openbsd) {
|
||||
low_memory = true;
|
||||
}
|
||||
document.getElementById('buildLowMemoryDiv').style.display = 'none';
|
||||
}
|
||||
|
||||
|
@ -70,4 +70,10 @@ bool is_service_message_content(MessageContentType content_type);
|
||||
|
||||
bool can_have_message_content_caption(MessageContentType content_type);
|
||||
|
||||
struct MessageContentTypeHash {
|
||||
std::size_t operator()(MessageContentType content_type) const {
|
||||
return std::hash<int32>()(static_cast<int32>(content_type));
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace td
|
||||
|
@ -1922,7 +1922,7 @@ class SearchMessagesQuery : public Td::ResultHandler {
|
||||
send_query(G()->net_query_creator().create(
|
||||
telegram_api::messages_getUnreadMentions(std::move(input_peer), from_message_id.get_server_message_id().get(),
|
||||
offset, limit, std::numeric_limits<int32>::max(), 0)));
|
||||
} else if (top_thread_message_id.is_valid() && !sender_dialog_id.is_valid() &&
|
||||
} else if (top_thread_message_id.is_valid() && query.empty() && !sender_dialog_id.is_valid() &&
|
||||
filter == MessageSearchFilter::Empty) {
|
||||
handle_errors_ = dialog_id.get_type() != DialogType::Channel ||
|
||||
td->contacts_manager_->get_channel_type(dialog_id.get_channel_id()) != ChannelType::Broadcast;
|
||||
@ -23227,7 +23227,7 @@ Result<vector<MessageId>> MessagesManager::send_message_group(
|
||||
TRY_RESULT(message_send_options, process_message_send_options(dialog_id, std::move(options)));
|
||||
|
||||
vector<std::pair<unique_ptr<MessageContent>, int32>> message_contents;
|
||||
std::unordered_set<MessageContentType> message_content_types;
|
||||
std::unordered_set<MessageContentType, MessageContentTypeHash> message_content_types;
|
||||
for (auto &input_message_content : input_message_contents) {
|
||||
TRY_RESULT(message_content, process_input_message_content(dialog_id, std::move(input_message_content)));
|
||||
TRY_STATUS(can_use_message_send_options(message_send_options, message_content));
|
||||
|
@ -52,7 +52,7 @@
|
||||
using namespace td;
|
||||
|
||||
struct CheckExitGuard {
|
||||
explicit CheckExitGuard(bool expected_value): expected_value_(expected_value) {
|
||||
explicit CheckExitGuard(bool expected_value) : expected_value_(expected_value) {
|
||||
}
|
||||
CheckExitGuard(CheckExitGuard &&) = delete;
|
||||
CheckExitGuard &operator=(CheckExitGuard &&) = delete;
|
||||
|
Loading…
Reference in New Issue
Block a user