/* This file is part of Telegram Desktop, the official desktop application for the Telegram messaging service. For license and copyright information please follow this link: https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL */ #include "info/profile/info_profile_actions.h" #include "data/data_peer_values.h" #include "data/data_session.h" #include "data/data_folder.h" #include "data/data_channel.h" #include "data/data_user.h" #include "ui/wrap/vertical_layout.h" #include "ui/wrap/padding_wrap.h" #include "ui/wrap/slide_wrap.h" #include "ui/widgets/shadow.h" #include "ui/widgets/labels.h" #include "ui/toast/toast.h" #include "ui/text/text_utilities.h" // Ui::Text::ToUpper #include "boxes/abstract_box.h" #include "boxes/confirm_box.h" #include "boxes/peer_list_box.h" #include "boxes/peer_list_controllers.h" #include "boxes/add_contact_box.h" #include "boxes/report_box.h" #include "boxes/generic_box.h" // window->show(Box(InitMethod())) #include "boxes/peers/edit_contact_box.h" #include "lang/lang_keys.h" #include "info/info_controller.h" #include "info/info_memento.h" #include "info/profile/info_profile_icon.h" #include "info/profile/info_profile_values.h" #include "info/profile/info_profile_button.h" #include "info/profile/info_profile_text.h" #include "support/support_helper.h" #include "window/window_session_controller.h" #include "window/window_controller.h" // Window::Controller::show. #include "window/window_peer_menu.h" #include "mainwidget.h" #include "mainwindow.h" // MainWindow::controller. #include "auth_session.h" #include "core/application.h" #include "apiwrap.h" #include "styles/style_info.h" #include "styles/style_boxes.h" namespace Info { namespace Profile { namespace { object_ptr CreateSkipWidget( not_null parent) { return Ui::CreateSkipWidget(parent, st::infoProfileSkip); } object_ptr> CreateSlideSkipWidget( not_null parent) { auto result = Ui::CreateSlideSkipWidget( parent, st::infoProfileSkip); result->setDuration(st::infoSlideDuration); return result; } template auto AddActionButton( not_null parent, Text &&text, ToggleOn &&toggleOn, Callback &&callback, const style::InfoProfileButton &st = st::infoSharedMediaButton) { auto result = parent->add(object_ptr>( parent, object_ptr