2020-09-04 07:03:04 +00:00
|
|
|
/*
|
|
|
|
SPDX-FileCopyrightText: 2020 Vlad Zahorodnii <vlad.zahorodnii@kde.org>
|
|
|
|
|
|
|
|
SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include "inputpanelv1integration.h"
|
|
|
|
#include "inputpanelv1client.h"
|
|
|
|
#include "wayland_server.h"
|
|
|
|
|
|
|
|
#include <KWaylandServer/display.h>
|
|
|
|
#include <KWaylandServer/inputmethod_v1_interface.h>
|
|
|
|
|
|
|
|
using namespace KWaylandServer;
|
|
|
|
|
|
|
|
namespace KWin
|
|
|
|
{
|
|
|
|
|
|
|
|
InputPanelV1Integration::InputPanelV1Integration(QObject *parent)
|
|
|
|
: WaylandShellIntegration(parent)
|
|
|
|
{
|
2020-12-09 21:24:41 +00:00
|
|
|
InputPanelV1Interface *shell = new InputPanelV1Interface(waylandServer()->display(), this);
|
2020-09-04 07:03:04 +00:00
|
|
|
|
|
|
|
connect(shell, &InputPanelV1Interface::inputPanelSurfaceAdded,
|
|
|
|
this, &InputPanelV1Integration::createClient);
|
|
|
|
}
|
|
|
|
|
|
|
|
void InputPanelV1Integration::createClient(InputPanelSurfaceV1Interface *shellSurface)
|
|
|
|
{
|
2021-06-08 07:02:14 +00:00
|
|
|
Q_EMIT clientCreated(new InputPanelV1Client(shellSurface));
|
2020-09-04 07:03:04 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
} // namespace KWin
|