correct the surface id

This commit is contained in:
Gang Wu 2020-11-03 20:30:48 +08:00 committed by Gang Wu
parent 1caf9f61d6
commit 28b6db4993

View file

@ -735,8 +735,10 @@ void Toplevel::setSurface(KWaylandServer::SurfaceInterface *surface)
connect(m_surface, &SurfaceInterface::destroyed, this,
[this] {
m_surface = nullptr;
m_surfaceId = 0;
}
);
m_surfaceId = surface->id();
emit surfaceChanged();
}