mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-04-18 23:27:09 +02:00
Improve top bar icons layout.
This commit is contained in:
parent
b6483cb65c
commit
d69caacded
3 changed files with 6 additions and 5 deletions
|
@ -647,7 +647,8 @@ void TopBarWidget::updateControlsGeometry() {
|
|||
}
|
||||
_infoToggle->moveToRight(_rightTaken, otherButtonsTop);
|
||||
if (!_infoToggle->isHidden()) {
|
||||
_rightTaken += _infoToggle->width() + st::topBarSkip;
|
||||
_infoToggle->moveToRight(_rightTaken, otherButtonsTop);
|
||||
_rightTaken += _infoToggle->width();
|
||||
}
|
||||
if (!_call->isHidden() || !_groupCall->isHidden()) {
|
||||
_call->moveToRight(_rightTaken, otherButtonsTop);
|
||||
|
|
|
@ -748,7 +748,7 @@ topBarSearch: IconButton {
|
|||
color: windowBgOver;
|
||||
}
|
||||
}
|
||||
topBarSkip: -2px;
|
||||
topBarSkip: -5px;
|
||||
topBarCallSkip: -1px;
|
||||
topBarMenuToggle: IconButton(topBarSearch) {
|
||||
width: 44px;
|
||||
|
@ -766,7 +766,7 @@ topBarCall: IconButton(topBarSearch) {
|
|||
topBarGroupCall: IconButton(topBarSearch) {
|
||||
icon: icon {{ "top_bar_group_call", menuIconFg }};
|
||||
iconOver: icon {{ "top_bar_group_call", menuIconFgOver }};
|
||||
iconPosition: point(8px, 15px);
|
||||
iconPosition: point(8px, 16px);
|
||||
}
|
||||
topBarInfo: IconButton(topBarSearch) {
|
||||
icon: icon {{ "top_bar_profile", menuIconFg }};
|
||||
|
|
|
@ -473,10 +473,10 @@ void Generator::paintTopBar() {
|
|||
|
||||
auto right = st::topBarMenuToggle.width;
|
||||
st::topBarMenuToggle.icon[_palette].paint(*_p, _topBar.x() + _topBar.width() - right + st::topBarMenuToggle.iconPosition.x(), _topBar.y() + st::topBarMenuToggle.iconPosition.y(), _rect.width());
|
||||
right += st::topBarSkip + st::topBarCall.width;
|
||||
st::topBarCall.icon[_palette].paint(*_p, _topBar.x() + _topBar.width() - right + st::topBarCall.iconPosition.x(), _topBar.y() + st::topBarCall.iconPosition.y(), _rect.width());
|
||||
right += st::topBarSearch.width;
|
||||
st::topBarSearch.icon[_palette].paint(*_p, _topBar.x() + _topBar.width() - right + st::topBarSearch.iconPosition.x(), _topBar.y() + st::topBarSearch.iconPosition.y(), _rect.width());
|
||||
right += st::topBarCallSkip + st::topBarCall.width;
|
||||
st::topBarCall.icon[_palette].paint(*_p, _topBar.x() + _topBar.width() - right + st::topBarCall.iconPosition.x(), _topBar.y() + st::topBarCall.iconPosition.y(), _rect.width());
|
||||
|
||||
auto decreaseWidth = st::topBarCall.width + st::topBarCallSkip + st::topBarSearch.width + st::topBarMenuToggle.width;
|
||||
auto nameleft = _topBar.x() + st::topBarArrowPadding.right();
|
||||
|
|
Loading…
Add table
Reference in a new issue