dde-dock/plugins/shutdown/shutdownwidget.h
tsic404 5f6cacdf2a refactor: Rewrite the calling method of dock settings
Rewrite the calling method of dock settings, using the new dconfig interface instead of AM's dbus interface

log: as title
2023-07-18 07:35:19 +00:00

36 lines
829 B
C++

// Copyright (C) 2011 ~ 2018 Deepin Technology Co., Ltd.
// SPDX-FileCopyrightText: 2018 - 2023 UnionTech Software Technology Co., Ltd.
//
// SPDX-License-Identifier: LGPL-3.0-or-later
#ifndef PLUGINWIDGET_H
#define PLUGINWIDGET_H
#include "constants.h"
#include <QWidget>
#include <QIcon>
class ShutdownWidget : public QWidget
{
Q_OBJECT
public:
explicit ShutdownWidget(QWidget *parent = Q_NULLPTR);
QPixmap loadPixmap() const;
protected:
void paintEvent(QPaintEvent *e) override;
void mousePressEvent(QMouseEvent *event) override;
void mouseReleaseEvent(QMouseEvent *event) override;
void mouseMoveEvent(QMouseEvent *event) override;
void leaveEvent(QEvent *event) override;
private:
Dock::DisplayMode m_displayMode;
bool m_hover;
bool m_pressed;
};
#endif // PLUGINWIDGET_H