diff --git a/Telegram/SourceFiles/api/api_chat_invite.cpp b/Telegram/SourceFiles/api/api_chat_invite.cpp index e7e9d1bc1a..059cbfc850 100644 --- a/Telegram/SourceFiles/api/api_chat_invite.cpp +++ b/Telegram/SourceFiles/api/api_chat_invite.cpp @@ -39,6 +39,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL #include "window/window_session_controller.h" #include "styles/style_boxes.h" #include "styles/style_chat_helpers.h" +#include "styles/style_color_indices.h" #include "styles/style_credits.h" #include "styles/style_info.h" #include "styles/style_layers.h" @@ -263,7 +264,7 @@ void ConfirmSubscriptionBox( } } else { state->photoEmpty = std::make_unique( - Ui::EmptyUserpic::UserpicColor(0), + Ui::EmptyUserpic::UserpicColor(st::colorIndexRed), name); } Ui::AddSkip(content); @@ -502,7 +503,7 @@ void ConfirmInviteBox( } } else { state->photoEmpty = std::make_unique( - Ui::EmptyUserpic::UserpicColor(0), + Ui::EmptyUserpic::UserpicColor(st::colorIndexRed), invite.title); } diff --git a/Telegram/SourceFiles/info/statistics/info_statistics_list_controllers.cpp b/Telegram/SourceFiles/info/statistics/info_statistics_list_controllers.cpp index ab04d9b938..b63a7b4975 100644 --- a/Telegram/SourceFiles/info/statistics/info_statistics_list_controllers.cpp +++ b/Telegram/SourceFiles/info/statistics/info_statistics_list_controllers.cpp @@ -485,7 +485,7 @@ private: BoostRow::BoostRow(not_null peer, const Data::Boost &boost) : PeerListRow(peer, UniqueRowIdFromString(boost.id)) , _boost(boost) -, _userpic(Ui::EmptyUserpic::UserpicColor(0), QString()) { +, _userpic(Ui::EmptyUserpic::UserpicColor(st::colorIndexRed), QString()) { init(); } diff --git a/Telegram/SourceFiles/ui/chat/sponsored_message_bar.cpp b/Telegram/SourceFiles/ui/chat/sponsored_message_bar.cpp index ce3f4c0213..4218ae0063 100644 --- a/Telegram/SourceFiles/ui/chat/sponsored_message_bar.cpp +++ b/Telegram/SourceFiles/ui/chat/sponsored_message_bar.cpp @@ -32,6 +32,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL #include "window/window_session_controller.h" #include "styles/style_chat.h" #include "styles/style_chat_helpers.h" +#include "styles/style_color_indices.h" #include "styles/style_dialogs.h" namespace Ui { @@ -265,7 +266,7 @@ void FillSponsoredMessageBar( GenerateReplyColorCallback( widget, fullId, - from.colorIndex ? from.colorIndex : 4/*blue*/)); + from.colorIndex ? from.colorIndex : st::colorIndexBlue)); badgeButton->setClickedCallback( hostedClick(from.canReport ? AboutSponsoredClickHandler() diff --git a/Telegram/SourceFiles/ui/color_indices.style b/Telegram/SourceFiles/ui/color_indices.style index 3acd347ab1..59e80ec965 100644 --- a/Telegram/SourceFiles/ui/color_indices.style +++ b/Telegram/SourceFiles/ui/color_indices.style @@ -6,11 +6,11 @@ For license and copyright information please follow this link: https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL */ -colorIndexRed: 0; -colorIndexOrange: 1; -colorIndexGreen: 2; -colorIndexSea: 3; -colorIndexBlue: 4; -colorIndexPurple: 5; -colorIndexPink: 6; -colorIndexYellow: 7; +colorIndexRed: 0; // [[maybe_unused]] +colorIndexOrange: 1; // [[maybe_unused]] +colorIndexGreen: 2; // [[maybe_unused]] +colorIndexSea: 3; // [[maybe_unused]] +colorIndexBlue: 4; // [[maybe_unused]] +colorIndexPurple: 5; // [[maybe_unused]] +colorIndexPink: 6; // [[maybe_unused]] +colorIndexYellow: 7; // [[maybe_unused]] diff --git a/Telegram/SourceFiles/ui/effects/credits_graphics.cpp b/Telegram/SourceFiles/ui/effects/credits_graphics.cpp index abf7a7965a..bfb0373888 100644 --- a/Telegram/SourceFiles/ui/effects/credits_graphics.cpp +++ b/Telegram/SourceFiles/ui/effects/credits_graphics.cpp @@ -33,6 +33,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL #include "ui/wrap/padding_wrap.h" #include "ui/wrap/vertical_layout.h" #include "styles/style_channel_earn.h" +#include "styles/style_color_indices.h" #include "styles/style_credits.h" #include "styles/style_dialogs.h" #include "styles/style_intro.h" // introFragmentIcon. @@ -233,7 +234,7 @@ PaintRoundImageCallback GenerateCreditsPaintUserpicCallback( case Data::CreditsHistoryEntry::PeerType::API: return { st::historyPeer2UserpicBg, st::historyPeer2UserpicBg2 }; case Data::CreditsHistoryEntry::PeerType::Peer: - return EmptyUserpic::UserpicColor(0); + return EmptyUserpic::UserpicColor(st::colorIndexRed); case Data::CreditsHistoryEntry::PeerType::AppStore: return { st::historyPeer7UserpicBg, st::historyPeer7UserpicBg2 }; case Data::CreditsHistoryEntry::PeerType::PlayMarket: