Commit Graph

23798 Commits

Author SHA1 Message Date
Alexander Volkov
431e5d9f47 fingerpaint example: Use the maximum diameter for the touch spot by default
The result doesn't look good when you paint with the MinimumDiameter (3 px).
Also don't paint released touch points, because we can't get neither the
touch rect not the pressure for them.

Change-Id: I8d17c4884ae41545b2cd3f208afa73262133456c
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-05-23 11:28:00 +00:00
Friedemann Kleint
0c85cdb8c2 QFtp: Suppress warning about reading from closed QIODevice.
Clear bytesFromSocket when the socket is not open instead of
reading in QFtpDTP::socketConnectionClosed(), which is connected
to QTcpSocket::disconnected().

Task-number: QTBUG-46112
Change-Id: I0e5e47448f88601eb5c62fe9ba92e1a461323364
Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
2015-05-23 08:59:27 +00:00
Friedemann Kleint
06de0da1e8 Make warnings of QIODevice more verbose.
Include class name, object name and file name when available.
For the bug in question:

QIODevice::read: device not open

becomes

QIODevice::read (QTcpSocket, "QFtpDTP Passive state socket"): device not open

Adding a static function also makes it easier to set a breakpoint
and find the culprit.

Task-number: QTBUG-46112
Change-Id: Ic181d8ab292912d1acbcc3cb84d9679fe4842ca0
Reviewed-by: Laszlo Papp <lpapp@kde.org>
Reviewed-by: Alex Trotsenko <alex1973tr@gmail.com>
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
2015-05-23 08:59:20 +00:00
Friedemann Kleint
cab7e7858a Make OpenGL legacy examples hellogl and overpainting work with Dynamic GL.
Call GL functions using QOpenGLFunctions_1_1.

Task-number: QTBUG-46103
Change-Id: I1cbacf9c192c17d96d96aa861bb16e2918a0c053
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-05-23 08:59:14 +00:00
Friedemann Kleint
4476966e04 Direct2D: Fix MSVC2015 warnings.
qwindowsdirect2dpaintengine.cpp(365): warning C4838: conversion from 'const qreal' to 'FLOAT' requires a narrowing conversion
qwindowsdirect2dpaintengine.cpp(928): warning C4838: conversion from 'const qreal' to 'FLOAT' requires a narrowing conversion
qwindowsdirect2dpaintengine.cpp(928): warning C4838: conversion from 'int' to 'UINT32' requires a narrowing conversion
qwindowsdirect2dpaintengine.cpp(1398): warning C4838: conversion from 'qreal' to 'FLOAT' requires a narrowing conversion
qwindowsdirect2dpaintengine.cpp(1426): warning C4838: conversion from 'double' to 'FLOAT' requires a narrowing conversion
qwindowsdirect2dbitmap.cpp(78): warning C4838: conversion from 'int' to 'UINT32' requires a narrowing conversion
qwindowsdirect2dwindow.cpp(166): warning C4838: conversion from 'double' to 'BYTE' requires a narrowing conversion

Change-Id: I6992260ed2696fa4c47c1c0dd666f448f115879a
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-23 08:58:58 +00:00
Oswald Buddenhagen
8e797477b9 remove vestiges of -prebind magic
since commit 22edeb3f4 (private; anno 2002), the generator would extract
-prebind and translate it into a PREBINDING property in the pbx file.

the writeout to the pbx file got lost in the rewrite for Xcode 3.2
(commit 66f6e5b1; anno 2012).
this isn't particularly bad, as prebinding is obsolete since OS X 10.3.4.

we now go the last mile and remove the handling of the flag. that means
that remaining projects which still use it (meaninglessly) will get a
warning from Xcode, which is kinda what we want.

QMAKE_LFLAGS should have never been part of the library iteration loop.
it was added there in the prebind handling commit, so we can get rid of
it again now.

Change-Id: Id7dee2b1e248bb2bd7aa7a3e66f82057921afffd
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
2015-05-22 19:04:24 +00:00
Oswald Buddenhagen
bcf3a3c113 fix quoting of qmake parameters in 'qmake' target
we need to do full shell quoting, not the limited whitespace quoting.

Task-number: QTBUG-46224
Change-Id: I41bc9aee556ca680dce0875b58159a31db962452
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-22 19:04:21 +00:00
Oswald Buddenhagen
1e2829f5bf remove vestiges of .private_depends
amends 16f4bc5b6.

Change-Id: I5a9acb2fb57e92a152656be196e55c830031988e
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-22 19:04:19 +00:00
Timur Pocheptsov
79ad3de7bf QCoreWlanEngine - null the pointer
QCoreWlanEngine is using a global variable but fails to reset it to nil when deleted,
thus re-creating this WLAN manager we use a dangling pointer (found in
qnetworkconfigurationmanagerqappless). Since our API allows to (re)create object(s) of
these class, the pointer must be set to nil after -release call.
Ideally, of course, this class has to be re-factored.

Change-Id: I08662f55dc6cd2ceb0e0cad2574ee3dee6b8e3fd
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
2015-05-22 14:47:56 +00:00
Maurice Kalinowski
21b5298d15 WinRT: Windows 10 compilation fix
Header is required for successful compilation.

Change-Id: I401b7c6fbc594b3cd0c9a4b25afc8ff918d8bddd
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
2015-05-22 14:27:58 +00:00
Simon Hausmann
6a72afa5f7 Blacklist tst_qwindow tests that are failing on Ubuntu 14.04
This should allow us to make the rest of 14.04 enforcing

Change-Id: I37f6751e8b966b047d1bd2e49ba9482e5846acb1
Reviewed-by: Tony Sarajärvi <tony.sarajarvi@digia.com>
2015-05-22 14:24:32 +00:00
Jan Arve Saether
11838622e5 Fix compile error with VS 2015
Change-Id: Ib3b61de27feccb980e5efdf02f0372602d7ffb5a
Task-number: QTBUG-45961
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@theqtcompany.com>
2015-05-22 14:17:35 +00:00
Maurice Kalinowski
7c7c815a1a MSVC2015: Compile fix
Q_DECL_NOTHROW needs to be present at the definition as well in VS2015.

Change-Id: I8a6def607aa4ae9c9fe64386a38fc1c728edd8d1
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
2015-05-22 14:17:30 +00:00
Oliver Wolff
97a6f28200 Fixed compilation of auto tests using vc(x)proj files
As the defines looked like -DQT_TESTCASE_BUILDDIR=""C:\..."" compilation
from Visual Studio (vcxproj) failed due to the two quotation marks at
the beginning/end of the actual path. So for the vc(x)proj we do not use
shell_quote but add the quotes manually.

Change-Id: I186258d82a56928cd0316bff1ec9f60147044165
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2015-05-22 14:13:00 +00:00
Andy Shaw
e96ad10fd8 Ensure the same behavior on Win as Unix re the host in isApparentlyStale
When the hostname is empty then it is assumed that the lock file is from
the same host as the one running the application.

Change-Id: Iba8aefc171a209294371dc2022d93ede3035b242
Reviewed-by: Will Wagner <willw@carallon.com>
Reviewed-by: David Faure <david.faure@kdab.com>
2015-05-22 06:02:39 +00:00
Allan Sandfeld Jensen
ad9698713f Adjust curveThreshold based on strokeWidth
Currently curveThreshold is relative to pen width, this allows wide
pen to be increasingly off target.

This patch adjust the curveThreshold relative to stroke width, thereby
ensuring wide pens stays on the curve.

Task-number: QTBUG-46151
Change-Id: Ifd4371aa2853331d02e3c6f6565c243eb1b7ed2e
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
2015-05-22 05:45:38 +00:00
Friedemann Kleint
9d9450f5f9 Add CONFIG += testcase to test qglobalstatic.
Otherwise, make check does nothing, always succeeding.

Change-Id: I0fe04697e02ab0f33cd9aebb550777e200c70804
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
2015-05-22 04:37:52 +00:00
Friedemann Kleint
b0a1a134c2 Add debug operator for QTouchDevice.
Produces:
QTouchDevice("", type=TouchScreen, capabilities=Position|Area|NormalizedPosition|MouseEmulation, maximumTouchPoints=10)

Remove operator from manual test.

Change-Id: I6b792665031902d5f822c80807a400a334c27526
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2015-05-22 04:36:41 +00:00
Friedemann Kleint
97e75b2763 Make QTouchDevice a Q_GADGET and introduce Q_ENUM/Q_FLAG.
Make it possible to stream the enumerations to a debug stream.#

Change-Id: I0add2dcd835333a8d6cebf779252f22c1418faf3
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2015-05-22 04:36:28 +00:00
Friedemann Kleint
6794319bbd Fix a crash in tst_QTouchEvent::deleteInRawEventTranslation().
The test deletes a widget in QEvent::TouchBegin.

This is part of a series of patches to revive the test; it is currently
not run since tests/auto/gui/kernel/qtouchevent/qtouchevent.pro
is missing CONFIG += testcase.

Task-number: QTBUG-46266
Change-Id: I65c0a431ff1807133438764dd8b3c16bb9cb6743
Reviewed-by: Caroline Chao <caroline.chao@theqtcompany.com>
2015-05-22 04:34:54 +00:00
Allan Sandfeld Jensen
d4a296b538 Do not modify decoder when determining image-format
We should not configure the decoder when just determining the image-
format. Doing so can cause all versions of libpng to print a warning,
and some versions to fail to decode.

The code appears to be a leftover from when the image-format logic was
copied out of the introduction of the decoding method, where the proper
settings are still applied.

Task-number: QTBUG-46233
Change-Id: I6619728804f040ae6c9d637c7298a8586e22499e
Reviewed-by: Andy Shaw <andy.shaw@theqtcompany.com>
Reviewed-by: aavit <eirik.aavitsland@theqtcompany.com>
2015-05-21 08:49:47 +00:00
Shawn Rutledge
d8bfd812c3 D-Bus system tray icon: submenus can be created after context menu
QMenuPrivate::init() calls QPlatformTheme::createPlatformMenu() to
create a platform menu, but on Linux, that returns null for now.
QSystemTrayIcon::setContextMenu() results in recursive calls to
QSystemTrayIconPrivate::addPlatformMenu() which then calls
QDBusTrayIcon::createMenu() for the context menu and each submenu.
However if a submenu is added afterwards, a corresponding platform
menu is not immediately created.  Now copyActionToPlatformItem()
will detect and create the missing platform submenu, by calling
a new method: DBusPlatformMenu::createSubMenu().  This is because
there is no way of knowing that it's a tray-specific context menu
(which is so far the only case in which we use DBusPlatformMenu).
So, QPlatformMenu::createSubMenu() needs to exist as a new
QPA interface for this use case.

Task-number: QTBUG-45803
Change-Id: Ib319e873082196515ea0580d70d069099cf2c175
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
2015-05-21 05:17:08 +00:00
Alexander Volkov
2858a3c91b Don't propagate single touch events only from touchpads on OS X
This way the tests that send fake touchscreen events can work.

Change-Id: I997ef015d0096249c4549dbd21b99d0248e0c987
Task-number: QTBUG-46111
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Caroline Chao <caroline.chao@theqtcompany.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2015-05-21 05:16:33 +00:00
Jani Heikkinen
fc78456fba Updated WinRT license headers to use LGPLv3 instead of LGPLv21
From 5.5.0 -> WinRT port is licensed with LGPLv3, see
http://blog.qt.io/blog/2015/04/29/windows-10-support-in-qt/

Change-Id: I7e42564276af3fdbd0d4c61e2736610fa698b11c
Reviewed-by: Tuukka Turunen <tuukka.turunen@digia.com>
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@theqtcompany.com>
2015-05-20 18:12:14 +00:00
Friedemann Kleint
b3f7b23294 Unclutter debug operators of gestures.
Use the helpers in qdebug_p.h to suppress class and enum names.

Change-Id: Ib71f0a1e5b3c22f44d68a7930fef38384f037204
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2015-05-20 18:12:14 +00:00
Oswald Buddenhagen
d88df1ca6a allow modules to declare that they have generated private includes
Change-Id: Ifbd561aab9c6a6634930b525aa1d51b9ad792a09
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
2015-05-20 18:11:48 +00:00
Oswald Buddenhagen
12106b66b9 move symlinking loop into the symlink container emptiness conditional
it obviously makes no sense to set up the loop if the container is empty.
as we now have that conditional anyway ...

Change-Id: I6d95c0102734852443c188012bfcb076d879581e
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-20 18:11:44 +00:00
Oswald Buddenhagen
6e3ba36a06 bundles: create Versions/Current only if versioned resources are present
QMAKE_FRAMEWORK_VERSION has a fallback to VER_MAJ (which derives from
VERSION), so it's pretty much always set, thus defeating the previous
check.

amends 6cb495de.

Task-number: QTBUG-46215
Change-Id: I2c5560c469617ebeab978e4de78df00baf38d49d
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-20 18:11:41 +00:00
Oswald Buddenhagen
8175e31bda remove now redundant tests
the functionality is now covered by the qmakelib test.

Change-Id: Id627f573fb247ff3b86558509e27b6a9862c1a59
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-20 18:11:37 +00:00
Oswald Buddenhagen
5ddc16b5df add qmake evaluator test
Change-Id: I31b95daede5edef245dd1ba447f2937a0db34232
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-20 18:11:34 +00:00
Oswald Buddenhagen
ef50e244cd split parser test initialization
the idea was to speed up optimized msvc compilation, but it didn't help.
still, it's better structured that way.

Change-Id: I4b2108d02a47ef8ef704b0b542b0f281bff20165
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-20 18:11:32 +00:00
Oswald Buddenhagen
48c38aae10 move parser test to a separate file
for better structure.

Change-Id: I16bd1ca245640e92ffe167241a5a565e7a550e1d
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-20 18:11:30 +00:00
Oswald Buddenhagen
df43683975 move get{,Hash}Str from QMakeEvaluator to ProFile
this makes it possible to use these functions without an evaluator.

Change-Id: I23e4ec141b427f4c3c8b647305532be179058c07
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-20 18:11:28 +00:00
Oswald Buddenhagen
637a0889b2 remove bogus parens from error messages
Change-Id: I2683a4fb19a7251dc537e3265db3ba28079eb4b8
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-20 18:11:26 +00:00
Oswald Buddenhagen
fe9baf7e5b trim whitespace from windows error messages
the messages contain a trailing CRLF, which is not helpful.

Change-Id: I4a27115a191dc416a62e28a41f2a9c5893bdc64b
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-20 18:11:23 +00:00
Oswald Buddenhagen
4334ddc76b remove trailing dots from some error messages
the i/o functions are not very consistent about having the dot already
in the message. the windows api does, and qt passes this on.

Change-Id: I2d1a213965e15478985d6eff205689ea44aa2a03
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-20 18:11:19 +00:00
Oswald Buddenhagen
109e3fa0ae make defined() error message tell about "var" type
Change-Id: I21d994ebaee2db0d9b114812a8f89bb680ca311e
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-20 18:11:17 +00:00
Oswald Buddenhagen
bd19870b81 make infinite loop protection work even without an iterator variable
... (which is the usual case).

Change-Id: I464b6b284f963df45c7340ed079d540b528136f0
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-20 18:11:15 +00:00
Oswald Buddenhagen
c9270d6639 fix quote nesting in split_value_list()
a single quote must not disrupt a double quoted string and vice-versa.

Change-Id: Ibb277bc1c930a7dbe9199ca572507ababbcfae4c
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-20 18:11:12 +00:00
Oswald Buddenhagen
f37381e292 add autotest for ProString
also adds documentation, which is kind of a sanity test. ehm.

Change-Id: I6b520e8b505a2bfbb1e376fa72be0f140227a3a4
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-20 18:11:08 +00:00
Oswald Buddenhagen
a3fac53864 add parser tests for use of 'else' after bad conditionals
Change-Id: I9885f629a2f6511574eebd81896a1d9f258e55cb
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2015-05-20 18:11:05 +00:00
Oswald Buddenhagen
79de60f38b silence MSVC warnings about using TS() without parameters
Change-Id: I23264dcabc02b89441fa47c890fc662e9a41f7ce
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-05-20 18:11:03 +00:00
Thiago Macieira
9269dcc8ed Fix compilation of QContiguousCache::operator=
freeData() takes a Data*, not a QContiguousCacheData*.

Task-number: QTBUG-45783
Change-Id: I96d7ac38dac24b418138ffff13d7fdf09b1d6b07
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
2015-05-20 17:23:33 +00:00
Topi Reinio
9a1283f8d3 Doc: Qt Network: List the classes on SSL Classes page
Change-Id: I32693ac3012142c04671f8278e06165396ca3242
Task-number: QTBUG-46145
Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com>
Reviewed-by: Martin Smith <martin.smith@digia.com>
2015-05-20 11:24:52 +00:00
Paul Olav Tvete
938f9fc0f8 Workaround for Samsung keyboard bug
Return null string instead of empty string when the selection is
empty. It looks like Samsung just tests for selection == null when
doing backspace.

Task-number: QTBUG-45785
Change-Id: Iaa006a8ffe52b2704c7348646dde9ca4e1f78c5c
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
2015-05-20 10:10:34 +00:00
Venugopal Shivashankar
20e36879d7 Doc: Excluded qdoc files that caused unnecessary Qt Creator warnings.
The customcompleter and textcodes are widget examples, but they end up
in the Qt Core exampledirs boundary because of a reference to the
plugandpaint example in the docs. This resulted in a couple of wrong
entries being written into the examples-manifest.xml, which is used
by Qt Creator.

This change explicitly exludes the qdoc pages for the two examples
so that qdoc doesn't add the corresponding entries into
examples-manifest.xml.

Task-number: QTBUG-41996
Change-Id: I0e95b6d4d93e0ce18f5b34e5034b279598b4924f
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Reviewed-by: Martin Smith <martin.smith@digia.com>
2015-05-20 08:45:15 +00:00
Richard Moe Gustavsen
d204dd1d5e doc: add QStandardPaths documentation for iOS
Task-number: QTBUG-36171
Change-Id: I15c5ac4f5c4944218e5f30c11530160f65699be9
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Reviewed-by: Samuel Gaist <samuel.gaist@edeltech.ch>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
2015-05-20 07:45:33 +00:00
Paul Olav Tvete
e2102752ba Workaround for Samsung keyboard bug
Return null string instead of empty string when the selection is
empty. It looks like Samsung just tests for selection == null when
doing backspace.

Task-number: QTBUG-45785
Change-Id: Id26ce707130777fcd0ab1a4cff08367bb2810f2f
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
2015-05-20 07:42:56 +00:00
Maurice Kalinowski
b6634023fa WinRT: Disable exceptions when turned off
On desktop windows we define _HAS_EXCEPTIONS=0 to also forward this
option. Hence harmonize this with WinRT builds as well.

As a side-effect qtdeclarative now compiles without warnings on WinRT.

Change-Id: I8e343f172160991ffb2ede01303802f321de82b5
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
2015-05-19 11:46:04 +00:00
Topi Reinio
f1fdac97ab qdoc: Improve logic for automatic example tag generation
QDoc generates tags for examples based on the example title and the
name of the module. This change makes the following improvements:

    - Edit regular expression to match strings like 'OpenGL' and
      'Qt3D' as a single tag.
    - Strip off enclosing parentheses.
    - Filter out common words ('and', 'the')
    - When cleaning/modifying generated tags, keep them in a QSet
      to eliminate duplicates.

Change-Id: I288104df12bf23a224068d40bce1f980148a412a
Reviewed-by: Martin Smith <martin.smith@digia.com>
2015-05-19 11:19:05 +00:00