QCocoaEventDispatcher stores user input events in a queue in certain
cases. If the target of those events is destroyed, the events are later
sent to the stale window, causing a crash.
Task-number: QTBUG-39211
Change-Id: Ie55d2df5697c742bcb644ebf8c5028015a0b8148
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
Don't interrupt the Qt event loop if the Qt event
loop isn't running (meaning processEvents has not/
will not be called). This can happen in the QMacNativeWidget
or plugin case where the native code calls [NSApp run]
and QApplication::exec() is never called.
In Qt 4 this was not necessary since UI event
processing was more direct: QCocoaView would call
QCoreApplication::sendMouseEvent/sendSpontaneousEvent
directly on mouse events.
Task-number: QTBUG-36225
Change-Id: I2894cbbca66a902652c9f8bc916e94ad8ce0e18e
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
Block flush until all bits have been flushed. This prevents Qt from trying to
draw over the buffer while it is still being cleared.
Change-Id: I49b90a7653ec3768411a1a94837bb31fec4d44e8
Reviewed-by: Frank Osterfeld <frank.osterfeld@kdab.com>
Reviewed-by: Andreas Holzammer <andreas.holzammer@kdab.com>
Reviewed-by: Bernd Weimer <bweimer@blackberry.com>
If QNX does not have inotify there is no native engine.
Change-Id: I042efd0b59f916f9e0b55bbe5c7f3fe7bb6914c8
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Sergio Ahumada <sahumada@blackberry.com>
Reviewed-by: Fabian Bumberger <fbumberger@rim.com>
CRT dependencies should contain "Phone" in the name.
Change-Id: I1b0de01df6a016c20b59232f6068e9bb87e3f18c
Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@digia.com>
It speeds up the extraction and it reduces memory consumption.
Change-Id: I188f7efbb826343e5bd75f63ace36522f0d7a24d
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
HSTRING needs to be released or handles will be leaked.
Instead use HString which takes care of resource management
on its own.
Task-Number: QTBUG-38115
Change-Id: I2c767776c1f22f45acd8dd77b693f30d63d894b9
Reviewed-by: Andrew Knight <andrew.knight@digia.com>
Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
The original dist target no longer copies files around, but
merely does the final packaging. It depends on a new recursive
distdir target, which handles copying distfiles to the distdir.
[ChangeLog][Tools][qmake] Added 'make dist' target for subdirs
projects (unix only)
Task-number: QTBUG-21910
Change-Id: Ib59139c3fe196caf832d8dcefab484ab91f1f5ce
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Testing whether alphaBufferSize() != 0 does not work, because when no alpha
channel is present, alphaBufferSize() can return '-1', which will cause
non-transparent windows to be wrongly cleared and an artifact will appear.
Change-Id: Id9e985f105c0bb302cc6f53960a5dbae2acdb921
Reviewed-by: Frank Osterfeld <frank.osterfeld@kdab.com>
Reviewed-by: Wolfgang Bremer <wbremer@blackberry.com>
Reviewed-by: Sergio Ahumada <sahumada@blackberry.com>
When binding an FBO directly via glBindFramebuffer, the QOpenGLContext's
internal current_fbo, that is maintained by QOpenGLFramebufferObject,
becomes out of sync. This will lead to QOpenGLFramebufferObjects thinking
they are still bound.
Such state tracking should be avoided since it is becoming increasingly
difficult to keep it consistent between the various OpenGL API wrappers
and will never be robust enough when the application changes the state by
directly calling OpenGL functions.
current_fbo is now removed in QtGui. QtOpenGL is not touched.
Change-Id: Id809aab1306c9486d1e2ba3bb5aa93593659e920
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
This update is preparation for implementing the actual task
described in the bug. To implement it required converting
the QML type node and the QML basic type node to be first
order tree nodes instead of subtypes of the documentation
node. This cleans up a lot of messy logic in some places.
It was also necessary to split the getLink() function in the
html output generator into two functions, one still called
getLink(), which handles the \l command, and one called
qetAutoLink() which is called for generating auto links.
This should make qdoc run faster.
The basic infrastructure was also added for parsing the
string in the square brackets for the \l command.
There will be a further update to complete this task.
Note that some autolinks might not be generated due to
this change. I haven't seen any yet, but I believe there
will be some. This can be fixed later, if it is a problem.
Task-number: QTBUG-39221
Change-Id: I8135229984398408205ba901b9ef95ceac74683c
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
The selectable/selected states refer to items in a list and similar,
do not interpret them as text selection states.
Without this change NVDA for example announces text edits as selected
which makes no sense and which it doesn't do for native text items.
Change-Id: Ib1d109523bd4cc2b9b40ace8a8c3d7d3a7f9f25c
Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
It will now share the same behavior as QGroupBox, which has NoFocus
if its not checkable.
This doesn't lure AT clients to stop and read its content (this is the
case for android accessibility) (designer seems to generate a tooltip
for each QDialogButtonBox, which will be read as the name).
Change-Id: I6cfacdd9c01299521222c773634df1e36971d982
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
The previous code resulted in that all regions that had some alpha
blending content had to be rasterized as bitmaps.
With this patch, we only need to fallback to proper alpha blending
if there is a background content to blend against.
If there is no background content we simly assume that the background
is white (which happen to be the most common paper color). It will
then be treated as a solid background.
Task-number: QTBUG-33548
Change-Id: I9d2c9be95a701704cdb3724480421db49b4cdd98
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
gestaltSystemVersion's encoding only has room for a single version
digit. Thus, OS X 10.10 would previously have been detected as OS X 10.9
(Apple's comments in the header even warn against this).
Change-Id: I41c35b1507d39e2958a9aaffaa8c48ac380f61d9
Reviewed-by: Samuel Gaist <samuel.gaist@edeltech.ch>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
QSignalBlocker resets to the previous state, which might have already
been a blocked signal state.
Task-number: QTBUG-39352
Change-Id: I918cc6ea346755b940e027cee5d6704824fbba32
Reviewed-by: David Faure <david.faure@kdab.com>
A typo caused qmake to stop output dependency information
added by the depend_command clause.
Task-number: QTBUG-13334
Change-Id: I00fabc87438ce94e80341e6f88aa2e0eaab57e19
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
[ChangeLog][QtCore][QSaveFile] Now follows symbolic links while writing to
a link instead of replacing the link with the contents.
Change-Id: I5afd519cb9f96ae68fa4c23c33a18de75671a301
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: David Faure <david.faure@kdab.com>
This is especially relevant on mobile devices where screen readers often
send mouse clicks to the middle of the object.
Task-number: QTBUG-39100
Change-Id: I5972f21dd12434601d86136215ab9b61248c9691
Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
Instead do it only once (in registerNatives). This is seems to be the
preferred way of doing it in other parts of the platform plugin.
Change-Id: I361a7862bb5a24b4024c7c6a30ecb14fc515d4ff
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
a162a3cb (Android: Add "unversioned_libname" configuration, 2014-04-23)
removed the version for shared libs on Android. This change updates
the generated CMake files to support that.
Change-Id: Ia6ef04872c664bd4c31546456a82730babed2910
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Without having the dummy window being override redirect Qt might
confuse window managers. Window managers might react on the create
notify event, but there is no reason to do anything with the window
as it is most likely already destroyed at the time the window manager
receives the create notify event.
By marking the window as override redirect we indicate to the window
manager that they can ignore it.
Change-Id: I35259436da4548f4190b92de412fb0de1d2e8077
Reviewed-by: Uli Schlachter <psychon@znc.in>
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Qt5 allows QAIM subclasses to reimplement the sibling() method. Unfortunately,
the default QAbstractProxyModel's reimplementation differs in behavior to what
the Qt4 version was doing. In particular, the Qt4 version used to use the row
and column as positions within the proxy model, while the Qt5 version mistakenly
does this at the level of source model. This is arguably broken; the caller asks
for a sibling of the proxy index, not for a sibling within the proxy model.
This change makes the QAPM::sibling work explicitly in the same way as the Qt4
code behaved.
The reimplementation of QAbstractProxyModel::sibling was introduced in
9dfba89c28. It was subsequently fixed with commit
999109866d not to return indexes from the source
model, but the logic was still different from the Qt4 version.
[ChangeLog][QtCore][QAbstractProxyModel] Fixed QAbstractProxyModel::sibling to
work in the same manner as the Qt4 code used to behave. Previously, Qt5's
implementation would treat the row and column as positions in the source model
instead of a position in the proxy itself.
Followup-to 9dfba89c28 and
999109866d
Change-Id: Ia25027b2ad9e4777ba28de2d2226d48f8cccf587
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
The sanity check added in d16508a285
didn't actually catch the case where the invalid data is large
enough to contain the offset table and table directory. Added sanity
checks to all the code that accesses the font data now, so this
should fix crashes with partial data as well as invalid data.
Task-number: QTBUG-37190
Change-Id: Ie43f10d8cf0b09007783b9b1c4d91bfed8c6b0f0
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
identified by static analysis from
http://www.viva64.com/en/b/0251/
Change-Id: I0042336d9598415b978bf9819e74639685c627b5
Reviewed-by: Martin Smith <martin.smith@digia.com>
This patch removes the need for the user to put a dot at the end of the
bundle prefix which makes it's use more consistent and intuitive.
The prefix is based on what Xcode calls the "Company Identifier",
basically "com.digia" plus the product name. Changing that to
"com.digia.prefix-" and the product name to "Foo" results in a bundle
identifier of "com.digia.prefix-.Foo" which is in line with Xcode.
Change-Id: I9b62fc4dee1df51b523ce890a8896ea58ea2c62d
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
-transferred group page from qtdoc repository
-added description in example pages
-set the example documentation to use the standard Qt thumbnail
-added an entry in the help index for the example page
Change-Id: I9d5747bc329b5ecc15acd2eb3139696931166c6f
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Call [NSApp endModalSession] at the correct time.
Calling cleanupModalSessions() from processPostedEvents()
resulted in endModalSession being called from within
[NSApp runModalSession] - ending and cleaning up the
the modal session while Cocoa is still using it.
Move the cleanupModalSessions() call to to after
runModalSession returns.
Task-number: QTBUG-37699
Change-Id: I5868def36f6869667b0bbe33733286e3e49488eb
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
This reverts parts of commit d9875f7bff,
in particular the code for "2. Make interrupt() use [NSApp abortModal]"
abortModal is not the right way to end a modal session,
and introduced bad side effects, as reported in
QTBUG-34677.
Restore this part of the event dispatcher to the
Qt 4 state.
Change-Id: Iacc2d4a0757807c87c4320c93ed4db186622945c
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
This reverts commit ff3dcc49c4.
The reverted commit is an incorrect bug-fix for a
regression introduced by adding a call to
[NSApp abortModal] in change d9875f7b.
Change-Id: I1307d1790ada740e0552d62267b6009cbccd6c4c
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
This reverts commit a9cbddf473.
The reverted commit is an incorrect bug-fix for a
regression introduced by adding a call to
[NSApp abortModal] in change d9875f7b.
Change-Id: If23463ebdfe2ff64c68739dbece73a13773683c9
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
This brings QTimer::singleShot on par with QObject::connect in
terms of the new Qt5 syntax. With this patch, it is now possible
to connect singleShot to a member pointer, a static function
pointer and a functor (with or without a context object).
The short code path for 0 msec is not yet implemented - it will
require further modifications to QMetaObject before it will be.
An additional SFINAE on the new singleShot overloads had to be
implemented to prevent tricking the compiler into believing
const char * might be a function pointer.
[ChangeLog][QtCore][QTimer] Implemented new style connect syntax,
including functors, in QTimer::singleShot
Task-number: QTBUG-26406
Change-Id: I31b2fa2c8369648030ec80b12e3ae10b92eb28b4
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Call clear() in the destructor of QOpenGLTextureGlyphCache class to
prevent QOpenGLGlyphTexture object leak.
Change-Id: I290b09b0786d30603391e6855a21e9232b112739
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
These functions are not used anywhere. Since the classes are not
documented, we're free to remove the inline functions.
The implementation of the const function in QMapNode is also bogus: it
discards a const qualifier.
Task-number: QTBUG-39301
Change-Id: Ib8fd10a4da4b58a62cef17017ea6127c4d964325
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
QRasterPaintEngine::alphaPenBlt makes the assumption that a device with
bit depth 32 has optimized alphamapBlit and alphaRGBBlit routines.
This will fail on RGBA8888 format resulting in some text not being
rendered.
Change-Id: Ia7d88bb0e3094894affceda1acc42396b67b3677
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
We don't use it and it was never documented. Search engine hits
only point to this occurrence in the Qt sources.
Change-Id: I2dd7adc5438893560daf01ac85620d9f9c028982
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Note added in QNetworkReply and QSslSocket documentation.
Task-number: QTBUG-16770
Change-Id: I2dd8cfb913ec29a96b5465a905cd213713b8d537
Reviewed-by: Richard J. Moore <rich@kde.org>
This change improves the synced resizes of xcb windows and adds support
for synced resizes of glx windows.
The QXcbWindow keeps a better track on whether the window manager
expects a sync and can be in one of three states:
* no sync required
* sync required, but configure notify event not yet received
* sync required and configured
By tracking this in the QXcbWindow itself the backing store can make
use of this information and doesn't need an own heuristic to decide
whether a sync is needed.
Also this allows to add support for synced resizes of windows with an
OpenGLSurface. This is accomplished by checking the sync state after
swapping buffers. As the OpenGL context may be bound to a background
thread the sync is done using a QueuedConnection to ensure that the
sync happens in the thread which created the xcb window.
So far this is only added for GLX.
This significantly improves the resize experience of QQuickWindow and
also the initial mapping with a composited window manager in case the
compositor uses the sync protocol to determine whether the window is
ready to get painted on screen.
Change-Id: Ied0261873043d785dec652d2821fc3638292fa36
Reviewed-by: Uli Schlachter <psychon@znc.in>
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
If the call to SQLNumResultCols fails for whatever reason then it will
not be correctly caught since the count might be higher than 0 since it is
uninitalized. This ensures that if it fails then it does not try to act as
if it succeeded.
Task-number: QTBUG-39137
Change-Id: Ifae8c1f7fac8416643f2317747f87295642a7935
Reviewed-by: Mark Brand <mabrand@mabrand.nl>