added hyprctl kill

This commit is contained in:
vaxerski
2022-06-27 13:42:20 +02:00
parent b9a5fc0d2f
commit 781526dac5
9 changed files with 154 additions and 38 deletions

View File

@@ -77,4 +77,16 @@ wlr_box CWindow::getWindowIdealBoundingBoxIgnoreReserved() {
void CWindow::updateWindowDecos() {
for (auto& wd : m_dWindowDecorations)
wd->updateWindow(this);
}
}
pid_t CWindow::getPID() {
pid_t PID = -1;
if (!m_bIsX11) {
const auto CLIENT = wl_resource_get_client(m_uSurface.xdg->resource);
wl_client_get_credentials(CLIENT, &PID, nullptr, nullptr);
} else {
PID = m_uSurface.xwayland->pid;
}
return PID;
}