fix(tray): Join notify thread after setting activate state

This commit is contained in:
Michael Carlberg 2016-10-15 03:33:35 +02:00
parent 6b0109e8dd
commit 1ab0724347

View File

@ -184,9 +184,6 @@ class traymanager
m_logger.info("Deactivating traymanager");
if (m_notifythread.joinable())
m_notifythread.join();
if (m_sinkattached) {
m_connection.detach_sink(this, 2);
m_sinkattached = false;
@ -200,6 +197,9 @@ class traymanager
m_activated = false;
if (m_notifythread.joinable())
m_notifythread.join();
try {
if (m_connection.get_selection_owner(m_atom).owner<xcb_window_t>() == m_tray)
m_connection.set_selection_owner_checked(XCB_NONE, m_atom, XCB_CURRENT_TIME);