The test is passing on Ubuntu 11.10.
Adding qWaitForWindowExposed after the line edit show() call to ensure
the line edit is actually shown on the screen.
Task-number: QTBUG-24518
Change-Id: I2af65bef76d171b36032120738dfbd7cfff51d7f
Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
The differences to VS 2010 project files are the
version number (surprise!) and the PlatformToolSet tag which
sets the version of the toolchain.
Change-Id: If26f08fad1a69d7e6cd28cc5e860ff964f19b264
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
- fix typo in comment
- make translateDriveName file-static
- use QList::reserve()
- explicit ctor
- annotate functions called by owning thread/run()
- iconProvider() and resolveSymlinks() shouldn't be slots
- private instead of protected
- run() marked Q_DECL_OVERRIDE
- annotate which members are protected by 'mutex'
Change-Id: Ic176a030b0597c98f48185efd17260fd62532460
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Member variables for lastSeparator, first and lastDotInFileName are now
initialized to -1 (non-existing), where the previous value of zero would
mean a separator/dot at that position and resulted in path() returning
'/', instead of '.'.
Tests were expanded for better coverage of empty state and
default-constructed instances.
Change-Id: Ie27547886b52224d38b5be0b4f920c9927fd440f
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
Moc should not see a defined QT_NAMESPACE, to
keep the names of all symbols consistent with
an un-namespaced Qt.
Change-Id: Ia72afabaa0820b02a0863148510122ce942a5082
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Added some test cases that check that moc
correctly expands #defines
Change-Id: I7fe6eed129d46ca9281d73064571cae43b32410d
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Moc now supports full expansion of macros with arguments
with the exception of some keywords such as Q_OBJECT
and others that are used internally
Change-Id: I283d47152f75de81ec68a3df1f0f2273f11c5149
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
This is required so preprocessing macros with arguments
can work correctly.
Change-Id: Ia30ede6a3579be13800bf1255d313748e2d696f9
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Parse function macros and add it's list of arguments
to the Macro definition.
Change-Id: Id22f5cf4a1c098f7b4f5b72f002900cd40d03e0f
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
This helps e.g. cases where a namespace is defined
through a macro and moc doesn't see it at all.
Expanding macros with arguments is significantly more
work, and should happen in a separate commit.
Change-Id: Ic8d0443d06fab2ed343115d8c43022f2c67ec3cd
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Since we only want one row, never ever run a SELECT without a WHERE
clause.
Change-Id: I40a78935f5573111faa3922eae97e6d5961be5f2
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
It's good to clean up the query before emitting signals about the
updated row. It's possible that connected slots will call selectRow()
again for other rows.
Change-Id: I482fe2dd58218f53567ce8725ee591ce2eeda348
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
This method was originally intended for refreshing rows after
submitting changes. It should also work for refreshing rows
that are unchanged (i.e., not cached), but did not because
constructing the primary values depended on the cache. As a
consequence, the WHERE clause for the query was not created.
Fixed by deriving primary values for uncached rows from the
query record. Note that the cache is still authoritative for rows
it holds. This is important because the prmary values there may
differ from the original query record due to changes to columns
of the primary key.
Includes new test.
Change-Id: I41cca2cbf26019d4b495ffa6d876e2b55ec57803
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
Added a test for QMacCocoaViewContainer which will enable the testing
of the fixes coming
Change-Id: I73e9540bc58411634f0da7d398eca4b7ffafba8e
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
The test is not hanging on Windows anymore.
On Windows, add an expected failure for the failing case.
Task-number: QTBUG-22801
Task-number: QTBUG-27306
Change-Id: Iede95766504f3e8a278a4554a5967ca333aae3bf
Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
These functions have begun showing in the tst_symbols unit test as
"symbol does not start with q". Since they're never called directly,
they're never inlined. Since they were inline, the compiler was probably
deciding to not export them.
Something changed and it could be anything (new compiler version, new
options, etc.). So mark them static.
Change-Id: I838dfc94edd7f09c202743bff0daf9d20c10c3a6
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
The default is the current behaviour: strip on installing release, no
strip on installing debug. This option does not change the
installation of debug builds because qmake does not support that.
Change-Id: Ic208d5ffe860d5f1ee1cafdc944e12001673d33f
Reviewed-by: Davide Pesavento <davidepesa@gmail.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
We had two instances of this function in the Qt source code, one clearly
a copy of the other, so both had the same thread-safety issue. Instead,
let's have one copy and have both write_nosignal() and sendto() call
them.
Q_NO_POSIX_SIGNALS is also gone. It was only used with Symbian.
Change-Id: I0f1354a8e9df8e6b10a02f86a940e3c6d1222087
Reviewed-by: Peter Hartmann <phartmann@rim.com>
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
The configure script correctly detects freetype and sets
"system-freetype" in QT_CONFIG. However, the project file did not
consider this possibility.
Change-Id: I9ce90e7cd032a12ed7d06d3858b16c5a8d90c073
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Native font rendering is broken for QML applications, use free type
rendering for those scenarios. Use native rendering for all other
applications.
Use a workaround to find out if we are running a QML application on the
target.
Related to QTBUG-24205.
Change-Id: I653ea579098db1e58af8176cb2c3f943be0b9602
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
The functions dealing with the void* internalPointer() can't be
constexpr on GCC 4.6 and Clang 3.2-trunk, even though GCC 4.8-trunk
accepts it, because of the casts required.
Change-Id: Id04105312da3d0c7632f7df06a34bc5a71120b32
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Rationale:
1. Comparing pointers that don't point the same array is undefined behaviour, IIRC,
and op== and op< did that.
2. The functions that cast to/from the storage type can't be constexpr. It makes
more sense to have the quintptr functions be constexpr (they have a fighting
chance to actually get passed something constant) than it is to have the void*
functions constexpr. Thus, the storage type should be quintptr.
Also prepare op< to be constexpr-compatible.
Change-Id: I4b2d4a0ec8ca80d619d272bf07c57887cbd11c2f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
It looks like the qmake process failed if cmake is not installed.
Change-Id: I721796a602d8c572144e9d21be5d62b737698b73
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Cached hoverBranch could get invalid if branches were collapsed or
expanded programmatically, leading to a crash in some situations.
Fixed the logic for updating hovered over branch indicators and
also now update hoverBranch when drawing so that it is guaranteed to be
up to date there - this fixes issues like hover indicator not updating
when the view is programmatically scrolled.
Task-number: QTBUG-27158
Change-Id: I5bd1ad76aee512ad78df33959a84ead16886a47c
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
The private method is called in several places in QListViewPrivate,
but before this patch, the implementation in QAbstractItemView was
called. This meant that the options were not set properly,
resulting, for example, in icons in icon mode being laid out in
list mode (on the left and small).
This is a regression resulting from
8eab9cbce2 and
3578e05b29. Other views are not
affected in a similar way.
Change-Id: I753cb99410e367266753eaf2fa43361b9212ab96
Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@gmail.com>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Otherwise we get strange build errors by attempting to build an
project in debug mode against a release-mode Qt:
http://testresults.qt-project.org/ci/QtBase_master_Integration/build_03955/win32-msvc2010_Windows_7/log.txt.gz
(grep for MSVCRTD)
The CMAKE_BUILD_TYPE variable is always specified by the ctest_testcase
driver as either Debug or Release.
Change-Id: Ia5af7f0c31550b92679a3190e07b4e5c4ea638c6
Reviewed-by: Brad King <brad.king@kitware.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
The result of replacements for special characters should not be
used here. CTest needs the replacements for the test names, but
requires the argument to the project() command to match the
argument to ctest --build-project.
Task-number: QTBUG-27087
Change-Id: I4ff7a7e00ddb65ab0c0f2305901e1d03f46e07d1
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
The name passed to the project() command must be the same as the argument
to ctest --build-project.
Initially I had appended _build to disambiguate the generated project
from the project under test, but that is not needed anyway as the
project under test is self-contained, so it's ok.
Task-number: QTBUG-27087
Change-Id: I648d57271529d4e8d308ff60b81419ade29b2e44
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
To fix a compile error when QT_NO_LIBRARY is defined.
Change-Id: Ie72b60b8204641fa05f4cdbf66e908cb3526217e
Reviewed-by: Jing Bai <jing.bai@digia.com>
Reviewed-by: Richard J. Moore <rich@kde.org>
There is a pending patch to reinstate this for Qt 5.1 (the patch
introduces new API top QOpenGLContext). I will fold the revert of this
patch into:
https://codereview.qt-project.org/#change,31231
Note that QGLShaderProgram still supports Geometry shaders so source
compatibility with Qt 4.8 is maintained.
Change-Id: I53faedd4e4a2a6c2a9765afdc1bee6df5ae2f711
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
Negation operator ("!") have precedence over bitwise and ("&").
Change-Id: I39e2d99da6eaa4477bbe35a1259f745e05c9841a
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
A new QScreen is created when an output is activated (monitor or
projector is added, for example), and destroyed when the output is
turned off. Ensures that screens and siblings are always in
the right order: primary comes first.
Logical DPI is derived from virtual geom / virtual size,
which will be different than output geom / physical size
if X was started with --dpi override. This is a good thing:
when X gets wrong EDID info for physical size and you need to
override it to get reasonable font sizes, Qt will heed the
logical DPI for font sizing.
Change-Id: I5e3de34013c1b6b21067243de56f3f1eb72787fa
Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
This is an automated change performing the following replacements:
join\("(.)"\) -> join('\1')
join\(QLatin1String\("(.)"\)\) -> join(QLatin1Char('\1'))
join\(QStringLiteral\("(.)"\)\) -> join(QLatin1Char('\1'))
Change-Id: Ia087beb886bbaec1a0976cd924440d8904044879
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
This is an automated change performing the following replacements:
join\("(.)"\) -> join('\1')
join\(QLatin1String\("(.)"\)\) -> join(QLatin1Char('\1'))
join\(QStringLiteral\("(.)"\)\) -> join(QLatin1Char('\1'))
Change-Id: I81c378ef6aeeada5e116f1394cc9fc67f901ffd6
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
This is an automated change performing the following replacements:
join\("(.)"\) -> join('\1')
join\(QLatin1String\("(.)"\)\) -> join(QLatin1Char('\1'))
join\(QStringLiteral\("(.)"\)\) -> join(QLatin1Char('\1'))
Change-Id: I1d0c9782cc1522d937b930531720e32d4c8f7ce8
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
qCompare() was both overloaded and specialised, but always as a template.
This lead to the QIcon specialisation actually invoking
qCompare(QFlags<void*>, ...)
when specifically asking for qCompare<void*>() (detected by adding
underlying-type detection to QFlags).
Fix by preferring overloading and not specialising anything.
Change-Id: Ie001ebb9dfb0847c6c33a3f45177a61579fd61ee
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
This test actually passes using the "xcb" platform and fails otherwise.
Second, the Jira task is misleading since it refers to
tst_QFocusEvent::checkReason_Shortcut()
Change-Id: Icab91ace8c214d958b534c5cebae900242522372
Reviewed-by: Caroline Chao <caroline.chao@digia.com>
Use the native parent's window if the widget in question does not
have one. This should be in line with Qt 4.8 using effectiveWinId().
Remove redundant code in grabMouse(QCursor).
Change-Id: Id6ab192e739221fe89f865f4d2f7a6d4671a190b
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
The m_iconProvider and m_resolveSymlinks members are only ever
accessed from getInfo(), which is not called from run(). So the
mutex-lockers aren't needed in the setters.
Change-Id: I3257c95366528c5c66352d20a09e8a43b811f3ba
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
QAIM::createIndex() took either int or quint32, but QMI::internalId()
returned qint64.
In the new interface, createIndex() takes, and internalId() provides,
integers of type quintptr.
This matches the storage size of the void* in the model index and
avoids truncation.
Remove the
createIndex(int, int, quint32) and
\obsolete createIndex(int,int,int)
overloads.
This makes a literal 0 in the third parameter ambiguous now.
The solutions have been noted in changes-5.0.0.
Change-Id: I0a0ecd8430eaf695129a4d09d14d4e30745485c4
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Change copyrights and license headers from Nokia to Digia
Change-Id: If1cc974286d29fd01ec6c19dd4719a67f4c3f00e
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>