mirror of
https://github.com/Qz3rK/tdesktop.git
synced 2026-07-03 14:15:08 +02:00
Strict alignment request for base::lambda. Various improvements.
This commit is contained in:
@@ -419,7 +419,7 @@ void Widget::hideStop() {
|
||||
}
|
||||
}
|
||||
|
||||
void Widget::hideAnimated(float64 duration, anim::transition func) {
|
||||
void Widget::hideAnimated(float64 duration, const anim::transition &func) {
|
||||
_opacityDuration = duration;
|
||||
a_func = func;
|
||||
a_opacity.start(0);
|
||||
|
||||
@@ -152,7 +152,7 @@ protected:
|
||||
private:
|
||||
void destroyDelayed();
|
||||
void moveByShift();
|
||||
void hideAnimated(float64 duration, anim::transition func);
|
||||
void hideAnimated(float64 duration, const anim::transition &func);
|
||||
void step_opacity(float64 ms, bool timer);
|
||||
void step_shift(float64 ms, bool timer);
|
||||
|
||||
|
||||
@@ -25,7 +25,7 @@ Copyright (c) 2014-2016 John Preston, https://desktop.telegram.org
|
||||
|
||||
namespace Window {
|
||||
|
||||
PlayerWrapWidget::PlayerWrapWidget(QWidget *parent, base::lambda_unique<void()> updateCallback) : Parent(parent
|
||||
PlayerWrapWidget::PlayerWrapWidget(QWidget *parent, base::lambda<void()> &&updateCallback) : Parent(parent
|
||||
, new Media::Player::Widget(parent)
|
||||
, style::margins(0, 0, 0, 0)
|
||||
, std_::move(updateCallback)) {
|
||||
|
||||
@@ -13,7 +13,7 @@ class PlayerWrapWidget : public Ui::WidgetSlideWrap<Media::Player::Widget> {
|
||||
using Parent = Ui::WidgetSlideWrap<Media::Player::Widget>;
|
||||
|
||||
public:
|
||||
PlayerWrapWidget(QWidget *parent, base::lambda_unique<void()> updateCallback);
|
||||
PlayerWrapWidget(QWidget *parent, base::lambda<void()> &&updateCallback);
|
||||
|
||||
void updateAdaptiveLayout() {
|
||||
updateShadowGeometry();
|
||||
|
||||
@@ -35,10 +35,10 @@ public:
|
||||
void setPixmaps(const QPixmap &oldContentCache, const QPixmap &newContentCache);
|
||||
void setTopBarShadow(bool enabled);
|
||||
|
||||
using RepaintCallback = base::lambda_unique<void()>;
|
||||
using RepaintCallback = base::lambda<void()>;
|
||||
void setRepaintCallback(RepaintCallback &&callback);
|
||||
|
||||
using FinishedCallback = base::lambda_unique<void()>;
|
||||
using FinishedCallback = base::lambda<void()>;
|
||||
void setFinishedCallback(FinishedCallback &&callback);
|
||||
|
||||
void start();
|
||||
|
||||
@@ -126,7 +126,7 @@ void TopBarWidget::showMenu() {
|
||||
}
|
||||
});
|
||||
_menuToggle->installEventFilter(_menu);
|
||||
App::main()->fillPeerMenu(peer, [this](const QString &text, base::lambda_unique<void()> callback) {
|
||||
App::main()->fillPeerMenu(peer, [this](const QString &text, base::lambda<void()> &&callback) {
|
||||
return _menu->addAction(text, std_::move(callback));
|
||||
});
|
||||
_menu->moveToRight(st::topBarMenuPosition.x(), st::topBarMenuPosition.y());
|
||||
|
||||
@@ -33,7 +33,7 @@ class WarningWidget : public TWidget {
|
||||
public:
|
||||
WarningWidget(QWidget *parent);
|
||||
|
||||
void setHiddenCallback(base::lambda_unique<void()> callback) {
|
||||
void setHiddenCallback(base::lambda<void()> &&callback) {
|
||||
_hiddenCallback = std_::move(callback);
|
||||
}
|
||||
|
||||
@@ -65,7 +65,7 @@ private:
|
||||
ChildWidget<Ui::RoundButton> _keepChanges;
|
||||
ChildWidget<Ui::RoundButton> _revert;
|
||||
|
||||
base::lambda_unique<void()> _hiddenCallback;
|
||||
base::lambda<void()> _hiddenCallback;
|
||||
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user