2015-06-12 01:05:14 +00:00
|
|
|
/********************************************************************
|
|
|
|
Copyright 2015 Martin Gräßlin <mgraesslin@kde.org>
|
|
|
|
|
|
|
|
This library is free software; you can redistribute it and/or
|
|
|
|
modify it under the terms of the GNU Lesser General Public
|
|
|
|
License as published by the Free Software Foundation; either
|
|
|
|
version 2.1 of the License, or (at your option) version 3, or any
|
|
|
|
later version accepted by the membership of KDE e.V. (or its
|
|
|
|
successor approved by the membership of KDE e.V.), which shall
|
|
|
|
act as a proxy defined in Section 6 of version 3 of the license.
|
|
|
|
|
|
|
|
This library is distributed in the hope that it will be useful,
|
|
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
Lesser General Public License for more details.
|
|
|
|
|
|
|
|
You should have received a copy of the GNU Lesser General Public
|
|
|
|
License along with this library. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
*********************************************************************/
|
|
|
|
#ifndef WAYLAND_SERVER_PLASMA_WINDOW_MANAGEMENT_INTERFACE_H
|
|
|
|
#define WAYLAND_SERVER_PLASMA_WINDOW_MANAGEMENT_INTERFACE_H
|
|
|
|
|
|
|
|
#include <QObject>
|
|
|
|
|
|
|
|
#include <KWayland/Server/kwaylandserver_export.h>
|
|
|
|
|
|
|
|
#include "global.h"
|
2015-06-15 19:42:38 +00:00
|
|
|
#include "resource.h"
|
2015-06-12 01:05:14 +00:00
|
|
|
|
|
|
|
class QSize;
|
|
|
|
|
|
|
|
namespace KWayland
|
|
|
|
{
|
|
|
|
namespace Server
|
|
|
|
{
|
|
|
|
|
|
|
|
class Display;
|
2015-06-15 19:42:38 +00:00
|
|
|
class PlasmaWindowInterface;
|
2015-06-12 01:05:14 +00:00
|
|
|
|
|
|
|
class KWAYLANDSERVER_EXPORT PlasmaWindowManagementInterface : public Global
|
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
public:
|
|
|
|
virtual ~PlasmaWindowManagementInterface();
|
|
|
|
enum class ShowingDesktopState {
|
|
|
|
Disabled,
|
|
|
|
Enabled
|
|
|
|
};
|
|
|
|
void setShowingDesktopState(ShowingDesktopState state);
|
|
|
|
|
2015-06-15 19:42:38 +00:00
|
|
|
PlasmaWindowInterface *createWindow(QObject *parent);
|
|
|
|
QList<PlasmaWindowInterface*> windows() const;
|
|
|
|
|
2015-06-12 01:05:14 +00:00
|
|
|
Q_SIGNALS:
|
|
|
|
void requestChangeShowingDesktop(ShowingDesktopState requestedState);
|
|
|
|
|
|
|
|
private:
|
|
|
|
friend class Display;
|
|
|
|
explicit PlasmaWindowManagementInterface(Display *display, QObject *parent);
|
|
|
|
class Private;
|
|
|
|
Private *d_func() const;
|
|
|
|
};
|
|
|
|
|
2015-06-15 19:42:38 +00:00
|
|
|
class KWAYLANDSERVER_EXPORT PlasmaWindowInterface : public QObject
|
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
public:
|
|
|
|
virtual ~PlasmaWindowInterface();
|
|
|
|
|
|
|
|
void setTitle(const QString &title);
|
|
|
|
void setAppId(const QString &appId);
|
|
|
|
void setVirtualDesktop(quint32 desktop);
|
|
|
|
|
2015-06-17 22:10:52 +00:00
|
|
|
void unmap();
|
|
|
|
|
2015-06-15 19:42:38 +00:00
|
|
|
private:
|
|
|
|
friend class PlasmaWindowManagementInterface;
|
|
|
|
explicit PlasmaWindowInterface(PlasmaWindowManagementInterface *wm, QObject *parent);
|
|
|
|
|
|
|
|
class Private;
|
|
|
|
const QScopedPointer<Private> d;
|
|
|
|
};
|
|
|
|
|
2015-06-12 01:05:14 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|