apply proposed fixes for QTBUG-34614,37380,38585 for LibreOffice (#1105422)
* Fri Jun 06 2014 Kevin Kofler <Kevin@tigcc.ticalc.org> 4.8.6-9 - apply proposed fixes for QTBUG-34614,37380,38585 for LibreOffice (#1105422)
This commit is contained in:
parent
0aff623ddf
commit
0da40876de
94
qt-everywhere-opensource-src-4.8.6-QTBUG-34614.patch
Normal file
94
qt-everywhere-opensource-src-4.8.6-QTBUG-34614.patch
Normal file
@ -0,0 +1,94 @@
|
|||||||
|
--- src/corelib/kernel/qeventdispatcher_glib.cpp.sav 2014-03-28 15:26:37.000000000 +0100
|
||||||
|
+++ src/corelib/kernel/qeventdispatcher_glib.cpp 2014-04-24 09:44:09.358659204 +0200
|
||||||
|
@@ -255,22 +255,30 @@ struct GPostEventSource
|
||||||
|
GSource source;
|
||||||
|
QAtomicInt serialNumber;
|
||||||
|
int lastSerialNumber;
|
||||||
|
+ QEventLoop::ProcessEventsFlags processEventsFlags;
|
||||||
|
QEventDispatcherGlibPrivate *d;
|
||||||
|
};
|
||||||
|
|
||||||
|
static gboolean postEventSourcePrepare(GSource *s, gint *timeout)
|
||||||
|
{
|
||||||
|
+ GPostEventSource *source = reinterpret_cast<GPostEventSource *>(s);
|
||||||
|
QThreadData *data = QThreadData::current();
|
||||||
|
if (!data)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
+ QEventLoop::ProcessEventsFlags excludeAllFlags
|
||||||
|
+ = QEventLoop::ExcludeUserInputEvents
|
||||||
|
+ | QEventLoop::ExcludeSocketNotifiers
|
||||||
|
+ | QEventLoop::X11ExcludeTimers;
|
||||||
|
+ if ((source->processEventsFlags & excludeAllFlags) == excludeAllFlags)
|
||||||
|
+ return false;
|
||||||
|
+
|
||||||
|
gint dummy;
|
||||||
|
if (!timeout)
|
||||||
|
timeout = &dummy;
|
||||||
|
const bool canWait = data->canWaitLocked();
|
||||||
|
*timeout = canWait ? -1 : 0;
|
||||||
|
|
||||||
|
- GPostEventSource *source = reinterpret_cast<GPostEventSource *>(s);
|
||||||
|
return (!canWait
|
||||||
|
|| (source->serialNumber != source->lastSerialNumber));
|
||||||
|
}
|
||||||
|
@@ -284,8 +292,14 @@ static gboolean postEventSourceDispatch(
|
||||||
|
{
|
||||||
|
GPostEventSource *source = reinterpret_cast<GPostEventSource *>(s);
|
||||||
|
source->lastSerialNumber = source->serialNumber;
|
||||||
|
- QCoreApplication::sendPostedEvents();
|
||||||
|
- source->d->runTimersOnceWithNormalPriority();
|
||||||
|
+ QEventLoop::ProcessEventsFlags excludeAllFlags
|
||||||
|
+ = QEventLoop::ExcludeUserInputEvents
|
||||||
|
+ | QEventLoop::ExcludeSocketNotifiers
|
||||||
|
+ | QEventLoop::X11ExcludeTimers;
|
||||||
|
+ if ((source->processEventsFlags & excludeAllFlags) != excludeAllFlags) {
|
||||||
|
+ QCoreApplication::sendPostedEvents();
|
||||||
|
+ source->d->runTimersOnceWithNormalPriority();
|
||||||
|
+ }
|
||||||
|
return true; // i dunno, george...
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -329,6 +343,7 @@ QEventDispatcherGlibPrivate::QEventDispa
|
||||||
|
postEventSource = reinterpret_cast<GPostEventSource *>(g_source_new(&postEventSourceFuncs,
|
||||||
|
sizeof(GPostEventSource)));
|
||||||
|
postEventSource->serialNumber = 1;
|
||||||
|
+ postEventSource->processEventsFlags = QEventLoop::AllEvents;
|
||||||
|
postEventSource->d = this;
|
||||||
|
g_source_set_can_recurse(&postEventSource->source, true);
|
||||||
|
g_source_attach(&postEventSource->source, mainContext);
|
||||||
|
@@ -423,6 +438,7 @@ bool QEventDispatcherGlib::processEvents
|
||||||
|
|
||||||
|
// tell postEventSourcePrepare() and timerSource about any new flags
|
||||||
|
QEventLoop::ProcessEventsFlags savedFlags = d->timerSource->processEventsFlags;
|
||||||
|
+ d->postEventSource->processEventsFlags = flags;
|
||||||
|
d->timerSource->processEventsFlags = flags;
|
||||||
|
d->socketNotifierSource->processEventsFlags = flags;
|
||||||
|
|
||||||
|
@@ -435,6 +451,7 @@ bool QEventDispatcherGlib::processEvents
|
||||||
|
while (!result && canWait)
|
||||||
|
result = g_main_context_iteration(d->mainContext, canWait);
|
||||||
|
|
||||||
|
+ d->postEventSource->processEventsFlags = savedFlags;
|
||||||
|
d->timerSource->processEventsFlags = savedFlags;
|
||||||
|
d->socketNotifierSource->processEventsFlags = savedFlags;
|
||||||
|
|
||||||
|
--- src/corelib/kernel/qeventdispatcher_unix.cpp.sav 2013-06-07 07:16:52.000000000 +0200
|
||||||
|
+++ src/corelib/kernel/qeventdispatcher_unix.cpp 2014-04-24 09:43:06.927589535 +0200
|
||||||
|
@@ -905,7 +905,15 @@ bool QEventDispatcherUNIX::processEvents
|
||||||
|
|
||||||
|
// we are awake, broadcast it
|
||||||
|
emit awake();
|
||||||
|
- QCoreApplicationPrivate::sendPostedEvents(0, 0, d->threadData);
|
||||||
|
+
|
||||||
|
+ QEventLoop::ProcessEventsFlags excludeAllFlags
|
||||||
|
+ = QEventLoop::ExcludeUserInputEvents
|
||||||
|
+ | QEventLoop::ExcludeSocketNotifiers
|
||||||
|
+ | QEventLoop::X11ExcludeTimers;
|
||||||
|
+ if ((flags & excludeAllFlags) == excludeAllFlags)
|
||||||
|
+ return false;
|
||||||
|
+ if(( flags & excludeAllFlags ) != excludeAllFlags )
|
||||||
|
+ QCoreApplicationPrivate::sendPostedEvents(0, 0, d->threadData);
|
||||||
|
|
||||||
|
int nevents = 0;
|
||||||
|
const bool canWait = (d->threadData->canWaitLocked()
|
63
qt-everywhere-opensource-src-4.8.6-QTBUG-37380.patch
Normal file
63
qt-everywhere-opensource-src-4.8.6-QTBUG-37380.patch
Normal file
@ -0,0 +1,63 @@
|
|||||||
|
Author: Jan-Marek Glogowski <glogow@fbihome.de>
|
||||||
|
Date: Thu Mar 06 18:44:43 2014 +0100
|
||||||
|
|
||||||
|
Honor QEventLoop::ExcludeSocketNotifiers in glib event loop.
|
||||||
|
|
||||||
|
Implements QEventLoop::ExcludeSocketNotifiers in the same way
|
||||||
|
QEventLoop::X11ExcludeTimers is already implemented for the glib
|
||||||
|
event loop.
|
||||||
|
|
||||||
|
--- qt4-x11-4.8.1.orig/src/corelib/kernel/qeventdispatcher_glib.cpp
|
||||||
|
+++ qt4-x11-4.8.1/src/corelib/kernel/qeventdispatcher_glib.cpp
|
||||||
|
@@ -65,6 +65,7 @@ struct GPollFDWithQSocketNotifier
|
||||||
|
struct GSocketNotifierSource
|
||||||
|
{
|
||||||
|
GSource source;
|
||||||
|
+ QEventLoop::ProcessEventsFlags processEventsFlags;
|
||||||
|
QList<GPollFDWithQSocketNotifier *> pollfds;
|
||||||
|
};
|
||||||
|
|
||||||
|
@@ -80,6 +81,9 @@ static gboolean socketNotifierSourceChec
|
||||||
|
GSocketNotifierSource *src = reinterpret_cast<GSocketNotifierSource *>(source);
|
||||||
|
|
||||||
|
bool pending = false;
|
||||||
|
+ if (src->processEventsFlags & QEventLoop::ExcludeSocketNotifiers)
|
||||||
|
+ return pending;
|
||||||
|
+
|
||||||
|
for (int i = 0; !pending && i < src->pollfds.count(); ++i) {
|
||||||
|
GPollFDWithQSocketNotifier *p = src->pollfds.at(i);
|
||||||
|
|
||||||
|
@@ -103,6 +107,9 @@ static gboolean socketNotifierSourceDisp
|
||||||
|
QEvent event(QEvent::SockAct);
|
||||||
|
|
||||||
|
GSocketNotifierSource *src = reinterpret_cast<GSocketNotifierSource *>(source);
|
||||||
|
+ if (src->processEventsFlags & QEventLoop::ExcludeSocketNotifiers)
|
||||||
|
+ return true;
|
||||||
|
+
|
||||||
|
for (int i = 0; i < src->pollfds.count(); ++i) {
|
||||||
|
GPollFDWithQSocketNotifier *p = src->pollfds.at(i);
|
||||||
|
|
||||||
|
@@ -330,6 +337,7 @@ QEventDispatcherGlibPrivate::QEventDispa
|
||||||
|
reinterpret_cast<GSocketNotifierSource *>(g_source_new(&socketNotifierSourceFuncs,
|
||||||
|
sizeof(GSocketNotifierSource)));
|
||||||
|
(void) new (&socketNotifierSource->pollfds) QList<GPollFDWithQSocketNotifier *>();
|
||||||
|
+ socketNotifierSource->processEventsFlags = QEventLoop::AllEvents;
|
||||||
|
g_source_set_can_recurse(&socketNotifierSource->source, true);
|
||||||
|
g_source_attach(&socketNotifierSource->source, mainContext);
|
||||||
|
|
||||||
|
@@ -415,6 +423,7 @@ bool QEventDispatcherGlib::processEvents
|
||||||
|
// tell postEventSourcePrepare() and timerSource about any new flags
|
||||||
|
QEventLoop::ProcessEventsFlags savedFlags = d->timerSource->processEventsFlags;
|
||||||
|
d->timerSource->processEventsFlags = flags;
|
||||||
|
+ d->socketNotifierSource->processEventsFlags = flags;
|
||||||
|
|
||||||
|
if (!(flags & QEventLoop::EventLoopExec)) {
|
||||||
|
// force timers to be sent at normal priority
|
||||||
|
@@ -426,6 +435,7 @@ bool QEventDispatcherGlib::processEvents
|
||||||
|
result = g_main_context_iteration(d->mainContext, canWait);
|
||||||
|
|
||||||
|
d->timerSource->processEventsFlags = savedFlags;
|
||||||
|
+ d->socketNotifierSource->processEventsFlags = savedFlags;
|
||||||
|
|
||||||
|
if (canWait)
|
||||||
|
emit awake();
|
12
qt-everywhere-opensource-src-4.8.6-QTBUG-38585.patch
Normal file
12
qt-everywhere-opensource-src-4.8.6-QTBUG-38585.patch
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
--- src/gui/kernel/qclipboard_x11.cpp.sav 2014-04-25 09:52:03.855693228 +0200
|
||||||
|
+++ src/gui/kernel/qclipboard_x11.cpp 2014-04-25 09:51:58.038693777 +0200
|
||||||
|
@@ -548,7 +548,8 @@ bool QX11Data::clipboardWaitForEvent(Win
|
||||||
|
return false;
|
||||||
|
|
||||||
|
XSync(X11->display, false);
|
||||||
|
- usleep(50000);
|
||||||
|
+ if (!XPending(X11->display))
|
||||||
|
+ usleep(5000);
|
||||||
|
|
||||||
|
now.start();
|
||||||
|
|
13
qt.spec
13
qt.spec
@ -25,7 +25,7 @@ Summary: Qt toolkit
|
|||||||
Name: qt
|
Name: qt
|
||||||
Epoch: 1
|
Epoch: 1
|
||||||
Version: 4.8.6
|
Version: 4.8.6
|
||||||
Release: 8%{?dist}
|
Release: 9%{?dist}
|
||||||
|
|
||||||
# See LGPL_EXCEPTIONS.txt, LICENSE.GPL3, respectively, for exception details
|
# See LGPL_EXCEPTIONS.txt, LICENSE.GPL3, respectively, for exception details
|
||||||
License: (LGPLv2 with exceptions or GPLv3 with exceptions) and ASL 2.0 and BSD and FTL and MIT
|
License: (LGPLv2 with exceptions or GPLv3 with exceptions) and ASL 2.0 and BSD and FTL and MIT
|
||||||
@ -141,6 +141,11 @@ Patch84: qt-everywhere-opensource-src-4.8.5-QTBUG-35459.patch
|
|||||||
# systemtrayicon plugin support (for appindicators)
|
# systemtrayicon plugin support (for appindicators)
|
||||||
Patch86: qt-everywhere-opensource-src-4.8.6-systemtrayicon.patch
|
Patch86: qt-everywhere-opensource-src-4.8.6-systemtrayicon.patch
|
||||||
|
|
||||||
|
# fixes for LibreOffice from the upstream Qt bug tracker (#1105422):
|
||||||
|
Patch87: qt-everywhere-opensource-src-4.8.6-QTBUG-34614.patch
|
||||||
|
Patch88: qt-everywhere-opensource-src-4.8.6-QTBUG-37380.patch
|
||||||
|
Patch89: qt-everywhere-opensource-src-4.8.6-QTBUG-38585.patch
|
||||||
|
|
||||||
# upstream patches
|
# upstream patches
|
||||||
# backported from Qt5 (essentially)
|
# backported from Qt5 (essentially)
|
||||||
# http://bugzilla.redhat.com/702493
|
# http://bugzilla.redhat.com/702493
|
||||||
@ -519,6 +524,9 @@ rm -fv mkspecs/linux-g++*/qmake.conf.multilib-optflags
|
|||||||
%patch81 -p1 -b .assistant-crash
|
%patch81 -p1 -b .assistant-crash
|
||||||
%patch82 -p1 -b .QTBUG-4862
|
%patch82 -p1 -b .QTBUG-4862
|
||||||
%patch83 -p1 -b .poll
|
%patch83 -p1 -b .poll
|
||||||
|
%patch87 -p0 -b .QTBUG-34614
|
||||||
|
%patch88 -p1 -b .QTBUG-37380
|
||||||
|
%patch89 -p0 -b .QTBUG-38585
|
||||||
|
|
||||||
# upstream patches
|
# upstream patches
|
||||||
%patch102 -p1 -b .qgtkstyle_disable_gtk_theme_check
|
%patch102 -p1 -b .qgtkstyle_disable_gtk_theme_check
|
||||||
@ -1229,6 +1237,9 @@ fi
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri Jun 06 2014 Kevin Kofler <Kevin@tigcc.ticalc.org> 4.8.6-9
|
||||||
|
- apply proposed fixes for QTBUG-34614,37380,38585 for LibreOffice (#1105422)
|
||||||
|
|
||||||
* Tue Jun 03 2014 Rex Dieter <rdieter@fedoraproject.org> 4.8.6-8
|
* Tue Jun 03 2014 Rex Dieter <rdieter@fedoraproject.org> 4.8.6-8
|
||||||
- backport selected upstream commits...
|
- backport selected upstream commits...
|
||||||
- Fix visual index lookup (QTBUG-37813)
|
- Fix visual index lookup (QTBUG-37813)
|
||||||
|
Loading…
Reference in New Issue
Block a user