summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* WinRT: Fix compile warningsMaurice Kalinowski2014-05-269-3/+19
| | | | | Change-Id: If223dd73b9558a0f5144be38f19a61316f8c807b Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
* Make QT_MAC_OPENGL_SURFACE_ORDER=-1 work betterMorten Johan Sørvig2014-05-261-2/+13
| | | | | | | | Mark the window as not opaque and give it a transparent background when layering OpenGL below the window. Change-Id: I2188842249c592f17619f7a2c3ef1fd30958987e Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Cocoa: Remove the NSWindow -> QCococaWindow hash.Morten Johan Sørvig2014-05-263-20/+5
| | | | | | | | Cast the NSWindow to a QNSWindow instead. Now there is no way we can fail to maintain the hash properly. Change-Id: I5fd03b6fad964a61fadb3460b7063fd43ff25c79 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Cocoa: Prevent crash on QWindow delete.Morten Johan Sørvig2014-05-261-0/+1
| | | | | | | | | | | Clear the QCocoaWindow pointer stored on the QNSWindowHelper when detaching from the platform window. This makes sure callbacks from cocoa does not try access deleted Qt window objects. Task-number: QTBUG-39141 Change-Id: I4672eae92940dcbd59a2848e56f94b50a828bbf6 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Direct2D QPA: Match raster engine line outputLouai Al-Khanji2014-05-261-0/+27
| | | | | | | | | | For whatever reason direct2d and the raster engine disagree by one pixel about the positioning of positively sloping aliased lines. To get the same output, we shift such lines by one pixel. Change-Id: I4b20319770c02e3fdd212b3535ccae3c27ca9f2f Reviewed-by: Risto Avila <risto.avila@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Ensure all encrypted bytes are sent when closing QSslSocket.Richard J. Moore2014-05-261-0/+2
| | | | | | | | | | If you do sock->write(data) followed by sock->close() then the data written is not transmitted unless you flush when using QSslSocket but is when using QTcpSocket. This change makes QSslSocket work like QTcpSocket. Change-Id: Ia2e1c021dc48ac0d573f78da782ea77641c03bc1 Reviewed-by: Peter Hartmann <phartmann@blackberry.com>
* Replace hard-coded qWait() by QTRY_COMPARE/VERIFY in widget tests.Friedemann Kleint2014-05-262-15/+7
| | | | | | Task-number: QTBUG-38890 Change-Id: I9a729430fcd30b782c100bb76d5e287a3b4c1238 Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
* Cocoa: Make sure modal windows get correct geometry on showAndy Shaw2014-05-262-1/+18
| | | | | | | | | beginModalSessionForWindow will center the window and ignore the set geometry. So to workaround this it checks the new value against the old one and moves it back if need be. Change-Id: I38bc74c04138992f2e0570fca666414025aeeba8 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* Account for the sort indicator being placed above the text on VistaAndy Shaw2014-05-263-9/+23
| | | | | | | | | | | In WindowsVista style and later the sort indicator is placed above the text as opposed to alongside it. Therefore the extra space given is moved to the common style allowing styles that have it placed differently to easily ensure it is not included. Task-number: QTBUG-19915 Change-Id: Ic21fcc1d95f4c3cc2eb9c465e1c8afb9b805389a Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Fix loss of precision warningsFrederik Gladhorn2014-05-262-3/+3
| | | | | | | | Found by http://www.viva64.com/en/b/0251 Change-Id: I2a0c3dba74fef07c3119c9e57b343a8253ee7daa Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* IPv6 scope ID of zero is not validThiago Macieira2014-05-262-6/+9
| | | | | | | | IANA reserves scope ID of 0x0 to mean "no scope ID", so make sure that we don't try to set it when reading from the sockaddr_in6 structure. Change-Id: I71b207e6f8262ab2bf9fde993288a71ba63c7572 Reviewed-by: Richard J. Moore <rich@kde.org>
* QOpenGLTexture: test for extensions when checking featuresGiuseppe D'Angelo2014-05-251-8/+24
| | | | | | | | | | | | | Don't use only the GL version, as vendors expose many many extensions on viable hardware. For instance, I have a NVIDIA G210 which supports up to GL3.3, but which features immutable storage, immutable multisampled storage, texture buffers and ranges, stencil texturing, and cubemap arrays. Change-Id: Ie6023ee854b679737fca982578cb2093e10d083f Reviewed-by: Paul Lemire <paul.lemire@kdab.com> Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Fix the doc so it uses the defined parameter names for the signalsAndy Shaw2014-05-241-15/+15
| | | | | | | | | | The documentation needs to use the defined parameter names for the signals as this is what QML will make them available as if they are used in a connection to that signal. Task-number: QTBUG-35694 Change-Id: I0f56b9e1ace45cfff72c45273dd64766e3c792f2 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* QPrinter/Windows: Fix handling of native paper source ids.Friedemann Kleint2014-05-234-21/+57
| | | | | | | | | | | | On Windows, it is possible to pass native Windows paper source ids >= DMBIN_USER to QPrinter::setPaperSource() and they are listed by supportedPaperSources(). Task-number: QTBUG-38897 Task-number: QTBUG-38888 Change-Id: I8f1264e80ce5bdddd3873602200b24eabee00502 Reviewed-by: Lars Knoll <lars.knoll@digia.com> Reviewed-by: Andy Shaw <andy.shaw@digia.com>
* Windows: Fix qt_imageFromWinHBITMAP().Friedemann Kleint2014-05-231-74/+86
| | | | | | | | | | | | | Factor out common code paths from the QPixmap/QImage conversion code and use the same algorithm for copying the image data with alpha correction as does qt_pixmapFromWinHBITMAP(). Rename the previous version of qt_imageFromWinHBITMAP() to qt_imageFromWinIconHBITMAP() since it is used for HICON conversion. Task-number: QTBUG-39084 Change-Id: Ia4042c33db485c3604461a5eafd6282968b36e3b Reviewed-by: Andy Shaw <andy.shaw@digia.com>
* Remove unused variable in qwindowsmousehandler.cpp.Friedemann Kleint2014-05-231-1/+0
| | | | | Change-Id: Iacfeec396c2eeef973b62bf78c698aa206b01c41 Reviewed-by: Andy Shaw <andy.shaw@digia.com>
* iOS: Be more careful when hiding the keyboard upon enterRichard Moe Gustavsen2014-05-231-3/+3
| | | | | | | | | | | | | | | | | | A typical pattern in an application is to listen for "enter" in a line edit and transfer focus to the next edit in the focus chain. This would currently not work on iOS since we would force the keyboard down after delivering the KeyPress/release events, effectively overriding any focus handling done by the app. This patch will hide the keyboard _before_ sending the events, so that we don't override focus handling done by the app. By also hiding the keyboard using QInputMethod, the hiding will also be delayed a bit (in QIOSInputContext) to catch subsequent hide/show calls. Change-Id: Ic19511d494a55d1bda963ed9bc7185d63b51bc03 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
* fix and de-duplicate qprocess apidocsOswald Buddenhagen2014-05-233-78/+77
| | | | | | | | | | | | | | | - rectify confusion and outright disinformation about argument quoting - say that open() is an alias for start(), not the other way round, as this is more consistent - apply some trickery to hide mergeable startDetached() overload - rename program -> command where it stands for a joined command line, for consistency - copy less information to the various overloads - misc language fixes and reshuffling Change-Id: I1b9c8dbed003f551ee6855044bbfc0aedddb4757 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* escape apostropheOswald Buddenhagen2014-05-231-1/+1
| | | | | Change-Id: Ib9da4903167fce8ccc41fd2aa050b5c611cced11 Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* fix C4275 warnings for MSVC 2010 buildJoerg Bornemann2014-05-231-1/+1
| | | | | | | | | | | | | The _HAS_EXCEPTIONS=0 define that was introduced in commit f59083636b89fc9b7983f9a0758a79f2980826dc leads to lots of C4275 warnings: non dll-interface class "stdext::exception" used as base for dll-interface class "std::bad_cast" from the <algorithm> include in qglobal.h. Newer versions of MSVC do not have this problem. Task-number: QTBUG-39126 Change-Id: Ieea5adde649fe16e6b41fbbb23fd582b3bb12b89 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* fix qmlplugindump's import path constructionOswald Buddenhagen2014-05-231-3/+5
| | | | | | | | the location of the import paths have changed a long time ago. also, we can make use of QTREPOS now. Change-Id: Iee50854b7441968c3c60538e54d9312e53d39cb6 Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
* fix/simplify the qmlimportscanner's import path constructionOswald Buddenhagen2014-05-231-7/+3
| | | | | | | | | now that we have QTREPOS, we can use that directly instead of collecting the QT.<foo>.qml dirs. as a "side effect", this makes qml modules without a corresponding c++ module available to the scan. Change-Id: I6f172121588ec01c9fa47a99d9990bf9fcfbc69f Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
* purge obsolete variable documentationPathOswald Buddenhagen2014-05-231-6/+0
| | | | | Change-Id: I1eb9e7ff28e0632c5a87b726dcd52b6542612101 Reviewed-by: Martin Smith <martin.smith@digia.com>
* fix quoting and path separators in qtPrepareTool()Oswald Buddenhagen2014-05-232-11/+16
| | | | | | | | | | | | | | | we need to store commands with system path separators in the .pri files, as we might clobber windows command arguments if we just converted separators later on. and we can actually do that, as the path separators are actually bound to the host system, not the shell. we also need to shell-quote the commands, as whitespace, and more commonly windows path separators in an msys shell, would break things. we delay this to the last moment possible, as it does depend on the shell. Change-Id: I1fe6b63aebd5663b72492c32928ec397f86e336f Reviewed-by: Sergio Ahumada <sahumada@blackberry.com>
* Call doneCurrent on QOpenGLContext when the surface diesLaszlo Agocs2014-05-231-0/+6
| | | | | | | | | | | | | | | | Doing makeCurrent() followed by destroying the surface (and no doneCurrent) results in still having the pointer stored internally in the QOpenGLContext. If then a function like defaultFramebufferObject() is called, the pointer is dereferenced. To fix this, the doneCurrent() has to be called when the surface is destroyed before the context without doneCurrent(). This is pretty much what the user would expect anyhow. Task-number: QTBUG-38994 Change-Id: Ibd4083d9291c7fd39b38ce81a988a8e0c9d55d60 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* WinRT: fix default font when DirectWrite is disabledAndrew Knight2014-05-232-2/+9
| | | | | | | | Instead of loading the default font "Helvetica", which is likely not part of the package, load the first font found. Change-Id: I225979986883a26c3fec72858cf32c3d1e45d902 Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
* Direct2D QPA: Fix HighRes paintingLouai Al-Khanji2014-05-232-11/+10
| | | | | | | | | | | | | | | | | | | It turns out that supporting HighRes painting with Direct2D is quite simple. Two things are necessary. First, we set the unit mode to D2D1_UNIT_MODE_PIXELS on all our device contexts, which tells Direct2D that we specify everything in pixels. Direct2D will internally do the required conversions. Second, we scale font sizes according to DPI. Previously rendering errors resulted when a highres mode was used, this fixes those errors. Task-number: QTBUG-39105 Change-Id: Ibb4dbea4746687228249e2c36d48c4bd6c5c7bf9 Reviewed-by: Risto Avila <risto.avila@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Direct2D QPA: Add missing break statementLouai Al-Khanji2014-05-231-0/+1
| | | | | | Change-Id: Ib40daa1ba56cce423b29ac8f1ab50e4638980728 Reviewed-by: Risto Avila <risto.avila@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Mark tst_qfiledialog2 as insignificant due to failing testsTony Sarajärvi2014-05-231-0/+2
| | | | | | Task-number: QTBUG-39183 Change-Id: I6663d0e4c49e904ffe5d5fdc990073abd4188d9d Reviewed-by: Simo Fält <simo.falt@digia.com>
* Fix a crash in QOpenGLTexture::allocateStorage()Tasuku Suzuki2014-05-231-1/+3
| | | | | | | | | QOpenGLTexture texture(QOpenGLTexture::Target2D); texture.allocateStorage(); // crashed Change-Id: Ia12f69b72e537cf765387cd172d7cb2cbbbad6e6 Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com> Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Stabilize and speed up tst_QGraphicsItem::cursor().Friedemann Kleint2014-05-221-12/+22
| | | | | | | | Use QTRY_COMPARE instead of hard-coded timeouts, ensure window is shown. Change-Id: I4f23144ee14150c4fba9c6fbd8c4ee2da472cc75 Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
* QPrintDialog OSX: Fix qApp->processEvents argumentsDyami Caliri2014-05-221-1/+1
| | | | | | | | | The call to processEvents had the flags separated by a comma instead of bitwise OR. This worked because processEvents has an optional second argument that is an int. Change-Id: I6dc74bc44b1d782aa7206f106c51c16eab5f2a76 Reviewed-by: Jake Petroules <jake.petroules@petroules.com>
* Fall back to ANGLE BlitFramebuffer and RenderbufferStorageMultiSampleAndrew Knight2014-05-221-2/+6
| | | | | | | | | When these extensions aren't available, use ANGLE's versions of them. Task-number: QTBUG-31010 Change-Id: I9a85b9f4d2bb60bdb1d79c92edf241b95d0627bf Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* WinRT app manifest: update namespace prefixAndrew Knight2014-05-221-9/+9
| | | | | | | | | | If the prefix isn't "m2" for the 2013 namespace, Visual Studio Update 2 won't open the document in the designer view. Even though there is nothing technically wrong with the way it's currently done, change it to "m2" to keep VS happy. Change-Id: I62721114610de5396eb507828b39db89c1e96b1a Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
* WinRT: Support High-DPIAndrew Knight2014-05-226-38/+171
| | | | | | | | | | | | | | | | | Previously, the backing store and default framebuffer were created with the logical screen resolution (in device-independent pixels), not the the physical screen resolution. This lead to blurry text on high-DPI devices. This change fixes this by creating those at full size, and setting the device pixel ratio appropriately. Windows are still reported in device-independent pixels, but text and images are now rendered sharply for Qt Quick applications. As QPainter does not support non-integer scaling, the backing store is still drawn in DIPs and scaled by OpenGL. Task-number: QTBUG-38464 Change-Id: I7377d4c734126825d670b8ebb65fd0dd1ef705f2 Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
* ANGLE WinRT: Create swap chain using physical resolutionAndrew Knight2014-05-222-14/+228
| | | | | | | | | | | | ANGLE has been creating the framebuffer in logical pixels instead of physical pixels, which leads to unexpected results and side effects like smudged anti-aliased text. This fixes the issue by multiplying the DIP resolution by the scale factor, making the framebuffer match the physical pixel resolution of the screen. Change-Id: I3594995ce8e18a31b47e27165f72bc6a391b97b6 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
* Support Windows Phone 8.1 in WinRT QPAAndrew Knight2014-05-225-18/+69
| | | | | | | | | | - Unsupported code paths for WP8.0 are avoided, and new APIs are used where appropriate (virtual keyboard) - DirectWrite fonts are loaded on WP8.1 - Platform dialogs are used on WP8.1 Change-Id: I721006ac943ad4e248f0f1590ce247a03e40fbc0 Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
* Add build support for Windows Phone 8.1Andrew Knight2014-05-2214-36/+225
| | | | | | | | Tweak qmake, add mkspecs for emulator and device, adjust the manifest template for WP8.1, and add missing icons. Change-Id: I7a6405fa85297ae4cc8522015274e65fb7a315a6 Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
* Direct2D QPA: Move QVectorPath conversion function into private classLouai Al-Khanji2014-05-221-101/+103
| | | | | | | | | | The function already needs information from the engine for conversion, moving it into the private class makes it possible to get this info directly in the method and makes calling the method nicer. Change-Id: I47fa9a4531d0d0605aa587fba90fbfdf036f0998 Reviewed-by: Risto Avila <risto.avila@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Direct2D QPA: Get rid of QPainterPath conversion functionLouai Al-Khanji2014-05-221-46/+3
| | | | | | | | | | This function was used only in one place and duplicated a lot of logic with the very similar QVectorPath conversion function. Just use QVectorPath everywhere instead. Change-Id: I3a4821f0452634c309ca0730047ea6ef7a7591ca Reviewed-by: Risto Avila <risto.avila@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Direct2D QPA: Cache QVectorPaths if drawn more than onceLouai Al-Khanji2014-05-221-6/+43
| | | | | | | | | | Hooking into the caching mechanism gets us a measurable performance boost for paths that are drawn repeatedly, around 10% on my machine when drawing aliased arcs. Change-Id: I32f4ed7daa8a51b5c5a9c6d5414ab5d4ef759f70 Reviewed-by: Risto Avila <risto.avila@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Trigger repaint of window when toggling unified toolbar on or off.Jake Petroules2014-05-222-0/+4
| | | | | Change-Id: I5204e5c65ae3cf84459cc62f587ecccd855e02f8 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* Mark the missing QDnsLookup constructor as \internalAndy Shaw2014-05-211-0/+5
| | | | | | | | | Implementation will be added for Qt 5.4.0 as it cannot be done sooner. Change-Id: I4d2626416fae99339988cd994653ce7ec753f081 Reviewed-by: Richard J. Moore <rich@kde.org> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fix for bindvalue(int) memory allocation problemKarim Pinter2014-05-211-1/+3
| | | | | | | | | | QSqlResult::bindValue(int index, ...) is increasing the memory usage when called multiple times for same index Task-number: QTBUG-33169 Change-Id: I4f26125f6bb994bb430dc054df5761b6ddf03075 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Mark Brand <mabrand@mabrand.nl>
* Fix broken QPlainTextDocumentLayout after removing charsAxel Rasmussen2014-05-212-2/+48
| | | | | | | | | | | | This fixes an issue where, if characters were removed from several blocks in a single edit, the document layout would end up being corrupted since the document layout manager wouldn't re-layout the proper number of text blocks. Task-number: QTBUG-30051 Change-Id: Idf3a6f567120e6a5dbebf1f65f685d374219328a Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>
* Cocoa: Do not process ampersands in menus twice.Christoph Schleifenbaum2014-05-214-2/+87
| | | | | | | | | | When syncing between QAction and native NSMenuItems, the ampersands (mnemonics) were removed twice. This lead to double ampersands being removed instead of replace with single ones. Task-number: QTBUG-37933 Change-Id: If1d9cd247b467472647b22b38460b44b03f13d82 Reviewed-by: Liang Qi <liang.qi@digia.com>
* Socks5 socket engine test: Disable UDP over Socks testPeter Hartmann2014-05-211-10/+4
| | | | | | | | | | | ... because it fails on the new network test server. The Socks5 tests in QUdpSocket have already been disabled by commit aa3eaf9d2ec4927df51e7d773a66f68ec5e4fce9 . Task-number: QTBUG-35490 Change-Id: Ib062adb422ff6e5538f14d15a266d79c3bb53956 Reviewed-by: Richard J. Moore <rich@kde.org> Reviewed-by: Tony Sarajärvi <tony.sarajarvi@digia.com>
* Android: Fix crash caused by unintentionally modification of env data.Christian Strømme2014-05-211-9/+11
| | | | | | | | | | | | The data given to putenv(3) becomes a part of the environment, as described in SUSv2, so If the data is unintentionally modified or deleted the consequence can be fatal. In previous versions of Android, the putenv(3) implementation made a copy of the data, so this bug has gone unnoticed. Task-number: QTBUG-39042 Change-Id: I20559c848fded10eeae54c4700ba0f4669fe49fc Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
* xcode generator: don't modify or copy QMAKE_INFO_PLISTRichard Moe Gustavsen2014-05-212-8/+10
| | | | | | | | | | | | | | | | | | | | | If the project has a custom Info.plist assigned to QMAKE_INFO_PLIST, we should leave it as-is without scanning and replacing contents inside it. Since we always copy the file to the build folder at qmake time, any later attempts to modify the source file will not have any effect. A better solution is to just reference the custom plist directly from the Xcode, without modifying it. This change will also stop unixmake2 from assigning the default plist to QMAKE_INFO_PLIST, since we need to know in the xcode generator if the variable was set in the project or not. Task-number: QTBUG-38260 Change-Id: I3c488b2960170c544d94f9db89d3ca95ee290bdd Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
* iOS: don't report negative selection ranges for backspaceRichard Moe Gustavsen2014-05-211-1/+1
| | | | | | | | | | | | | | | | | Qt sometimes report that the selection anchor is placed before the cursor when querying it for current selection. We need to accomodate for this when reporting current selection back to iOS, since it expects the range to always be positive. When pressing backspace, iOS will select the letter that should be deleted, and then call "deleteBackwards". If holding down backspace for a while, it will start selecting whole words instead. Since we reported negative ranges during this process, it caused artifacts and stray letters to be drawn. Task-number: QTBUG-39073 Change-Id: Ida9518307adce915adf49160b541a2f88637a0da Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>