diff options
author | Fathi Boudra <fabo@debian.org> | 2007-12-06 21:48:31 +0000 |
---|---|---|
committer | Fathi Boudra <fabo@debian.org> | 2007-12-06 21:48:31 +0000 |
commit | 67b50a77e6895e553d25d2e9aa3090d93b20aa38 (patch) | |
tree | 703e2b379aade64c0240ac567e7f1f60aac0f73d /debian/patches | |
parent | 15f2cbce5e701470e98416cfb012de4c80f6a488 (diff) | |
download | qt4-x11-67b50a77e6895e553d25d2e9aa3090d93b20aa38.tar.gz |
* Prepare Qt4.3.3:
* Update patches.
* Add patches 0200 and 0203.
* Remove patches merged upstream.
Diffstat (limited to 'debian/patches')
34 files changed, 235 insertions, 599 deletions
diff --git a/debian/patches/0163-fix-gcc43-support.diff b/debian/patches/0163-fix-gcc43-support.diff deleted file mode 100644 index 90975fa..0000000 --- a/debian/patches/0163-fix-gcc43-support.diff +++ /dev/null @@ -1,164 +0,0 @@ -qt-bugs@ issue : N154723 -Trolltech task ID : none -bugs.kde.org number : None -applied: no -author: Dirk Mueller <mueller@kde.org> - -various fixes to get Qt 4.3 without hundreds of warnings compiling - ---- a/config.tests/unix/endian.test -+++ b/config.tests/unix/endian.test -@@ -30,6 +30,7 @@ - [ "$VERBOSE" = "yes" ] && echo " Found 'MostSignificantByteFirst' in binary" - ENDIAN="BIG" - fi -+[ "$VERBOSE" = "yes" ] && make clean || make clean >/dev/null 2>&1 - - # done - if [ "$ENDIAN" = "LITTLE" ]; then ---- a/config.tests/unix/glib/glib.cpp -+++ b/config.tests/unix/glib/glib.cpp -@@ -6,7 +6,7 @@ - { - GMainContext *context; - GSource *source; -- GPollFD *pollfd; -+ GPollFD *pollfd = NULL; - if (!g_thread_supported()) - g_thread_init(NULL); - context = g_main_context_default(); ---- a/src/corelib/codecs/qtextcodec.cpp -+++ b/src/corelib/codecs/qtextcodec.cpp -@@ -432,7 +432,7 @@ - localeMapper = checkForCodec(lang); - - // 5. "@euro" -- if (!localeMapper && ctype && strstr(ctype, "@euro") || lang && strstr(lang, "@euro")) -+ if ((!localeMapper && ctype && strstr(ctype, "@euro")) || (lang && strstr(lang, "@euro"))) - localeMapper = checkForCodec("ISO 8859-15"); - - // 6. guess locale from ctype unless ctype is "C" ---- a/src/corelib/io/qtextstream.cpp -+++ b/src/corelib/io/qtextstream.cpp -@@ -553,8 +553,8 @@ - if (!codec || autoDetectUnicode) { - autoDetectUnicode = false; - -- if (bytesRead >= 2 && (uchar(buf[0]) == 0xff && uchar(buf[1]) == 0xfe -- || uchar(buf[0]) == 0xfe && uchar(buf[1]) == 0xff)) { -+ if (bytesRead >= 2 && ((uchar(buf[0]) == 0xff && uchar(buf[1]) == 0xfe) -+ || (uchar(buf[0]) == 0xfe && uchar(buf[1]) == 0xff))) { - codec = QTextCodec::codecForName("UTF-16"); - } else if (!codec) { - codec = QTextCodec::codecForLocale(); ---- a/src/corelib/io/qurl.cpp -+++ b/src/corelib/io/qurl.cpp -@@ -4741,9 +4741,9 @@ - if (include.isEmpty()) { - for (int i = 0; i < len; ++i) { - unsigned char c = *inputData++; -- if (c >= 0x61 && c <= 0x7A // ALPHA -- || c >= 0x41 && c <= 0x5A // ALPHA -- || c >= 0x30 && c <= 0x39 // DIGIT -+ if ((c >= 0x61 && c <= 0x7A) // ALPHA -+ || (c >= 0x41 && c <= 0x5A) // ALPHA -+ || (c >= 0x30 && c <= 0x39) // DIGIT - || c == 0x2D // - - || c == 0x2E // . - || c == 0x5F // _ -@@ -4760,9 +4760,9 @@ - const char * alsoEncode = include.constData(); - for (int i = 0; i < len; ++i) { - unsigned char c = *inputData++; -- if ((c >= 0x61 && c <= 0x7A // ALPHA -- || c >= 0x41 && c <= 0x5A // ALPHA -- || c >= 0x30 && c <= 0x39 // DIGIT -+ if (((c >= 0x61 && c <= 0x7A) // ALPHA -+ || (c >= 0x41 && c <= 0x5A) // ALPHA -+ || (c >= 0x30 && c <= 0x39) // DIGIT - || c == 0x2D // - - || c == 0x2E // . - || c == 0x5F // _ ---- a/src/corelib/tools/qlocale.cpp -+++ b/src/corelib/tools/qlocale.cpp -@@ -2609,8 +2609,8 @@ - - QChar c1 = format.at(i); - QChar c2 = format.at(i + 1); -- if (c1.unicode() == 'a' && c2.unicode() == 'p' -- || c1.unicode() == 'A' && c2.unicode() == 'P') -+ if ((c1.unicode() == 'a' && c2.unicode() == 'p') -+ || (c1.unicode() == 'A' && c2.unicode() == 'P')) - return true; - - ++i; ---- a/src/gui/kernel/qapplication.cpp -+++ b/src/gui/kernel/qapplication.cpp -@@ -2036,11 +2036,11 @@ - #ifndef QT_NO_TRANSLATION - static bool qt_detectRTLLanguage() - { -- return force_reverse ^ -+ return (force_reverse ^ - QApplication::tr("QT_LAYOUT_DIRECTION", - "Translate this string to the string 'LTR' in left-to-right" - " languages or to 'RTL' in right-to-left languages (such as Hebrew" -- " and Arabic) to get proper widget layout.") == QLatin1String("RTL"); -+ " and Arabic) to get proper widget layout.") == QLatin1String("RTL")); - } - #endif - ---- a/src/gui/kernel/qkeymapper_x11.cpp -+++ b/src/gui/kernel/qkeymapper_x11.cpp -@@ -1330,8 +1330,8 @@ - } - - if (directionKeyEvent && lastWinId == keyWidget->internalWinId()) { -- if (keysym == XK_Shift_L && directionKeyEvent == XK_Control_L || -- keysym == XK_Control_L && directionKeyEvent == XK_Shift_L) { -+ if ((keysym == XK_Shift_L && directionKeyEvent == XK_Control_L) || -+ (keysym == XK_Control_L && directionKeyEvent == XK_Shift_L)) { - directionKeyEvent = Qt::Key_Direction_L; - } else if (keysym == XK_Shift_R && directionKeyEvent == XK_Control_R || - keysym == XK_Control_R && directionKeyEvent == XK_Shift_R) { ---- a/src/gui/kernel/qwidget.cpp -+++ b/src/gui/kernel/qwidget.cpp -@@ -1872,7 +1872,7 @@ - - for (int i = 0; i < pd->children.size(); ++i) { - QWidget *w = qobject_cast<QWidget *>(pd->children.at(i)); -- if (w && !w->isWindow() && !w->testAttribute(Qt::WA_WState_Created)) -+ if (w && !w->isWindow() && !w->testAttribute(Qt::WA_WState_Created)) { - if (w!=q) { - w->create(); - } else { -@@ -1882,6 +1882,7 @@ - if (winid) - w->raise(); - } -+ } - } - } else { - q->create(); ---- a/src/gui/painting/qregion_unix.cpp -+++ b/src/gui/painting/qregion_unix.cpp -@@ -1944,7 +1944,7 @@ - else - --isInside; - -- if (!inside && !isInside || inside && isInside) { -+ if ((!inside && !isInside) || (inside && isInside)) { - pWETE->nextWETE = AET; - pWETE = AET; - inside = !inside; ---- a/src/tools/uic/driver.cpp -+++ b/src/tools/uic/driver.cpp -@@ -175,7 +175,7 @@ - - static bool isAnsiCCharacter(const QChar& c) - { -- return c.toUpper() >= QLatin1Char('A') && c.toUpper() <= QLatin1Char('Z') -+ return (c.toUpper() >= QLatin1Char('A') && c.toUpper() <= QLatin1Char('Z')) - || c.isDigit() || c == QLatin1Char('_'); - } - diff --git a/debian/patches/0167-fix-group-reading.diff b/debian/patches/0167-fix-group-reading.diff index 28e36e9..acf27d0 100644 --- a/debian/patches/0167-fix-group-reading.diff +++ b/debian/patches/0167-fix-group-reading.diff @@ -9,7 +9,7 @@ Try a bit harder. --- a/src/corelib/io/qfsfileengine_unix.cpp +++ b/src/corelib/io/qfsfileengine_unix.cpp -@@ -845,9 +845,16 @@ +@@ -843,9 +843,16 @@ } else if (own == OwnerGroup) { struct group *gr = 0; #if !defined(QT_NO_THREAD) && defined(_POSIX_THREAD_SAFE_FUNCTIONS) && !defined(Q_OS_OPENBSD) diff --git a/debian/patches/0172-prefer-xrandr-over-xinerama.diff b/debian/patches/0172-prefer-xrandr-over-xinerama.diff new file mode 100644 index 0000000..c89a43a --- /dev/null +++ b/debian/patches/0172-prefer-xrandr-over-xinerama.diff @@ -0,0 +1,47 @@ +qt-bugs@ issue : none +Trolltech task ID : none +bugs.kde.org number : +applied: no +author: Dirk Mueller <mueller@kde.org> + +only trust libxinerama if its not the emulated information +coming from xrandr 1.2. xrandr 1.2 is merged fb and libxinerama +presents then virtual screens in clone mode, which qt (and KDE) +can't deal with. + +proper fix would be to detect crtcs as virtual screens, but +given that qt can't deal with dynamically changing number of screens, +this is for "when I have time". + +--- a/src/gui/kernel/qdesktopwidget_x11.cpp ++++ b/src/gui/kernel/qdesktopwidget_x11.cpp +@@ -140,7 +140,8 @@ + + // get the geometry of each screen + int i, x, y, w, h; +- for (i = 0; i < screenCount; i++) { ++ int itScreenCount = screenCount; ++ for (i = 0; i < itScreenCount; i++) { + + #ifndef QT_NO_XINERAMA + if (use_xinerama) { +@@ -158,10 +159,19 @@ + } + + rects[i].setRect(x, y, w, h); ++ if (i > 0 && rects[i-1].intersects(rects[i]) && ++ (rects[i].width()*rects[i].height()) > ++ (rects[i-1].width()*rects[i-1].height())) { ++ rects[i-1] = rects[i]; ++ screenCount--; ++ } + workareas[i] = QRect(); + } + + #ifndef QT_NO_XINERAMA ++ if (use_xinerama && screenCount == 1) ++ use_xinerama = false; ++ + if (xinerama_screeninfo) + XFree(xinerama_screeninfo); + #endif // QT_NO_XINERAMA diff --git a/debian/patches/0175-fix-s390-qatomic.diff b/debian/patches/0175-fix-s390-qatomic.diff index 913b570..542c2a2 100644 --- a/debian/patches/0175-fix-s390-qatomic.diff +++ b/debian/patches/0175-fix-s390-qatomic.diff @@ -8,7 +8,7 @@ fix s390(x) build --- a/src/corelib/arch/qatomic_s390.h +++ b/src/corelib/arch/qatomic_s390.h -@@ -197,10 +197,20 @@ +@@ -195,10 +195,20 @@ #endif } diff --git a/debian/patches/0176-coverity-fixes.diff b/debian/patches/0176-coverity-fixes.diff index 340f6fb..2037ce3 100644 --- a/debian/patches/0176-coverity-fixes.diff +++ b/debian/patches/0176-coverity-fixes.diff @@ -8,7 +8,7 @@ fix various obvious memory leaks etc --- a/src/gui/painting/qimagescale.cpp +++ b/src/gui/painting/qimagescale.cpp -@@ -1020,6 +1020,7 @@ +@@ -1024,6 +1024,7 @@ buffer = QImage(dw, dh, src.format()); if (buffer.isNull()) { qWarning("QImage: out of memory, returning null"); @@ -18,7 +18,7 @@ fix various obvious memory leaks etc --- a/src/svg/qsvghandler.cpp +++ b/src/svg/qsvghandler.cpp -@@ -1144,15 +1144,9 @@ +@@ -1142,15 +1142,9 @@ if (!size.isEmpty()) { QSvgHandler::LengthType type; qreal len = parseLength(size, type, handler); diff --git a/debian/patches/0178-transparency-window-types.diff b/debian/patches/0178-transparency-window-types.diff index 1cdf4e3..3441d11 100644 --- a/debian/patches/0178-transparency-window-types.diff +++ b/debian/patches/0178-transparency-window-types.diff @@ -6,23 +6,32 @@ author: Lubos Lunak <l.lunak@kde.org> This patch adds Qt support for new window types used for compositing. ---- a/src/gui/kernel/qapplication_x11.cpp -+++ b/src/gui/kernel/qapplication_x11.cpp -@@ -214,6 +214,11 @@ - "_NET_WM_WINDOW_TYPE_SPLASH\0" - "_NET_WM_WINDOW_TYPE_TOOLBAR\0" - "_NET_WM_WINDOW_TYPE_UTILITY\0" -+ "_NET_WM_WINDOW_TYPE_DROPDOWN_MENU\0" -+ "_NET_WM_WINDOW_TYPE_POPUP_MENU\0" -+ "_NET_WM_WINDOW_TYPE_COMBO\0" -+ "_NET_WM_WINDOW_TYPE_DND\0" -+ "_NET_WM_WINDOW_TYPE_TOOLTIP\0" + +--- a/src/gui/kernel/qwidget.h ++++ b/src/gui/kernel/qwidget.h +@@ -352,6 +352,19 @@ - "_KDE_NET_WM_FRAME_STRUT\0" + void setWindowOpacity(qreal level); + qreal windowOpacity() const; ++#if defined(Q_WS_X11) ++ enum X11WindowType { ++ X11WindowTypeSelect, ++ X11WindowTypeCombo, ++ X11WindowTypeDND, ++ X11WindowTypeTooltip, ++ X11WindowTypeMenu, // torn-off ++ X11WindowTypeDropdown, ++ X11WindowTypePopup ++ }; ++ void x11SetWindowType( X11WindowType type = X11WindowTypeSelect ); ++ void x11SetWindowTransient( QWidget* parent ); ++#endif + bool isWindowModified() const; + #ifndef QT_NO_TOOLTIP --- a/src/gui/kernel/qdnd_x11.cpp +++ b/src/gui/kernel/qdnd_x11.cpp -@@ -270,6 +270,7 @@ +@@ -268,6 +268,7 @@ QWidget(QApplication::desktop()->screen(screen), Qt::Tool | Qt::FramelessWindowHint | Qt::X11BypassWindowManagerHint) { @@ -30,7 +39,7 @@ This patch adds Qt support for new window types used for compositing. } void setPixmap(const QPixmap &pm) -@@ -1438,6 +1439,7 @@ +@@ -1436,6 +1437,7 @@ // recreate the pixmap on the new screen... delete xdnd_data.deco; xdnd_data.deco = new QShapedPixmapWidget(screen); @@ -38,7 +47,7 @@ This patch adds Qt support for new window types used for compositing. if (!QWidget::mouseGrabber()) { updatePixmap(); xdnd_data.deco->grabMouse(); -@@ -1899,6 +1901,7 @@ +@@ -1897,6 +1899,7 @@ object = o; object->d_func()->target = 0; xdnd_data.deco = new QShapedPixmapWidget(); @@ -48,7 +57,7 @@ This patch adds Qt support for new window types used for compositing. --- a/src/gui/kernel/qt_x11_p.h +++ b/src/gui/kernel/qt_x11_p.h -@@ -530,6 +530,11 @@ +@@ -528,6 +528,11 @@ _NET_WM_WINDOW_TYPE_SPLASH, _NET_WM_WINDOW_TYPE_TOOLBAR, _NET_WM_WINDOW_TYPE_UTILITY, @@ -62,7 +71,7 @@ This patch adds Qt support for new window types used for compositing. --- a/src/gui/kernel/qtooltip.cpp +++ b/src/gui/kernel/qtooltip.cpp -@@ -149,6 +149,9 @@ +@@ -147,6 +147,9 @@ setMouseTracking(true); fadingOut = false; reuseTip(text); @@ -72,7 +81,7 @@ This patch adds Qt support for new window types used for compositing. } void QTipLabel::restartHideTimer() -@@ -369,6 +372,10 @@ +@@ -367,6 +370,10 @@ // that is showing (removes flickering) if (QTipLabel::instance->tipChanged(pos, text, w)){ QTipLabel::instance->reuseTip(text); @@ -83,7 +92,7 @@ This patch adds Qt support for new window types used for compositing. QTipLabel::instance->setTipRect(w, rect); QTipLabel::instance->placeTip(pos, w); } -@@ -378,6 +385,10 @@ +@@ -376,6 +383,10 @@ if (!text.isEmpty()){ // no tip can be reused, create new tip: new QTipLabel(pos, text, w); // sets QTipLabel::instance to itself @@ -94,31 +103,23 @@ This patch adds Qt support for new window types used for compositing. QTipLabel::instance->setTipRect(w, rect); QTipLabel::instance->placeTip(pos, w); QTipLabel::instance->setObjectName(QLatin1String("qtooltip_label")); ---- a/src/gui/kernel/qwidget.h -+++ b/src/gui/kernel/qwidget.h -@@ -354,6 +354,19 @@ +--- a/src/gui/kernel/qapplication_x11.cpp ++++ b/src/gui/kernel/qapplication_x11.cpp +@@ -212,6 +212,11 @@ + "_NET_WM_WINDOW_TYPE_SPLASH\0" + "_NET_WM_WINDOW_TYPE_TOOLBAR\0" + "_NET_WM_WINDOW_TYPE_UTILITY\0" ++ "_NET_WM_WINDOW_TYPE_DROPDOWN_MENU\0" ++ "_NET_WM_WINDOW_TYPE_POPUP_MENU\0" ++ "_NET_WM_WINDOW_TYPE_COMBO\0" ++ "_NET_WM_WINDOW_TYPE_DND\0" ++ "_NET_WM_WINDOW_TYPE_TOOLTIP\0" - void setWindowOpacity(qreal level); - qreal windowOpacity() const; -+#if defined(Q_WS_X11) -+ enum X11WindowType { -+ X11WindowTypeSelect, -+ X11WindowTypeCombo, -+ X11WindowTypeDND, -+ X11WindowTypeTooltip, -+ X11WindowTypeMenu, // torn-off -+ X11WindowTypeDropdown, -+ X11WindowTypePopup -+ }; -+ void x11SetWindowType( X11WindowType type = X11WindowTypeSelect ); -+ void x11SetWindowTransient( QWidget* parent ); -+#endif + "_KDE_NET_WM_FRAME_STRUT\0" - bool isWindowModified() const; - #ifndef QT_NO_TOOLTIP --- a/src/gui/kernel/qwidget_x11.cpp +++ b/src/gui/kernel/qwidget_x11.cpp -@@ -562,10 +562,6 @@ +@@ -560,10 +560,6 @@ } #endif // QT_NO_XRENDER @@ -129,7 +130,7 @@ This patch adds Qt support for new window types used for compositing. QtMWMHints mwmhints; mwmhints.flags = 0L; mwmhints.functions = MWM_FUNC_ALL; -@@ -576,15 +572,11 @@ +@@ -574,15 +570,11 @@ if (topLevel) { ulong wsa_mask = 0; if (type == Qt::SplashScreen) { @@ -146,7 +147,7 @@ This patch adds Qt support for new window types used for compositing. mwmhints.decorations |= MWM_DECOR_BORDER; mwmhints.decorations |= MWM_DECOR_RESIZEH; -@@ -606,22 +598,6 @@ +@@ -604,22 +596,6 @@ wsa.save_under = True; wsa_mask |= CWSaveUnder; } @@ -169,7 +170,7 @@ This patch adds Qt support for new window types used for compositing. if (flags & Qt::X11BypassWindowManagerHint) { wsa.override_redirect = True; -@@ -640,6 +616,7 @@ +@@ -638,6 +614,7 @@ wsa.save_under = True; XChangeWindowAttributes(dpy, id, CWOverrideRedirect | CWSaveUnder, &wsa); @@ -177,7 +178,7 @@ This patch adds Qt support for new window types used for compositing. } else if (topLevel && !desktop) { // top-level widget if (!X11->wm_client_leader) create_wm_client_leader(); -@@ -684,12 +661,7 @@ +@@ -682,12 +659,7 @@ // set mwm hints SetMWMHints(dpy, id, mwmhints); @@ -191,7 +192,7 @@ This patch adds Qt support for new window types used for compositing. // set _NET_WM_PID long curr_pid = getpid(); -@@ -785,6 +757,63 @@ +@@ -783,6 +755,63 @@ q->setAttribute(Qt::WA_OutsideWSRange, true); } @@ -257,7 +258,7 @@ This patch adds Qt support for new window types used for compositing. destroyWindow is true. --- a/src/gui/widgets/qcombobox.cpp +++ b/src/gui/widgets/qcombobox.cpp -@@ -333,6 +333,10 @@ +@@ -332,6 +332,10 @@ combo->update(); } } @@ -267,10 +268,10 @@ This patch adds Qt support for new window types used for compositing. +#endif } - void QComboBoxPrivateContainer::leaveEvent(QEvent *) + void QComboBoxPrivateContainer::resizeEvent(QResizeEvent *e) --- a/src/gui/widgets/qmenu.cpp +++ b/src/gui/widgets/qmenu.cpp -@@ -99,6 +99,9 @@ +@@ -97,6 +97,9 @@ QTornOffMenu(QMenu *p) : QMenu(*(new QTornOffMenuPrivate(p))) { setParent(p, Qt::Window | Qt::Tool); @@ -280,7 +281,7 @@ This patch adds Qt support for new window types used for compositing. setAttribute(Qt::WA_DeleteOnClose, true); setWindowTitle(p->windowTitle()); setEnabled(p->isEnabled()); -@@ -145,6 +148,9 @@ +@@ -143,6 +146,9 @@ } defaultMenuAction = menuAction = new QAction(q); menuAction->d_func()->menu = q; @@ -290,10 +291,11 @@ This patch adds Qt support for new window types used for compositing. } //Windows and KDE allows menus to cover the taskbar, while GNOME and Mac don't -@@ -1682,6 +1688,32 @@ +@@ -1678,6 +1684,33 @@ + } } setGeometry(QRect(pos, size)); - ++ +#ifdef Q_WS_X11 + QWidget* top = this; + for(;;) { @@ -323,7 +325,7 @@ This patch adds Qt support for new window types used for compositing. #ifndef QT_NO_EFFECTS int hGuess = qApp->layoutDirection() == Qt::RightToLeft ? QEffects::LeftScroll : QEffects::RightScroll; int vGuess = QEffects::DownScroll; -@@ -1878,6 +1910,9 @@ +@@ -1874,6 +1907,9 @@ if (QMenuBar *mb = qobject_cast<QMenuBar*>(d->causedPopup.widget)) mb->d_func()->setCurrentAction(0); #endif diff --git a/debian/patches/0179-transient-hack.diff b/debian/patches/0179-transient-hack.diff index 62f39d0..a983715 100644 --- a/debian/patches/0179-transient-hack.diff +++ b/debian/patches/0179-transient-hack.diff @@ -10,7 +10,7 @@ It is not a proper solution, waiting for TT to come up with something. --- a/src/gui/kernel/qwidget_x11.cpp +++ b/src/gui/kernel/qwidget_x11.cpp -@@ -1650,7 +1650,7 @@ +@@ -1648,7 +1648,7 @@ do_size_hints(q, extra); // udpate WM_TRANSIENT_FOR diff --git a/debian/patches/0180-window-role.diff b/debian/patches/0180-window-role.diff index fec3405..80b7e18 100644 --- a/debian/patches/0180-window-role.diff +++ b/debian/patches/0180-window-role.diff @@ -36,7 +36,7 @@ handling the QWidget-related functionality from QtCore is fine. --- a/src/corelib/kernel/qobject.cpp +++ b/src/corelib/kernel/qobject.cpp -@@ -1008,9 +1008,18 @@ +@@ -1006,9 +1006,18 @@ { Q_D(QObject); d->objectName = name; @@ -57,7 +57,7 @@ handling the QWidget-related functionality from QtCore is fine. QObject::child is compat but needs to call itself recursively, --- a/src/corelib/kernel/qobject_p.h +++ b/src/corelib/kernel/qobject_p.h -@@ -139,6 +139,9 @@ +@@ -137,6 +137,9 @@ mutable quint32 connectedSignals; QString objectName; @@ -69,7 +69,7 @@ handling the QWidget-related functionality from QtCore is fine. class QSemaphore; --- a/src/gui/kernel/qwidget_p.h +++ b/src/gui/kernel/qwidget_p.h -@@ -309,6 +309,7 @@ +@@ -307,6 +307,7 @@ #if defined(Q_WS_X11) void setWindowRole(const char *role); @@ -79,7 +79,7 @@ handling the QWidget-related functionality from QtCore is fine. --- a/src/gui/kernel/qwidget_x11.cpp +++ b/src/gui/kernel/qwidget_x11.cpp -@@ -671,11 +671,8 @@ +@@ -669,11 +669,8 @@ // when we create a toplevel widget, the frame strut should be dirty data.fstrut_dirty = 1; @@ -93,7 +93,7 @@ handling the QWidget-related functionality from QtCore is fine. // set client leader property XChangeProperty(dpy, id, ATOM(WM_CLIENT_LEADER), -@@ -2671,12 +2668,20 @@ +@@ -2669,12 +2666,20 @@ void QWidgetPrivate::setWindowRole(const char *role) { Q_Q(QWidget); diff --git a/debian/patches/0185-fix-format-strings.diff b/debian/patches/0185-fix-format-strings.diff deleted file mode 100644 index db97bc7..0000000 --- a/debian/patches/0185-fix-format-strings.diff +++ /dev/null @@ -1,112 +0,0 @@ -qt-bugs@ issue : N171087 -Trolltech task ID : 173777 -bugs.kde.org number : -applied: no -author: Dirk Mueller <mueller@kde.org> - -This patch fixes various code issues with handling format strings -None of them seem to be exceptionally bad, but its better safe -than sorry. - ---- a/src/corelib/global/qglobal.h -+++ b/src/corelib/global/qglobal.h -@@ -1276,8 +1276,16 @@ - #ifdef QT3_SUPPORT - Q_CORE_EXPORT QT3_SUPPORT void qSystemWarning(const char *msg, int code = -1); - #endif /* QT3_SUPPORT */ --Q_CORE_EXPORT void qErrnoWarning(int code, const char *msg, ...); --Q_CORE_EXPORT void qErrnoWarning(const char *msg, ...); -+Q_CORE_EXPORT void qErrnoWarning(int code, const char *msg, ...) -+#if defined(Q_CC_GNU) && !defined(__INSURE__) -+ __attribute__ ((format (printf, 2, 3))) -+#endif -+ ; -+Q_CORE_EXPORT void qErrnoWarning(const char *msg, ...) -+#if defined(Q_CC_GNU) && !defined(__INSURE__) -+ __attribute__ ((format (printf, 1, 2))) -+#endif -+ ; - - #if (defined(QT_NO_DEBUG_OUTPUT) || defined(QT_NO_TEXTSTREAM)) && !defined(QT_NO_DEBUG_STREAM) - #define QT_NO_DEBUG_STREAM ---- a/src/corelib/tools/qbytearray.h -+++ b/src/corelib/tools/qbytearray.h -@@ -86,8 +86,16 @@ - Q_CORE_EXPORT int qstrnicmp(const char *, const char *, uint len); - - // implemented in qvsnprintf.cpp --Q_CORE_EXPORT int qvsnprintf(char *str, size_t n, const char *fmt, va_list ap); --Q_CORE_EXPORT int qsnprintf(char *str, size_t n, const char *fmt, ...); -+Q_CORE_EXPORT int qvsnprintf(char *str, size_t n, const char *fmt, va_list ap) -+#if defined(Q_CC_GNU) && !defined(__INSURE__) -+ __attribute__ ((format (printf, 3, 0))) -+#endif -+ ; -+Q_CORE_EXPORT int qsnprintf(char *str, size_t n, const char *fmt, ...) -+#if defined(Q_CC_GNU) && !defined(__INSURE__) -+ __attribute__ ((format (printf, 3, 4))) -+#endif -+ ; - - #ifdef QT3_SUPPORT - inline QT3_SUPPORT void *qmemmove(void *dst, const void *src, uint len) ---- a/src/gui/painting/qprintengine_pdf_p.h -+++ b/src/gui/painting/qprintengine_pdf_p.h -@@ -163,7 +163,11 @@ - void writePage(); - - int addXrefEntry(int object, bool printostr = true); -- void xprintf(const char* fmt, ...); -+ void xprintf(const char* fmt, ...) -+#if defined(Q_CC_GNU) && !defined(__INSURE__) -+ __attribute__ ((format (printf, 2, 3))) -+#endif -+ ; - inline void write(const QByteArray &data) { - stream->writeRawData(data.constData(), data.size()); - streampos += data.size(); ---- a/src/qt3support/tools/q3cstring.h -+++ b/src/qt3support/tools/q3cstring.h -@@ -72,7 +72,11 @@ - } - - Q3CString copy() const { return *this; } -- Q3CString &sprintf(const char *format, ...); -+ Q3CString &sprintf(const char *format, ...) -+#if defined(Q_CC_GNU) && !defined(__INSURE__) -+ __attribute__ ((format (printf, 2, 3))) -+#endif -+ ; - - Q3CString left(uint len) const { return QByteArray::left(len); } - Q3CString right(uint len) const { return QByteArray::right(len); } ---- a/tools/linguist/shared/profileevaluator.h -+++ b/tools/linguist/shared/profileevaluator.h -@@ -103,7 +103,11 @@ - - private: - void logMessage(const QString &msg, MessageType mt = MT_DebugLevel2); -- void logMessage(MessageType mt, const char *msg, ...); -+ void logMessage(MessageType mt, const char *msg, ...) -+#if defined(Q_CC_GNU) && !defined(__INSURE__) -+ __attribute__ ((format (printf, 3, 4))) -+#endif -+ ; - QString expandVariableReferences(const QString &value); - QString evaluateExpandFunction(const QByteArray &func, const QString &arguments); - ---- a/tools/qtestlib/src/qtest_global.h -+++ b/tools/qtestlib/src/qtest_global.h -@@ -74,7 +74,11 @@ - enum SkipMode { SkipSingle = 1, SkipAll = 2 }; - enum TestFailMode { Abort = 1, Continue = 2 }; - -- int Q_TESTLIB_EXPORT qt_snprintf(char *str, int size, const char *format, ...); -+ int Q_TESTLIB_EXPORT qt_snprintf(char *str, int size, const char *format, ...) -+#if defined(Q_CC_GNU) && !defined(__INSURE__) -+ __attribute__ ((format (printf, 3, 4))) -+#endif -+ ; - } - - QT_END_HEADER diff --git a/debian/patches/0187-fix-font-fixed-pitch.diff b/debian/patches/0187-fix-font-fixed-pitch.diff index d26512d..e289fd7 100644 --- a/debian/patches/0187-fix-font-fixed-pitch.diff +++ b/debian/patches/0187-fix-font-fixed-pitch.diff @@ -1,5 +1,5 @@ qt-bugs@ issue : 173297 -Trolltech task ID : 175024 +Trolltech task ID : 175024 (status: pending for Qt 4.4.0) applied: no author: Matthew Woehlke <mw_triad@users.sourceforge.net> @@ -17,7 +17,7 @@ This patch should be considered temporary until TT has a better fix. --- a/src/gui/text/qfont.cpp +++ b/src/gui/text/qfont.cpp -@@ -2093,7 +2093,6 @@ +@@ -2091,7 +2091,6 @@ { QFontEngine *engine = d->engineForScript(QUnicodeTables::Common); Q_ASSERT(engine != 0); @@ -25,7 +25,7 @@ This patch should be considered temporary until TT has a better fix. if (!engine->fontDef.fixedPitchComputed) { QChar ch[2] = { QLatin1Char('i'), QLatin1Char('m') }; QGlyphLayout g[2]; -@@ -2102,7 +2101,6 @@ +@@ -2100,7 +2099,6 @@ engine->fontDef.fixedPitch = g[0].advance.x == g[1].advance.x; engine->fontDef.fixedPitchComputed = true; } @@ -35,7 +35,7 @@ This patch should be considered temporary until TT has a better fix. --- a/src/gui/text/qfont_p.h +++ b/src/gui/text/qfont_p.h -@@ -66,9 +66,7 @@ +@@ -64,9 +64,7 @@ styleStrategy(QFont::PreferDefault), styleHint(QFont::AnyStyle), weight(50), fixedPitch(false), style(QFont::StyleNormal), stretch(100), ignorePitch(true) @@ -45,7 +45,7 @@ This patch should be considered temporary until TT has a better fix. { } -@@ -90,7 +88,7 @@ +@@ -88,7 +86,7 @@ uint stretch : 12; // 0-400 uint ignorePitch : 1; diff --git a/debian/patches/0188-fix-moc-parser-same-name-header.diff b/debian/patches/0188-fix-moc-parser-same-name-header.diff deleted file mode 100644 index ca16b64..0000000 --- a/debian/patches/0188-fix-moc-parser-same-name-header.diff +++ /dev/null @@ -1,35 +0,0 @@ -qt-bugs@ issue : none -Trolltech task ID : none -applied: yes -author: Helio Chissini de Castro <helio@kde.org> -os: unix - -In situations where included header have same name as their parent dir, i.e. -include/QtMyModule/QtMyModule and #include <QtMyModule> on code. moc will fail if parent dir was -added in front of includepath. -moc -Iinclude -Iinclude/QtMyModule fails -moc -Iinclude/QtMyModule works -This patch move dir test to proper place, as entry is validated only if is a real file, not a dir. -Detected by qca2 plugins code that uses QtCrypto/QtCrypto -Thanks to Thiago to find proper syntax - ---- a/src/tools/moc/preprocessor.cpp -+++ b/src/tools/moc/preprocessor.cpp -@@ -768,7 +768,7 @@ - QFileInfo fi; - if (local) - fi.setFile(QFileInfo(QString::fromLocal8Bit(filename)).dir(), QString::fromLocal8Bit(include)); -- for (int j = 0; j < Preprocessor::includes.size() && !fi.exists(); ++j) { -+ for (int j = 0; j < Preprocessor::includes.size() && ( !fi.exists() || fi.isDir() ); ++j) { - const IncludePath &p = Preprocessor::includes.at(j); - if (p.isFrameworkPath) { - const int slashPos = include.indexOf('/'); -@@ -782,7 +782,7 @@ - } - } - -- if (!fi.exists() || fi.isDir()) -+ if ( !fi.exists() ) - continue; - include = fi.filePath().toLocal8Bit(); - diff --git a/debian/patches/0189-fix-q3toolbar-qcombobox-signal-slot.diff b/debian/patches/0189-fix-q3toolbar-qcombobox-signal-slot.diff deleted file mode 100644 index 68499f6..0000000 --- a/debian/patches/0189-fix-q3toolbar-qcombobox-signal-slot.diff +++ /dev/null @@ -1,31 +0,0 @@ -qt-bugs@ issue : none -Trolltech task ID : 171843 -bugs.kde.org number : none -applied: yes -author: Laurent Montel <montel@kde.org> - -This patch changed un-existing slot in qcombobox by existing slot. -(internalActivate is defined by q3combobox) -When qcombobox was transform to popupmenu when toolbar with combobox is too small -we used this slot to update combobox. (now it's updated) - ---- a/src/qt3support/widgets/q3toolbar.cpp -+++ b/src/qt3support/widgets/q3toolbar.cpp -@@ -667,7 +667,7 @@ - Q3PopupMenu *cp = new Q3PopupMenu(d->extensionPopup); - cp->setEnabled(c->isEnabled()); - d->extensionPopup->insertItem(s, cp); -- connect(cp, SIGNAL(activated(int)), c, SLOT(internalActivate(int))); -+ connect(cp, SIGNAL(activated(int)), c, SLOT(setCurrentIndex(int))); - for (int i = 0; i < c->count(); ++i) { - QString tmp = c->text(i); - cp->insertItem(tmp, i); -@@ -682,7 +682,7 @@ - Q3PopupMenu* sp = new Q3PopupMenu(d->extensionPopup); - cp->insertItem(tr("More..."), sp); - cp = sp; -- connect(cp, SIGNAL(activated(int)), c, SLOT(internalActivate(int))); -+ connect(cp, SIGNAL(activated(int)), c, SLOT(setCurrentIndex(int))); - } - } - } diff --git a/debian/patches/0191-listview-alternate-row-colors.diff b/debian/patches/0191-listview-alternate-row-colors.diff index 65af0ad..d81a994 100644 --- a/debian/patches/0191-listview-alternate-row-colors.diff +++ b/debian/patches/0191-listview-alternate-row-colors.diff @@ -1,5 +1,5 @@ qt-bugs@ issue : 178507 -Trolltech task ID : 179170 +Trolltech task ID : 179170 (status: fixed for Qt 4.4.0) applied: no author: Matthew Woehlke <mw_triad@users.sourceforge.net> diff --git a/debian/patches/0192-itemdelegate-palette-state.diff b/debian/patches/0192-itemdelegate-palette-state.diff index e031933..d1aed7f 100644 --- a/debian/patches/0192-itemdelegate-palette-state.diff +++ b/debian/patches/0192-itemdelegate-palette-state.diff @@ -1,5 +1,5 @@ qt-bugs@ issue : 178507 -Trolltech task ID : 179170 +Trolltech task ID : 179170 (status: fixed for Qt 4.4.0) applied: no author: Matthew Woehlke <mw_triad@users.sourceforge.net> @@ -9,7 +9,7 @@ in active windows. --- a/src/gui/itemviews/qitemdelegate.cpp +++ b/src/gui/itemviews/qitemdelegate.cpp -@@ -635,10 +635,10 @@ +@@ -633,10 +633,10 @@ QPen pen = painter->pen(); QPalette::ColorGroup cg = option.state & QStyle::State_Enabled diff --git a/debian/patches/0193-qtreeview-division-by-zero.diff b/debian/patches/0193-qtreeview-division-by-zero.diff deleted file mode 100644 index 801b533..0000000 --- a/debian/patches/0193-qtreeview-division-by-zero.diff +++ /dev/null @@ -1,21 +0,0 @@ -qt-bugs@ issue : N180629 -Trolltech task ID : none -bugs.kde.org number : None -applied: yes -author: Rafael Fernández López <ereslibre@kde.org> - -This patch fixes a division by zero that happens on the QTreeView widget -if the ScrollPerPixel scroll mode is set. - ---- a/src/gui/itemviews/qtreeview.cpp -+++ b/src/gui/itemviews/qtreeview.cpp -@@ -2983,6 +2983,9 @@ - } - // ScrollMode == ScrollPerPixel - if (uniformRowHeights) { -+ if (!defaultItemHeight) -+ return -1; -+ - if (offset) - *offset = -(value % defaultItemHeight); - return value / defaultItemHeight; diff --git a/debian/patches/0194-fix-moveonly-dnd-in-itemviews.diff b/debian/patches/0194-fix-moveonly-dnd-in-itemviews.diff index 4ae99b6..45d7847 100644 --- a/debian/patches/0194-fix-moveonly-dnd-in-itemviews.diff +++ b/debian/patches/0194-fix-moveonly-dnd-in-itemviews.diff @@ -1,13 +1,24 @@ qt-bugs@ issue : 181399 -Trolltech task ID : 181413 +Trolltech task ID : 181413 (status: pending for Qt 4.4.0) applied: no author: Matthias Kretz <kretz@kde.org> Allows drag and drop to work without pressing the shift key for itemviews that use InternalMove. +--- a/src/gui/itemviews/qlistview.cpp ++++ b/src/gui/itemviews/qlistview.cpp +@@ -992,7 +992,7 @@ + } + QDrag *drag = new QDrag(this); + drag->setMimeData(d->model->mimeData(indexes)); +- Qt::DropAction action = drag->start(supportedActions); ++ Qt::DropAction action = drag->exec(supportedActions); + d->dynamicListView->draggedItems.clear(); + if (action == Qt::MoveAction) + d->clearOrRemove(); --- a/src/gui/itemviews/qabstractitemview.cpp +++ b/src/gui/itemviews/qabstractitemview.cpp -@@ -2968,7 +2968,7 @@ +@@ -2966,7 +2966,7 @@ #ifndef QT_NO_DRAGANDDROP /*! @@ -16,7 +27,7 @@ Allows drag and drop to work without pressing the shift key for itemviews that u */ void QAbstractItemView::startDrag(Qt::DropActions supportedActions) { -@@ -2985,7 +2985,7 @@ +@@ -2983,7 +2983,7 @@ drag->setPixmap(pixmap); drag->setMimeData(data); drag->setHotSpot(d->pressedPosition - rect.topLeft()); @@ -25,14 +36,3 @@ Allows drag and drop to work without pressing the shift key for itemviews that u d->clearOrRemove(); } } ---- a/src/gui/itemviews/qlistview.cpp -+++ b/src/gui/itemviews/qlistview.cpp -@@ -992,7 +992,7 @@ - d->dynamicListView->draggedItems.push_back(*it); - QDrag *drag = new QDrag(this); - drag->setMimeData(d->model->mimeData(indexes)); -- Qt::DropAction action = drag->start(supportedActions); -+ Qt::DropAction action = drag->exec(supportedActions); - d->dynamicListView->draggedItems.clear(); - if (action == Qt::MoveAction) - d->clearOrRemove(); diff --git a/debian/patches/0195-compositing-properties.diff b/debian/patches/0195-compositing-properties.diff index 98a1d6e..bb86db6 100644 --- a/debian/patches/0195-compositing-properties.diff +++ b/debian/patches/0195-compositing-properties.diff @@ -9,7 +9,7 @@ so they can be used when compositing. --- a/src/gui/kernel/qwidget_x11.cpp +++ b/src/gui/kernel/qwidget_x11.cpp -@@ -616,7 +616,11 @@ +@@ -614,7 +614,11 @@ wsa.save_under = True; XChangeWindowAttributes(dpy, id, CWOverrideRedirect | CWSaveUnder, &wsa); @@ -18,11 +18,11 @@ so they can be used when compositing. + QByteArray appName = qAppName().toLatin1(); + class_hint.res_name = appName.data(); // application name + class_hint.res_class = const_cast<char *>(QX11Info::appClass()); // application class -+ XSetClassHint(dpy, id, &class_hint); ++ XSetWMProperties(dpy, id, 0, 0, 0, 0, 0, 0, &class_hint); } else if (topLevel && !desktop) { // top-level widget if (!X11->wm_client_leader) create_wm_client_leader(); -@@ -661,29 +665,34 @@ +@@ -659,29 +663,34 @@ // set mwm hints SetMWMHints(dpy, id, mwmhints); diff --git a/debian/patches/0196-q3toolbar-clean-rebuild.diff b/debian/patches/0196-q3toolbar-clean-rebuild.diff deleted file mode 100644 index b8f643f..0000000 --- a/debian/patches/0196-q3toolbar-clean-rebuild.diff +++ /dev/null @@ -1,38 +0,0 @@ -qt-bugs@ issue : 182657 -bugs.kde.org number : none -applied: yes -author: TrollTech - -This patch fixes crash when we clear q3toolbar and rebuild it. -bug reported and tested by Laurent Montel <montel@kde.org>, -fixed by TT, patch will be in qt 4.3.3. - ---- a/src/qt3support/widgets/q3toolbar.cpp -+++ b/src/qt3support/widgets/q3toolbar.cpp -@@ -489,7 +489,8 @@ - if (child && child->isWidgetType() && !((QWidget*)child)->isWindow() - && child->parent() == this - && QLatin1String("qt_dockwidget_internal") != child->objectName()) { -- QWidgetItem *item = new QWidgetItem((QWidget*)child); -+ boxLayout()->addWidget((QWidget*)child); -+ QLayoutItem *item = boxLayout()->itemAt(boxLayout()->indexOf((QWidget*)child)); - if (QToolButton *button = qobject_cast<QToolButton*>(child)) { - item->setAlignment(Qt::AlignHCenter); - button->setFocusPolicy(Qt::NoFocus); -@@ -503,7 +504,6 @@ - } - button->setAutoRaise(true); - } -- boxLayout()->addItem(item); - if (isVisible()) { - // toolbar compatibility: we auto show widgets that - // are not explicitly hidden -@@ -551,6 +551,8 @@ - void Q3ToolBar::clear() - { - QObjectList childList = children(); -+ d->extension = 0; -+ d->extensionPopup = 0; //they will both be destroyed by the following code - for (int i = 0; i < childList.size(); ++i) { - QObject *obj = childList.at(i); - if (obj->isWidgetType() && QLatin1String("qt_dockwidget_internal") != obj->objectName()) diff --git a/debian/patches/0197-fix-qstylesheetstyle.diff b/debian/patches/0197-fix-qstylesheetstyle.diff deleted file mode 100644 index f047908..0000000 --- a/debian/patches/0197-fix-qstylesheetstyle.diff +++ /dev/null @@ -1,45 +0,0 @@ -qt-bugs@ issue : none -bugs.kde.org number : none -applied: yes -author: TrollTech - -it is a patch from Girish Ramakrishnan <girish@trolltech.com> -fixes eg klineedits looking wrong under oxygen. - ---- a/src/gui/styles/qstylesheetstyle.cpp -+++ b/src/gui/styles/qstylesheetstyle.cpp -@@ -1433,28 +1433,28 @@ - - #ifndef QT_NO_SPINBOX - if (qobject_cast<const QAbstractSpinBox *>(w)) -- return base->pixelMetric(QStyle::PM_SpinBoxFrameWidth); -+ return base->pixelMetric(QStyle::PM_SpinBoxFrameWidth, 0, w); - #endif - - #ifndef QT_NO_COMBOBOX - if (qobject_cast<const QComboBox *>(w)) -- return base->pixelMetric(QStyle::PM_ComboBoxFrameWidth); -+ return base->pixelMetric(QStyle::PM_ComboBoxFrameWidth, 0, w); - #endif - - #ifndef QT_NO_MENU - if (qobject_cast<const QMenu *>(w)) -- return base->pixelMetric(QStyle::PM_MenuPanelWidth); -+ return base->pixelMetric(QStyle::PM_MenuPanelWidth, 0, w); - #endif - - #ifndef QT_NO_MENUBAR - if (qobject_cast<const QMenuBar *>(w)) -- return base->pixelMetric(QStyle::PM_MenuBarPanelWidth); -+ return base->pixelMetric(QStyle::PM_MenuBarPanelWidth, 0, w); - #endif - - if (QString::fromLatin1(w->metaObject()->className()) == QLatin1String("QTipLabel")) -- return base->pixelMetric(QStyle::PM_ToolTipLabelFrameWidth); -+ return base->pixelMetric(QStyle::PM_ToolTipLabelFrameWidth, 0, w); - -- return base->pixelMetric(QStyle::PM_DefaultFrameWidth); -+ return base->pixelMetric(QStyle::PM_DefaultFrameWidth, 0, w); - } - - static int pseudoClass(QStyle::State state) diff --git a/debian/patches/0198-fix-qstylesheetstyle2.diff b/debian/patches/0198-fix-qstylesheetstyle2.diff deleted file mode 100644 index 9907b21..0000000 --- a/debian/patches/0198-fix-qstylesheetstyle2.diff +++ /dev/null @@ -1,38 +0,0 @@ -qt-bugs@ issue : none -bugs.kde.org number : none -applied: yes -author: Trolltech - -it is a patch from Girish Ramakrishnan <girish@trolltech.com> -fixes eg kcombobox with a clean button - ---- a/src/gui/styles/default.qss -+++ b/src/gui/styles/default.qss -@@ -11,6 +11,10 @@ - -qt-style-features: background-color; - } - -+QLineEdit:no-frame { -+ border: none; -+} -+ - QFrame { - border: native; - } ---- a/src/gui/styles/qstylesheetstyle.cpp -+++ b/src/gui/styles/qstylesheetstyle.cpp -@@ -1738,8 +1738,13 @@ - #endif // QT_NO_TOOLBOX - #ifndef QT_NO_LINEEDIT - // LineEdit sets Sunken flag to indicate Sunken frame (argh) -- if (qobject_cast<const QLineEdit *>(w)) { -+ if (const QLineEdit *lineEdit = qobject_cast<const QLineEdit *>(w)) { - state &= ~QStyle::State_Sunken; -+ if (lineEdit->frame()) { -+ extraClass &= ~PseudoClass_Frameless; -+ } else { -+ extraClass |= PseudoClass_Frameless; -+ } - } else - #endif - { } // required for the above ifdef'ery diff --git a/debian/patches/0200-fix-qsslsocket-waitfor.diff b/debian/patches/0200-fix-qsslsocket-waitfor.diff new file mode 100644 index 0000000..f8f5904 --- /dev/null +++ b/debian/patches/0200-fix-qsslsocket-waitfor.diff @@ -0,0 +1,60 @@ +qt-bugs@ issue : N188142 +Trolltech task ID : 188329 (status: fixed for Qt 4.4.0) +bugs.kde.org number : None +applied: no +author: Andreas Hartmetz <ahartmetz@gmail.com> + +This patch fixes that some QSslSocket::waitFor$X methods, when passed -1 as the +argument, behave as if they were passed 0. -1 is supposed to mean "wait indefi- +nitely" while 0 means "don't wait". + + +--- a/src/network/qsslsocket.cpp ++++ b/src/network/qsslsocket.cpp +@@ -250,6 +250,19 @@ + #include <QtNetwork/qhostaddress.h> + #include <QtNetwork/qhostinfo.h> + ++/* ++ Returns the difference between msecs and elapsed. If msecs is -1, ++ however, -1 is returned. ++*/ ++static int qt_timeout_value(int msecs, int elapsed) ++{ ++ if (msecs == -1) ++ return -1; ++ ++ int timeout = msecs - elapsed; ++ return timeout < 0 ? 0 : timeout; ++} ++ + class QSslSocketGlobalData + { + public: +@@ -1109,7 +1122,7 @@ + startClientEncryption(); + // Loop, waiting until the connection has been encrypted or an error + // occurs. +- if (!d->plainSocket->waitForReadyRead(qBound(0, msecs - stopWatch.elapsed(), msecs))) ++ if (!d->plainSocket->waitForReadyRead(qt_timeout_value(msecs, stopWatch.elapsed()))) + return false; + } + return d->connectionEncrypted; +@@ -1137,7 +1150,7 @@ + return false; + } + +- while (d->plainSocket->waitForReadyRead(qBound(0, msecs - stopWatch.elapsed(), msecs))) { ++ while (d->plainSocket->waitForReadyRead(qt_timeout_value(msecs, stopWatch.elapsed()))) { + if (d->readBuffer.size() != oldReadBufferSize) { + // If the read buffer has grown, readyRead() must have been emitted. + return true; +@@ -1166,7 +1179,7 @@ + return false; + } + +- return d->plainSocket->waitForBytesWritten(qBound(0, msecs - stopWatch.elapsed(), msecs)); ++ return d->plainSocket->waitForBytesWritten(qt_timeout_value(msecs, stopWatch.elapsed())); + } + + /*! diff --git a/debian/patches/0203-qtexthtmlparser-link-color.diff b/debian/patches/0203-qtexthtmlparser-link-color.diff new file mode 100644 index 0000000..5a7e8d5 --- /dev/null +++ b/debian/patches/0203-qtexthtmlparser-link-color.diff @@ -0,0 +1,18 @@ +qt-bugs@ issue : none +Trolltech task ID : none +applied: yes +author: Rafael Fernández López <ereslibre@kde.org> + +Links are assigned a foreground color according to the system current color scheme. + +--- a/src/gui/text/qtexthtmlparser.cpp ++++ b/src/gui/text/qtexthtmlparser.cpp +@@ -1031,7 +1031,7 @@ + && !attributes.at(i + 1).isEmpty()) { + hasHref = true; + charFormat.setUnderlineStyle(QTextCharFormat::SingleUnderline); +- charFormat.setForeground(Qt::blue); ++ charFormat.setForeground(QApplication::palette().link()); + } + } + diff --git a/debian/patches/02_launch_assistant-qt4.diff b/debian/patches/02_launch_assistant-qt4.diff index 16ca90a..042a4bc 100644 --- a/debian/patches/02_launch_assistant-qt4.diff +++ b/debian/patches/02_launch_assistant-qt4.diff @@ -2,7 +2,7 @@ author: Brian Nelson <pyro@debian.org> --- a/tools/assistant/lib/qassistantclient.cpp +++ b/tools/assistant/lib/qassistantclient.cpp -@@ -187,11 +187,11 @@ +@@ -185,11 +185,11 @@ : QObject( parent ), host ( QLatin1String("localhost") ) { if ( path.isEmpty() ) diff --git a/debian/patches/03_launch_moc-qt4.diff b/debian/patches/03_launch_moc-qt4.diff index 31945eb..79db752 100644 --- a/debian/patches/03_launch_moc-qt4.diff +++ b/debian/patches/03_launch_moc-qt4.diff @@ -4,7 +4,7 @@ Ensure the Qt4 version of moc is launched. --- a/tools/qdbus/tools/qdbuscpp2xml/qdbuscpp2xml.cpp +++ b/tools/qdbus/tools/qdbuscpp2xml/qdbuscpp2xml.cpp -@@ -391,7 +391,7 @@ +@@ -389,7 +389,7 @@ else { // run moc on this file QProcess proc; diff --git a/debian/patches/04_launch_uic-qt4.diff b/debian/patches/04_launch_uic-qt4.diff index 8119a61..002d3b1 100644 --- a/debian/patches/04_launch_uic-qt4.diff +++ b/debian/patches/04_launch_uic-qt4.diff @@ -2,7 +2,7 @@ author: Fathi Boudra <fboudra@free.fr> --- a/tools/designer/src/lib/shared/qdesigner_utils.cpp +++ b/tools/designer/src/lib/shared/qdesigner_utils.cpp -@@ -133,7 +133,7 @@ +@@ -131,7 +131,7 @@ binary += QDir::separator(); switch (mode) { case UIC_GenerateCode: diff --git a/debian/patches/07_trust_dpkg-arch_over_uname-m.diff b/debian/patches/07_trust_dpkg-arch_over_uname-m.diff index 67b94fe..ce40ef6 100644 --- a/debian/patches/07_trust_dpkg-arch_over_uname-m.diff +++ b/debian/patches/07_trust_dpkg-arch_over_uname-m.diff @@ -1,7 +1,5 @@ author: Sune Vuorela Reported to trolltech as N180631 - and task 181882 -Index: b/configure -=================================================================== --- a/configure +++ b/configure @@ -93,7 +93,44 @@ diff --git a/debian/patches/08_load_ssl.diff b/debian/patches/08_load_ssl.diff index 1b85cb3..e393f7a 100644 --- a/debian/patches/08_load_ssl.diff +++ b/debian/patches/08_load_ssl.diff @@ -1,6 +1,6 @@ --- a/src/network/qsslsocket_openssl_symbols.cpp +++ b/src/network/qsslsocket_openssl_symbols.cpp -@@ -249,7 +249,7 @@ +@@ -247,7 +247,7 @@ return false; } #else @@ -9,7 +9,7 @@ if (!libssl.load()) { // Cannot find libssl qWarning("QSslSocket: cannot find ssl library: %s.", -@@ -257,7 +257,7 @@ +@@ -255,7 +255,7 @@ return false; } diff --git a/debian/patches/30_arm_ftbfs_fixes.diff b/debian/patches/30_arm_ftbfs_fixes.diff index 9f2648a..3d2be94 100644 --- a/debian/patches/30_arm_ftbfs_fixes.diff +++ b/debian/patches/30_arm_ftbfs_fixes.diff @@ -4,7 +4,7 @@ Fix arm FTBFS. --- a/tools/qtestlib/src/qtestcase.h +++ b/tools/qtestlib/src/qtestcase.h -@@ -210,7 +210,7 @@ +@@ -208,7 +208,7 @@ template <typename T1, typename T2> bool qCompare(T1 const &, T2 const &, const char *, const char *, const char *, int); diff --git a/debian/patches/31_arm_eabi_fix.diff b/debian/patches/31_arm_eabi_fix.diff index c6557fe..7af3152 100644 --- a/debian/patches/31_arm_eabi_fix.diff +++ b/debian/patches/31_arm_eabi_fix.diff @@ -4,7 +4,7 @@ Add support for EABI ARM platforms to Qt. --- a/src/corelib/global/qglobal.h +++ b/src/corelib/global/qglobal.h -@@ -331,7 +331,7 @@ +@@ -329,7 +329,7 @@ # if defined(Q_OS_DARWIN) && __GNUC__ == 3 && (__GNUC_MINOR__ >= 1 && __GNUC_MINOR__ < 3) # define Q_BROKEN_DEBUG_STREAM # endif diff --git a/debian/patches/40_alpha_ice.diff b/debian/patches/40_alpha_ice.diff index c55986e..7e75989 100644 --- a/debian/patches/40_alpha_ice.diff +++ b/debian/patches/40_alpha_ice.diff @@ -1,6 +1,6 @@ --- a/src/corelib/global/qlibraryinfo.cpp +++ b/src/corelib/global/qlibraryinfo.cpp -@@ -69,14 +69,7 @@ +@@ -67,14 +67,7 @@ { public: static QSettings *findConfiguration(); @@ -16,7 +16,7 @@ static QSettings *configuration() { #ifdef QT_NO_THREAD -@@ -95,6 +88,15 @@ +@@ -93,6 +86,15 @@ } }; @@ -34,7 +34,7 @@ settings = QLibraryInfoPrivate::findConfiguration(); --- a/src/corelib/tools/qhash.h +++ b/src/corelib/tools/qhash.h -@@ -479,7 +479,7 @@ +@@ -477,7 +477,7 @@ } template <class Key, class T> diff --git a/debian/patches/50_kfreebsd_build_fix.diff b/debian/patches/50_kfreebsd_build_fix.diff index 81601a0..6a04aad 100644 --- a/debian/patches/50_kfreebsd_build_fix.diff +++ b/debian/patches/50_kfreebsd_build_fix.diff @@ -4,7 +4,7 @@ Fixes FTBFS on GNU/kFreeBSD by creating new Q_OS_GLIBC. --- a/src/corelib/global/qglobal.h +++ b/src/corelib/global/qglobal.h -@@ -125,6 +125,12 @@ +@@ -123,6 +123,12 @@ # define Q_OS_RELIANT #elif defined(__linux__) || defined(__linux) # define Q_OS_LINUX @@ -17,7 +17,7 @@ Fixes FTBFS on GNU/kFreeBSD by creating new Q_OS_GLIBC. #elif defined(__FreeBSD__) || defined(__DragonFly__) # define Q_OS_FREEBSD # define Q_OS_BSD4 -@@ -145,8 +151,6 @@ +@@ -143,8 +149,6 @@ # define Q_OS_AIX #elif defined(__Lynx__) # define Q_OS_LYNX @@ -28,7 +28,7 @@ Fixes FTBFS on GNU/kFreeBSD by creating new Q_OS_GLIBC. #elif defined(__QNXNTO__) --- a/src/corelib/plugin/qlibrary.cpp +++ b/src/corelib/plugin/qlibrary.cpp -@@ -293,11 +293,11 @@ +@@ -291,11 +291,11 @@ #if defined(Q_OS_UNIX) && !defined(Q_OS_MAC) @@ -44,7 +44,7 @@ Fixes FTBFS on GNU/kFreeBSD by creating new Q_OS_GLIBC. const char *pattern, ulong p_len) --- a/src/corelib/tools/qlocale.cpp +++ b/src/corelib/tools/qlocale.cpp -@@ -63,7 +63,7 @@ +@@ -61,7 +61,7 @@ #include <qdebug.h> #include <time.h> @@ -53,7 +53,7 @@ Fixes FTBFS on GNU/kFreeBSD by creating new Q_OS_GLIBC. # include <fenv.h> #endif -@@ -5930,7 +5930,7 @@ +@@ -5927,7 +5927,7 @@ _control87(MCW_EM, MCW_EM); #endif @@ -62,7 +62,7 @@ Fixes FTBFS on GNU/kFreeBSD by creating new Q_OS_GLIBC. fenv_t envp; feholdexcept(&envp); #endif -@@ -5946,7 +5946,7 @@ +@@ -5943,7 +5943,7 @@ #endif //_M_X64 #endif //Q_OS_WIN diff --git a/debian/patches/60_m68k_inotify_fix.diff b/debian/patches/60_m68k_inotify_fix.diff index 4e1c7c7..8f10f4c 100644 --- a/debian/patches/60_m68k_inotify_fix.diff +++ b/debian/patches/60_m68k_inotify_fix.diff @@ -5,7 +5,7 @@ m68k tree, they should appear like this soon also in the upstream source. --- a/src/corelib/io/qfilesystemwatcher_inotify.cpp +++ b/src/corelib/io/qfilesystemwatcher_inotify.cpp -@@ -103,6 +103,10 @@ +@@ -101,6 +101,10 @@ # define __NR_inotify_init 269 # define __NR_inotify_add_watch 270 # define __NR_inotify_rm_watch 271 diff --git a/debian/patches/80_hurd_max_path.diff b/debian/patches/80_hurd_max_path.diff index 9b3d274..b53e50b 100644 --- a/debian/patches/80_hurd_max_path.diff +++ b/debian/patches/80_hurd_max_path.diff @@ -2,7 +2,7 @@ author: Brian Nelson <pyro@debian.org> --- a/src/corelib/io/qfsfileengine_unix.cpp +++ b/src/corelib/io/qfsfileengine_unix.cpp -@@ -55,6 +55,10 @@ +@@ -53,6 +53,10 @@ # include <private/qcore_mac_p.h> #endif diff --git a/debian/patches/series b/debian/patches/series index 6f246c4..ada56ba 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -1,23 +1,18 @@ # qt-copy patches -0163-fix-gcc43-support.diff 0167-fix-group-reading.diff +#0172-prefer-xrandr-over-xinerama.diff 0175-fix-s390-qatomic.diff 0176-coverity-fixes.diff 0178-transparency-window-types.diff 0179-transient-hack.diff 0180-window-role.diff -0185-fix-format-strings.diff 0187-fix-font-fixed-pitch.diff -0188-fix-moc-parser-same-name-header.diff -0189-fix-q3toolbar-qcombobox-signal-slot.diff 0191-listview-alternate-row-colors.diff 0192-itemdelegate-palette-state.diff -0193-qtreeview-division-by-zero.diff 0194-fix-moveonly-dnd-in-itemviews.diff 0195-compositing-properties.diff -0196-q3toolbar-clean-rebuild.diff -0197-fix-qstylesheetstyle.diff -0198-fix-qstylesheetstyle2.diff +0200-fix-qsslsocket-waitfor.diff +0203-qtexthtmlparser-link-color.diff # debian patches 01_qmake_for_debian.diff |