Commit Graph

5951 Commits

Author SHA1 Message Date
Sérgio Martins
4bced6e7a6 Introduce QHash key iterators
So we can have interoperability with algorithms.
Motivated by inefficient code like qDeleteAll(hash.keys())

[ChangeLog][QtCore][QHash] Added key iterators, accessible through
keyBegin() and keyEnd().

Change-Id: I1f9db8a7a4294e1556cbb50b8fe5ebdcf0dc29a2
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2015-07-28 19:11:17 +00:00
Sérgio Martins
07f27fcf6d Introduce QMap key iterators
So we can have interoperability with algorithms.
Motivated by inefficient code like qDeleteAll(map.keys())

[ChangeLog][QtCore][QMap] Added key iterators, accessible through
keyBegin() and keyEnd().

Change-Id: Ieee2f9ad031e9d1e845a71447746699bbe95b96c
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2015-07-28 19:11:12 +00:00
Friedemann Kleint
75244bf985 tst_qgraphicsproxywidget: Rename test slot to fix compiler warning.
Rename the test slot eventFilter() to testEventFilter(), which fixes:

tst_qgraphicsproxywidget.cpp:101:10: warning: 'tst_QGraphicsProxyWidget::eventFilter' hides overloaded virtual function [-Woverloaded-virtual]
    void eventFilter();.

Change-Id: Ia05d188b18dcbf3a0b093dcea19a7122bcde6e62
Reviewed-by: Andreas Aardal Hanssen <andreas@hanssen.name>
2015-07-28 13:19:39 +00:00
Friedemann Kleint
18a2d9438f tst_qhostaddress: Add braces to initialization of a Q_IPV6ADDR.
Fix warning:

tst_qhostaddress.cpp:319:38: warning: suggest braces around initialization of subobject [-Wmissing-braces]
    Q_IPV6ADDR localhostv4mapped = { 0, 0, 0, 0,  0, 0, 0, 0,  0, 0, 255, 255,  127, 0, 0, 1 };
                                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Change-Id: I9e00300413bfd9ac393c61adf8eb773009ed969d
Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
2015-07-28 13:19:26 +00:00
Friedemann Kleint
120cc9f78e tst_qgraphicsanchorlayout: Fix warning about unused function result.
tst_qgraphicsanchorlayout.cpp:144:5: warning: ignoring return value of function declared with warn_unused_result attribute [-Wunused-result]
    layoutGeometry.adjusted(+right, +top, -left, -bottom);

Change-Id: I411ccaa867e418f36869fc244ea2eeaa5b117312
Reviewed-by: Andreas Aardal Hanssen <andreas@hanssen.name>
2015-07-28 13:19:17 +00:00
Friedemann Kleint
4b8cda8a36 Tests: Remove some unused member variables.
Fix warnings:

tst_qtcpsocket.cpp:245:9: warning: private field 'numConnections' is not used [-Wunused-private-field]
    int numConnections;
        ^
tst_qtcpsocket.cpp:1834:9: warning: private field 'exitCode' is not used [-Wunused-private-field]
    int exitCode;

tst_qcheckbox.cpp:86:10: warning: private field 'tmp' is not used [-Wunused-private-field]
    uint tmp;
         ^
tst_qcheckbox.cpp:88:10: warning: private field 'tmp2' is not used [-Wunused-private-field]
    uint tmp2;

Below warning is caused by code #ifdefed for OS X only, make it a local variable:
tst_qlabel.cpp:114:16: warning: private field 'test_edit' is not used [-Wunused-private-field]
    QLineEdit *test_edit;

Change-Id: I53c755545fe2e7ca1f053f40c8c0e50aec2efcdd
Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
2015-07-28 13:19:07 +00:00
Friedemann Kleint
569785cb00 Various tests: Replace Q[TRY]_VERIFY(a == b) by Q[TRY]_COMPARE(a, b).
- Replace Q[TRY]_VERIFY(pointer == 0) by Q[TRY]_VERIFY(!pointer).
- Replace Q[TRY]_VERIFY(smartPointer == 0)  by
          Q[TRY]_VERIFY(smartPointer.isNull()).
- Replace Q[TRY]_VERIFY(a == b) by  Q[TRY]_COMPARE(a, b) and
  add casts where necessary. The values will then be logged
  should a test fail.

in tests/auto/other, tests/auto/printsupport and tests/auto/xml.

Change-Id: I28cbdc89d36791f179425f17f90b697c60660938
Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
2015-07-28 13:18:55 +00:00
Friedemann Kleint
3b04cc6a4a tst_qmenubar: Cast char-type array subscripts to int.
Fix CLANG warnings:

tst_qmenubar.cpp:719:35: warning: array subscript is of type 'char' [-Wchar-subscripts]
    QCOMPARE(m_complexTriggerCount['c'], 1);
(repeated)

Change-Id: I3628ccdd91af4d31863b3514163bb78c862b78f1
Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
2015-07-28 13:18:13 +00:00
Friedemann Kleint
c067c012dc Tests: Replace Q[TRY]_VERIFY(v == true|false) by QVERIFY(v)|QVERIFY(!v).
Preparing the replacement of Q[TRY]_VERIFY(a == b) by
Q[TRY]_COMPARE(a, b) for non-boolean types.

Change-Id: Iab6ec2f0a89a3adc79e18304573994965013dab5
Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
2015-07-27 12:09:19 +00:00
Friedemann Kleint
424e6386c6 tests/auto/opengl: Replace Q[TRY]_VERIFY(a == b) by Q[TRY]_COMPARE(a, b).
- Replace Q[TRY]_VERIFY(pointer == 0) by Q[TRY]_VERIFY(!pointer).
- Replace Q[TRY]_VERIFY(smartPointer == 0)  by
          Q[TRY]_VERIFY(smartPointer.isNull()).
- Replace Q[TRY]_VERIFY(a == b) by  Q[TRY]_COMPARE(a, b) and
  add casts where necessary. The values will then be logged
  should a test fail.

Change-Id: I7add5b7afeba83895acdcbed110e8275dc76864a
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-07-24 21:23:34 +00:00
Erik Verbruggen
5fd9fe02ff QStateMachine: add defaultTransition in QHistoryState
The history state had the limitation that it was hard (or impossible) to
use when more than one default state had to be entered. For example,
using it in a parallel state was impossible without ending up in an
infinite loop.

This patch changes the QHistoryState to only have an initial transition,
and the state selection algorithm is changed accordingly. It also brings
QStateMachine closer to the SCXML standard.

The existing defaultState is implemented on top of the
defaultTransition: when used, a new transition, with the default state as
its target, is set as the defaultTransition.

Task-number: QTBUG-46703
Change-Id: Ifbb44e4f0f26b72e365af4c94753e4483f9850e7
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
2015-07-23 13:29:46 +00:00
Erik Verbruggen
0cd34a0c39 StateMachine: remove initial state for parallel states.
A parallel state cannot have an initial state, as all children of the
parallel state will be entered. Setting such an initial state on a
QState marked as ParallelStates would already produce a warning and
ignore the initial state. Now any initial state that has been set before
changing the child-mode to ParallelStates will also produce a warning
and remove the previously set initial state.

Change-Id: Ie5fcd44b03516744f785f2d1880bf806918c44d4
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
2015-07-23 07:44:35 +00:00
Friedemann Kleint
5f5db1c38b QTestLib: Add macros QTRY_VERIFY2_WITH_TIMEOUT(), QTRY_VERIFY2().
Add QTRY_VERIFY2_WITH_TIMEOUT() similar to QTRY_VERIFY_WITH_TIMEOUT()
except that QTRY_VERIFY2() is used below the loop and QTRY_VERIFY2()
based on it.

Add tests to cmptest.

[ChangeLog][QtTest] Added macros QTRY_VERIFY2_WITH_TIMEOUT(), QTRY_VERIFY2()
making it possible to output a message after the timeout has expired.

Change-Id: I587e24f3aeb73542dbf3ccb936a16f2e0806555f
Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
2015-07-22 19:32:39 +00:00
Thiago Macieira
db2fc7843c QProcess: make setWorkingDirectory stop launch if the dir doesn't exist
[ChangeLog][QtCore][QProcess] Fixed a bug that caused QProcess to launch
a child process on Unix even if the directory specified with
setWorkingDirectory did not exist.

Task-number: QTBUG-47271
Change-Id: Ib306f8f647014b399b87ffff13f195158b0e52f5
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2015-07-20 16:07:46 +00:00
Ulf Hermann
ee0fd87007 Selectively update library paths when creating QCoreApplication
We force a recreation of the library paths with added information on
construction of QCoreApplication. This way we can find plugins in
the application directory which only becomes known when
QCoreApplication is created. When the user changes the library path
we create a new list of the manually modified library paths and
recalculate it from the delta of original vs. modified paths when
QCoreApplication is created.

The upsides of this approach vs. keeping an explicit delta are:

* We don't need to introduce a separate data structure to hold
  the added/removed status for delta items or the information that
  the whole list got replaced.

* The lists never get larger than the the real library paths. An
  explicit delta would have to record all modifications.

* I don't think the delta replay algorithm we would have to do
  anyway could be made much more compact than the one this change
  introduces.

Of course, if the user actually changes anything, the list is
duplicated. Considering that this is a rarely used function and
that we would have to save some extra information anyway, I think
we can live with this.

Task-number: QTBUG-38598
Change-Id: I3bfbbd1be62dd5804dcc7ac808b053428a4e3149
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2015-07-20 15:57:07 +00:00
Jeremy Lainé
49fee77ccc ssl: add openssl-based QSslKeyPrivate::encrypt / decrypt
This adds an OpenSSL-based implementation of the QSslKeyPrivate encrypt
and decrypt method. This puts both the OpenSSL-based and non-OpenSSL
backends (WinRT for now) on par.

Change-Id: I18a75ee5f1c223601e51ebf0933f4430e7c5c29b
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
Reviewed-by: Richard J. Moore <rich@kde.org>
2015-07-20 15:51:02 +00:00
Marc Mutz
4ea3c0ba80 QVector: add an rvalue overload of push_back/append
This is low-hanging fruit, for two reasons:
1. The implementation is dead-simple (unlike, say, in QList).
2. It's completely transparent to the QVector user (unlike,
   say, emplace_back, which can only be used inside an ifdef).

Change-Id: Iaf750100cf61ced77aa452f0e4e3c4ec36b29639
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2015-07-19 18:09:27 +00:00
Marc Mutz
0abd207052 QZip*: don't hold QZipReader::FileInfo in QList
FileInfo is larger than a void*, so holding them in a QList is needlessly
inefficient. Worse, the code could come to depend on the fragile property
of (inefficient) QLists that references to elements therein never are
invalidated.

Change-Id: I772177c5ac544a5fecce2368f628148308ef260f
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2015-07-19 10:35:41 +00:00
Friedemann Kleint
ce7fb157f0 Tests: Do not rely on qCompare(bool, int,...).
The overload was added for NokiaX86 and RVCT and is bound for
removal.

Task-number: QTBUG-47260
Change-Id: Ic67cee8769847956e16cd0470ebcd663a9e98a40
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2015-07-18 10:36:17 +00:00
Thiago Macieira
10c529b08d Add a way for auxiliary threads to handle events without CoreApp
Long-lived threads started by Qt itself can now receive events even if
QCoreApplication hasn't been created. This is required in all threads we
start that will handle events, unless we're sure that the thread will
exit before the global application object begins destruction.

Otherwise, those threads will have race conditions dealing with the
event delivery system trying to call the QCoreApplication::notify()
virtual while the object is being destroyed.

Change-Id: I27eaacb532114dd188c4ffff13d4ad2a4bb443e6
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2015-07-18 02:24:59 +00:00
Thiago Macieira
7331b15525 Add QTemporaryDir::errorString()
[ChangeLog][QtCore][QTemporaryDir] Added errorString() method that
returns the string explaining why creating the temporary directory
failed.

Change-Id: Ib306f8f647014b399b87ffff13f0a1f3c89e0a2c
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: David Faure <david.faure@kdab.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2015-07-17 17:36:07 +00:00
Simon Hausmann
dcc301abfa Merge "Merge remote-tracking branch 'origin/5.5' into HEAD" into refs/staging/dev 2015-07-17 14:43:34 +00:00
Simon Hausmann
b2603b7665 Merge remote-tracking branch 'origin/5.5' into HEAD
Conflicts:
	src/plugins/platforms/windows/qwindowsopengltester.cpp

Change-Id: Ia7abeba9395ccf84e2fa81b91a5725a86dedb9fe
2015-07-17 16:35:42 +02:00
Friedemann Kleint
4b8ba3c91a Fix sub test float of tests/auto/testlib/selftests/tst_selftests for MSVC 2015.
From MSVC 2015 onwards, MSVC formats floats using printf("%g") like
g++, so the fiddling of the expected output needs to restricted
accordingly.

Change-Id: I6e7f78e5e90f70886a8b2ef37c0fb9bf82b5e1a3
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
2015-07-17 14:15:19 +00:00
Friedemann Kleint
7f77d4fcd5 tst_qprintdevice: Extend output.
Show the printer parameters using the new QDebug operator
for QPrintDevice for better error analysis in the CI.

Produces output:
Created printer *HP_Color_LaserJet_CM6030_MFP*:
QPrintDevice(id="HP_Color_LaserJet_CM6030_MFP", state=0, name="HP Color LaserJet CM6030 MFP", makeAndModel="HP Color LaserJet CM6030 MFP Postscript (recommended)", default, defaultPageSize=QPageSize("Letter", "Letter", 612x792pt, 2), supportsCustomPageSizes, physicalPageSize=(278, 396)..(907, 1296), defaultResolution=600, defaultDuplexMode=0, defaultColorMode=1, supportedMimeTypes=( "application/pdf" "application/postscript" "image/gif" "image/png" "image/jpeg" "image/tiff" "text/html" "text/plain"))

Task-number: QTBUG-47246
Change-Id: I5245d19ecf958a730a0288d5eff2d24fc3064a55
Reviewed-by: Andy Shaw <andy.shaw@theqtcompany.com>
2015-07-17 14:15:04 +00:00
Friedemann Kleint
696ea2fff1 tst_qmimedatabase: Add some log output when running update-mime-database.
When running the test, one gets the impression that it hangs.
Add some debug output including time to show what happens.

Change-Id: Iac6b4f0518ecec62169bf2269a0a8ec9192da570
Reviewed-by: David Faure <david.faure@kdab.com>
2015-07-17 14:14:42 +00:00
Friedemann Kleint
26bcc0565f QDir::removeRecursively(): Retry file deletion with write permission set.
On Windows, having read-only files in a directory can cause removal
to fail. When file deletion fails, check on the permissions, set
write permissions and retry.

Split apart code paths by OS in tst_QDir::removeRecursivelyFailure();
deletion of the read-only directory on UNIX should still fail.

Change-Id: I36e54be5229a7b552e90fd5f42722b868fa0b6ee
Reviewed-by: David Faure <david.faure@kdab.com>
2015-07-17 11:06:28 +00:00
Friedemann Kleint
d6553d2cd8 Stabilize tst_QListView::batchedMode().
The test showed failures on OS X:

FAIL!  : tst_QListView::batchedMode() Compared values are not the same
    Actual   (ba.size()): 2
    Expected (3)        : 3
    Loc: [tst_qlistview.cpp(848)]

Use QTRY_COMPARE() to count the number of visible indexes with
a helper function instead of using hard-coded timeouts. Item 3
appears with a little delay on OS X.

Change-Id: I2fb2ff5ebdf9dbe85bdc79401375ad6f47b7b12b
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
2015-07-17 10:30:39 +00:00
Friedemann Kleint
2a289d1947 Stabilize tst_QApplication::touchEventPropagation().
The test checks whether a child window receives
mouse events synthesizes from touch. Enlarge the child
window so that it fully covers the parent and move the
touch point a bit inside so that it is not affected
by window manager positioning issues.
Use QTRY_VERIFY.

FAIL!  : tst_QApplication::touchEventPropagation() 'widget.seenMouseEvent' returned FALSE. ()
     Loc: [/work/build/qt/qtbase/tests/auto/widgets/kernel/qapplication/tst_qapplication.cpp(2107)]

Change-Id: Ic08e68b1e547cc7148cd8994464fdc2a14ac507b
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
2015-07-16 21:45:28 +00:00
Friedemann Kleint
a847c2cb61 Stabilize tst_QTouchEvent::touchBeginWithGraphicsWidget().
The test sends touch events to the root item at the top left
corner which fails if the views starts to scroll.
Make the view sufficiently large to prevent scrolling and align
at top left.

FAIL!  : tst_QTouchEvent::touchBeginWithGraphicsWidget() Compared values are not the same
     Actual   (((root->touchBeginCounter))): 0
     Expected (1)                          : 1
     Loc: [/work/build/qt/qtbase/tests/auto/gui/kernel/qtouchevent/tst_qtouchevent.cpp(1471)]

Change-Id: I357322ccc809ddb5cb587febf3c75cbe497e59d8
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
2015-07-16 21:43:31 +00:00
Friedemann Kleint
3e34484a3f tst_qaccessibility: Add message in case fuzzy comparison of QRect fails.
Change-Id: I815dc5e79c539b384793bf3573f6149240cf0390
Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
2015-07-16 13:29:41 +00:00
Thiago Macieira
3aa5ef2ea9 Disable thread-safe statics for MSVC 2015: they're broken
An object that throws in its constructor cannot be reentered. This
violates both C++11 and C++98. It's also a regression from MSVC 2013.

The unit test is renamed to indicate what it really does, as opposed to
a misleading name that was probably a "thinko" on my part.

Task-number: QTBUG-47224
Change-Id: Ib306f8f647014b399b87ffff13f132436d0578ef
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
2015-07-16 08:28:07 +00:00
Thiago Macieira
02418d1aaa Set the state of QTemporaryFileEngine properly prior to reopening
QTemporaryFileEngine does not store the pattern, so it needs to get it
again from QTemporaryFilePrivate prior to reopening the file. It's
possible to lose the pattern when remove() is called on the object.

Task-number: QTBUG-46156
Change-Id: I66a35ce5f88941f29aa6ffff13dfc7f83d4fa3a2
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Reviewed-by: David Faure <david.faure@kdab.com>
2015-07-15 04:53:30 +00:00
Kai Koehne
4672e319e6 Core: Replace QProcess::error signal with QProcess::errorOccurred
Make the name of the signal and the name of the getter unambiguous,
which in turn allows the easy use of Qt 5-style connects.

[ChangeLog][QtCore] Deprecated QProcess::error() signal in favor
of new QProcess::errorOccurred() one.

Change-Id: Ic5bcf7d6878e6985f1b4fed9dbe247527d13758c
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2015-07-10 18:31:38 +00:00
Frederik Gladhorn
a2c829f339 Disable spdy test on Windows
The test is crashing regularly (see bugreport).
Currently the test is not run in the regular CI system, that is why
the failures were not noticed.

Task-number: QTBUG-47128
Change-Id: I70d4ada0872316cc63d7629bb9ab2d055d70cf2a
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
2015-07-10 16:38:07 +00:00
Keith Gardner
6094ae1ff5 Added QVersionNumber to QtCore's public API
[ChangeLog][QtCore] Added QVersionNumber.

Change-Id: I11acc1fae3dc9368a72593afcfa2e462c53a620e
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Keith Gardner <kreios4004@gmail.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2015-07-10 00:47:03 +00:00
Frederik Gladhorn
8c7a9bfbbc Do not support static QIcon instances
There was an attempt to allow static instances of QIcon in
7727a4355876607a1a022ff54e2570dae883f79c (Qt 4). This patch does only
solve some of the corner cases and broke with
aa5f70c00a. Since the "breakage" has been
there for two years, let's officially declare it unsupported instead of
trying to work around the issue.

Change-Id: I61e12fd03953763ee2e70eae58bcaecabdcb85b8
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2015-07-09 10:53:29 +00:00
Thorbjørn Martsum
b9438e6cbd QComboBox::setView only delete the old view if it is a child
We have ownership for a reason - and there seems to be
no good reason not to accept it here.

[ChangeLog][QtWidgets][QComboBox] QComboBox::setView no longer
deletes the old view directly. It now checks the ownership first.

Change-Id: Icb5e5c0a6e9dc93c1d1c1a90ff57fbcc0786aa60
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
2015-07-08 17:37:33 +00:00
Sérgio Martins
f61de80e1f QVarLengthArray: Unit-test that clear() preserves capacity
Change-Id: Ib2b798b93ce9a1b77bca09b2a8c27a568ebf8670
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2015-07-08 14:22:44 +00:00
Thiago Macieira
d01d08971a Fix the remainingTime() result after the first activation of a QTimer
On Windows, t->timeout was updated only once, at creation time, so the
timer would always show as "overdue" after the first activation.

The timer is updated to indicate the full remaining time during the slot
activation, which is the behavior of the Unix and Glib dispatchers.

Task-number: QTBUG-46940
Change-Id: I255870833a024a36adf6ffff13ecadb021c4358c
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2015-07-08 03:20:29 +00:00
Frederik Gladhorn
290e875fd9 Test QAction::autoRepeat
Sending several key presses with repeat=true should trigger the action
several times, unless autoRepeat is set to false.

Change-Id: I6469bbd78a608a87852554882c1632ce34422662
Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
2015-07-07 22:26:31 +00:00
Morten Johan Sørvig
899153b6f9 Run tst_qwindow::positioningDuringMinimized on OSX
The test passes.

Change-Id: Ic1a0aa4b861eb6fe18fed3d5b5cd4481b9f5fbad
Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
2015-07-07 12:52:24 +00:00
Marc Mutz
8b5cdc20be QProcessEnvironment: fix op==
Not all empty states were considered equal.

[ChangeLog][QtCore][QProcessEnvironment] Fixed a bug in
operator== involving different empty states.

Change-Id: I13c3200897847475bde2f963db0d2c587336b8a7
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2015-07-07 05:22:33 +00:00
Marc Mutz
6aa89ddf5e QProcessEnvironment: add a check for inserting into self
Wasn't checked, and with all the mutex locking going
on under the hood, we better rule out that there's a
deadlock.

Change-Id: I5a2ef1a524fb42b7840c9f3c18395cde05b7ef28
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2015-07-07 05:22:28 +00:00
Marc Mutz
f405352fee QByteArray: add {const_,reverse_iterator}, {c,}r{begin,end}()
Had to mark {,c,const}{begin,end}() inline, since they are, and mingw
complains about inconsistent dllimport attributes.

[ChangeLog][QtCore][QByteArray] Added rbegin(), crbegin(), rend(), crend(),
and reverse_iterator and const_reverse_iterator typedefs.

Task-number: QTBUG-25919
Change-Id: Id5aefb52635f029305135afcd99db0b036a7af82
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2015-07-07 05:22:08 +00:00
Marc Mutz
92d5733c78 QString: add {const_,reverse_iterator}, {c,}r{begin,end}()
Had to mark {,c,const}{begin,end}() inline, since they are, and mingw
complains about inconsistent dllimport attributes.

[ChangeLog][QtCore][QString] Added rbegin(), crbegin(), rend(), crend(),
and reverse_iterator and const_reverse_iterator typedefs.

Task-number: QTBUG-25919
Change-Id: I1d48729c76e510c1e49c0e5dc41691aa662fdf21
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2015-07-07 05:22:04 +00:00
Liang Qi
0698f876ca Merge "Merge remote-tracking branch 'origin/5.5' into dev" into refs/staging/dev 2015-07-01 09:59:28 +00:00
Allan Sandfeld Jensen
cd297f99a2 Fix A2RGB30 compositing tests
With two alpha-bits half opacity can not be represented, so we must use
one third (85) instead of half (127).

Change-Id: I2b3f1c983a3034196bf2604840945ad3a81f5b38
Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
2015-07-01 09:59:26 +00:00
Liang Qi
0aa2d318b1 Merge remote-tracking branch 'origin/5.5' into dev
Conflicts:
	src/corelib/global/qglobal.cpp
	src/corelib/global/qglobal.h
	src/corelib/global/qsysinfo.h
	src/corelib/global/qsystemdetection.h
	src/corelib/kernel/qobjectdefs.h
	src/plugins/plugins.pro
	tests/auto/widgets/itemviews/qlistview/qlistview.pro

Change-Id: Ib55aa79d707c4c1453fb9d697f6cf92211ed665c
2015-07-01 11:05:26 +02:00
Marc Mutz
1be6bad232 Add qHash(QLocale)
QLocales can be compared for equality,
so qHash should be overloaded, too.

[ChangeLog][QtCore][QLocale] Added qHash(QLocale).

Change-Id: Ia0fdf1207b842b9bb20b8f9ab0165016915debf4
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2015-06-30 20:10:54 +00:00