mirror of
https://git.outfoxxed.me/quickshell/quickshell.git
synced 2026-04-10 06:11:54 +10:00
hyprland/focus_grab: handle destruction of tracked windows
This commit is contained in:
parent
3520c85d77
commit
0cb62920a7
11 changed files with 67 additions and 102 deletions
|
|
@ -57,6 +57,12 @@ ProxyWindowBase::ProxyWindowBase(QObject* parent)
|
|||
|
||||
ProxyWindowBase::~ProxyWindowBase() { this->deleteWindow(true); }
|
||||
|
||||
ProxyWindowBase* ProxyWindowBase::forObject(QObject* obj) {
|
||||
if (auto* proxy = qobject_cast<ProxyWindowBase*>(obj)) return proxy;
|
||||
if (auto* iface = qobject_cast<WindowInterface*>(obj)) return iface->proxyWindow();
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void ProxyWindowBase::onReload(QObject* oldInstance) {
|
||||
if (this->mVisible) this->window = this->retrieveWindow(oldInstance);
|
||||
auto wasVisible = this->window != nullptr && this->window->isVisible();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue