Accepting request 324146 from KDE:Qt5

Update to 5.5.0

OBS-URL: https://build.opensuse.org/request/show/324146
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/libqt5-qtbase?expand=0&rev=46
This commit is contained in:
Stephan Kulow 2015-09-27 06:38:22 +00:00 committed by Git OBS Bridge
parent 22413b57e6
commit 05c147f1a9
20 changed files with 708 additions and 440 deletions

View File

@ -1,7 +1,7 @@
From 5944a751857de997ee674a90c2e35ff3adaa655b Mon Sep 17 00:00:00 2001
From: Alexander Volkov <a.volkov@rusbitech.ru>
Date: Mon, 8 Jun 2015 14:35:22 +0300
Subject: [PATCH 1/1] Fix QWidget::setWindowRole()
Subject: [PATCH] Fix QWidget::setWindowRole()
Introduce QXcbWindowFunctions::setWmWindowRole() and call it either from
the implementation of QWidget::setWindowRole() or after the creation of
@ -10,22 +10,21 @@ the corresponding QWidgetWindow.
Change-Id: I143450f4673dd707bb491c1d0f0e8b61d564283d
Task-number: QTBUG-45484
---
.../xcbfunctions/qxcbwindowfunctions.h | 11 +++++++++++
src/plugins/platforms/xcb/qxcbnativeinterface.cpp | 3 +++
src/plugins/platforms/xcb/qxcbwindow.cpp | 20 ++++++++++++++++++++
src/plugins/platforms/xcb/qxcbwindow.h | 2 ++
src/widgets/kernel/qwidget.cpp | 12 +++++++-----
.../xcbfunctions/qxcbwindowfunctions.h | 10 ++++++++++
src/plugins/platforms/xcb/qxcbnativeinterface.cpp | 3 +++
src/plugins/platforms/xcb/qxcbwindow.cpp | 21 +++++++++++++++++++++
src/plugins/platforms/xcb/qxcbwindow.h | 2 ++
src/widgets/kernel/qwidget.cpp | 12 +++++++-----
5 files changed, 43 insertions(+), 5 deletions(-)
diff --git a/src/platformheaders/xcbfunctions/qxcbwindowfunctions.h b/src/platformheaders/xcbfunctions/qxcbwindowfunctions.h
index 5227732..81cb32f 100644
index ae05cf5..a7fe8d9 100644
--- a/src/platformheaders/xcbfunctions/qxcbwindowfunctions.h
+++ b/src/platformheaders/xcbfunctions/qxcbwindowfunctions.h
@@ -72,6 +72,17 @@ public:
if (func)
@@ -73,6 +73,16 @@ public:
func(window, type);
}
+
+ typedef void (*SetWmWindowRole)(QWindow *window, const QByteArray &role);
+ static const QByteArray setWmWindowRoleIdentifier() { return QByteArrayLiteral("XcbSetWmWindowRole"); }
+
@ -36,36 +35,36 @@ index 5227732..81cb32f 100644
+ func(window, role);
+ }
+
};
typedef uint (*VisualId)(QWindow *window);
static const QByteArray visualIdIdentifier() { return QByteArrayLiteral("XcbVisualId"); }
diff --git a/src/plugins/platforms/xcb/qxcbnativeinterface.cpp b/src/plugins/platforms/xcb/qxcbnativeinterface.cpp
index 31dedd4..0bd49b8 100644
index 8bf9003..3cfdbde 100644
--- a/src/plugins/platforms/xcb/qxcbnativeinterface.cpp
+++ b/src/plugins/platforms/xcb/qxcbnativeinterface.cpp
@@ -339,6 +339,9 @@ QFunctionPointer QXcbNativeInterface::platformFunction(const QByteArray &functio
@@ -392,6 +392,9 @@ QFunctionPointer QXcbNativeInterface::platformFunction(const QByteArray &functio
if (function == QXcbWindowFunctions::setWmWindowTypeIdentifier()) {
return QFunctionPointer(QXcbWindow::setWmWindowTypeStatic);
}
+ if (function == QXcbWindowFunctions::setWmWindowRoleIdentifier()) {
+ return QFunctionPointer(QXcbWindow::setWmWindowRoleStatic);
+ }
return Q_NULLPTR;
}
if (function == QXcbWindowFunctions::visualIdIdentifier()) {
return QFunctionPointer(QXcbWindowFunctions::VisualId(QXcbWindow::visualIdStatic));
}
diff --git a/src/plugins/platforms/xcb/qxcbwindow.cpp b/src/plugins/platforms/xcb/qxcbwindow.cpp
index c0076a9..c736814 100644
index 6e021ce..edf68d4 100644
--- a/src/plugins/platforms/xcb/qxcbwindow.cpp
+++ b/src/plugins/platforms/xcb/qxcbwindow.cpp
@@ -236,6 +236,7 @@ static inline bool positionIncludesFrame(QWindow *w)
}
@@ -322,6 +322,7 @@ static inline XTextProperty* qstringToXTP(Display *dpy, const QString& s)
#endif // XCB_USE_XLIB
static const char *wm_window_type_property_id = "_q_xcb_wm_window_type";
+static const char *wm_window_role_property_id = "_q_xcb_wm_window_role";
QXcbWindow::QXcbWindow(QWindow *window)
: QPlatformWindow(window)
@@ -557,6 +558,11 @@ void QXcbWindow::create()
@@ -660,6 +661,11 @@ void QXcbWindow::create()
setOpacity(opacity);
if (window()->isTopLevel())
setWindowIcon(window()->icon());
@ -77,8 +76,8 @@ index c0076a9..c736814 100644
}
QXcbWindow::~QXcbWindow()
@@ -1597,6 +1603,14 @@ void QXcbWindow::setWmWindowTypeStatic(QWindow *window, QXcbWindowFunctions::WmW
window->setProperty(wm_window_type_property_id, QVariant::fromValue(static_cast<int>(windowTypes)));
@@ -1674,6 +1680,14 @@ void QXcbWindow::setWmWindowTypeStatic(QWindow *window, QXcbWindowFunctions::WmW
static_cast<QXcbWindow *>(window->handle())->setWmWindowType(windowTypes, window->flags());
}
+void QXcbWindow::setWmWindowRoleStatic(QWindow *window, const QByteArray &role)
@ -89,10 +88,10 @@ index c0076a9..c736814 100644
+ window->setProperty(wm_window_role_property_id, role);
+}
+
QXcbWindowFunctions::WmWindowTypes QXcbWindow::wmWindowTypes() const
uint QXcbWindow::visualIdStatic(QWindow *window)
{
QXcbWindowFunctions::WmWindowTypes result(0);
@@ -1713,6 +1727,13 @@ void QXcbWindow::setWmWindowType(QXcbWindowFunctions::WmWindowTypes types)
if (window && window->handle())
@@ -1839,6 +1853,13 @@ void QXcbWindow::setWmWindowType(QXcbWindowFunctions::WmWindowTypes types, Qt::W
xcb_flush(xcb_connection());
}
@ -107,23 +106,24 @@ index c0076a9..c736814 100644
{
public:
diff --git a/src/plugins/platforms/xcb/qxcbwindow.h b/src/plugins/platforms/xcb/qxcbwindow.h
index 254421e..2c9964c 100644
index a379a6f..15d5c1b 100644
--- a/src/plugins/platforms/xcb/qxcbwindow.h
+++ b/src/plugins/platforms/xcb/qxcbwindow.h
@@ -143,9 +143,11 @@ public:
#endif
@@ -140,10 +140,12 @@ public:
void updateNetWmUserTime(xcb_timestamp_t timestamp);
static void setWmWindowTypeStatic(QWindow *window, QXcbWindowFunctions::WmWindowTypes windowTypes);
+ static void setWmWindowRoleStatic(QWindow *window, const QByteArray &role);
static uint visualIdStatic(QWindow *window);
QXcbWindowFunctions::WmWindowTypes wmWindowTypes() const;
void setWmWindowType(QXcbWindowFunctions::WmWindowTypes types);
void setWmWindowType(QXcbWindowFunctions::WmWindowTypes types, Qt::WindowFlags flags);
+ void setWmWindowRole(const QByteArray &role);
bool needsSync() const;
uint visualId() const;
diff --git a/src/widgets/kernel/qwidget.cpp b/src/widgets/kernel/qwidget.cpp
index 637afb3..e38262d 100644
index bd77e7f..4b64490 100644
--- a/src/widgets/kernel/qwidget.cpp
+++ b/src/widgets/kernel/qwidget.cpp
@@ -100,6 +100,7 @@
@ -134,7 +134,7 @@ index 637afb3..e38262d 100644
// widget/widget data creation count
//#define QWIDGET_EXTRA_DEBUG
@@ -1453,6 +1454,9 @@ void QWidgetPrivate::create_sys(WId window, bool initializeWindow, bool destroyO
@@ -1451,6 +1452,9 @@ void QWidgetPrivate::create_sys(WId window, bool initializeWindow, bool destroyO
data.window_flags = win->flags();
@ -144,11 +144,11 @@ index 637afb3..e38262d 100644
QBackingStore *store = q->backingStore();
if (!store) {
@@ -6247,13 +6251,11 @@ QString QWidget::windowRole() const
@@ -6254,13 +6258,11 @@ QString QWidget::windowRole() const
*/
void QWidget::setWindowRole(const QString &role)
{
-#if defined(Q_WS_X11)
-#if defined(Q_DEAD_CODE_FROM_QT4_X11)
Q_D(QWidget);
+ d->createTLExtra();
d->topData()->role = role;
@ -162,6 +162,4 @@ index 637afb3..e38262d 100644
/*!
--
2.4.2
2.3.5

View File

@ -1,32 +0,0 @@
From 4e3b27ffc2f2d4d528abbbe58ee43acce0700fb2 Mon Sep 17 00:00:00 2001
From: Simon Hausmann <simon.hausmann@theqtcompany.com>
Date: Fri, 10 Apr 2015 08:46:37 +0200
Subject: [PATCH 1/2] Speed up compose file parsing in the X11 composition
input method plugin
There's no need to decode the string until the end of the line, it's
sufficient to stop at the end of the quotes.
Change-Id: Ie617d2538511e91d0e0146f98b7e5ea3213b8db2
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
(cherry picked from commit 1aab68648d3aa38811be38b5bbd3a0704e17ccf8)
---
src/plugins/platforminputcontexts/compose/generator/qtablegenerator.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/plugins/platforminputcontexts/compose/generator/qtablegenerator.cpp b/src/plugins/platforminputcontexts/compose/generator/qtablegenerator.cpp
index 4e90f618765e7a9a0509af7282500c133f11d3e3..622c71e5b01219cd39d594557a9d3ca63eea8748 100644
--- a/src/plugins/platforminputcontexts/compose/generator/qtablegenerator.cpp
+++ b/src/plugins/platforminputcontexts/compose/generator/qtablegenerator.cpp
@@ -399,7 +399,7 @@ void TableGenerator::parseKeySequence(char *line)
// handle direct text encoded in the locale
if (*composeValue == '\\')
++composeValue;
- elem.value = QString::fromLocal8Bit(composeValue).at(0).unicode();
+ elem.value = QString::fromLocal8Bit(composeValue, composeValueEnd - composeValue).at(0).unicode();
++composeValue;
}
--
2.3.5

View File

@ -1,98 +0,0 @@
From bf425e52923e84c93b74ec4644045014a2d5a9a1 Mon Sep 17 00:00:00 2001
From: Simon Hausmann <simon.hausmann@theqtcompany.com>
Date: Fri, 10 Apr 2015 09:01:47 +0200
Subject: [PATCH 2/2] Speed up application startup on X11
Avoid parsing the composition tables on application startup. Instead let's
do that on-demand the first time a composition key is pressed.
Change-Id: I52feb36246a091b9a84d46e479ba2ad1f5cd1556
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
(cherry picked from commit d11665b27ce3357fb30bff6ffc1379a4756ec8d1)
---
.../compose/qcomposeplatforminputcontext.cpp | 32 ++++++++++++----------
.../compose/qcomposeplatforminputcontext.h | 1 +
2 files changed, 19 insertions(+), 14 deletions(-)
diff --git a/src/plugins/platforminputcontexts/compose/qcomposeplatforminputcontext.cpp b/src/plugins/platforminputcontexts/compose/qcomposeplatforminputcontext.cpp
index b0e34e3edc73b27d181bff6589877ed301dadfdc..c34978c720c226b298350362957b2eb149d58470 100644
--- a/src/plugins/platforminputcontexts/compose/qcomposeplatforminputcontext.cpp
+++ b/src/plugins/platforminputcontexts/compose/qcomposeplatforminputcontext.cpp
@@ -80,37 +80,32 @@ static const int composingKeys[] = {
};
QComposeInputContext::QComposeInputContext()
+ : m_tableState(TableGenerator::EmptyTable)
+ , m_compositionTableInitialized(false)
{
- TableGenerator reader;
- m_tableState = reader.tableState();
-
- if ((m_tableState & TableGenerator::NoErrors) == TableGenerator::NoErrors) {
- m_composeTable = reader.composeTable();
- clearComposeBuffer();
- }
+ clearComposeBuffer();
}
bool QComposeInputContext::filterEvent(const QEvent *event)
{
- // if there were errors when generating the compose table input
- // context should not try to filter anything, simply return false
- if ((m_tableState & TableGenerator::NoErrors) != TableGenerator::NoErrors)
- return false;
-
QKeyEvent *keyEvent = (QKeyEvent *)event;
// should pass only the key presses
if (keyEvent->type() != QEvent::KeyPress) {
return false;
}
+ // if there were errors when generating the compose table input
+ // context should not try to filter anything, simply return false
+ if (m_compositionTableInitialized && (m_tableState & TableGenerator::NoErrors) != TableGenerator::NoErrors)
+ return false;
+
int keyval = keyEvent->key();
int keysym = 0;
if (ignoreKey(keyval))
return false;
- QString text = keyEvent->text();
- if (!composeKey(keyval) && text.isEmpty())
+ if (!composeKey(keyval) && keyEvent->text().isEmpty())
return false;
keysym = keyEvent->nativeVirtualKey();
@@ -163,6 +158,15 @@ static bool isDuplicate(const QComposeTableElement &lhs, const QComposeTableElem
bool QComposeInputContext::checkComposeTable()
{
+ if (!m_compositionTableInitialized) {
+ TableGenerator reader;
+ m_tableState = reader.tableState();
+
+ if ((m_tableState & TableGenerator::NoErrors) == TableGenerator::NoErrors)
+ m_composeTable = reader.composeTable();
+
+ m_compositionTableInitialized = true;
+ }
QVector<QComposeTableElement>::const_iterator it =
std::lower_bound(m_composeTable.constBegin(), m_composeTable.constEnd(), m_composeBuffer, Compare());
diff --git a/src/plugins/platforminputcontexts/compose/qcomposeplatforminputcontext.h b/src/plugins/platforminputcontexts/compose/qcomposeplatforminputcontext.h
index 897b164b3be22be99d8bdeaf45bcffc0a141009a..52654b458d0265d778926df22ad00094a4f6847c 100644
--- a/src/plugins/platforminputcontexts/compose/qcomposeplatforminputcontext.h
+++ b/src/plugins/platforminputcontexts/compose/qcomposeplatforminputcontext.h
@@ -70,6 +70,7 @@ private:
QVector<QComposeTableElement> m_composeTable;
uint m_composeBuffer[QT_KEYSEQUENCE_MAX_LEN + 1];
TableGenerator::TableState m_tableState;
+ bool m_compositionTableInitialized;
};
QT_END_NAMESPACE
--
2.3.5

View File

@ -1,7 +1,10 @@
From f211b79ef00f8a8874c96389699e788e0855df3c Mon Sep 17 00:00:00 2001
From 1d9a6d0859a7daca0385cbdfdf4c6b7caf32e6d8 Mon Sep 17 00:00:00 2001
From: Alexander Volkov <a.volkov@rusbitech.ru>
Date: Tue, 5 May 2015 23:04:26 +0300
Subject: [PATCH 1/1] xcb: Set _NET_WM_WINDOW_TYPE from a single place
Subject: xcb: Set _NET_WM_WINDOW_TYPE from a single place
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Merge QXcbWindow::setNetWmWindowFlags(), which was called from
QXcbWindow::setWindowFlags(), into QXcbWindow::setWmWindowType().
@ -12,16 +15,17 @@ Also reorder _NET_WM_WINDOW_TYPE atoms in QXcbWindow::setWmWindowType()
as it was in Qt 4.
Change-Id: Id1752d78f91caf04e9d16bb1ac40ed180597df7b
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
---
src/plugins/platforms/xcb/qxcbwindow.cpp | 117 ++++++++++++++++---------------
src/plugins/platforms/xcb/qxcbwindow.h | 3 +-
2 files changed, 63 insertions(+), 57 deletions(-)
diff --git a/src/plugins/platforms/xcb/qxcbwindow.cpp b/src/plugins/platforms/xcb/qxcbwindow.cpp
index 42a86ae8104641d24b0ce4dbd7418ad17bf8bd38..a0c21abf4f49fdaf52cd6ceef8e4ed66b3cd7043 100644
index cb5f410..6e021ce 100644
--- a/src/plugins/platforms/xcb/qxcbwindow.cpp
+++ b/src/plugins/platforms/xcb/qxcbwindow.cpp
@@ -762,11 +762,6 @@ void QXcbWindow::show()
@@ -873,11 +873,6 @@ void QXcbWindow::show()
updateNetWmStateBeforeMap();
}
@ -33,7 +37,7 @@ index 42a86ae8104641d24b0ce4dbd7418ad17bf8bd38..a0c21abf4f49fdaf52cd6ceef8e4ed66
if (connection()->time() != XCB_TIME_CURRENT_TIME)
updateNetWmUserTime(connection()->time());
@@ -1027,7 +1022,13 @@ void QXcbWindow::setWindowFlags(Qt::WindowFlags flags)
@@ -1140,7 +1135,13 @@ void QXcbWindow::setWindowFlags(Qt::WindowFlags flags)
xcb_change_window_attributes(xcb_connection(), xcb_window(), mask, values);
@ -48,7 +52,7 @@ index 42a86ae8104641d24b0ce4dbd7418ad17bf8bd38..a0c21abf4f49fdaf52cd6ceef8e4ed66
setMotifWindowFlags(flags);
setTransparentForMouseEvents(flags & Qt::WindowTransparentForInput);
@@ -1176,42 +1177,6 @@ void QXcbWindow::setWindowState(Qt::WindowState state)
@@ -1291,42 +1292,6 @@ void QXcbWindow::setWindowState(Qt::WindowState state)
m_windowState = state;
}
@ -91,7 +95,7 @@ index 42a86ae8104641d24b0ce4dbd7418ad17bf8bd38..a0c21abf4f49fdaf52cd6ceef8e4ed66
void QXcbWindow::updateMotifWmHintsBeforeMap()
{
QtMotifWmHints mwmhints = getMotifWmHints(connection(), m_window);
@@ -1596,10 +1561,10 @@ QXcbEGLSurface *QXcbWindow::eglSurface() const
@@ -1703,10 +1668,10 @@ QSurfaceFormat QXcbWindow::format() const
void QXcbWindow::setWmWindowTypeStatic(QWindow *window, QXcbWindowFunctions::WmWindowTypes windowTypes)
{
@ -104,8 +108,8 @@ index 42a86ae8104641d24b0ce4dbd7418ad17bf8bd38..a0c21abf4f49fdaf52cd6ceef8e4ed66
+ static_cast<QXcbWindow *>(window->handle())->setWmWindowType(windowTypes, window->flags());
}
void QXcbWindow::setWmWindowRoleStatic(QWindow *window, const QByteArray &role)
@@ -1681,40 +1646,82 @@ QXcbWindowFunctions::WmWindowTypes QXcbWindow::wmWindowTypes() const
uint QXcbWindow::visualIdStatic(QWindow *window)
@@ -1787,40 +1752,82 @@ QXcbWindowFunctions::WmWindowTypes QXcbWindow::wmWindowTypes() const
return result;
}
@ -199,19 +203,19 @@ index 42a86ae8104641d24b0ce4dbd7418ad17bf8bd38..a0c21abf4f49fdaf52cd6ceef8e4ed66
if (atoms.isEmpty()) {
Q_XCB_CALL(xcb_delete_property(xcb_connection(), m_window, atom(QXcbAtom::_NET_WM_WINDOW_TYPE)));
diff --git a/src/plugins/platforms/xcb/qxcbwindow.h b/src/plugins/platforms/xcb/qxcbwindow.h
index 2c9964c5b16dc863c4dd0837a7b71bf3dba6be65..8d754286c57e1d8e16d1b8b1b55627bfde620f10 100644
index e62bfcb..a379a6f 100644
--- a/src/plugins/platforms/xcb/qxcbwindow.h
+++ b/src/plugins/platforms/xcb/qxcbwindow.h
@@ -146,7 +146,7 @@ public:
static void setWmWindowRoleStatic(QWindow *window, const QByteArray &role);
@@ -143,7 +143,7 @@ public:
static uint visualIdStatic(QWindow *window);
QXcbWindowFunctions::WmWindowTypes wmWindowTypes() const;
- void setWmWindowType(QXcbWindowFunctions::WmWindowTypes types);
+ void setWmWindowType(QXcbWindowFunctions::WmWindowTypes types, Qt::WindowFlags flags);
void setWmWindowRole(const QByteArray &role);
bool needsSync() const;
@@ -166,7 +166,6 @@ private:
uint visualId() const;
@@ -179,7 +179,6 @@ protected:
NetWmStates netWmStates();
void setNetWmStates(NetWmStates);
@ -220,5 +224,4 @@ index 2c9964c5b16dc863c4dd0837a7b71bf3dba6be65..8d754286c57e1d8e16d1b8b1b55627bf
void updateMotifWmHintsBeforeMap();
--
2.4.2
cgit v0.11.0

View File

@ -1,8 +1,8 @@
From 0b27bcd6d15f34ad62667dd3b0f2f23f6261b2c6 Mon Sep 17 00:00:00 2001
From 552cbc0d89dcdbf32dfe652ff7d3bbe45dafe595 Mon Sep 17 00:00:00 2001
From: Alexander Volkov <a.volkov@rusbitech.ru>
Date: Thu, 7 May 2015 17:36:57 +0300
Subject: [PATCH 1/1] Restore documented behavior for the
WA_X11NetWmWindowType* attributes
Subject: [PATCH] Restore documented behavior for the WA_X11NetWmWindowType*
attributes
Use QXcbWindowFunctions::setWmWindowType() to add the corresponding
types to the window's _NET_WM_WINDOW_TYPE X11 window property.
@ -10,14 +10,29 @@ types to the window's _NET_WM_WINDOW_TYPE X11 window property.
Change-Id: Ia2413ad7a69ab8d49b448de11dd07c77101a564c
Task-number: QTBUG-39887
---
src/widgets/kernel/qwidget.cpp | 44 ++++++++++++++++++++++++++++++++++++++----
1 file changed, 40 insertions(+), 4 deletions(-)
src/src.pro | 2 +-
src/widgets/kernel/qwidget.cpp | 45 ++++++++++++++++++++++++++++++++++++++----
src/widgets/kernel/qwidget_p.h | 3 ++-
3 files changed, 44 insertions(+), 6 deletions(-)
diff --git a/src/src.pro b/src/src.pro
index b4d62aa..090ae68 100644
--- a/src/src.pro
+++ b/src/src.pro
@@ -110,7 +110,7 @@ src_platformsupport.depends = src_corelib src_gui src_platformheaders
src_widgets.subdir = $$PWD/widgets
src_widgets.target = sub-widgets
-src_widgets.depends = src_corelib src_gui src_tools_uic
+src_widgets.depends = src_corelib src_gui src_tools_uic src_platformheaders
src_opengl.subdir = $$PWD/opengl
src_opengl.target = sub-opengl
diff --git a/src/widgets/kernel/qwidget.cpp b/src/widgets/kernel/qwidget.cpp
index e38262d97fc8e28618141868165a5526cb952aa8..78680f8961b9911fafea68d33db243dba1b901c1 100644
index b2ea83c..d918b1a 100644
--- a/src/widgets/kernel/qwidget.cpp
+++ b/src/widgets/kernel/qwidget.cpp
@@ -1409,6 +1409,7 @@ void QWidgetPrivate::create_sys(WId window, bool initializeWindow, bool destroyO
@@ -1406,6 +1407,7 @@ void QWidgetPrivate::create_sys(WId window, bool initializeWindow, bool destroyO
win->setProperty("_q_showWithoutActivating", QVariant(true));
if (q->testAttribute(Qt::WA_MacAlwaysShowToolWindow))
win->setProperty("_q_macAlwaysShowToolWindow", QVariant::fromValue(QVariant(true)));
@ -25,15 +40,15 @@ index e38262d97fc8e28618141868165a5526cb952aa8..78680f8961b9911fafea68d33db243db
win->setFlags(data.window_flags);
fixPosIncludesFrame();
if (q->testAttribute(Qt::WA_Moved)
@@ -11128,7 +11129,6 @@ void QWidget::setAttribute(Qt::WidgetAttribute attribute, bool on)
@@ -11135,7 +11137,6 @@ void QWidget::setAttribute(Qt::WidgetAttribute attribute, bool on)
break;
}
-#ifdef Q_WS_X11
-#ifdef Q_DEAD_CODE_FROM_QT4_X11
case Qt::WA_X11NetWmWindowTypeDesktop:
case Qt::WA_X11NetWmWindowTypeDock:
case Qt::WA_X11NetWmWindowTypeToolBar:
@@ -11142,10 +11142,8 @@ void QWidget::setAttribute(Qt::WidgetAttribute attribute, bool on)
@@ -11149,10 +11150,8 @@ void QWidget::setAttribute(Qt::WidgetAttribute attribute, bool on)
case Qt::WA_X11NetWmWindowTypeNotification:
case Qt::WA_X11NetWmWindowTypeCombo:
case Qt::WA_X11NetWmWindowTypeDND:
@ -45,8 +60,8 @@ index e38262d97fc8e28618141868165a5526cb952aa8..78680f8961b9911fafea68d33db243db
case Qt::WA_StaticContents:
if (QWidgetBackingStore *bs = d->maybeBackingStore()) {
@@ -12784,6 +12782,44 @@ void QWidget::clearMask()
setMask(QRegion());
@@ -12796,6 +12795,44 @@ void QWidgetPrivate::setWidgetParentHelper(QObject *widgetAsObject, QObject *new
widget->setParent(static_cast<QWidget*>(newParent));
}
+void QWidgetPrivate::setNetWmWindowTypes()
@ -91,10 +106,10 @@ index e38262d97fc8e28618141868165a5526cb952aa8..78680f8961b9911fafea68d33db243db
#include "moc_qwidget.cpp"
diff --git a/src/widgets/kernel/qwidget_p.h b/src/widgets/kernel/qwidget_p.h
index 85e1cf9..2d2948a 100644
index fe65cb1..dc1c580 100644
--- a/src/widgets/kernel/qwidget_p.h
+++ b/src/widgets/kernel/qwidget_p.h
@@ -750,7 +750,6 @@ public:
@@ -752,7 +752,6 @@ public:
void setWindowRole();
void sendStartupMessage(const char *message) const;
@ -102,7 +117,7 @@ index 85e1cf9..2d2948a 100644
void x11UpdateIsOpaque();
bool isBackgroundInherited() const;
void updateX11AcceptFocus();
@@ -847,6 +846,8 @@ public:
@@ -849,6 +848,8 @@ public:
static bool qt_widget_rgn(QWidget *, short, RgnHandle, bool);
void registerTouchWindow(bool enable = true);
#endif
@ -112,5 +127,4 @@ index 85e1cf9..2d2948a 100644
bool stealMouseGrab(bool grab);
};
--
2.4.2
2.3.5

View File

@ -1,80 +1,18 @@
From f0b07d5e9d6db6b7717de198bc5bcd303705e895 Mon Sep 17 00:00:00 2001
From: Stefan Becker <chemobejk@gmail.com>
Date: Mon, 25 May 2015 17:46:49 +0300
Subject: [PATCH 1/1] xcb: set SM_CLIENT_ID property
SM_CLIENT_ID is required by kwin for proper session management.
- move client leader initialization from screen to connection
- add SM_CLIENT_ID property to client leader
Change-Id: I19fb0d098811c865f6f13d5bc3e59a173c596a65
Task-number: QTBUG-46310
---
src/plugins/platforms/xcb/qxcbconnection.cpp | 53 ++++++++++++++++++++++++++++
src/plugins/platforms/xcb/qxcbconnection.h | 2 ++
src/plugins/platforms/xcb/qxcbscreen.h | 3 --
src/plugins/platforms/xcb/qxcbwindow.cpp | 4 +--
4 files changed, 57 insertions(+), 5 deletions(-)
diff --git a/src/plugins/platforms/xcb/qxcbscreen.cpp b/src/plugins/platforms/xcb/qxcbscreen.cpp
index 7136455..264883a 100644
--- a/src/plugins/platforms/xcb/qxcbscreen.cpp
+++ b/src/plugins/platforms/xcb/qxcbscreen.cpp
@@ -163,38 +163,6 @@ QXcbScreen::QXcbScreen(QXcbConnection *connection, xcb_screen_t *scr,
else
m_syncRequestSupported = true;
- m_clientLeader = xcb_generate_id(xcb_connection());
- Q_XCB_CALL2(xcb_create_window(xcb_connection(),
- XCB_COPY_FROM_PARENT,
- m_clientLeader,
- screen()->root,
- 0, 0, 1, 1,
- 0,
- XCB_WINDOW_CLASS_INPUT_OUTPUT,
- screen()->root_visual,
- 0, 0), connection);
-#ifndef QT_NO_DEBUG
- QByteArray ba("Qt client leader window for screen ");
- ba += m_outputName.toUtf8();
- Q_XCB_CALL2(xcb_change_property(xcb_connection(),
- XCB_PROP_MODE_REPLACE,
- m_clientLeader,
- atom(QXcbAtom::_NET_WM_NAME),
- atom(QXcbAtom::UTF8_STRING),
- 8,
- ba.length(),
- ba.constData()), connection);
-#endif
-
- Q_XCB_CALL2(xcb_change_property(xcb_connection(),
- XCB_PROP_MODE_REPLACE,
- m_clientLeader,
- atom(QXcbAtom::WM_CLIENT_LEADER),
- XCB_ATOM_WINDOW,
- 32,
- 1,
- &m_clientLeader), connection);
-
xcb_depth_iterator_t depth_iterator =
xcb_screen_allowed_depths_iterator(screen());
diff --git a/src/plugins/platforms/xcb/qxcbconnection.cpp b/src/plugins/platforms/xcb/qxcbconnection.cpp
index 77e4601485bdeee8cce3b35bd746e9c1e5c2ecfd..7e234e920ac7a7e92f01fa053e9e0ffb7ae77ac1 100644
index b8b6651..06fec12 100644
--- a/src/plugins/platforms/xcb/qxcbconnection.cpp
+++ b/src/plugins/platforms/xcb/qxcbconnection.cpp
@@ -321,6 +321,7 @@ QXcbConnection::QXcbConnection(QXcbNativeInterface *nativeInterface, bool canGra
@@ -454,6 +454,7 @@ QXcbConnection::QXcbConnection(QXcbNativeInterface *nativeInterface, bool canGra
, has_xkb(false)
, m_buttons(0)
, m_focusWindow(0)
+ , m_clientLeader(0)
, m_systemTrayTracker(0)
{
#ifdef XCB_USE_EGL
@@ -1238,6 +1239,58 @@ xcb_window_t QXcbConnection::rootWindow()
return primaryScreen()->root();
}
, m_glIntegration(Q_NULLPTR)
, m_xiGrab(false)
@@ -1358,6 +1359,58 @@ void *QXcbConnection::createVisualInfoForDefaultVisualId() const
#endif
+xcb_window_t QXcbConnection::clientLeader()
+{
@ -132,40 +70,83 @@ index 77e4601485bdeee8cce3b35bd746e9c1e5c2ecfd..7e234e920ac7a7e92f01fa053e9e0ffb
{
int connection_error = xcb_connection_has_error(xcb_connection());
diff --git a/src/plugins/platforms/xcb/qxcbconnection.h b/src/plugins/platforms/xcb/qxcbconnection.h
index 9a73006cec6435039042c0f6bb94df3b8b77857f..ccc0d3e95d59e22c6f62fb3b0d082f454935c2a0 100644
index 2911936..891fa9f 100644
--- a/src/plugins/platforms/xcb/qxcbconnection.h
+++ b/src/plugins/platforms/xcb/qxcbconnection.h
@@ -394,6 +394,7 @@ public:
@@ -402,6 +402,7 @@ public:
QXcbWMSupport *wmSupport() const { return m_wmSupport.data(); }
xcb_window_t rootWindow();
+ xcb_window_t clientLeader();
#ifdef XCB_USE_XLIB
void *xlib_display() const { return m_xlib_display; }
#endif
@@ -620,6 +621,7 @@ private:
bool hasDefaultVisualId() const { return m_defaultVisualId != UINT_MAX; }
xcb_visualid_t defaultVisualId() const { return m_defaultVisualId; }
@@ -639,6 +640,7 @@ private:
QXcbWindow *m_focusWindow;
+ xcb_window_t m_clientLeader;
QByteArray m_startupId;
QXcbSystemTrayTracker *m_systemTrayTracker;
QXcbGlIntegration *m_glIntegration;
diff --git a/src/plugins/platforms/xcb/qxcbscreen.cpp b/src/plugins/platforms/xcb/qxcbscreen.cpp
index 040cea1..c7f8114 100644
--- a/src/plugins/platforms/xcb/qxcbscreen.cpp
+++ b/src/plugins/platforms/xcb/qxcbscreen.cpp
@@ -170,38 +170,6 @@ QXcbScreen::QXcbScreen(QXcbConnection *connection, QXcbVirtualDesktop *virtualDe
else
m_syncRequestSupported = true;
- m_clientLeader = xcb_generate_id(xcb_connection());
- Q_XCB_CALL2(xcb_create_window(xcb_connection(),
- XCB_COPY_FROM_PARENT,
- m_clientLeader,
- screen()->root,
- 0, 0, 1, 1,
- 0,
- XCB_WINDOW_CLASS_INPUT_OUTPUT,
- screen()->root_visual,
- 0, 0), connection);
-#ifndef QT_NO_DEBUG
- QByteArray ba("Qt client leader window for screen ");
- ba += m_outputName.toUtf8();
- Q_XCB_CALL2(xcb_change_property(xcb_connection(),
- XCB_PROP_MODE_REPLACE,
- m_clientLeader,
- atom(QXcbAtom::_NET_WM_NAME),
- atom(QXcbAtom::UTF8_STRING),
- 8,
- ba.length(),
- ba.constData()), connection);
-#endif
-
- Q_XCB_CALL2(xcb_change_property(xcb_connection(),
- XCB_PROP_MODE_REPLACE,
- m_clientLeader,
- atom(QXcbAtom::WM_CLIENT_LEADER),
- XCB_ATOM_WINDOW,
- 32,
- 1,
- &m_clientLeader), connection);
-
xcb_depth_iterator_t depth_iterator =
xcb_screen_allowed_depths_iterator(screen());
diff --git a/src/plugins/platforms/xcb/qxcbscreen.h b/src/plugins/platforms/xcb/qxcbscreen.h
index e9ab2edaa0921c0d36d0f83dd131901e6983fba4..6bc143f02a6fceca022097762d8930f10a599af9 100644
index 4451947..ccc30c0 100644
--- a/src/plugins/platforms/xcb/qxcbscreen.h
+++ b/src/plugins/platforms/xcb/qxcbscreen.h
@@ -80,8 +80,6 @@ public:
xcb_screen_t *screen() const { return m_screen; }
xcb_window_t root() const { return m_screen->root; }
@@ -116,8 +116,6 @@ public:
xcb_randr_crtc_t crtc() const { return m_crtc; }
xcb_randr_mode_t mode() const { return m_mode; }
- xcb_window_t clientLeader() const { return m_clientLeader; }
-
void windowShown(QXcbWindow *window);
QString windowManagerName() const { return m_windowManagerName; }
bool syncRequestSupported() const { return m_syncRequestSupported; }
@@ -125,7 +123,6 @@ private:
int m_number;
@@ -173,7 +171,6 @@ private:
Qt::ScreenOrientation m_orientation;
QString m_windowManagerName;
bool m_syncRequestSupported;
- xcb_window_t m_clientLeader;
@ -173,27 +154,24 @@ index e9ab2edaa0921c0d36d0f83dd131901e6983fba4..6bc143f02a6fceca022097762d8930f1
QMap<xcb_visualid_t, quint8> m_visualDepths;
QXcbCursor *m_cursor;
diff --git a/src/plugins/platforms/xcb/qxcbwindow.cpp b/src/plugins/platforms/xcb/qxcbwindow.cpp
index a0c21abf4f49fdaf52cd6ceef8e4ed66b3cd7043..9282dd45c877177a9b739fb4a606d707042642a1 100644
index edf68d4..6e39f59 100644
--- a/src/plugins/platforms/xcb/qxcbwindow.cpp
+++ b/src/plugins/platforms/xcb/qxcbwindow.cpp
@@ -519,7 +519,7 @@ void QXcbWindow::create()
@@ -623,7 +623,7 @@ void QXcbWindow::create()
xcb_set_wm_hints(xcb_connection(), m_window, &hints);
- xcb_window_t leader = m_screen->clientLeader();
- xcb_window_t leader = platformScreen->clientLeader();
+ xcb_window_t leader = connection()->clientLeader();
Q_XCB_CALL(xcb_change_property(xcb_connection(), XCB_PROP_MODE_REPLACE, m_window,
atom(QXcbAtom::WM_CLIENT_LEADER), XCB_ATOM_WINDOW, 32,
1, &leader));
@@ -747,7 +747,7 @@ void QXcbWindow::show()
@@ -864,7 +864,7 @@ void QXcbWindow::show()
// Default to client leader if there is no transient parent, else modal dialogs can
// be hidden by their parents.
if (!transientXcbParent)
- transientXcbParent = static_cast<QXcbScreen *>(screen())->clientLeader();
- transientXcbParent = xcbScreen()->clientLeader();
+ transientXcbParent = connection()->clientLeader();
if (transientXcbParent) { // ICCCM 4.1.2.6
Q_XCB_CALL(xcb_change_property(xcb_connection(), XCB_PROP_MODE_REPLACE, m_window,
XCB_ATOM_WM_TRANSIENT_FOR, XCB_ATOM_WINDOW, 32,
--
2.4.2

View File

@ -0,0 +1,110 @@
From 38c28ad2420542d795a27c5359226260c886b112 Mon Sep 17 00:00:00 2001
From: Thiago Macieira <thiago.macieira@intel.com>
Date: Tue, 2 Jun 2015 11:10:22 -0700
Subject: [PATCH] Add a linker version script to Qt libraries
This linker script is only enabled for systems with GCC or GCC-like
compilers, though technically it should work on the BSDs too (will
enable after testing). For regular modules, this declares one ELF
version "Qt_5" and places all QtCore symbols inside, then it declares
unused ELF versions "Qt_5.x" for each older minor release. For modules
declared "internal_module", all symbols are placed in version
Qt_5_PRIVATE_API.
The big advantage of an ELF version is that, when we do Qt 6, both
versions of QtCore could be loaded in memory without conflicts and all
symbols would be resolved to the correct library. No module can talk to
both at the same time, but this avoids mistakes of loading them
indirectly by plugins.
The extra Qt_5.x versions will be used in the next commit.
Change-Id: I049a653beeb5454c9539ffff13e3fe6f050fdf31
---
mkspecs/common/gcc-base-unix.conf | 1 +
mkspecs/common/qcc-base-qnx.conf | 1 +
mkspecs/features/qt_module.prf | 22 ++++++++++++++++++++++
mkspecs/linux-icc/qmake.conf | 1 +
mkspecs/unsupported/linux-host-g++/qmake.conf | 1 +
5 files changed, 26 insertions(+)
diff --git a/mkspecs/common/gcc-base-unix.conf b/mkspecs/common/gcc-base-unix.conf
index 29e0521..3e0b3ba 100644
--- a/mkspecs/common/gcc-base-unix.conf
+++ b/mkspecs/common/gcc-base-unix.conf
@@ -22,3 +22,4 @@ QMAKE_LFLAGS_USE_GOLD = -fuse-ld=gold
# -Bsymbolic-functions (ld) support
QMAKE_LFLAGS_BSYMBOLIC_FUNC = -Wl,-Bsymbolic-functions
QMAKE_LFLAGS_DYNAMIC_LIST = -Wl,--dynamic-list,
+QMAKE_LFLAGS_VERSION_SCRIPT = -Wl,--version-script,
diff --git a/mkspecs/common/qcc-base-qnx.conf b/mkspecs/common/qcc-base-qnx.conf
index a0a88b9..cebbe06 100644
--- a/mkspecs/common/qcc-base-qnx.conf
+++ b/mkspecs/common/qcc-base-qnx.conf
@@ -19,6 +19,7 @@ QMAKE_LFLAGS_RPATHLINK = -Wl,-rpath-link,
# -Bsymbolic-functions (ld) support
QMAKE_LFLAGS_BSYMBOLIC_FUNC = -Wl,-Bsymbolic-functions
QMAKE_LFLAGS_DYNAMIC_LIST = -Wl,--dynamic-list,
+QMAKE_LFLAGS_VERSION_SCRIPT = -Wl,--version-script,
# Generic options for all BlackBerry/QNX qcc mkspecs
QMAKE_CFLAGS_THREAD = -D_REENTRANT
diff --git a/mkspecs/features/qt_module.prf b/mkspecs/features/qt_module.prf
index 8919d41..3264740 100644
--- a/mkspecs/features/qt_module.prf
+++ b/mkspecs/features/qt_module.prf
@@ -185,6 +185,28 @@ equals(QT_ARCH, i386):contains(QT_CPU_FEATURES.$$QT_ARCH, sse2):compiler_support
QMAKE_CXXFLAGS += -mfpmath=sse
}
+!isEmpty(QMAKE_LFLAGS_VERSION_SCRIPT):!static {
+ verscript = $$OUT_PWD/$${TARGET}.version
+ QMAKE_LFLAGS += $${QMAKE_LFLAGS_VERSION_SCRIPT}$$verscript
+
+ internal_module {
+ verscript_content = "Qt_$${QT_MAJOR_VERSION}_PRIVATE_API { *; };"
+ } else {
+ current = Qt_$$QT_MAJOR_VERSION
+ verscript_content = "$$current { *; };"
+ for(i, 0..$$section(VERSION, ., 1, 1)) {
+ previous = $$current
+ current = Qt_$${QT_MAJOR_VERSION}.$$i
+ verscript_content += "$$current {} $$previous;"
+ }
+ }
+ write_file($$verscript, verscript_content)|error("Aborting.")
+ unset(current)
+ unset(previous)
+ unset(verscript)
+ unset(verscript_content)
+}
+
android: CONFIG += qt_android_deps
#install directives
diff --git a/mkspecs/linux-icc/qmake.conf b/mkspecs/linux-icc/qmake.conf
index 8119c8a..0cd55ee 100644
--- a/mkspecs/linux-icc/qmake.conf
+++ b/mkspecs/linux-icc/qmake.conf
@@ -97,6 +97,7 @@ QMAKE_CXXFLAGS_PRECOMPILE = -c -pch-create ${QMAKE_PCH_OUTPUT} -include ${QMAKE_
# -Bsymbolic-functions (ld) support
QMAKE_LFLAGS_BSYMBOLIC_FUNC = -Wl,-Bsymbolic-functions
QMAKE_LFLAGS_DYNAMIC_LIST = -Wl,--dynamic-list,
+QMAKE_LFLAGS_VERSION_SCRIPT = -Wl,--version-script,
# Symbol visibility control
QMAKE_CFLAGS_HIDESYMS += -fvisibility=hidden
diff --git a/mkspecs/unsupported/linux-host-g++/qmake.conf b/mkspecs/unsupported/linux-host-g++/qmake.conf
index 1523126..546ff21 100644
--- a/mkspecs/unsupported/linux-host-g++/qmake.conf
+++ b/mkspecs/unsupported/linux-host-g++/qmake.conf
@@ -71,6 +71,7 @@ QMAKE_PCH_OUTPUT_EXT = .gch
# -Bsymbolic-functions (ld) support
QMAKE_LFLAGS_BSYMBOLIC_FUNC = -Wl,-Bsymbolic-functions
QMAKE_LFLAGS_DYNAMIC_LIST = -Wl,--dynamic-list,
+QMAKE_LFLAGS_VERSION_SCRIPT = -Wl,--version-script,
#
# qmake configuration for common linux
--
2.3.5

View File

@ -0,0 +1,125 @@
From c665b0ce8c663030b856073262bd2ce30347bd7b Mon Sep 17 00:00:00 2001
From: Thiago Macieira <thiago.macieira@intel.com>
Date: Tue, 2 Jun 2015 11:15:05 -0700
Subject: [PATCH] Add a qt_version_tag symbol to QtCore that uses ELF versions
This symbol will exist with different ELF versions, allowing us to know
which version of Qt a given library or application was linked
against. When this symbol gets used, automatic packaging tools will
extract the dependency. The trick here is that the application uses
qt_version_tag without knowing which version is current, but the linker
resolves it to the current version and records that.
For example, if this were used with Qt 5.5, RPM's find-requires on an
application using QtCore would print:
libQt5Core.so.5()(64bit)
libQt5Core.so.5(Qt_5.5)(64bit)
libQt5Core.so.5(Qt_5)(64bit)
Whereas find-provides on QtCore would print:
libQt5Core.so.5()(64bit)
libQt5Core.so.5(libQt5Core.so.5)(64bit)
libQt5Core.so.5(Qt_5.0)(64bit)
libQt5Core.so.5(Qt_5.1)(64bit)
libQt5Core.so.5(Qt_5.2)(64bit)
libQt5Core.so.5(Qt_5.3)(64bit)
libQt5Core.so.5(Qt_5.4)(64bit)
libQt5Core.so.5(Qt_5.5)(64bit)
libQt5Core.so.5(Qt_5)(64bit)
Therefore, automatic dependency resolution would have the information it
needs to conclude that the application requires Qt >= 5.5.
Change-Id: I049a653beeb5454c9539ffff13e3fec9aeb50197
---
src/corelib/global/global.pri | 3 +-
src/corelib/global/qversiontagging.cpp | 62 ++++++++++++++++++++++++++++++++++
2 files changed, 64 insertions(+), 1 deletion(-)
create mode 100644 src/corelib/global/qversiontagging.cpp
diff --git a/src/corelib/global/global.pri b/src/corelib/global/global.pri
index bc11c77..fdbebca 100644
--- a/src/corelib/global/global.pri
+++ b/src/corelib/global/global.pri
@@ -27,7 +27,8 @@ SOURCES += \
global/qmalloc.cpp \
global/qnumeric.cpp \
global/qlogging.cpp \
- global/qhooks.cpp
+ global/qhooks.cpp \
+ global/qversiontagging.cpp
# qlibraryinfo.cpp includes qconfig.cpp
INCLUDEPATH += $$QT_BUILD_TREE/src/corelib/global
diff --git a/src/corelib/global/qversiontagging.cpp b/src/corelib/global/qversiontagging.cpp
new file mode 100644
index 0000000..e3d9efa
--- /dev/null
+++ b/src/corelib/global/qversiontagging.cpp
@@ -0,0 +1,62 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 Intel Corporation.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qglobal.h"
+
+#if defined(Q_CC_GNU) && defined(Q_OS_LINUX) && defined(Q_PROCESSOR_X86) && !defined(QT_STATIC)
+# define SYM QT_MANGLE_NAMESPACE(qt_version_tag)
+# define SSYM QT_STRINGIFY(SYM)
+
+asm(
+// ASM macro that makes one ELF versioned symbol qt_version_tag{sep}Qt_{major}.{minor}
+// that is an alias to qt_version_tag_{major}_{minor}.
+// The {sep} parameter must be @ for all old versions and @@ for the current version.
+".macro make_one_tag major minor sep\n"
+".globl " SSYM "_\\major\\()_\\minor\n" // make the symbol global
+SSYM "_\\major\\()_\\minor:\n" // declare it
+" .symver " SSYM "_\\major\\()_\\minor, " SSYM "\\sep\\()Qt_\\major\\().\\minor\n"
+".endm\n"
+
+".altmacro\n"
+".bss\n"
+".set qt_version_major, " QT_STRINGIFY(QT_VERSION) " >> 16\n" // set qt_version_major
+".set qt_version_minor, 0\n" // set qt_version_minor to 0 (it will grow to the current)
+".rept (" QT_STRINGIFY(QT_VERSION) " >> 8) & 0xff\n" // repeat minor version times (0 to N-1)
+" make_one_tag %qt_version_major, %qt_version_minor, @\n"
+" .set qt_version_minor, (qt_version_minor + 1)\n"
+".endr\n"
+" make_one_tag %qt_version_major, %qt_version_minor, @@\n" // call the macro for the current version
+" .space 1\n" // variable is 1 byte, value 0
+);
+
+#endif
--
2.3.5

View File

@ -0,0 +1,145 @@
From 7a2d2a1c3b66308cf03a00757f8fd97f043ccde4 Mon Sep 17 00:00:00 2001
From: Thiago Macieira <thiago.macieira@intel.com>
Date: Tue, 2 Jun 2015 11:30:57 -0700
Subject: [PATCH] Add an automatic use of the ELF-versioned QtCore symbol
See the comment in the header for an explanation of what it does.
This trick is enabled for every single .o that is compiled, unless
QT_NO_VERSION_TAGGING is defined. The assembly expands to a COMDAT
section, which is mergeable by the linker, so only one copy of the
output is present in the ELF module.
The next commit will add a configure-time option to set
QT_NO_VERSION_TAGGING to qconfig.h.
This is enabled only for Linux and x86 / x86-64 / x32 due to the
requirement of writing assembly and relocations, so it needs to be
tested on each platform, which I have not done. It probably works on the
BSDs too and might work on Solaris/x86, but again it requires
testing. Support for other architectures requires different assembly
output and relocations and can be added as needed, but they are not as
important since this trick is has most value on desktop systems.
Change-Id: I049a653beeb5454c9539ffff13e3ff5782a8cb86
---
src/corelib/global/global.pri | 3 +-
src/corelib/global/qglobal.h | 1 +
src/corelib/global/qversiontagging.h | 80 ++++++++++++++++++++++++++++++++++++
3 files changed, 83 insertions(+), 1 deletion(-)
create mode 100644 src/corelib/global/qversiontagging.h
diff --git a/src/corelib/global/global.pri b/src/corelib/global/global.pri
index fdbebca..9f31fb9 100644
--- a/src/corelib/global/global.pri
+++ b/src/corelib/global/global.pri
@@ -17,7 +17,8 @@ HEADERS += \
global/qisenum.h \
global/qtypetraits.h \
global/qflags.h \
- global/qhooks_p.h
+ global/qhooks_p.h \
+ global/qversiontagging.h
SOURCES += \
global/archdetect.cpp \
diff --git a/src/corelib/global/qglobal.h b/src/corelib/global/qglobal.h
index c4e2f76..e7995ac 100644
--- a/src/corelib/global/qglobal.h
+++ b/src/corelib/global/qglobal.h
@@ -1103,6 +1103,7 @@ QT_END_NAMESPACE
#include <QtCore/qatomic.h>
#include <QtCore/qglobalstatic.h>
#include <QtCore/qnumeric.h>
+#include <QtCore/qversiontagging.h>
#endif /* __cplusplus */
diff --git a/src/corelib/global/qversiontagging.h b/src/corelib/global/qversiontagging.h
new file mode 100644
index 0000000..94246dd
--- /dev/null
+++ b/src/corelib/global/qversiontagging.h
@@ -0,0 +1,80 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 Intel Corporation.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+// qglobal.h includes this header, so keep it outside of our include guards
+#include <QtCore/qglobal.h>
+
+#if !defined(QVERSIONTAGGING_H) && !defined(QT_NO_VERSION_TAGGING)
+#define QVERSIONTAGGING_H
+
+QT_BEGIN_NAMESPACE
+
+/*
+ * Ugly hack warning and explanation:
+ *
+ * This file causes all ELF modules, be they libraries or applications, to use the
+ * qt_version_tag symbol that is present in QtCore. Such symbol is versioned,
+ * so the linker will automatically pull the current Qt version and add it to
+ * the ELF header of the library/application. The assembly produces one section
+ * called ".qtversion" containing two pointer-sized values. The first is a
+ * relocation to the qt_version_tag symbol (which is what causes the ELF
+ * version to get used). The second value is the current Qt version at the time
+ * of compilation.
+ *
+ * There will only be one copy of the section in the output library or application.
+ */
+
+#if defined(QT_BUILD_CORE_LIB)
+// skip
+#elif defined(Q_CC_GNU)
+# if defined(Q_PROCESSOR_X86) && defined(Q_OS_LINUX)
+asm (
+".section .qtversion, \"aG\", @progbits, qt_version_tag, comdat\n"
+".align 8\n"
+# ifdef __LP64__
+".quad " QT_STRINGIFY(QT_MANGLE_NAMESPACE(qt_version_tag)) "@GOTPCREL\n"
+# elif defined(Q_PROCESSOR_X86_64) // x32
+".long " QT_STRINGIFY(QT_MANGLE_NAMESPACE(qt_version_tag)) "@GOTPCREL\n"
+# else // x86
+".long " QT_STRINGIFY(QT_MANGLE_NAMESPACE(qt_version_tag)) "@GOT\n"
+#endif
+".long " QT_STRINGIFY(QT_VERSION) "\n"
+".align 8\n"
+".previous"
+);
+# endif
+#endif
+
+QT_END_NAMESPACE
+
+#endif // QVERSIONTAGGING_H && !QT_NO_VERSION_TAGGING
--
2.3.5

View File

@ -1,35 +0,0 @@
From 365c63e7b177701c0bf80a7cb138b7559b92f350 Mon Sep 17 00:00:00 2001
From: Gatis Paeglis <gatis.paeglis@theqtcompany.com>
Date: Tue, 14 Apr 2015 14:00:05 +0200
Subject: Fix regression in compose table parsing
Performance optimization from 1aab68648 revealed
that "composeValueEnd" needs adjustment for compose
sequences that result in a quotation mark, for example:
<dead_diaeresis> <space> : "\"" quotedbl # REVERSE SOLIDUS
Change-Id: I66bf83fbe62727f1ee245aae90f8d0eb53dea6d4
Task-number: QTBUG-45538
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
---
.../platforminputcontexts/compose/generator/qtablegenerator.cpp | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/src/plugins/platforminputcontexts/compose/generator/qtablegenerator.cpp b/src/plugins/platforminputcontexts/compose/generator/qtablegenerator.cpp
index 120b228..65020eb 100644
--- a/src/plugins/platforminputcontexts/compose/generator/qtablegenerator.cpp
+++ b/src/plugins/platforminputcontexts/compose/generator/qtablegenerator.cpp
@@ -385,6 +385,10 @@ void TableGenerator::parseKeySequence(char *line)
if (!composeValueEnd)
return;
+ // if composed value is a quotation mark adjust the end pointer
+ if (composeValueEnd[1] == '"')
+ ++composeValueEnd;
+
if (*composeValue == '\\' && composeValue[1] >= '0' && composeValue[1] <= '9') {
// handle octal and hex code values
char detectBase = composeValue[2];
--
cgit v0.11.0

View File

@ -1,7 +1,7 @@
From 3426ce9b8e62e8d76db0d9cc2899113c0c3cb073 Mon Sep 17 00:00:00 2001
From 849aebc0ce344dedc91035bf4bcc7ccb4c15ffe4 Mon Sep 17 00:00:00 2001
From: David Faure <david.faure@kdab.com>
Date: Mon, 27 Jul 2015 00:22:11 +0200
Subject: [PATCH 1/1] QMimeDatabase: use QElapsedTimer instead of
Subject: [PATCH] QMimeDatabase: use QElapsedTimer instead of
QDateTime::currentDateTime()
This reduces the number of syscalls greatly, by avoiding the timezone
@ -14,10 +14,10 @@ Change-Id: I39a54def4b45f25c6e037ced6943b05ddc749c9d
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/src/corelib/mimetypes/qmimeprovider.cpp b/src/corelib/mimetypes/qmimeprovider.cpp
index cca9a40b9f28e1b45a6e5e0172f512c5880a10d6..9f6bdb30981f4f236ef422cfd16f6c1cd38c643f 100644
index 7342a5c..3914710 100644
--- a/src/corelib/mimetypes/qmimeprovider.cpp
+++ b/src/corelib/mimetypes/qmimeprovider.cpp
@@ -77,10 +77,9 @@ Q_CORE_EXPORT int qmime_secondsBetweenChecks = 5; // exported for the unit test
@@ -79,10 +79,9 @@ Q_CORE_EXPORT int qmime_secondsBetweenChecks = 5; // exported for the unit test
bool QMimeProviderBase::shouldCheck()
{
@ -31,18 +31,18 @@ index cca9a40b9f28e1b45a6e5e0172f512c5880a10d6..9f6bdb30981f4f236ef422cfd16f6c1c
}
diff --git a/src/corelib/mimetypes/qmimeprovider_p.h b/src/corelib/mimetypes/qmimeprovider_p.h
index 027fddd2c81ddb52fb3c383edfeda3a03f9ccaac..e4bc55a1a2deb5f4d030f451dd97729c2ca95bb8 100644
index 5a89ac2..eaf9594 100644
--- a/src/corelib/mimetypes/qmimeprovider_p.h
+++ b/src/corelib/mimetypes/qmimeprovider_p.h
@@ -48,6 +48,7 @@
@@ -51,6 +51,7 @@
#include <QtCore/qdatetime.h>
#include "qmimedatabase_p.h"
#include <QtCore/qset.h>
+#include <QtCore/qelapsedtimer.h>
QT_BEGIN_NAMESPACE
@@ -74,7 +75,7 @@ public:
@@ -77,7 +78,7 @@ public:
QMimeDatabasePrivate *m_db;
protected:
bool shouldCheck();
@ -52,5 +52,4 @@ index 027fddd2c81ddb52fb3c383edfeda3a03f9ccaac..e4bc55a1a2deb5f4d030f451dd97729c
/*
--
2.4.6
2.3.5

View File

@ -0,0 +1,54 @@
From ae51e360f986698eaf41fdb38f8a878a50f69be1 Mon Sep 17 00:00:00 2001
From: Alexander Volkov <a.volkov@rusbitech.ru>
Date: Fri, 19 Jun 2015 13:34:11 +0300
Subject: xcb: Ignore disabling of outputs in the middle of the mode switch
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X server may send RROutputChangeNotify event with null crtc and mode,
when it switches an output mode. Request RROutputInfo to distinguish
this case from the case when the output is explicitly disabled.
Change-Id: I4c2356ec71dbcc8013009ea8a6f46dd11f19d6bb
Task-number: QTBUG-44158
Task-number: QTBUG-46786
Task-number: QTBUG-46822
Reviewed-by: Daniel Vrátil <dvratil@redhat.com>
Reviewed-by: Gatis Paeglis <gatis.paeglis@digia.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
---
src/plugins/platforms/xcb/qxcbconnection.cpp | 18 +++++++++++++-----
1 file changed, 13 insertions(+), 5 deletions(-)
diff --git a/src/plugins/platforms/xcb/qxcbconnection.cpp b/src/plugins/platforms/xcb/qxcbconnection.cpp
index 0867615..29e1fd1 100644
--- a/src/plugins/platforms/xcb/qxcbconnection.cpp
+++ b/src/plugins/platforms/xcb/qxcbconnection.cpp
@@ -265,11 +265,19 @@ void QXcbConnection::updateScreens(const xcb_randr_notify_event_t *event)
} else if (screen) {
// Screen has been disabled -> remove
if (output.crtc == XCB_NONE && output.mode == XCB_NONE) {
- qCDebug(lcQpaScreen) << "output" << screen->name() << "has been disabled";
- m_screens.removeOne(screen);
- foreach (QXcbScreen *otherScreen, m_screens)
- otherScreen->removeVirtualSibling((QPlatformScreen *) screen);
- QXcbIntegration::instance()->destroyScreen(screen);
+ xcb_randr_get_output_info_cookie_t outputInfoCookie =
+ xcb_randr_get_output_info(xcb_connection(), output.output, output.config_timestamp);
+ QScopedPointer<xcb_randr_get_output_info_reply_t, QScopedPointerPodDeleter> outputInfo(
+ xcb_randr_get_output_info_reply(xcb_connection(), outputInfoCookie, NULL));
+ if (outputInfo->crtc == XCB_NONE) {
+ qCDebug(lcQpaScreen) << "output" << screen->name() << "has been disabled";
+ m_screens.removeOne(screen);
+ foreach (QXcbScreen *otherScreen, m_screens)
+ otherScreen->removeVirtualSibling((QPlatformScreen *) screen);
+ QXcbIntegration::instance()->destroyScreen(screen);
+ } else {
+ qCDebug(lcQpaScreen) << "output" << screen->name() << "has been temporarily disabled for the mode switch";
+ }
} else {
// Just update existing screen
screen->updateGeometry(output.config_timestamp);
--
cgit v0.11.0

View File

@ -4,10 +4,10 @@
--- a/src/gui/text/qtextengine.cpp
+++ b/src/gui/text/qtextengine.cpp
@@ -1549,6 +1549,7 @@ void QTextEngine::itemize() const
case QChar::Script_Hiragana:
@@ -1640,6 +1640,7 @@ void QTextEngine::itemize() const
case QChar::Script_Katakana:
case QChar::Script_Bopomofo:
case QChar::Script_Han:
+ case QChar::Script_Gujarati:
analysis[i].script = QChar::Script_Common;
break;

View File

@ -1,11 +0,0 @@
--- qtbase/qmake/generators/unix/unixmake2.cpp 2012/11/12 14:21:54 1.1
+++ qtbase/qmake/generators/unix/unixmake2.cpp 2012/11/12 14:22:13
@@ -1320,7 +1320,7 @@ UnixMakefileGenerator::writeLibtoolFile(
QTextStream t(&ft);
t << "# " << lname << " - a libtool library file\n";
t << "# Generated by qmake/libtool (" QMAKE_VERSION_STR ") (Qt "
- << QT_VERSION_STR << ") on: " << QDateTime::currentDateTime().toString();
+ << QT_VERSION_STR << ")";
t << "\n";
t << "# The name that we can dlopen(3).\n"

View File

@ -1,3 +1,33 @@
-------------------------------------------------------------------
Tue Aug 18 16:38:29 UTC 2015 - hrvoje.senjan@gmail.com
- Added patches from upstream:
ignore-disabling-of-outputs-in-the-middle-of-the-mode-switch.patch
(qtbug#44158, qtbug#46786, qtbug#46822)
when-a-screen-comes-back-online-the-windows-need-to-be-told-about-it.patch
(qtbug#47041)
-------------------------------------------------------------------
Sun Aug 16 08:31:58 UTC 2015 - hrvoje.senjan@gmail.com
- Update to 5.5.0
* For more details please see:
http://blog.qt.io/blog/2015/07/01/qt-5-5-released/
and https://wiki.qt.io/New_Features_in_Qt_5.5
- Drop patches merged upstream:
0001-Speed-up-compose-file-parsing-in-the-X11-composition.patch,
0002-Speed-up-application-startup-on-X11.patch,
Fix-regression-in-compose-table-parsing.patch,
libqt5-libtool-nodate.diff and
make-qdbusxml2cpp-output-reproducible.patch
- Add patches from upstream:
Add-a-linker-version-script-to-Qt-libraries.patch,
Add-a-qt_version_tag-symbol-to-QtCore-that-uses-ELF-versions.patch
and Add-an-automatic-use-of-the-ELF-versioned-QtCore-symbol.patch
- Added tslib-devel and libinput-devel (Build)Requires
- Drop all openSUSE 13.1 conditionals, we won't build Qt >= 5.5 on
that distro version anymore
-------------------------------------------------------------------
Tue Aug 4 19:05:31 UTC 2015 - hrvoje.senjan@gmail.com

View File

@ -26,15 +26,15 @@
%endif
Name: libqt5-qtbase
Version: 5.4.2
Version: 5.5.0
Release: 0
Summary: C++ Program Library, Core Components
License: GPL-3.0 or SUSE-LGPL-2.1-with-digia-exception-1.1
Group: System/Libraries
Url: http://qt.digia.com
%define base_name libqt5
%define real_version 5.4.2
%define so_version 5.4.2
%define real_version 5.5.0
%define so_version 5.5.0
%define tar_version qtbase-opensource-src-%{real_version}
Source: %{tar_version}.tar.xz
# to get mtime of file:
@ -43,8 +43,6 @@ Source2: macros.qt5
Source3: baselibs.conf
Source99: libqt5-qtbase-rpmlintrc
# patches 0-1000 are openSUSE and/or non-upstream(able) patches #
# PATCH-FIX-UPSTREAM libqt5-libtool-nodate.diff -- for ommiting date/time on build
Patch0: libqt5-libtool-nodate.diff
# PATCH-FIX-UPSTREAM use-freetype-default.patch -- allow using lcd-default filter regardless of how freetype2 library has been built (w/ & w/o subpixel)
Patch2: use-freetype-default.patch
# PATCH-FIX-SUSE libqt5-Fix-Gujarati-font.patch bnc#878292 fix broken Gujarati font rendering
@ -53,18 +51,12 @@ Patch3: libqt5-Fix-Gujarati-font.patch
Patch4: protect-geometry-QTBUG-40584.patch
# Patch-FIX-SUSE libqt5-do-not-use-shm-if-display-name-doesnt-look-local.patch -- bnc#888858
Patch5: libqt5-do-not-use-shm-if-display-name-doesnt-look-local.patch
# PATCH-FIX-OPENSUSE make-qdbusxml2cpp-output-reproducible.patch -- https://codereview.qt-project.org/#/c/105210/1
Patch7: make-qdbusxml2cpp-output-reproducible.patch
# PATCH-FIX-OPENSUSE Fix-shortcuts-with-keypad-keys.patch -- https://codereview.qt-project.org/#/c/95219/
Patch8: Fix-shortcuts-with-keypad-keys.patch
# patches 1000-2000 and above from upstream 5.3 branch #
# patches 2000-3000 and above from upstream 5.5 branch #
# PATCH-FIX-UPSTREAM 0001-Speed-up-compose-file-parsing-in-the-X11-composition.patch
Patch2007: 0001-Speed-up-compose-file-parsing-in-the-X11-composition.patch
# PATCH-FIX-UPSTREAM 0002-Speed-up-application-startup-on-X11.patch
Patch2008: 0002-Speed-up-application-startup-on-X11.patch
# PATCH-FIX-UPSTREAM Fix-regression-in-compose-table-parsing.patch
Patch2009: Fix-regression-in-compose-table-parsing.patch
Patch2000: ignore-disabling-of-outputs-in-the-middle-of-the-mode-switch.patch
Patch2001: when-a-screen-comes-back-online-the-windows-need-to-be-told-about-it.patch
Patch2010: 0001-Fix-QWidget-setWindowRole.patch
Patch2011: 0002-xcb-Fix-getting-the-window-types-from-the-property-o.patch
Patch2012: 0003-Fix-centering-dialogs.patch
@ -72,6 +64,9 @@ Patch2013: 0004-xcb-Set-_NET_WM_WINDOW_TYPE-from-a-single-place.patch
Patch2014: 0005-Restore-documented-behavior-for-the-WA_X11NetWmWindo.patch
Patch2015: 0006-xcb-set-SM_CLIENT_ID-property.patch
Patch2016: QMimeDatabase-use-QElapsedTimer.patch
Patch3000: Add-a-linker-version-script-to-Qt-libraries.patch
Patch3001: Add-a-qt_version_tag-symbol-to-QtCore-that-uses-ELF-versions.patch
Patch3002: Add-an-automatic-use-of-the-ELF-versioned-QtCore-symbol.patch
BuildRequires: alsa-devel
BuildRequires: cups-devel
BuildRequires: gcc-c++
@ -103,6 +98,7 @@ BuildRequires: pkgconfig(glesv2)
%endif
BuildRequires: libicu-devel
BuildRequires: libpulse-devel
BuildRequires: tslib-devel
BuildRequires: xcb-util-image-devel
BuildRequires: xcb-util-keysyms-devel
BuildRequires: xcb-util-renderutil-devel
@ -111,18 +107,13 @@ BuildRequires: xorg-x11-devel
BuildRequires: xz
BuildRequires: pkgconfig(glib-2.0)
BuildRequires: pkgconfig(gtk+-2.0)
BuildRequires: pkgconfig(libudev)
%if 0%{?suse_version} > 1310
BuildRequires: pkgconfig(harfbuzz)
%endif
BuildRequires: pkgconfig(ice)
BuildRequires: pkgconfig(libinput)
BuildRequires: pkgconfig(libudev)
BuildRequires: pkgconfig(sm)
%if 0%{?suse_version} > 1310
BuildRequires: pkgconfig(xkbcommon) >= 0.4.1
BuildRequires: pkgconfig(xkbcommon-x11) >= 0.4.1
%else
BuildRequires: xkeyboard-config
%endif
%if %journald
BuildRequires: pkgconfig(libsystemd-journal)
%endif
@ -152,23 +143,23 @@ handling.
%prep
%setup -q -n qtbase-opensource-src-%{real_version}
%patch0 -p1
%patch2 -p1
%patch3 -p1
%patch4 -p1
%patch5 -p1
%patch7 -p0
%patch8 -p1
%patch2007 -p1
%patch2008 -p1
%patch2009 -p1
%patch2010 -p1
%patch2000 -p1
%patch2001 -p1
%patch2011 -p1
%patch2012 -p1
%patch2013 -p1
%patch2010 -p1
%patch2014 -p1
%patch2015 -p1
%patch2016 -p1
%patch3000 -p1
%patch3001 -p1
%patch3002 -p1
# be sure not to use them
rm -r src/3rdparty/{libjpeg,freetype,libpng,zlib}
@ -637,16 +628,20 @@ Requires: libQt5Core-devel = %{version}
Requires: libQt5Gui-devel = %{version}
Requires: libQt5PlatformHeaders-devel = %{version}
# List the below ones manually - they are private, but this is a static lib
Requires: tslib-devel
Requires: pkgconfig(Qt5DBus)
Requires: pkgconfig(egl)
Requires: pkgconfig(fontconfig)
Requires: pkgconfig(freetype2)
Requires: pkgconfig(gl)
Requires: pkgconfig(glib-2.0)
Requires: pkgconfig(libinput)
Requires: pkgconfig(libudev)
Requires: pkgconfig(mtdev)
Requires: pkgconfig(x11)
Requires: pkgconfig(xext)
Requires: pkgconfig(xkbcommon) >= 0.4.1
Requires: pkgconfig(xkbcommon-x11) >= 0.4.1
Requires: pkgconfig(xrender)
%description -n libQt5PlatformSupport-devel-static
@ -703,10 +698,10 @@ platform="-platform linux-g++-64"
platform=""
%endif
%define xkbconfigroot %(pkg-config --variable=xkb_base xkeyboard-config)
%if %qt5_snapshot
#if %qt5_snapshot
#force the configure script to generate the forwarding headers (it checks whether .git directory exists)
mkdir .git
%endif
#endif
# Record mtime of changes file instead of build time
export CHANGES=`stat --format="%y" %{SOURCE1}|cut --characters=1-10`
sed -i 's|qt_instdate=`date +%Y-%m-%d`|qt_instdate=$CHANGES|g' configure
@ -744,12 +739,7 @@ echo yes | ./configure $platform \
-no-separate-debug-info \
-shared \
-xkb \
%if 0%{?suse_version} >= 1315
-system-xkbcommon \
%else
-qt-xkbcommon \
-xkb-config-root %{xkbconfigroot} \
%endif
-xrender \
-xcursor \
-dbus-linked \
@ -761,9 +751,7 @@ echo yes | ./configure $platform \
-system-libjpeg \
-openssl-linked \
-system-libpng \
%if 0%{?suse_version} > 1310
-system-harfbuzz \
%endif
-fontconfig \
-system-freetype \
-cups \
@ -1069,10 +1057,14 @@ popd
%ifarch %ix86
%{libqt5_libdir}/sse2/libQt5Gui.so.*
%endif
%{libqt5_libdir}/libQt5EglDeviceIntegration.so.*
%{libqt5_libdir}/libQt5XcbQpa.so.*
%{libqt5_plugindir}/generic
%{libqt5_plugindir}/imageformats
%{libqt5_plugindir}/platforminputcontexts
%{libqt5_plugindir}/platforms
%{libqt5_plugindir}/egldeviceintegrations
%{libqt5_plugindir}/xcbglintegrations
%files platformtheme-gtk2
%defattr(-,root,root,755)
@ -1160,9 +1152,15 @@ popd
%files -n libQt5PlatformSupport-devel-static
%defattr(-,root,root,755)
%doc *.txt LICENSE.*
%{libqt5_libdir}/libQt5EglDeviceIntegration.so
%{libqt5_libdir}/libQt5XcbQpa.so
%{libqt5_libdir}/libQt5PlatformSupport.a
%{libqt5_libdir}/libQt5PlatformSupport.prl
%{libqt5_libdir}/libQt5EglDeviceIntegration.prl
%{libqt5_libdir}/libQt5XcbQpa.prl
%{libqt5_libdir}/pkgconfig/Qt5PlatformSupport.pc
%{libqt5_libdir}/pkgconfig/Qt5EglDeviceIntegration.pc
%{libqt5_libdir}/pkgconfig/Qt5XcbQpa.pc
%{libqt5_includedir}/QtPlatformSupport/
%exclude %{libqt5_includedir}/QtPlatformSupport/%{so_version}

View File

@ -1,53 +0,0 @@
--- src/tools/qdbusxml2cpp/qdbusxml2cpp.cpp.old 2014-12-05 17:24:31.000000000 +0100
+++ src/tools/qdbusxml2cpp/qdbusxml2cpp.cpp 2015-02-03 16:11:26.574739176 +0100
@@ -32,7 +32,6 @@
****************************************************************************/
#include <qbytearray.h>
-#include <qdatetime.h>
#include <qdebug.h>
#include <qfile.h>
#include <qfileinfo.h>
@@ -58,7 +57,6 @@ static QString parentClassName;
static QString proxyFile;
static QString adaptorFile;
static QString inputFile;
-static QDateTime classCreationTime;
static bool skipNamespaces;
static bool verbose;
static bool includeMocs;
@@ -212,10 +210,8 @@ static QDBusIntrospection::Interfaces re
QFile input(inputFile);
if (inputFile.isEmpty() || inputFile == QLatin1String("-")) {
input.open(stdin, QIODevice::ReadOnly);
- classCreationTime = QDateTime::currentDateTime();
} else {
input.open(QIODevice::ReadOnly);
- classCreationTime = QFileInfo(input).lastModified();
}
QByteArray data = input.readAll();
@@ -551,9 +547,8 @@ static void writeProxy(const QString &fi
} else {
includeGuard = QLatin1String("QDBUSXML2CPP_PROXY");
}
- includeGuard = QString(QLatin1String("%1_%2"))
- .arg(includeGuard)
- .arg(classCreationTime.toTime_t());
+ includeGuard = QString(QLatin1String("%1"))
+ .arg(includeGuard);
hs << "#ifndef " << includeGuard << endl
<< "#define " << includeGuard << endl
<< endl;
@@ -859,9 +854,8 @@ static void writeAdaptor(const QString &
} else {
includeGuard = QLatin1String("QDBUSXML2CPP_ADAPTOR");
}
- includeGuard = QString(QLatin1String("%1_%2"))
- .arg(includeGuard)
- .arg(QDateTime::currentDateTime().toTime_t());
+ includeGuard = QString(QLatin1String("%1"))
+ .arg(includeGuard);
hs << "#ifndef " << includeGuard << endl
<< "#define " << includeGuard << endl
<< endl;

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:9fc4f720b8b5a8b8e4a7d45e13ce4d5b86756ad46fb406386637eb2de5fd5a74
size 46354192

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:893f0691739c00d13ff85bf8d3fd14e1c7a62fbbbcffa44b0491da4d5e570965
size 46245180

View File

@ -0,0 +1,43 @@
From b0b08cc0e4e38504d6b833702f7477aee4e2a192 Mon Sep 17 00:00:00 2001
From: Ralf Jung <post@ralfj.de>
Date: Sun, 5 Jul 2015 12:15:29 +0200
Subject: When a screen comes back online, the windows need to be told about it
On my system, this fixes the misbehavior of Qt applications when the (only) active screen is
switched, e.g. from an external screen to the laptop.
This behavior is caused by the screen() of widgets to be set to NULL when their screen goes away.
When a new screen comes online, the widgets *should* be told about it, but they are not. The only
place that "maybeSetScreen" is called is when an existing screen changes its geometry, but not
when a screen gets enabled without its geometry being affected in any way (e.g. because it was
just disabled via xrandr, but has been connected all along). This makes sure that "maybeSetScreen"
is also called when a screen gets enabled.
Task-number: QTBUG-47041
Change-Id: Ic72d6beaa544bf9a4efdbea0830b1bc0d6ce5362
Reviewed-by: Dmitry Shachnev <mitya57@gmail.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
---
src/plugins/platforms/xcb/qxcbconnection.cpp | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/src/plugins/platforms/xcb/qxcbconnection.cpp b/src/plugins/platforms/xcb/qxcbconnection.cpp
index 74f48b0..0867615 100644
--- a/src/plugins/platforms/xcb/qxcbconnection.cpp
+++ b/src/plugins/platforms/xcb/qxcbconnection.cpp
@@ -252,6 +252,14 @@ void QXcbConnection::updateScreens(const xcb_randr_notify_event_t *event)
otherScreen->addVirtualSibling(screen);
m_screens << screen;
QXcbIntegration::instance()->screenAdded(screen, screen->isPrimary());
+
+ // Windows which had null screens have already had expose events by now.
+ // They need to be told the screen is back, it's OK to render.
+ foreach (QWindow *window, QGuiApplication::topLevelWindows()) {
+ QXcbWindow *xcbWin = static_cast<QXcbWindow*>(window->handle());
+ if (xcbWin)
+ xcbWin->maybeSetScreen(screen);
+ }
}
// else ignore disabled screens
} else if (screen) {
--
cgit v0.11.0