summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2019-07-02 03:03:53 +0200
committerJohan Klokkhammer Helsing <johan.helsing@qt.io>2019-07-02 08:52:03 +0200
commitbd5c03712cc0c3049479ee3636f0d795014d3f04 (patch)
tree689174ad3f7daea1263b1c5ac6d7cd8b773a9986 /src
parent9822df545cf1aaad684cb6179b214952a4027b71 (diff)
parenta640a8d46afa6c096013c8656c3ebebe1701e551 (diff)
Merge remote-tracking branch 'origin/5.13' into dev
Conflicts: .qmake.conf src/client/qwaylanddatadevice.cpp Change-Id: I1cc8640b68eba5dfb560749dfe679741ee62e6ad
Diffstat (limited to 'src')
-rw-r--r--src/client/qwaylanddatadevice.cpp5
-rw-r--r--src/client/qwaylandinputdevice.cpp7
-rw-r--r--src/compositor/extensions/qwaylandxdgdecorationv1.cpp2
3 files changed, 12 insertions, 2 deletions
diff --git a/src/client/qwaylanddatadevice.cpp b/src/client/qwaylanddatadevice.cpp
index 9dbef8d5b..e7afc3ca8 100644
--- a/src/client/qwaylanddatadevice.cpp
+++ b/src/client/qwaylanddatadevice.cpp
@@ -113,7 +113,10 @@ void QWaylandDataDevice::startDrag(QMimeData *mimeData, QWaylandWindow *icon)
if (!origin)
origin = seat->touchFocus();
- start_drag(m_dragSource->object(), origin->wlSurface(), icon->wlSurface(), m_display->currentInputDevice()->serial());
+ if (origin)
+ start_drag(m_dragSource->object(), origin->wlSurface(), icon->wlSurface(), m_display->currentInputDevice()->serial());
+ else
+ qCDebug(lcQpaWayland) << "Couldn't start a drag because the origin window could not be found.";
}
void QWaylandDataDevice::cancelDrag()
diff --git a/src/client/qwaylandinputdevice.cpp b/src/client/qwaylandinputdevice.cpp
index 6ebc3bed7..19e36ccba 100644
--- a/src/client/qwaylandinputdevice.cpp
+++ b/src/client/qwaylandinputdevice.cpp
@@ -279,6 +279,10 @@ void QWaylandInputDevice::Pointer::updateCursorTheme()
int pixelSize = cursorSize() * scale;
auto *display = seat()->mQDisplay;
mCursor.theme = display->loadCursorTheme(cursorThemeName(), pixelSize);
+
+ if (!mCursor.theme)
+ return; // A warning has already been printed in loadCursorTheme
+
if (auto *arrow = mCursor.theme->cursorImage(Qt::ArrowCursor)) {
int arrowPixelSize = qMax(arrow->width, arrow->height); // Not all cursor themes are square
while (scale > 1 && arrowPixelSize / scale < cursorSize())
@@ -317,6 +321,9 @@ void QWaylandInputDevice::Pointer::updateCursor()
if (!mCursor.theme || idealCursorScale() != mCursor.themeBufferScale)
updateCursorTheme();
+ if (!mCursor.theme)
+ return;
+
// Set from shape using theme
uint time = seat()->mCursor.animationTimer.elapsed();
if (struct ::wl_cursor_image *image = mCursor.theme->cursorImage(shape, time)) {
diff --git a/src/compositor/extensions/qwaylandxdgdecorationv1.cpp b/src/compositor/extensions/qwaylandxdgdecorationv1.cpp
index 2d283ddf9..a58601cd4 100644
--- a/src/compositor/extensions/qwaylandxdgdecorationv1.cpp
+++ b/src/compositor/extensions/qwaylandxdgdecorationv1.cpp
@@ -75,7 +75,7 @@ QT_BEGIN_NAMESPACE
}
\endqml
- \sa XdgToplevel::decorationMode
+ \sa QWaylandXdgToplevel::decorationMode
*/
/*!