shift-shell/containments/taskpanel/taskpanel.h

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

40 lines
900 B
C
Raw Normal View History

2021-03-01 20:03:25 +00:00
/*
* SPDX-FileCopyrightText: 2015 Marco Martin <mart@kde.org>
*
2021-03-01 20:03:25 +00:00
* SPDX-License-Identifier: GPL-2.0-or-later
*/
2023-11-14 06:37:08 +00:00
#pragma once
#include <Plasma/Containment>
#include <QOrientationSensor>
#include <kscreen/config.h>
class TaskPanel : public Plasma::Containment
{
Q_OBJECT
Q_PROPERTY(bool showRotationButton READ showRotationButton NOTIFY showRotationButtonChanged)
public:
2022-04-24 11:44:41 +00:00
TaskPanel(QObject *parent, const KPluginMetaData &data, const QVariantList &args);
2023-03-06 06:38:43 +00:00
Q_INVOKABLE void triggerTaskSwitcher() const;
bool showRotationButton() const;
Q_INVOKABLE void rotateToSuggestedRotation();
Q_SIGNALS:
void showRotationButtonChanged();
private Q_SLOTS:
void updateShowRotationButton();
private:
bool m_showRotationButton{false};
KScreen::Output::Rotation m_rotateTo;
KScreen::ConfigPtr m_config{nullptr};
QOrientationSensor *m_sensor{nullptr};
};