summaryrefslogtreecommitdiffstats
path: root/tests/auto
Commit message (Collapse)AuthorAgeFilesLines
* Don't "hope" that a connection gets picked up; do it right!Norwegian Rock Cat2009-05-191-2/+4
| | | | | | | | | | While downloadProgress and uploadProgress both work on local files. There still may be a delay before the connection is actually picked up. This usually is caught by the processEvents(), but could be missed. Therefore, do a wait if we don't have any pending connections and work in ALL cases. Reviewed-by: Markus Goetz
* grabWindow in MacGui test was grabbing the wrong area.Norwegian Rock Cat2009-05-191-6/+1
| | | | | | | I think grabWindow was borken and we were compensating for it in the auto test. Now that it works as documented our workaround broke. Reviewed-by: Morten Sørvig
* qmake autotest: Remove dependency on Qt3 Support on WindowsJoão Abecasis2009-05-191-4/+2
| | | | Reviewed-by: jbache
* make splitter autotest pass on mac tooKent Hansen2009-05-191-3/+2
| | | | It's not enough to call processEvents() just once on all platforms.
* Windows CE autotest compile fixesJoerg Bornemann2009-05-194-4/+4
| | | | | | Not always is "." in the includes path... Reviewed-by: mauricek
* fix compiler warnings when qreal == float in tessellator autotestJoerg Bornemann2009-05-191-4/+4
| | | | Reviewed-by: mauricek
* Fix autotest for qitemmodel on windowsJens Bache-Wiig2009-05-191-1/+1
| | | | | | Fixed a broken include Reviewed-by: Thomas Zander
* Fixed autotest tst_QPrinter::printDialogCompleter on Windows.Kim Motoyoshi Kalland2009-05-191-2/+3
| | | | | QApplication::activeWindow() returns null for native dialogs, so null cannot be passed as the target widget when calling QTest::keyClick().
* Fix autotest compile for qitemview on windowsJens Bache-Wiig2009-05-191-1/+1
| | | | Reviewed-by: Thomas Zander
* Fixed autotest failure in tst_QImage::smoothScale3()Samuel Rødal2009-05-191-3/+3
| | | | | | | Some optimized smooth scaling functions were introduced in 4.5, so increase the tolerance level a small bit. Reviewed-by: Trond
* Fix handling of dynamic casts in QSharedPointer.Thiago Macieira2009-05-181-9/+128
| | | | | | | | | | | | It's wrong to assume that static_cast<> is allowed everywhere where dynamic_cast<> is allowed. For example, if class C derives from both A and B, then you can dynamic_cast<B *>(ptr_to_A), but you can't static_cast. So introduce a helper for dynamic casts that doesn't do static_cast. Reviewed-by: Olivier Goffart
* Fix QNetworkDiskCache to expire the oldest files first.Benjamin C Meyer2009-05-181-1/+2
| | | | | | | | | | When expiring cache files use a QMultiMap, when using a QMap not all files are put into the map because often many files (downloaded or updated at the same time) will have the same creation QDateTime and so only one will go into the QMap who's key is QDateTime. Reviewed-By: Thiago Macieira Reviewed-By: Peter Hartmann
* QCss: font-family handle fallback font specsOlivier Goffart2009-05-181-4/+9
| | | | | | | | | | | | if one specify more than one parameter in font-family, e.g., font-family: Verdana, Arial Qt should fallback on the second font if the first cannot be found. QFont::setFamily handle the case when the family name contains a comas, so we do not need to handle that specially in the css parser code. Task-number: 252311 Reviewed-by: Thomas Zander
* Fix race condition in ~QObjectOlivier Goffart2009-05-181-0/+89
| | | | | | | | | | | | | | while using QOrderedMutexLocker::relock we might unlock our mutex protecting the 'senders' list for a short moment. Another thread may then modify or remove element on the list. Therefore, we need to recheck the consistency of the list once we did that. Also, we cannot call removeSender because that will remove every connections, making impossible for another object destroyed in the same time to clean up the senders list, so call derefSender instead. Reviewed-by: Brad
* QCalendarWidget::setDateTextFormat() reset the format is the date is invalidBenjamin Poulain2009-05-181-0/+53
| | | | | | | | | According to the documentation, QCalendarWidget::setDateTextFormat() should reset the format if the date is not valid. New tests included for the formating of this widget. Task-number: 252943 Reviewed-by: Olivier
* Adapted uic test-baseline to the icon generation change 251248)Friedemann Kleint2009-05-151-6/+6
| | | | Task-number: 251248
* HTTP authentication: return error if authentication cannot be handledPeter Hartmann2009-05-151-0/+52
| | | | | | | return error upon receiving an unknown authentication method (e.g. WSSE); before we were just silently returning. Reviewed-by: Thiago Macieira
* QColor::toCmyk() does not convert the color if it is already in CMYKBenjamin Poulain2009-05-141-0/+21
| | | | | | | | | QColor::toCmyk() converted the color to RGB and then to CMYK. If the color was already in CMYK, this conversion change it. The color is now returned directly if it is in CMYK Reviewed-by: Ariya Task-number: 253625
* Merge branch '4.5' of git@scm.dev.nokia.troll.no:qt/qt into 4.5Andy2009-05-141-0/+110
|\
| * Fix QGraphicsItem::deviceTransform() to also work with normal items.Andreas Aardal Hanssen2009-05-141-0/+110
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QGraphicsItem::deviceTransform() returns the item-to-device transform, provided with the device-to-scene transform, and combining it with the item's scene transform. This function is meant to handle items that enable ItemIgnoresTransformations, but it happened to not work properly for items that _don't_ enable that flag. Unfortunately this bug is hard to work around for users from the outside, as it requires you to check if the item or any ancestor enables ItemIgnoresTransformations. The fix also removes unnecessary branchs inside QGV so that we use the same function for all items. Reviewed-by: bnilsen
* | Prevent duplicate entries in the sidebar when the paths are the sameAndy2009-05-141-2/+7
|/ | | | | | | | | If two urls were added to the sidebar that only differed in how they referenced the added url (i.e. /foo/bar/. and /foo/bar) then only one entry should appear. Task-number: 253532 Reviewed-by: Alexis
* Improve the HTTP status line parsing and catch more errors.Thiago Macieira2009-05-131-0/+7
| | | | | | | | | | | | There's no need for using QByteArrayMatcher for one single character, so avoid the overhead. Also validate the message header a bit more: we require the status line to start with "HTTP/n.m " where n and m are positive integers less than 10. Task-number: 248838 Reviewed-by: Markus Goetz
* Fix handling of garbage data sent by the HTTP server instead of aThiago Macieira2009-05-131-0/+42
| | | | | | | | | | | proper HTTP reply. If the server's reply doesn't start with "HTTP/", then the reply is not valid. This could happen if we connected via HTTP to an HTTPS server. It could also happen with an Icecast server (reply ICY/x.y). Task-number: 248838 Reviewed-by: Markus Goetz
* Reset the 'connectedToScene' flag when changing the scene of a viewLeonardo Sobral Cunha2009-05-131-0/+24
| | | | | | | | | | In QGraphicsScene::_q_emitUpdated() the slot QGrpahicsView::updateScene(QList<QRectF>) gets connected and a boolean (connectedToScene) is set to prevent double connections. The problem is that this boolean was not reset when the view gets a new scene. Task-number: 253415 Reviewed-by: andreas
* Fixes a segfault from out of order cleanup of mysql resources.Bill King2009-05-131-2/+20
| | | | | | | If a QSqlQuery survived the lifetime of removal of a mysql db connection (that failed), the cleanup code would cause a segfault because it was using an out of date pointer that was pointing at memory that'd been freed by the removeDatabase() call. Revby: Justin McPherson Task-number: 205701
* Fixed bug with Qt::WidgetWithChildren shortcut context in QGraphicsWidget.jasplin2009-05-121-0/+85
| | | | | | | | | For a QGraphicsWidget w, a shortcut with Qt::WidgetWithChildren context would trigger even if w did not have focus (provided no other widgets in the view had focus). Reviewed-by: andreas Task-number: 250119
* Add a test for UTF-8 conditionsThiago Macieira2009-05-112-0/+312
|
* Don't leak memory when assigning scriptvalue to iteratorKent Hansen2009-05-111-0/+33
| | | | | | The d-pointer was not deleted as it should be. Reviewed-by: Harald Fernengel
* Add a license file for the XML Conformance Testsuite.Thiago Macieira2009-05-111-0/+59
| | | | | | | The source of the license text is http://www.w3.org/Consortium/Legal/copyright-software-19980720 Reviewed-by: Trust Me
* Fixes qt3support unit tests generating compile failures when Qt is notRohan McGovern2009-05-1153-9/+62
| | | | | | | | | | | | configured with qt3support. The build system knows when qt3support was turned off, so let's just skip these tests in that case. That makes more sense than individually configuring each autotest machine to skip these tests when the configuration is known to turn off qt3support, which is what's done previously. Reviewed-by: Lincoln Ramsay
* Fixes a crash in QPrinterDialog with relative filenamesJoão Abecasis2009-05-081-0/+18
| | | | | | | | | | | It's better to set the sourceModel in the constructor for QFSCompletor, as requiring that it be set separately is error prone. Surprisingly, the printer dialog crash only appears to happen when using relative filenames. Task-number: 253135 Reviewed-by: alexis
* Fix QCompleter with UnfilteredPopupCompletionJoão Abecasis2009-05-081-0/+46
| | | | | | | | | | | Fixes regression introduced in a794ded85f74516239a08cf848e6b4f8b6dcac6a. When using UnfilteredPopupCompletion the matchCount is always zero and completion was being skipped. By adding the check for showAll we still avoid the assert but retain correct behavior. Task-number: 253125 Reviewed-by: jasplin
* Fix leak of file descriptors in QTemporaryFileJoão Abecasis2009-05-082-2/+46
| | | | | | | | | | | Using setFileName in QFile::copy (introduced recently) has a nasty side-effect of leaking file descriptors in QTemporaryFile. This happens because the code assumes the file has been closed. In QTemporaryFile, we need to explicitly call native file engine close. Test case by Thiago. Bug report from Arora developers. Reviewed-by: thiago
* Fixes QIBASE driver crashes on multiple execution of a prepared queryBill King2009-05-071-4/+15
| | | | Task-number: 246808
* Make QNetworkProxy calculate the capabilities for a new proxy typeThiago Macieira2009-05-071-0/+33
| | | | | | | | | | | | If you write: QNetworkProxy proxy; proxy.setType(QNetworkProxy::HttpProxy); Then now QNetworkProxy will set the capabilities to the default value for the new proxy type. Previously, it wouldn't do that: default values were set only for the type passed in the constructor. Reviewed-by: Peter Hartmann
* Make QDBusPendingCallWatcher emit a signal if it is created on anThiago Macieira2009-05-071-0/+73
| | | | | | | | | | already-finished call. This fixes a bit of a "surprise" when calling a local method (which returns and finishes immediately) or when by accident calling a function that returns QDBusReply instead of QDBusPendingCall/Reply. Reviewed-by: Trust Me
* Crash in QWidget::render when passing an untransformed QPixmap painter.Bjoern Erik Nilsen2009-05-061-0/+11
| | | | | | | | | | | | | | | | | | | The crash only occurred on Windows and X11 when running with -graphicssystem raster. The reason is that the actual paint device in QRasterPaintEngine::begin() is changed to pixmap->data->buffer(), which means QPaintEngine::paintDevice() returns something else than what it was told to paint on (see cb0c899b56b84154f69ddc545991bc6ded96ab01) The root of the problem, however, was that we used a weird condition (painter->worldMatrixEnabled(), added in 345072b9 for Qt 4.4) to find the target device. We did that because the shared painter was completely different in 4.4. We refactored it in 4.5.0, and we can only trust QPaintEngine::paintDevice to be the target device. Auto-test included. Task-number: 252837 Reviewed-by: Trond
* QGraphicsItem::setOpacity(0.0) does not trigger an update.Bjoern Erik Nilsen2009-05-061-2/+87
| | | | | | | | | | | | | | | | The problem was that we discarded update requests for fully transparent items, which is correct, but we even did that when the update was issued from QGraphicsItem::setOpacity. We don't have to, and shouldn't, consider the opacity in that case. Whenever we reach the fullUpdateHelper call in setOpacity it means we have to do an update regardless of the current opacity (oldOpacity was not 0.0 if the currentOpacity is 0.0). Auto-test included. Task-number: 252913 Reviewed-by: Andreas
* Fixed bug where 0-opacity would cause images to be drawn fully opaque.Samuel Rødal2009-05-051-0/+18
| | | | | | | | | The bug appears in the raster paint engine and only in release mode as the cause of the bug is in the MMX and SSE blend functions which are disabled in debug. To prevent it simply we return early if we detect that we have an opacity of 0. Reviewed-by: Trond
* Fix memory leak in QFutureMorten Sørvig2009-05-051-0/+31
| | | | | | | | | The held results were not cleared by QFutureInterface::operator=(QFutureInterface) Add call to resultStore().clear(), similar to the destructor. This needs to be done in the header since we know the template type here. Task-number: 252208 Reviewed-by: brad
* QNetworkCookieJar: do not allow cookies for domains like ".com"Peter Hartmann2009-05-041-0/+11
| | | | | | | | the domain attribute in cookies must always contain one embedded dot, according to RFC 2109 section 4.3.2 Reviewed-by: Thiago Task-number: 251467
* Do not crash when passing wrong indexes to ↵Olivier Goffart2009-05-041-0/+18
| | | | | | | | | QSortFilterProxyModel::indexFomSource and *ToSource Show a warning instead Task-number: 252507 Reviewed-by: Marius Bugge Monsen
* QNetworkCookieJar: allow cookies with wrong domain attributePeter Hartmann2009-04-301-4/+4
| | | | | | | | | | According to the (old) cookie RFC 2109, the domain attribute must always contain a leading dot. Some servers do not have that, but all browsers accept those cookies anyway, so we should do that as well. Reviewed-by: Olivier Reviewed-by: Denis Task-number: 228974
* New autotest for Windows Mobile: tst_windowsmobileThomas Hartmann2009-04-3010-0/+446
| | | | | | | | | This autotest tests some Windows Mobile 5.0 specific thing like the native menubar and the integration into the window manager by taking and comparing screenshots. This should prevent nasty regressions we had. This autotest makes only sense on Windows Mobile 5.0 in 480x640 Reviewed-by: maurice
* Stabilize tst_QWidget::render_systemClip2 and remove wrong ifdefBjoern Erik Nilsen2009-04-291-3/+3
| | | | We only want to dump images *if* RENDER_DEBUG is defined.
* Wrong clip in QWidget::render(QPainter *, ...) when using Qt::(Replace|No)Clip.Bjoern Erik Nilsen2009-04-291-0/+102
| | | | | | | | | | | | | | | The problem was that we didn't take the painter's clip into account when setting the system viewport ("hard clip"). We only used the system clip, but we have to use system clip + painter clip, which is the current engine clip. Unfortunately, we have to calculate it again since there's no cross-platform way of retrieving it. This was only a problem with Qt::(Replace|No)Clip, since we in all other cases combine the old clip with the new one. (Uber cool) auto test included. Task-number: 250482 Reviewed-by: Samuel
* Fix regression in QSelectionModel::rowIntersectsSelectionOlivier Goffart2009-04-281-0/+46
| | | | | | | | | | and QSelectionModel::columnsIntersectsSelection The documentation says "if one is selected" inside the row/column, so we need to look over if we find one which is selected Task-number: 252069 Reviewed-by: Marius Bugge Monsen
* Fix a crash with a proxy model applied on the QFileDialog.Alexis Menard2009-04-281-0/+13
| | | | | | | | | | | | | | | The problem was located in _q_enterDirectory, this method take a QModelIndex that can be a model index from the treeview/listview (so it comes from the proxy that is applied) and from the side bar where there is always no proxy applied. Previously we were trying to convert from a proxy index to a source index the value that come from the sidebar which is already a source model index. Now, we just check if the model index is coming from the proxy and in that case we convert it otherwise this model index come from the source. Task-number: 252068 Reviewed-by: jasplin Reviewed-by: ogoffart
* When minimizing/restoring an item view it could jump to its currentlyThierry Bastian2009-04-281-0/+28
| | | | | | | selected item Task-number: 250446 Reviewed-by: ogoffart
* Fix stylesheet test when button color != window colorOlivier Goffart2009-04-281-1/+2
|