Merge remote-tracking branch 'qt/5.8' into 5.9
Change-Id: I43cd0147a63b5523e3112f09bbfe60e1d6636e6c
This commit is contained in:
commit
a89c479a01
@ -82,7 +82,7 @@
|
||||
"output": [ "privateFeature" ]
|
||||
},
|
||||
"wayland-brcm": {
|
||||
"label": "Rasberry Pi",
|
||||
"label": "Raspberry Pi",
|
||||
"condition": "features.wayland-client && features.eglfs_brcm",
|
||||
"output": [ "privateFeature" ]
|
||||
},
|
||||
|
@ -44,7 +44,7 @@ QT_BEGIN_NAMESPACE
|
||||
|
||||
namespace QtWaylandClient {
|
||||
|
||||
class QWaylandXCompositeEglClientBufferIntegrationPlugin : public QWaylandClientBufferIntegrationPlugin
|
||||
class QWaylandXCompositeEglClientBufferPlugin : public QWaylandClientBufferIntegrationPlugin
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_PLUGIN_METADATA(IID QWaylandClientBufferIntegrationFactoryInterface_iid FILE "xcomposite-egl.json")
|
||||
@ -52,7 +52,7 @@ public:
|
||||
QWaylandClientBufferIntegration *create(const QString&, const QStringList&) override;
|
||||
};
|
||||
|
||||
QWaylandClientBufferIntegration *QWaylandXCompositeEglClientBufferIntegrationPlugin::create(const QString& system, const QStringList& paramList)
|
||||
QWaylandClientBufferIntegration *QWaylandXCompositeEglClientBufferPlugin::create(const QString& system, const QStringList& paramList)
|
||||
{
|
||||
Q_UNUSED(paramList);
|
||||
Q_UNUSED(system);
|
||||
|
@ -11,5 +11,5 @@ SOURCES += \
|
||||
main.cpp
|
||||
|
||||
PLUGIN_TYPE = wayland-graphics-integration-client
|
||||
PLUGIN_CLASS_NAME = QWaylandXCompositeEglClientBufferIntegrationPlugin
|
||||
PLUGIN_CLASS_NAME = QWaylandXCompositeEglClientBufferPlugin
|
||||
load(qt_plugin)
|
||||
|
@ -44,7 +44,7 @@ QT_BEGIN_NAMESPACE
|
||||
|
||||
namespace QtWaylandClient {
|
||||
|
||||
class QWaylandXCompositeGlxClientBufferIntegrationPlugin : public QWaylandClientBufferIntegrationPlugin
|
||||
class QWaylandXCompositeGlxClientBufferPlugin : public QWaylandClientBufferIntegrationPlugin
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_PLUGIN_METADATA(IID QWaylandClientBufferIntegrationFactoryInterface_iid FILE "xcomposite-glx.json")
|
||||
@ -52,7 +52,7 @@ public:
|
||||
QWaylandClientBufferIntegration *create(const QString&, const QStringList&) override;
|
||||
};
|
||||
|
||||
QWaylandClientBufferIntegration *QWaylandXCompositeGlxClientBufferIntegrationPlugin::create(const QString& system, const QStringList& paramList)
|
||||
QWaylandClientBufferIntegration *QWaylandXCompositeGlxClientBufferPlugin::create(const QString& system, const QStringList& paramList)
|
||||
{
|
||||
Q_UNUSED(paramList);
|
||||
Q_UNUSED(system);
|
||||
|
@ -8,5 +8,5 @@ SOURCES += \
|
||||
main.cpp
|
||||
|
||||
PLUGIN_TYPE = wayland-graphics-integration-client
|
||||
PLUGIN_CLASS_NAME = QWaylandXCompositeGlxClientBufferIntegrationPlugin
|
||||
PLUGIN_CLASS_NAME = QWaylandXCompositeGlxClientBufferPlugin
|
||||
load(qt_plugin)
|
||||
|
@ -421,7 +421,14 @@ void QWaylandDisplay::handleKeyboardFocusChanged(QWaylandInputDevice *inputDevic
|
||||
if (mLastKeyboardFocus == keyboardFocus)
|
||||
return;
|
||||
|
||||
mWaylandIntegration->mShellIntegration->handleKeyboardFocusChanged(keyboardFocus, mLastKeyboardFocus);
|
||||
if (mWaylandIntegration->mShellIntegration) {
|
||||
mWaylandIntegration->mShellIntegration->handleKeyboardFocusChanged(keyboardFocus, mLastKeyboardFocus);
|
||||
} else {
|
||||
if (keyboardFocus)
|
||||
handleWindowActivated(keyboardFocus);
|
||||
if (mLastKeyboardFocus)
|
||||
handleWindowDeactivated(mLastKeyboardFocus);
|
||||
}
|
||||
|
||||
mLastKeyboardFocus = keyboardFocus;
|
||||
}
|
||||
|
@ -95,6 +95,7 @@ QWaylandWindow::QWaylandWindow(QWindow *window)
|
||||
{
|
||||
static WId id = 1;
|
||||
mWindowId = id++;
|
||||
initializeWlSurface();
|
||||
}
|
||||
|
||||
QWaylandWindow::~QWaylandWindow()
|
||||
@ -127,7 +128,7 @@ void QWaylandWindow::initWindow()
|
||||
return;
|
||||
|
||||
if (!isInitialized())
|
||||
init(mDisplay->createSurface(static_cast<QtWayland::wl_surface *>(this)));
|
||||
initializeWlSurface();
|
||||
|
||||
if (shouldCreateSubSurface()) {
|
||||
Q_ASSERT(!mSubSurfaceWindow);
|
||||
@ -200,6 +201,11 @@ void QWaylandWindow::initWindow()
|
||||
mFlags = window()->flags();
|
||||
}
|
||||
|
||||
void QWaylandWindow::initializeWlSurface()
|
||||
{
|
||||
init(mDisplay->createSurface(static_cast<QtWayland::wl_surface *>(this)));
|
||||
}
|
||||
|
||||
bool QWaylandWindow::shouldCreateShellSurface() const
|
||||
{
|
||||
if (shouldCreateSubSurface())
|
||||
@ -225,7 +231,8 @@ void QWaylandWindow::reset()
|
||||
mShellSurface = 0;
|
||||
delete mSubSurfaceWindow;
|
||||
mSubSurfaceWindow = 0;
|
||||
destroy();
|
||||
if (isInitialized())
|
||||
destroy();
|
||||
|
||||
if (mFrameCallback)
|
||||
wl_callback_destroy(mFrameCallback);
|
||||
@ -360,8 +367,11 @@ void QWaylandWindow::setMask(const QRegion &mask)
|
||||
|
||||
mMask = mask;
|
||||
|
||||
if (!isInitialized())
|
||||
return;
|
||||
|
||||
if (mMask.isEmpty()) {
|
||||
set_input_region(0);
|
||||
set_input_region(nullptr);
|
||||
} else {
|
||||
struct ::wl_region *region = mDisplay->createRegion(mMask);
|
||||
set_input_region(region);
|
||||
|
@ -248,6 +248,7 @@ private:
|
||||
bool setWindowStateInternal(Qt::WindowState flags);
|
||||
void setGeometry_helper(const QRect &rect);
|
||||
void initWindow();
|
||||
void initializeWlSurface();
|
||||
bool shouldCreateShellSurface() const;
|
||||
bool shouldCreateSubSurface() const;
|
||||
void reset();
|
||||
|
Loading…
x
Reference in New Issue
Block a user