Add payment button icon to the corner.

This commit is contained in:
John Preston 2021-04-13 17:21:24 +04:00
parent 34c5ce16d0
commit 04c0d79ccc
11 changed files with 3 additions and 0 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 213 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 249 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 300 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 228 B

After

Width:  |  Height:  |  Size: 338 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 341 B

After

Width:  |  Height:  |  Size: 569 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 427 B

After

Width:  |  Height:  |  Size: 768 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 146 B

After

Width:  |  Height:  |  Size: 305 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 234 B

After

Width:  |  Height:  |  Size: 428 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 273 B

After

Width:  |  Height:  |  Size: 550 B

View File

@ -102,6 +102,7 @@ void KeyboardStyle::paintButtonIcon(
switch (type) {
case Type::Url:
case Type::Auth: return &st::msgBotKbUrlIcon;
case Type::Buy: return &st::msgBotKbPaymentIcon;
case Type::SwitchInlineSame:
case Type::SwitchInline: return &st::msgBotKbSwitchPmIcon;
}
@ -124,6 +125,7 @@ int KeyboardStyle::minButtonWidth(
switch (type) {
case Type::Url:
case Type::Auth: iconWidth = st::msgBotKbUrlIcon.width(); break;
case Type::Buy: iconWidth = st::msgBotKbPaymentIcon.width(); break;
case Type::SwitchInlineSame:
case Type::SwitchInline: iconWidth = st::msgBotKbSwitchPmIcon.width(); break;
case Type::Callback:

View File

@ -463,6 +463,7 @@ msgBotKbFont: semiboldFont;
msgBotKbIconPadding: 2px;
msgBotKbUrlIcon: icon {{ "inline_button_url", msgBotKbIconFg }};
msgBotKbSwitchPmIcon: icon {{ "inline_button_switch", msgBotKbIconFg }};
msgBotKbPaymentIcon: icon {{ "inline_button_card", msgBotKbIconFg }};
msgBotKbButton: BotKeyboardButton {
margin: 5px;
padding: 10px;