Commit cfb8140f authored by Xaver Hugl's avatar Xaver Hugl
Browse files

wayland/drmlease: split up DrmLeaseV1Interface::deny


(cherry picked from commit 9ac3c64d)
parent 75cb0d88
Pipeline #204568 passed with stage
in 27 minutes and 40 seconds
......@@ -244,7 +244,7 @@ bool DrmGpu::updateOutputs()
}
}
if (!leaseActive) {
leaseOutput->lease()->deny();
leaseOutput->lease()->revoke();
}
}
}
......
......@@ -338,8 +338,14 @@ void DrmLeaseV1Interface::deny()
d->finished = true;
d->send_finished();
}
if (!d->lesseeId) {
return;
}
void DrmLeaseV1Interface::revoke()
{
Q_ASSERT(d->lesseeId != 0);
if (!d->finished) {
d->finished = true;
d->send_finished();
}
Q_EMIT d->device->q->leaseRevoked(this);
// check if we should offer connectors again
......
......@@ -100,10 +100,15 @@ public:
/**
* Deny the lease request. The compositor may call this in response to
* DrmLeaseDeviceV1Interface::leaseRequested or when it detects a lease being ended with libdrm
* DrmLeaseDeviceV1Interface::leaseRequested
*/
void deny();
/**
* revoke a granted lease request and offer the leased connectors again
*/
void revoke();
/**
* The connectors this lease (request) encompasses
*/
......
Supports Markdown
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