aboutsummaryrefslogtreecommitdiffstats
path: root/src/main.cpp
diff options
context:
space:
mode:
authorJan-Simon Moeller <jsmoeller@linuxfoundation.org>2018-07-19 13:08:17 +0000
committerJan-Simon Moeller <jsmoeller@linuxfoundation.org>2018-07-19 15:22:29 +0000
commitc6f9a9b8468b3746a3dec7ee2a0b7d84ec9fb44a (patch)
treee766e0b4b1bb894c5511ed6d1e71a4ac389415d6 /src/main.cpp
parente4222ca8da3b02afca5625fa2cef6832aa8ce90e (diff)
Revert "Add PolicyManager as plugin"
This reverts commit 99b6f4d2fcd421d3a760a88a67e511fb6fc98068. Change-Id: I8725ca05a3e3fa0ea9e1db935e9e7d5b85a9affd
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/main.cpp b/src/main.cpp
index e982337..6521c6c 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -195,6 +195,18 @@ static void cbRemoveClientCtxt(void *data)
if (pSid)
{
auto sid = *pSid;
+ auto o_state = *g_afb_instance->wmgr.layers.get_layout_state(sid);
+ if (o_state != nullptr)
+ {
+ if (o_state->main == sid)
+ {
+ o_state->main = -1;
+ }
+ else if (o_state->sub == sid)
+ {
+ o_state->sub = -1;
+ }
+ }
g_afb_instance->wmgr.id_alloc.remove_id(sid);
g_afb_instance->wmgr.layers.remove_surface(sid);
g_afb_instance->wmgr.controller->sprops.erase(sid);