mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-08-31 14:45:14 +00:00
Improve info wrapping in section / layer.
Also move layerwidget to window/layer_widget. Also replace ui/effects/widget_fade_wrap with ui/wrap/fade_wrap.
This commit is contained in:
@@ -20,25 +20,26 @@ Copyright (c) 2014-2017 John Preston, https://desktop.telegram.org
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
#include "layerwidget.h"
|
||||
#include "window/layer_widget.h"
|
||||
#include "ui/rp_widget.h"
|
||||
#include "ui/widgets/shadow.h"
|
||||
|
||||
namespace style {
|
||||
struct RoundButton;
|
||||
struct ScrollArea;
|
||||
} // namespace style
|
||||
|
||||
namespace Ui {
|
||||
class RoundButton;
|
||||
class IconButton;
|
||||
class ScrollArea;
|
||||
class FlatLabel;
|
||||
template <typename Widget>
|
||||
class WidgetFadeWrap;
|
||||
class FadeShadow;
|
||||
} // namespace Ui
|
||||
|
||||
namespace Window {
|
||||
class Controller;
|
||||
} // namespace Window
|
||||
|
||||
class BoxLayerTitleShadow;
|
||||
|
||||
class BoxContentDelegate {
|
||||
public:
|
||||
virtual Window::Controller *controller() const = 0;
|
||||
@@ -194,15 +195,18 @@ private:
|
||||
bool _noContentMargin = false;
|
||||
int _innerTopSkip = 0;
|
||||
object_ptr<Ui::ScrollArea> _scroll = { nullptr };
|
||||
object_ptr<Ui::WidgetFadeWrap<BoxLayerTitleShadow>> _topShadow = { nullptr };
|
||||
object_ptr<Ui::WidgetFadeWrap<BoxLayerTitleShadow>> _bottomShadow = { nullptr };
|
||||
object_ptr<Ui::FadeShadow> _topShadow = { nullptr };
|
||||
object_ptr<Ui::FadeShadow> _bottomShadow = { nullptr };
|
||||
|
||||
object_ptr<QTimer> _draggingScrollTimer = { nullptr };
|
||||
int _draggingScrollDelta = 0;
|
||||
|
||||
};
|
||||
|
||||
class AbstractBox : public LayerWidget, public BoxContentDelegate, protected base::Subscriber {
|
||||
class AbstractBox
|
||||
: public Window::LayerWidget
|
||||
, public BoxContentDelegate
|
||||
, protected base::Subscriber {
|
||||
public:
|
||||
AbstractBox(QWidget *parent, Window::Controller *controller, object_ptr<BoxContent> content);
|
||||
|
||||
@@ -284,12 +288,6 @@ private:
|
||||
|
||||
};
|
||||
|
||||
class BoxLayerTitleShadow : public Ui::PlainShadow {
|
||||
public:
|
||||
BoxLayerTitleShadow(QWidget *parent);
|
||||
|
||||
};
|
||||
|
||||
class BoxContentDivider : public Ui::RpWidget {
|
||||
public:
|
||||
BoxContentDivider(QWidget *parent);
|
||||
|
Reference in New Issue
Block a user