1 |
pesa 14/07/07 20:03:53 |
2 |
|
3 |
Added: qtcore-4.8.5-moc-boost-lexical-cast.patch |
4 |
qtcore-4.8.5-qeventdispatcher-recursive.patch |
5 |
qtcore-4.8.5-honor-ExcludeSocketNotifiers-in-glib-event-loop.patch |
6 |
Removed: moc-boost-lexical-cast.patch |
7 |
Log: |
8 |
Add fixes for libreoffice, bug 514968. |
9 |
|
10 |
(Portage version: 2.2.10/cvs/Linux x86_64, signed Manifest commit with key 0xDADED6B2671CB57D!) |
11 |
|
12 |
Revision Changes Path |
13 |
1.1 dev-qt/qtcore/files/qtcore-4.8.5-moc-boost-lexical-cast.patch |
14 |
|
15 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-qt/qtcore/files/qtcore-4.8.5-moc-boost-lexical-cast.patch?rev=1.1&view=markup |
16 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-qt/qtcore/files/qtcore-4.8.5-moc-boost-lexical-cast.patch?rev=1.1&content-type=text/plain |
17 |
|
18 |
Index: qtcore-4.8.5-moc-boost-lexical-cast.patch |
19 |
=================================================================== |
20 |
Index: qt-everywhere-opensource-src-4.8.9999/src/tools/moc/main.cpp |
21 |
=================================================================== |
22 |
--- qt-everywhere-opensource-src-4.8.9999.orig/src/tools/moc/main.cpp |
23 |
+++ qt-everywhere-opensource-src-4.8.9999/src/tools/moc/main.cpp |
24 |
@@ -190,6 +190,7 @@ int runMoc(int _argc, char **_argv) |
25 |
|
26 |
// Workaround a bug while parsing the boost/type_traits/has_operator.hpp header. See QTBUG-22829 |
27 |
pp.macros["BOOST_TT_HAS_OPERATOR_HPP_INCLUDED"]; |
28 |
+ pp.macros["BOOST_LEXICAL_CAST_INCLUDED"]; |
29 |
|
30 |
QByteArray filename; |
31 |
QByteArray output; |
32 |
|
33 |
|
34 |
|
35 |
1.1 dev-qt/qtcore/files/qtcore-4.8.5-qeventdispatcher-recursive.patch |
36 |
|
37 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-qt/qtcore/files/qtcore-4.8.5-qeventdispatcher-recursive.patch?rev=1.1&view=markup |
38 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-qt/qtcore/files/qtcore-4.8.5-qeventdispatcher-recursive.patch?rev=1.1&content-type=text/plain |
39 |
|
40 |
Index: qtcore-4.8.5-qeventdispatcher-recursive.patch |
41 |
=================================================================== |
42 |
--- src/corelib/kernel/qeventdispatcher_glib.cpp.sav 2014-03-28 15:26:37.000000000 +0100 |
43 |
+++ src/corelib/kernel/qeventdispatcher_glib.cpp 2014-04-24 09:44:09.358659204 +0200 |
44 |
@@ -255,22 +255,30 @@ struct GPostEventSource |
45 |
GSource source; |
46 |
QAtomicInt serialNumber; |
47 |
int lastSerialNumber; |
48 |
+ QEventLoop::ProcessEventsFlags processEventsFlags; |
49 |
QEventDispatcherGlibPrivate *d; |
50 |
}; |
51 |
|
52 |
static gboolean postEventSourcePrepare(GSource *s, gint *timeout) |
53 |
{ |
54 |
+ GPostEventSource *source = reinterpret_cast<GPostEventSource *>(s); |
55 |
QThreadData *data = QThreadData::current(); |
56 |
if (!data) |
57 |
return false; |
58 |
|
59 |
+ QEventLoop::ProcessEventsFlags excludeAllFlags |
60 |
+ = QEventLoop::ExcludeUserInputEvents |
61 |
+ | QEventLoop::ExcludeSocketNotifiers |
62 |
+ | QEventLoop::X11ExcludeTimers; |
63 |
+ if ((source->processEventsFlags & excludeAllFlags) == excludeAllFlags) |
64 |
+ return false; |
65 |
+ |
66 |
gint dummy; |
67 |
if (!timeout) |
68 |
timeout = &dummy; |
69 |
const bool canWait = data->canWaitLocked(); |
70 |
*timeout = canWait ? -1 : 0; |
71 |
|
72 |
- GPostEventSource *source = reinterpret_cast<GPostEventSource *>(s); |
73 |
return (!canWait |
74 |
|| (source->serialNumber != source->lastSerialNumber)); |
75 |
} |
76 |
@@ -284,8 +292,14 @@ static gboolean postEventSourceDispatch( |
77 |
{ |
78 |
GPostEventSource *source = reinterpret_cast<GPostEventSource *>(s); |
79 |
source->lastSerialNumber = source->serialNumber; |
80 |
- QCoreApplication::sendPostedEvents(); |
81 |
- source->d->runTimersOnceWithNormalPriority(); |
82 |
+ QEventLoop::ProcessEventsFlags excludeAllFlags |
83 |
+ = QEventLoop::ExcludeUserInputEvents |
84 |
+ | QEventLoop::ExcludeSocketNotifiers |
85 |
+ | QEventLoop::X11ExcludeTimers; |
86 |
+ if ((source->processEventsFlags & excludeAllFlags) != excludeAllFlags) { |
87 |
+ QCoreApplication::sendPostedEvents(); |
88 |
+ source->d->runTimersOnceWithNormalPriority(); |
89 |
+ } |
90 |
return true; // i dunno, george... |
91 |
} |
92 |
|
93 |
@@ -329,6 +343,7 @@ QEventDispatcherGlibPrivate::QEventDispa |
94 |
postEventSource = reinterpret_cast<GPostEventSource *>(g_source_new(&postEventSourceFuncs, |
95 |
sizeof(GPostEventSource))); |
96 |
postEventSource->serialNumber = 1; |
97 |
+ postEventSource->processEventsFlags = QEventLoop::AllEvents; |
98 |
postEventSource->d = this; |
99 |
g_source_set_can_recurse(&postEventSource->source, true); |
100 |
g_source_attach(&postEventSource->source, mainContext); |
101 |
@@ -423,6 +438,7 @@ bool QEventDispatcherGlib::processEvents |
102 |
|
103 |
// tell postEventSourcePrepare() and timerSource about any new flags |
104 |
QEventLoop::ProcessEventsFlags savedFlags = d->timerSource->processEventsFlags; |
105 |
+ d->postEventSource->processEventsFlags = flags; |
106 |
d->timerSource->processEventsFlags = flags; |
107 |
d->socketNotifierSource->processEventsFlags = flags; |
108 |
|
109 |
@@ -435,6 +451,7 @@ bool QEventDispatcherGlib::processEvents |
110 |
while (!result && canWait) |
111 |
result = g_main_context_iteration(d->mainContext, canWait); |
112 |
|
113 |
+ d->postEventSource->processEventsFlags = savedFlags; |
114 |
d->timerSource->processEventsFlags = savedFlags; |
115 |
d->socketNotifierSource->processEventsFlags = savedFlags; |
116 |
|
117 |
--- src/corelib/kernel/qeventdispatcher_unix.cpp.sav 2013-06-07 07:16:52.000000000 +0200 |
118 |
+++ src/corelib/kernel/qeventdispatcher_unix.cpp 2014-04-24 09:43:06.927589535 +0200 |
119 |
@@ -905,7 +905,15 @@ bool QEventDispatcherUNIX::processEvents |
120 |
|
121 |
// we are awake, broadcast it |
122 |
emit awake(); |
123 |
- QCoreApplicationPrivate::sendPostedEvents(0, 0, d->threadData); |
124 |
+ |
125 |
+ QEventLoop::ProcessEventsFlags excludeAllFlags |
126 |
+ = QEventLoop::ExcludeUserInputEvents |
127 |
+ | QEventLoop::ExcludeSocketNotifiers |
128 |
+ | QEventLoop::X11ExcludeTimers; |
129 |
+ if ((flags & excludeAllFlags) == excludeAllFlags) |
130 |
+ return false; |
131 |
+ if(( flags & excludeAllFlags ) != excludeAllFlags ) |
132 |
+ QCoreApplicationPrivate::sendPostedEvents(0, 0, d->threadData); |
133 |
|
134 |
int nevents = 0; |
135 |
const bool canWait = (d->threadData->canWaitLocked() |
136 |
|
137 |
|
138 |
|
139 |
1.1 dev-qt/qtcore/files/qtcore-4.8.5-honor-ExcludeSocketNotifiers-in-glib-event-loop.patch |
140 |
|
141 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-qt/qtcore/files/qtcore-4.8.5-honor-ExcludeSocketNotifiers-in-glib-event-loop.patch?rev=1.1&view=markup |
142 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-qt/qtcore/files/qtcore-4.8.5-honor-ExcludeSocketNotifiers-in-glib-event-loop.patch?rev=1.1&content-type=text/plain |
143 |
|
144 |
Index: qtcore-4.8.5-honor-ExcludeSocketNotifiers-in-glib-event-loop.patch |
145 |
=================================================================== |
146 |
From 267feb2de49eed0823ca0c29f1cd5238537c7116 Mon Sep 17 00:00:00 2001 |
147 |
From: Jan-Marek Glogowski <glogow@×××××××.de> |
148 |
Date: Thu, 6 Mar 2014 18:44:43 +0100 |
149 |
Subject: Honor ExcludeSocketNotifiers in glib event loop |
150 |
|
151 |
Implements QEventLoop::ExcludeSocketNotifiers in the same way |
152 |
QEventLoop::X11ExcludeTimers is already implemented for the glib |
153 |
event loop. |
154 |
|
155 |
This prevents crashes when QClipboard checks for clipboard events |
156 |
and |
157 |
qApp->clipboard()->setProperty( "useEventLoopWhenWaiting", true ); |
158 |
is set. |
159 |
|
160 |
Task-number: QTBUG-34614 |
161 |
Task-number: QTBUG-37380 |
162 |
|
163 |
Change-Id: Id4e2a74c6bdf8c3b439a4e3813d24d11368b607d |
164 |
--- |
165 |
src/corelib/kernel/qeventdispatcher_glib.cpp | 10 ++++++++++ |
166 |
1 file changed, 10 insertions(+) |
167 |
|
168 |
diff --git a/src/corelib/kernel/qeventdispatcher_glib.cpp b/src/corelib/kernel/qeventdispatcher_glib.cpp |
169 |
index 0b0e308..ba522fa 100644 |
170 |
--- a/src/corelib/kernel/qeventdispatcher_glib.cpp |
171 |
+++ b/src/corelib/kernel/qeventdispatcher_glib.cpp |
172 |
@@ -65,6 +65,7 @@ struct GPollFDWithQSocketNotifier |
173 |
struct GSocketNotifierSource |
174 |
{ |
175 |
GSource source; |
176 |
+ QEventLoop::ProcessEventsFlags processEventsFlags; |
177 |
QList<GPollFDWithQSocketNotifier *> pollfds; |
178 |
}; |
179 |
|
180 |
@@ -80,6 +81,9 @@ static gboolean socketNotifierSourceCheck(GSource *source) |
181 |
GSocketNotifierSource *src = reinterpret_cast<GSocketNotifierSource *>(source); |
182 |
|
183 |
bool pending = false; |
184 |
+ if (src->processEventsFlags & QEventLoop::ExcludeSocketNotifiers) |
185 |
+ return pending; |
186 |
+ |
187 |
for (int i = 0; !pending && i < src->pollfds.count(); ++i) { |
188 |
GPollFDWithQSocketNotifier *p = src->pollfds.at(i); |
189 |
|
190 |
@@ -103,6 +107,9 @@ static gboolean socketNotifierSourceDispatch(GSource *source, GSourceFunc, gpoin |
191 |
QEvent event(QEvent::SockAct); |
192 |
|
193 |
GSocketNotifierSource *src = reinterpret_cast<GSocketNotifierSource *>(source); |
194 |
+ if (src->processEventsFlags & QEventLoop::ExcludeSocketNotifiers) |
195 |
+ return true; |
196 |
+ |
197 |
for (int i = 0; i < src->pollfds.count(); ++i) { |
198 |
GPollFDWithQSocketNotifier *p = src->pollfds.at(i); |
199 |
|
200 |
@@ -331,6 +338,7 @@ QEventDispatcherGlibPrivate::QEventDispatcherGlibPrivate(GMainContext *context) |
201 |
reinterpret_cast<GSocketNotifierSource *>(g_source_new(&socketNotifierSourceFuncs, |
202 |
sizeof(GSocketNotifierSource))); |
203 |
(void) new (&socketNotifierSource->pollfds) QList<GPollFDWithQSocketNotifier *>(); |
204 |
+ socketNotifierSource->processEventsFlags = QEventLoop::AllEvents; |
205 |
g_source_set_can_recurse(&socketNotifierSource->source, true); |
206 |
g_source_attach(&socketNotifierSource->source, mainContext); |
207 |
|
208 |
@@ -416,6 +424,7 @@ bool QEventDispatcherGlib::processEvents(QEventLoop::ProcessEventsFlags flags) |
209 |
// tell postEventSourcePrepare() and timerSource about any new flags |
210 |
QEventLoop::ProcessEventsFlags savedFlags = d->timerSource->processEventsFlags; |
211 |
d->timerSource->processEventsFlags = flags; |
212 |
+ d->socketNotifierSource->processEventsFlags = flags; |
213 |
|
214 |
if (!(flags & QEventLoop::EventLoopExec)) { |
215 |
// force timers to be sent at normal priority |
216 |
@@ -427,6 +436,7 @@ bool QEventDispatcherGlib::processEvents(QEventLoop::ProcessEventsFlags flags) |
217 |
result = g_main_context_iteration(d->mainContext, canWait); |
218 |
|
219 |
d->timerSource->processEventsFlags = savedFlags; |
220 |
+ d->socketNotifierSource->processEventsFlags = savedFlags; |
221 |
|
222 |
if (canWait) |
223 |
emit awake(); |
224 |
-- |
225 |
2.0.0 |