Add max_video_upload_bitrate to autoDownloadSettings.
GitOrigin-RevId: dc443eae2066c85194efa9d338b5a498be8ffc12
This commit is contained in:
parent
7666c8a07f
commit
48f5681dfd
@ -2579,7 +2579,8 @@ networkStatistics since_date:int32 entries:vector<NetworkStatisticsEntry> = Netw
|
|||||||
//@preload_large_videos True, if the beginning of videos needs to be preloaded for instant playback
|
//@preload_large_videos True, if the beginning of videos needs to be preloaded for instant playback
|
||||||
//@preload_next_audio True, if the next audio track needs to be preloaded while the user is listening to an audio file
|
//@preload_next_audio True, if the next audio track needs to be preloaded while the user is listening to an audio file
|
||||||
//@use_less_data_for_calls True, if "use less data for calls" option needs to be enabled
|
//@use_less_data_for_calls True, if "use less data for calls" option needs to be enabled
|
||||||
autoDownloadSettings is_auto_download_enabled:Bool max_photo_file_size:int32 max_video_file_size:int32 max_other_file_size:int32 preload_large_videos:Bool preload_next_audio:Bool use_less_data_for_calls:Bool = AutoDownloadSettings;
|
//@max_video_upload_bitrate Maximum suggested bitrate for uploaded videos
|
||||||
|
autoDownloadSettings is_auto_download_enabled:Bool max_photo_file_size:int32 max_video_file_size:int32 max_other_file_size:int32 max_video_upload_bitrate:int32 preload_large_videos:Bool preload_next_audio:Bool use_less_data_for_calls:Bool = AutoDownloadSettings;
|
||||||
|
|
||||||
//@description Contains auto-download settings presets for the user
|
//@description Contains auto-download settings presets for the user
|
||||||
//@low Preset with lowest settings; supposed to be used by default when roaming
|
//@low Preset with lowest settings; supposed to be used by default when roaming
|
||||||
|
Binary file not shown.
@ -26,8 +26,8 @@ static td_api::object_ptr<td_api::autoDownloadSettings> convert_auto_download_se
|
|||||||
auto audio_preload_next = (flags & telegram_api::autoDownloadSettings::AUDIO_PRELOAD_NEXT_MASK) != 0;
|
auto audio_preload_next = (flags & telegram_api::autoDownloadSettings::AUDIO_PRELOAD_NEXT_MASK) != 0;
|
||||||
auto phonecalls_less_data = (flags & telegram_api::autoDownloadSettings::PHONECALLS_LESS_DATA_MASK) != 0;
|
auto phonecalls_less_data = (flags & telegram_api::autoDownloadSettings::PHONECALLS_LESS_DATA_MASK) != 0;
|
||||||
return td_api::make_object<td_api::autoDownloadSettings>(
|
return td_api::make_object<td_api::autoDownloadSettings>(
|
||||||
!disabled, settings->photo_size_max_, settings->video_size_max_, settings->file_size_max_, video_preload_large,
|
!disabled, settings->photo_size_max_, settings->video_size_max_, settings->file_size_max_,
|
||||||
audio_preload_next, phonecalls_less_data);
|
settings->video_upload_maxbitrate_, video_preload_large, audio_preload_next, phonecalls_less_data);
|
||||||
}
|
}
|
||||||
|
|
||||||
class GetAutoDownloadSettingsQuery : public Td::ResultHandler {
|
class GetAutoDownloadSettingsQuery : public Td::ResultHandler {
|
||||||
@ -76,7 +76,7 @@ telegram_api::object_ptr<telegram_api::autoDownloadSettings> get_input_auto_down
|
|||||||
}
|
}
|
||||||
return telegram_api::make_object<telegram_api::autoDownloadSettings>(
|
return telegram_api::make_object<telegram_api::autoDownloadSettings>(
|
||||||
flags, false /*ignored*/, false /*ignored*/, false /*ignored*/, false /*ignored*/, settings.max_photo_file_size,
|
flags, false /*ignored*/, false /*ignored*/, false /*ignored*/, false /*ignored*/, settings.max_photo_file_size,
|
||||||
settings.max_video_file_size, settings.max_other_file_size, 0);
|
settings.max_video_file_size, settings.max_other_file_size, settings.max_video_upload_bitrate);
|
||||||
}
|
}
|
||||||
|
|
||||||
class SaveAutoDownloadSettingsQuery : public Td::ResultHandler {
|
class SaveAutoDownloadSettingsQuery : public Td::ResultHandler {
|
||||||
@ -119,6 +119,7 @@ AutoDownloadSettings get_auto_download_settings(const td_api::object_ptr<td_api:
|
|||||||
result.max_photo_file_size = settings->max_photo_file_size_;
|
result.max_photo_file_size = settings->max_photo_file_size_;
|
||||||
result.max_video_file_size = settings->max_video_file_size_;
|
result.max_video_file_size = settings->max_video_file_size_;
|
||||||
result.max_other_file_size = settings->max_other_file_size_;
|
result.max_other_file_size = settings->max_other_file_size_;
|
||||||
|
result.max_video_upload_bitrate = settings->max_video_upload_bitrate_;
|
||||||
result.is_enabled = settings->is_auto_download_enabled_;
|
result.is_enabled = settings->is_auto_download_enabled_;
|
||||||
result.preload_large_videos = settings->preload_large_videos_;
|
result.preload_large_videos = settings->preload_large_videos_;
|
||||||
result.preload_next_audio = settings->preload_next_audio_;
|
result.preload_next_audio = settings->preload_next_audio_;
|
||||||
|
@ -22,6 +22,7 @@ class AutoDownloadSettings {
|
|||||||
int32 max_photo_file_size = 0;
|
int32 max_photo_file_size = 0;
|
||||||
int32 max_video_file_size = 0;
|
int32 max_video_file_size = 0;
|
||||||
int32 max_other_file_size = 0;
|
int32 max_other_file_size = 0;
|
||||||
|
int32 max_video_upload_bitrate = 0;
|
||||||
bool is_enabled = false;
|
bool is_enabled = false;
|
||||||
bool preload_large_videos = false;
|
bool preload_large_videos = false;
|
||||||
bool preload_next_audio = false;
|
bool preload_next_audio = false;
|
||||||
|
Loading…
Reference in New Issue
Block a user