scripting: Remove X11 specific signals
This commit is contained in:
parent
452bb20741
commit
93c1a610bc
5 changed files with 9 additions and 24 deletions
|
@ -286,14 +286,6 @@ void WorkspaceWrapper::setupClientConnections(Window *client)
|
|||
connect(client, &Window::clientUnminimized, this, &WorkspaceWrapper::clientUnminimized);
|
||||
connect(client, qOverload<Window *, bool, bool>(&Window::clientMaximizedStateChanged),
|
||||
this, &WorkspaceWrapper::clientMaximizeSet);
|
||||
|
||||
X11Window *x11Client = qobject_cast<X11Window *>(client); // TODO: Drop X11-specific signals.
|
||||
if (!x11Client) {
|
||||
return;
|
||||
}
|
||||
|
||||
connect(x11Client, &X11Window::clientManaging, this, &WorkspaceWrapper::clientManaging);
|
||||
connect(x11Client, &X11Window::clientFullScreenSet, this, &WorkspaceWrapper::clientFullScreenSet);
|
||||
}
|
||||
|
||||
void WorkspaceWrapper::showOutline(const QRect &geometry)
|
||||
|
|
|
@ -67,14 +67,12 @@ Q_SIGNALS:
|
|||
void desktopPresenceChanged(KWin::Window *client, int desktop);
|
||||
void clientAdded(KWin::Window *client);
|
||||
void clientRemoved(KWin::Window *client);
|
||||
void clientManaging(KWin::X11Window *client);
|
||||
void clientMinimized(KWin::Window *client);
|
||||
void clientUnminimized(KWin::Window *client);
|
||||
void clientRestored(KWin::X11Window *client);
|
||||
void clientMaximizeSet(KWin::Window *client, bool h, bool v);
|
||||
void killWindowCalled(KWin::X11Window *client);
|
||||
void clientActivated(KWin::Window *client);
|
||||
void clientFullScreenSet(KWin::X11Window *client, bool fullScreen, bool user);
|
||||
void clientSetKeepAbove(KWin::X11Window *client, bool keepAbove);
|
||||
/**
|
||||
* This signal is emitted when a virtual desktop is added or removed.
|
||||
|
|
|
@ -26,10 +26,13 @@ function isVideoPlayer(client) {
|
|||
return true;
|
||||
}
|
||||
|
||||
var videowall = function(client, set) {
|
||||
if (set && isVideoPlayer(client)) {
|
||||
client.frameGeometry = workspace.clientArea(KWin.FullArea, 0, 1);
|
||||
}
|
||||
};
|
||||
function setup(window) {
|
||||
window.fullScreenChanged.connect(() => {
|
||||
if (window.fullScreen && isVideoPlayer(window)) {
|
||||
window.frameGeometry = workspace.clientArea(KWin.FullArea, window);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
workspace.clientFullScreenSet.connect(videowall);
|
||||
workspace.clientAdded.connect(setup);
|
||||
workspace.clientList().forEach(setup);
|
||||
|
|
|
@ -1027,10 +1027,6 @@ bool X11Window::manage(xcb_window_t w, bool isMapped)
|
|||
info.setOpacityF(opacity());
|
||||
});
|
||||
|
||||
// TODO: there's a small problem here - isManaged() depends on the mapping state,
|
||||
// but this client is not yet in Workspace's client list at this point, will
|
||||
// be only done in addClient()
|
||||
Q_EMIT clientManaging(this);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -4617,7 +4613,6 @@ void X11Window::setFullScreen(bool set, bool user)
|
|||
|
||||
updateWindowRules(Rules::Fullscreen | Rules::Position | Rules::Size);
|
||||
updateAllowedActions(false);
|
||||
Q_EMIT clientFullScreenSet(this, set, user);
|
||||
Q_EMIT fullScreenChanged();
|
||||
}
|
||||
|
||||
|
|
|
@ -364,9 +364,6 @@ protected:
|
|||
// in between objects as compared to simple function
|
||||
// calls
|
||||
Q_SIGNALS:
|
||||
void clientManaging(KWin::X11Window *);
|
||||
void clientFullScreenSet(KWin::X11Window *, bool, bool);
|
||||
|
||||
/**
|
||||
* Emitted whenever the Client want to show it menu
|
||||
*/
|
||||
|
|
Loading…
Reference in a new issue