summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Ensure that we never increase the strong reference count up from zero.Thiago Macieira2009-08-032-5/+138
| | | | | | Also add some thread stress tests to try and detect doing it wrong. Reviewed-By: Bradley T. Hughes
* Change the pointer-tracking code to work everywhere.Thiago Macieira2009-08-035-12/+173
| | | | | | | | | | | | | | | | | | | | | | | | | | Currently, if you create a QSharedPointer in code with pointer-tracking, you must ensure it gets deleted in code with pointer-tracking, otherwise the internal safety tracker will be "leaking" objects. The pointers would never get removed. And if any new pointer happened to have the same pointer address (which happens quite often), the tracker code would promptly abort the application. With this change, the untracking of the pointer is scheduled by the same code that creates the tracking. This is done by "abusing" the custom deleter code: - for the QSharedPointer that used ExternalRefCountWithDestroyFn already, we intercept the call to the destroy function and call the untracking function - for a normal QSharedPointer, we use the "normalDeleter" function as custom deleter and chain up above Note: the autotest only *really* works in release mode. Otherwise functions don't get inlined and do get merged by the linker. Reviewed-By: Bradley T. Hughes
* Don't forget to delete the deleter object too in QSharedPointer.Thiago Macieira2009-08-032-0/+16
| | | | | | Destructors have to be run for the subobjects we initialise. Reviewed-By: Bradley T. Hughes
* Cleanup old code in QSharedPointerThiago Macieira2009-08-031-18/+16
| | | | | | | | | | | We don't support MSVC 6.0 or MSVC .NET 2002, so all compilers we support can deal with member templates and partial template specialisation. Remove the #ifdef protecting the code that needed it. Also add some comments indicating the sizes of the structures. There is no padding necessary in most cases. Reviewed-By: Trust Me
* Remove the need for internal API in QSharedPointer.Thiago Macieira2009-08-033-44/+56
| | | | | | | That way, this code can be compiled with an earlier version of Qt and should still work in new ones. Reviewed-by: Trust Me
* Autotest: add a way to ensure that there are no safety-check pointers leakingThiago Macieira2009-08-032-1/+64
| | | | | In the future, it would be nice to split the autotest in multiple functions at every check().
* Fix compilation and warningAlexis Menard2009-08-032-3/+5
| | | | Reviewed-by: TrustMe
* Merge branch 'master' of git:qt/qtThiago Macieira2009-08-0310-25/+30
|\
| * Warning --Alexis Menard2009-08-031-2/+2
| | | | | | | | Reviewed-by: TrustMe
| * Fixed warnings on phonon/ds9 with mingw (gcc 4)Thierry Bastian2009-08-039-23/+28
| | | | | | | | Reviewed-by: Trustme
* | Merge branch '4.5'Thiago Macieira2009-08-0345-404/+867
|\ \ | |/ |/| | | | | | | | | | | | | | | Conflicts: src/corelib/tools/qsharedpointer.cpp src/corelib/tools/qsharedpointer_impl.h src/gui/dialogs/qcolordialog.cpp src/gui/painting/qwindowsurface_raster.cpp src/network/access/qnetworkaccessmanager.cpp tests/auto/qsharedpointer/externaltests.cpp
| * Autotest: disable the pointer-tracking tests in 4.5Thiago Macieira2009-08-031-0/+2
| | | | | | | | | | | | | | The functionality these tests tested was broken in 4.5 and has been disabled. Therefore, these tests simply cannot pass. It's fixed in 4.6.
| * Fix compilation of webkit with mingwThierry Bastian2009-08-031-3/+0
| |
| * Fix more database autotests.Bill King2009-08-032-4/+6
| |
| * Cocoa with namespace breaks the buildRichard Moe Gustavsen2009-07-311-2/+2
| | | | | | | | | | | | | | Added the needed macros around the classnames the way it should be done. Reviewed-by: Prasanth
| * Coverty warnings --. This switch was missing a break.Alexis Menard2009-07-301-0/+1
| | | | | | | | Reviewed-by:TrustMe
| * Allow maximize button on the titlebar for a fixed size windowDenis Dzyubenko2009-07-301-0/+5
| | | | | | | | | | | | | | | | | | On Windows we will add maximize button to the titlebar even if the window has a fixed size if the user explicitely asked for it by setting Qt::CustomizeWindowHint | Qt::WindowMaximizeButtonHint. Task-number: 250188 Reviewed-by: Leonardo Sobral Cunha
| * Autotest: add a newline after the user program headers.Thiago Macieira2009-07-301-0/+1
| | | | | | | | | | | | | | | | If the user forgot to end their headers with a newline, the compilation would fail because the next line is #include <QtCore/QtCore>. Reviewed-by: Jesper Thomschütz
| * Remove mem leak / warning in the cocoaportRichard Moe Gustavsen2009-07-301-0/+1
| | | | | | | | | | | | Remove mem leak / warning in the cocoaport Reviewed-by: msorvig
| * Mac: Fix crash in QCoreTextFontEngineMulti when disabling font kerning.Morten Sørvig2009-07-301-1/+1
| | | | | | | | | | | | CFDictionaryAddValue expects a CFNumberRef, not a pointer-to-CFNumberRef. Reviewed-by: TrustMe
| * Unable to change focus between two line edits on macRichard Moe Gustavsen2009-07-301-37/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is because we try to decide whether the window cocoa tells us to be active should be active, and if we desagree, we do nothing. The result is that Qt and Cocoa ends up in different states. I decided to remove a lot of the logic that went on in this case, and the resons is: 1. By checking the callplaces to onApplicationWindowChangedActivation, we know that we always have a valid widget pointer, and we know that the widget always is a window (otherwise Cocoa would never tell us that the widget got active). 2. We can never end up doing nothing in this response. The best we can do is to follow what Cocoa tells us. If this turns out to break something, it would probably be better to check why we get an activation call in the first place for a window that should not be activated (e.g. is canBecomeKeyWindow set correctly?) Task: 253610 RevBy: msorvig
| * Fixes hack around show queries not allowed to be prepared.Bill King2009-07-301-3/+3
| | | | | | | | | | | | | | Mysql queries other than select can't be prepared, otherwise they fail to return the necessary meta-information to enable them to be seen as returning data under certain versions of mysql. This fixes the hack to work correctly until we stop preparing queries automagically.
| * Doc - Renamed the cursor's images to illustrate splitV and splitH properlyKavindra Devi Palaraja2009-07-293-2/+2
| | | | | | | | | | | | Task: 258895 Reviewed-By: Jens Bache-Wiig
| * Comment one of my changes from yesterdayRichard Moe Gustavsen2009-07-291-4/+7
| | | | | | | | Task-number: 258445
| * Disable benchlibtickcounter test by default.Rohan McGovern2009-07-291-3/+4
| | | | | | | | | | | | | | This test depends on some low-level features of the CPU and the OS scheduler which seem impractical to automatically verify independently of the test. So turn it off to stop its intermittent failures in our test farm.
| * Fixed failure of tst_qmake::simple_app_shadowbuild.Rohan McGovern2009-07-291-0/+1
| | | | | | | | Test needs a placeholder file to make sure its build directory exists.
| * Fixed failure of tst_moc.Rohan McGovern2009-07-291-1/+1
| | | | | | | | os9-newlines.h's lack of newline at end of file is significant.
| * Skip uic3 test when qt3support is disabled.Rohan McGovern2009-07-291-0/+3
| |
| * Fixed compile of tst_qitemeditorfactory.Rohan McGovern2009-07-281-5/+5
| |
| * Fixed failure of tst_q3urloperator.Rohan McGovern2009-07-281-5/+7
| | | | | | | | Make test use network-settings.h correctly.
| * Fixed failure of tst_q3socket.Rohan McGovern2009-07-281-6/+8
| | | | | | | | Make the test use network-settings.h correctly.
| * Qtify void* func => void *funcAnders Bakken2009-07-281-2/+2
| | | | | | | | Reviewed-by: TrustMe
| * Refactor QDirectFBPaintDeviceAnders Bakken2009-07-287-34/+37
| | | | | | | | | | | | | | | | | | | | Make the engine a member in QDirectFBPaintDevice instead of one in QDirectFBPixmapData and one in QDirectFBWindowSurface. Don't use the default screen for the dfbpaintdevices. Pass one explicitly. Reviewed-by: Noam Rosenthal <noam.rosenthal@nokia.com>
| * Make autorepeat work for DirectFBAnders Bakken2009-07-281-5/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | When holding down a key DirectFB gives us only keypresses. Qt wants these kind of events: press not autorepeat release autorepeat press autorepeat release autorepeat press autorepeat release not autorepeat Reviewed-by: Donald <qt-info@nokia.com>
| * Fix crash in when resizing directfb windowsAnders Bakken2009-07-282-5/+11
| | | | | | | | | | | | | | | | | | Since QRasterPaintEngine::baseClip was initialized when the QDirectFBPaintEngine was created and the paintengine persists for the window surface we run the risk that the baseClip is of the wrong size. This could lead to crashes and erroneous clipping. Reviewed-by: Donald <qt-info@nokia.com>
| * Compile with DirectFB < 1.0Anders Bakken2009-07-281-0/+2
| | | | | | | | | | | | These porter duff operations were added for 1.0. Reviewed-by: Donald <qt-info@nokia.com>
| * Regression: QColorDialog crash on Mac when accepting with keyboardRichard Moe Gustavsen2009-07-283-119/+134
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Basically, the crash happends because we release the dialog when the ok button is clicked. But when the button is clicked with the keyboard (actually cocoa emulates a click when pressing enter), it also tries to do some focus handling on the button afterwards. But at that point, the button is already freed up. With a crash as the result. This patch goes through a lot of the code, and rewrites it so we doesnt free up the cocoa objects before the destructor of the QColorDialog is called. Task-number: 258445 Reviewed-by: msorvig
| * Fixed drawImage() so that it doesn't sample outside the source image.Kim Motoyoshi Kalland2009-07-282-23/+331
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In qt_scale_image_16bit() and qt_scale_image_32bit(), when a sample point was located on the border between two pixels in the source image, the sample point was rounded up instead of down. If a sample point was exactly on the bottom or right edge of the source image, the function would therefore sample a pixel outside the image. Because of how the target rectangle is rounded, a sample point will never be exactly on the top or left edge of the source image, so we will not get a similar problem there. I extended the lance test pixmap_scaling.qps. Task-number: 258533 Reviewed-by: Samuel
| * Don't use layered windows for non-translucent windowsGunnar Sletta2009-07-281-2/+2
| | | | | | | | Reviewed-by: Samuel
| * Remove ignore system clip stuff in dfbpaintengineAnders Bakken2009-07-282-5/+1
| | | | | | | | Reviewed-by: Donald <qt-info@nokia.com>
| * Fix off-by-one bug in QDirectFBScreen::flipSurfaceAnders Bakken2009-07-281-4/+4
| | | | | | | | | | | | | | | | | | | | DFBRegions are exactly like QRects it turns out. x2/y2 == QRect::right()/QRect::bottom() This means I actually can reinterpret_cast QRect to DFBRegions but it's not really worth it. Reviewed-by: Noam Rosenthal <noam.rosenthal@nokia.com>
| * Major clipping patch in QDirectFBPaintEngineAnders Bakken2009-07-281-75/+91
| | | | | | | | | | | | | | Handle region clips by iterating over the rectangles and updating clips accordingly. Reviewed-by: Noam Rosenthal <noam.rosenthal@nokia.com>
| * Make porterduff operations work in DirectFBAnders Bakken2009-07-281-33/+97
| | | | | | | | | | | | | | | | This patch makes us not fall back to the raster engine for most of the composition mode operations when doing blits. Primitives are still handled by Qt when composition != SourceOver Reviewed-by: Noam Rosenthal <noam.rosenthal@nokia.com>
| * Disable the pointer tracking feature in Qt 4.5.Thiago Macieira2009-07-272-29/+5
| | | | | | | | | | | | | | | | The functionality is broken, since pointers can be released by a QSharedPointer tracking a pointer of different type, which would leave behind pointers in the hash. The fix requires Qt 4.6 because of a new symbol being added.
| * Roll back the fancy updating of translucent windows.Gunnar Sletta2009-07-271-4/+1
| | | | | | | | | | | | | | | | | | | | The problem with the fix, though it produces less flicker when resizing, is that it delays telling windows that the window has moved until after the window has been completely repainted. Problem with this is that functions that rely on windows to be up to date will fail until the backbuffer is flushed. This was the case for mapTo/FromGlobal, and potentially other functions too. Reviewed-By: Eskil
| * Fix missing title quoting.kh2009-07-271-2/+4
| | | | | | | | Reviewed-by: kh
| * Add docs for Windows Server 2008 R2 to QSysInfo::WinVersionBradley T. Hughes2009-07-271-2/+2
| | | | | | | | | | | | Windows Server 2008 R2 is based on kernel 6.1, the same as Windows 7. Reviewed-by: TrustMe
| * Fix crash when printing to PDF on Qt/MacMorten Sørvig2009-07-271-2/+5
| | | | | | | | | | | | | | | | | | | | Priting to PDF would crash for applications built on Leopard when running on Tiger. Add the standard runtime version check to QFontEngineMac::faceId(). Task-number: 251791 Reviewed-by: Richard Moe Gustavsen
| * Fixed failure of tst_qlocale if run when LC_ALL is set.Rohan McGovern2009-07-271-6/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This test tried to be unaffected by the locale environment variables set by the user by explicitly overwriting them and spawning a new process. However this was only done for LANG and not the other variables which can affect the locale. Do it for all the locale variables. Also, the previous approach (store the current value with qgetenv, then put it back with qputenv later) doesn't really work because that effectively takes variables which weren't set and sets them to an empty string, which is not the same thing. Use QProcess::setEnvironment instead. Reviewed-by: Andy Shaw
| * Doc - Mention Google trademarks with the two examples using Google services.Kavindra Palaraja2009-07-262-0/+2
| | | | | | | | Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>