Attempt to fix the naturalWidth feature.
This commit is contained in:
@@ -4147,14 +4147,15 @@ void InnerWidget::refreshEmpty() {
|
||||
.name = u"no_chats"_q,
|
||||
.sizeOverride = Size(st::changePhoneIconSize),
|
||||
});
|
||||
_emptyList->add(
|
||||
object_ptr<Ui::CenterWrap<>>(_emptyList, std::move(icon.widget)));
|
||||
_emptyList->add(std::move(icon.widget), {}, style::al_top);
|
||||
Ui::AddSkip(_emptyList);
|
||||
_emptyList->add(
|
||||
object_ptr<Ui::FlatLabel>(
|
||||
_emptyList,
|
||||
tr::lng_no_conversations(),
|
||||
st::dialogEmptyButtonLabel));
|
||||
st::dialogEmptyButtonLabel),
|
||||
{},
|
||||
style::al_top);
|
||||
if (_state == WidgetState::Default) {
|
||||
icon.animate(anim::repeat::once);
|
||||
}
|
||||
|
||||
@@ -170,30 +170,32 @@ void PostsSearchIntro::setup() {
|
||||
_content.get(),
|
||||
std::move(title),
|
||||
st::postsSearchIntroTitle),
|
||||
st::postsSearchIntroTitleMargin);
|
||||
st::postsSearchIntroTitleMargin,
|
||||
style::al_top);
|
||||
_title->setTryMakeSimilarLines(true);
|
||||
_subtitle = _content->add(
|
||||
object_ptr<Ui::FlatLabel>(
|
||||
_content.get(),
|
||||
std::move(subtitle),
|
||||
st::postsSearchIntroSubtitle),
|
||||
st::postsSearchIntroSubtitleMargin);
|
||||
st::postsSearchIntroSubtitleMargin,
|
||||
style::al_top);
|
||||
_subtitle->setTryMakeSimilarLines(true);
|
||||
_button = _content->add(
|
||||
object_ptr<Ui::CenterWrap<Ui::RoundButton>>(
|
||||
object_ptr<Ui::RoundButton>(
|
||||
_content.get(),
|
||||
object_ptr<Ui::RoundButton>(
|
||||
_content.get(),
|
||||
rpl::single(QString()),
|
||||
st::postsSearchIntroButton))
|
||||
)->entity();
|
||||
rpl::single(QString()),
|
||||
st::postsSearchIntroButton),
|
||||
{},
|
||||
style::al_top);
|
||||
_button->setTextTransform(Ui::RoundButton::TextTransform::NoTransform);
|
||||
_footer = _content->add(
|
||||
object_ptr<Ui::FlatLabel>(
|
||||
_content.get(),
|
||||
std::move(footer),
|
||||
st::postsSearchIntroFooter),
|
||||
st::postsSearchIntroFooterMargin);
|
||||
st::postsSearchIntroFooterMargin,
|
||||
style::al_top);
|
||||
_footer->setTryMakeSimilarLines(true);
|
||||
|
||||
_state.value(
|
||||
|
||||
Reference in New Issue
Block a user