Commit 76297196 authored by Vlad Zahorodnii's avatar Vlad Zahorodnii
Browse files

[scripting] Expose Workspace::sendClientToDesktop()

Summary:
BUG: 416093
FIXED-IN: 5.18.0

Test Plan: Only compile-time check.

Reviewers: #kwin, davidedmundson

Reviewed By: #kwin, davidedmundson

Subscribers: kwin

Tags: #kwin

Differential Revision: https://phabricator.kde.org/D26988
parent c43b25bd
...@@ -347,6 +347,14 @@ QSize WorkspaceWrapper::virtualScreenSize() const ...@@ -347,6 +347,14 @@ QSize WorkspaceWrapper::virtualScreenSize() const
return screens()->size(); return screens()->size();
} }
void WorkspaceWrapper::sendClientToScreen(AbstractClient *client, int screen)
{
if (screen < 0 || screen >= screens()->count()) {
return;
}
workspace()->sendClientToScreen(client, screen);
}
QtScriptWorkspaceWrapper::QtScriptWorkspaceWrapper(QObject* parent) QtScriptWorkspaceWrapper::QtScriptWorkspaceWrapper(QObject* parent)
: WorkspaceWrapper(parent) {} : WorkspaceWrapper(parent) {}
......
...@@ -330,6 +330,11 @@ public Q_SLOTS: ...@@ -330,6 +330,11 @@ public Q_SLOTS:
void slotWindowToDesktopUp(); void slotWindowToDesktopUp();
void slotWindowToDesktopDown(); void slotWindowToDesktopDown();
/**
* Sends the AbstractClient to the given @p screen.
*/
void sendClientToScreen(KWin::AbstractClient *client, int screen);
/** /**
* Shows an outline at the specified @p geometry. * Shows an outline at the specified @p geometry.
* If an outline is already shown the outline is moved to the new position. * If an outline is already shown the outline is moved to the new position.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment