diff --git a/xwl/databridge.cpp b/xwl/databridge.cpp
index 32e0d70fd4..69b6b46ee3 100644
--- a/xwl/databridge.cpp
+++ b/xwl/databridge.cpp
@@ -28,6 +28,7 @@ along with this program. If not, see .
#include "wayland_server.h"
#include "workspace.h"
+#include
#include
#include
@@ -58,7 +59,6 @@ DataBridge::DataBridge(QObject *parent)
DataDeviceManager *dataDeviceManager = waylandServer()->internalDataDeviceManager();
Seat *seat = waylandServer()->internalSeat();
m_dataDevice = dataDeviceManager->getDataDevice(seat, this);
- waylandServer()->dispatch();
const DataDeviceManagerInterface *dataDeviceManagerInterface =
waylandServer()->dataDeviceManager();
@@ -78,6 +78,9 @@ DataBridge::DataBridge(QObject *parent)
init();
}
);
+
+ waylandServer()->internalClientConection()->flush();
+ waylandServer()->dispatch();
}
DataBridge::~DataBridge()