代码拉取完成,页面将自动刷新
#ifndef QTMATERIALDRAWER_H
#define QTMATERIALDRAWER_H
#include "qtmaterialwidgets.h"
#include "lib/qtmaterialoverlaywidget.h"
class QtMaterialDrawerPrivate;
class QtMaterialDrawerStateMachine;
class QTMATERIALWIDGETS_EXPORT QtMaterialDrawer : public QtMaterialOverlayWidget
{
Q_OBJECT
Q_PROPERTY(bool clickOutsideToClose READ clickOutsideToClose WRITE setClickOutsideToClose)
Q_PROPERTY(bool autoRaise READ autoRaise WRITE setAutoRaise)
Q_PROPERTY(bool overlayMode READ overlayMode WRITE setOverlayMode)
public:
explicit QtMaterialDrawer(QWidget *parent = nullptr);
~QtMaterialDrawer() override;
int drawerWidth() const;
void setDrawerWidth(int width);
QLayout *drawerLayout() const;
void setDrawerLayout(QLayout *layout);
bool clickOutsideToClose() const;
void setClickOutsideToClose(bool state);
bool autoRaise() const;
void setAutoRaise(bool state);
bool overlayMode() const;
void setOverlayMode(bool value);
void setDirection(bool isLeft);
public slots:
void openDrawer();
void closeDrawer();
protected:
const QScopedPointer<QtMaterialDrawerPrivate> d_ptr;
private:
Q_DISABLE_COPY(QtMaterialDrawer)
Q_DECLARE_PRIVATE(QtMaterialDrawer)
// QWidget interface
protected:
bool event(QEvent *event) override;
bool eventFilter(QObject *obj, QEvent *event) override;
void paintEvent(QPaintEvent *event) override;
};
#endif // QTMATERIALDRAWER_H
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。