Replace all xlib calls with xcb equivalents, leaving only the
absolutely required xlib calls. Handle WM_DELETE_WINDOW so that
closing the window exits the app as expected. Finally, introduce
EGLFS_X11_FULLSCREEN to enable requesting a fullscreen native window.
Change-Id: I8c46ae832d38549ec7d673592f400a4f34bf4314
Reviewed-by: Andy Nichols <andy.nichols@digia.com>
With XCB a client cannot retrieve the information on which X screen it
is running. This information is only available when opening the xcb
connection. As this is done by Qt no application is able to retrieve
this information. By exporting the x11 screen we can provide this
information again in QtX11Extras.
Change-Id: I50f1d3e803dc7e3afac0e5c7f1648ccda4502e7c
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Adds combobox to select CUPS Page Set option (even/odd pages) into the
Unix print dialog
[ChangeLog][QtPrintSupport][QPrintDialog] Added support for setting CUPS
Page Set (even/odd pages only) in the print dialog.
Change-Id: I27dd846f58c164039fe2759064aafdf726a1287e
Reviewed-by: John Layt <jlayt@kde.org>
Similar to commit 8b062418 (MetaType: Fix operator{+,-}(int)
with the type-erased const_iterators., 2013-09-11), explicitly
create a copy of the iterator and intialise it.
Change-Id: I8b9edef40ca00c826f72768cba4a0992e55371f8
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
root(), leftNode() and rightNode() can be nullptr.
These pieces of code happened to work because the first thing lowerBound()
does is
Node *n = this;
// ...
while (n)
// ...
But that is _after_ dereferencing nullptr, which is undefined behavior.
So, check first, then deref.
This is the completion of I9137bf6e21014cd68404a7e49a748910b1d768cf:
all uses of root(), leftNode() and rightNode() have now been manually checked.
Change-Id: I3fcb958af9362104f94d6eea9c62da2ae07f1d5e
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
root(), leftNode() and rightNode() can be nullptr.
These pieces of code happened to work because the first thing lowerBound()
does is
Node *n = this;
// ...
while (n)
// ...
But that is _after_ dereferencing nullptr, which is undefined behavior.
So, check first, then deref.
Change-Id: I9137bf6e21014cd68404a7e49a748910b1d768cf
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
While at it, I hope that qplatformtheme API's are stable
by now :)
Change-Id: I83bf3118c91608710bb19380458e8f55cb3d427b
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Both Clang and ICC complain about the use of those atomics when used
with a forward-declared pointee. GCC doesn't, which makes me think
it's a GCC bug.
When using QBasicAtomicPointer<Foo> with these atomics, the _q_value
member causes the instantiation of QAtomicOps<Foo>, which causes the
instantiation of the regular member function
QAtomicOps<Foo>::fetchAndAddRelaxed. The problem is that function
takes a QAtomicAdditiveType<Foo>::AdditiveT as parameter, which
requires sizeof(Foo). Clang 3.3 and ICC 14 correctly expand and
complain. GCC 4.7-4.9 apparently don't.
The fix is to apply the same trick we used for the other atomics:
change all ops functions (including fetchAndAddRelaxed) to be member
templates. That way, they can't be expanded until the actual use.
Clang errors:
qgenericatomic.h:73:33: error: invalid application of 'sizeof' to an incomplete type 'QMutexData'
qatomic_gcc.h:136:48: note: in instantiation of template class 'QAtomicAdditiveType<QMutexData *>' requested here
qbasicatomic.h:272:22: note: in instantiation of template class 'QAtomicOps<QMutexData *>' requested here
ICC errors:
qgenericatomic.h(73): error: incomplete type is not allowed
detected during:
instantiation of class "QAtomicAdditiveType<T *> [with T=QMutexData]" at line 111 of "qatomic_cxx11.h"
instantiation of class "QAtomicOps<T> [with T=QMutexData *]" at line 272 of "qbasicatomic.h"
Found-by: Tor Arne
Change-Id: I9b10648cd47109a943b34a4c9926d77cd0c4fe12
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Clang 3.3 found a variable assigned to itself, probably to cause
GCC to shut up about a variable set-but-unused. So simply stop
assigning the value at all to this variable.
qxcbxsettings.cpp:155:16: error: explicitly assigning a variable of type 'uint' (aka 'unsigned int') to itself [-Werror,-Wself-assign]
Change-Id: I74ae8f724e87c1b3f6b9d358e13d6a440ff4a3e1
Reviewed-by: Uli Schlachter <psychon@znc.in>
Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
Remove the extern prototype as it's now defined in latest
firmware headers correctly. Moreover, the signature of the function
changed. This patch fixes both issues.
Change-Id: I0114b436dbaf5a171e6429a1e3760e292c7152cf
Reviewed-by: Andy Nichols <andy.nichols@digia.com>
Up to now, it was only possible to connect to functors in a direct
way, without being capable of using Qt::ConnectionType. This patch
allows for specifying a receiver for Functors and function
pointers, hence making it possible to specify effectively the
connection type.
To do this properly, it was needed to add an enum in FunctionPointer
representing whether the considered function is a member function
or not, to reduce ambiguity upon overloaded calls.
Moreover, now senders are checked for the existence of a slot obj
as well. This way, should the context be freed, the slot obj and
the functor contained in it will be freed as well.
On a side note, connecting to a static slot
(like QCoreApplication::quit) specifying the receiver object is
now compiling.
Change-Id: I46474099413b1dc6ca4db9934191d469baeef070
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
We don't have CoreServices on iOS, which hosts the UC* APIs.
Change-Id: I95b1b173e57665c2fc2cdc1701f8ad57cdc0e567
Reviewed-by: James Turner <james.turner@kdab.com>
Reviewed-by: Aleix Pol Gonzalez <aleixpol@kde.org>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
As used by the upcoming iPhone 5S' A7 SoC.
Change-Id: I276dc739c2565bce23fb1a12c9470dcd311e67ba
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
QPlatformFontDatabase::registerFont() method must be used instead.
Change-Id: I80aa5567a748a980f689c90125f8bcc20c304ee2
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
For easy cross-platform and cross-device UIs, automatic asset swapping
based on filename is being developed. This API provides the logic for
the swapping, so that applications can use it themselves with the same
logic as any automatic swapping done in application templates.
Selector set is initially minimal, aiming for just platform selection
and enabling a common selection mechanism for Qt platforms to use.
Change-Id: I219517d740fa7385e923a9e09cb7e241378f857a
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Currently, qdoc reports duplicate pages, when it should be reporting
duplicate page titles. Sometimes the duplicate titles actually refer
to the same page, but often they are different pages with the same
title. This update changes the error message to better indicate that
two identical page titles were seen.
A further complication was that the qdoc warnings for these duplate
page title errors were useless when the duplicates were in different Qt5
modules, because the support for file location information in the qdoc
index files was inadequate. This update adds better location information
to each section in the index file. This makes the index files bigger
and will increase qdoc runtimes, hopefully not too much.
Task-number: QTBUG-33506
Change-Id: I35db3c5e1551b9ef748d63377e94453da80c1e26
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
The responsibility of sendWindowSystemEvents() is to process events from
the window system. Historially that logic was part of the QPA/QWS event
dispatcher, which naturally also sent posted events. Through refactoring,
the code at some point ended up in in the QWindowSystemInterface class,
still with the posting of events in place.
This resulted in QPA event dispatchers adopting a pattern of just calling
sendWindowSystemEvents(), as that would cover both posted and window system
events. Other event dispatchers would call sendWindowSystemEvents(), and
then use a base-class implementation from QtCore for processing events,
resulting in two calls to QCoreApplication::sendPostedEvents() per
iteration of processEvents(). This breaks the contract that processEvents
will only process posted events that has been queued up until then.
We fix this entanglement by removing the sendPostedEvents() call from
QWindowSystemInterface::sendWindowSystemEvents() and move it to the
respective event dispatchers. For some EDs it means an explicit call
to sendPostedEvents, while others were already doing sendPostedEvents
though a separate source (GLib), or using a base-class (UNIX/BB), and
did not need an extra call.
We still keep the ordering of the original sendWindowSystemEvents()
function of first sending posted events, and then processing any
window system events.
Task-number: QTBUG-33485
Change-Id: I8b069e76cea1f37875e72a034c11d09bf3fe166a
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
QPlatformBackingStore::endPaint does not take a QRegion parameter.
6ce6b8a378 set the API, but the
platform implementations were not all synced up since then. There
was anyway no point in overriding beginPaint and endPaint on
platforms which don't need to do anything there. This fixes
clang warnings of the form
QXcbBackingStore::endPaint hides overloaded virtual function
Change-Id: Id6cd0fc2c831a34576ac2c73eeb0d5741d26e622
Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
That is what we do on on other "limited" platforms.
Change-Id: I608880698d60ab10ecbb2f3ce12ff6c5eaab7eed
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@digia.com>
Reviewed-by: Andrew Knight <andrew.knight@digia.com>
Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
This also fixes it in case of hidden or system files, which
were missing from the filter (found by Denis Kovalskiy).
Change-Id: Ic12de12ec51c20de52d040514e90be5e783add43
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The accessible plugins directory contains a QtQuick plugin
as well as a widgets plugin. We need to specify the correct
one to avoid all widgets applications implicitly depending
on QtQuick on Android.
Change-Id: I72b2ee4fcd2d7914fc2ed7996f504ce2df79842d
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
This was broken in 7ac6ce21 which removed some unused functions;
but MSVC2008 in debug mode requires this particular operator overload.
I'm re-adding it in an appropriate #ifdef so it doesn't cause "unused"
warnings in other platforms/compilers.
Task-number: QTBUG-33473
Change-Id: I6dfba0fa5f835e848e8a1e4213efb030fb5def3d
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
sqlite cannot be supported as Windows phone is
missing the needed memory mapping functionality.
Change-Id: I20e89292b9c7802c7402e8095854b72a9f21e614
Reviewed-by: Andrew Knight <andrew.knight@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@digia.com>
The user needs to specify the DEPLOYMENT variable. The syntax
is the same as previously used for DEPLOYMENT. For more info
please refer to the qmake documentation. The change adds
a new itemgroup, "Deployment Files". All files in this
itemgroup are marked as DeploymentContent and are then
packaged with the application either as XAP or the WinRT
specific file format.
Change-Id: Icf85887287c1c97eb782704340eaa3f8dde6719e
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
In order to be able to use the linker's /WINMD
and /WINMDFILE options
Change-Id: I2673e20aa073c6b807e8c9f191fd408c7976efc4
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
The change adds a new ItemGroup with a single library reference:
platform.winmd.
Change-Id: I0c7f4c46654b520afb79b6c6f49b5f2d1af400d3
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
It's a generic way to configure the Visual Studio Solution
architecture. It's added to support different project
architectures, ARM specifically. It may be a good idea
to replace the Win32 and x64 with VCPROJ_ARCH=Win32
and VCPROJ_ARCH=x64 defined in corresponding qmakespecs.
Change-Id: I9b23f7393bf248a629c425187d6dd8859092c45c
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
qmakespec for either WinRT or WinPhone have to specify
QMAKE_PLATFORM with winrt and/or winphone.
Change-Id: I87e0063881e6edd65de14adb006949247ce49904
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
After a bit of discussion, we should actually deprecate qBinaryFind too.
This puts the old code back (to avoid behavior changes / source
breaks).
This reverts commit 23d7f6ee5d.
Task-number: QTBUG-33473
Change-Id: I7f7d25171e14061e51543c501c30a7b6b184a8fd
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Q_STATIC_ASSERT gives better error with C++11 enabled.
Aslo the qt_check_for_QOBJECT_macro had warning on some compiler since
it used null reference
Change-Id: Ic6115da800064b00c50a5762f0b79f5f656bf750
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
On 64-bit platforms, with unaligned loads, this is defintely an
improvement since we can run fewer instructions. On 32-bit platforms
with unaligned loads, we'll do the exact same number of loads. On
platforms without unaligned loads, it's no worse.
Change-Id: Idd5dd5213975d77bbc3adf486adbf6f8ef071341
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
For platforms where the CPU can do unaligned loads on its own, like
x86, the compiler will generate actual loads. On other CPUs, it will
do the byte-by-byte load like we were doing. The compiler cannot
generate worse code than our hand-rolled load, so this change can only
improve performance.
Change-Id: I32a89e64aa64d8af504be6c5a10b04d7573cdb98
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Change storing the spec from QDateTimePrivate::Spec to Qt::TimeSpec.
Remove the storage and use of the Daylight Status as it is almost
never set or used, and would be inaccurate if the tz were to change.
It will be replaced later with proper daylight transition support.
This simplifies the code and makes the msecs storage change easier.
Change-Id: I78a70905025d7eddf1c2dc6001f6b490e5a2b3b8
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
A number of QDateTime functions directly use or modify the data stored
in the private, but future changes to store msecs and status make this
maintenance more complicated. Where possible simplify this code to use
the standard msecs functions, standard constructors, or public api
instead. This greatly simplifies the functions and the following msecs
storage code changes.
This is an intermim step towards storing the time in msecs. Some
functions will be slower as a result of this change, optimization
will take place after all the msecs changes are completed.
Note this also removes a test that used valid QDates outside the range
of msecs, this change in behavior will be documented in the final
mscs change.
Change-Id: I6ef710f24babc7024091010064082e9be0b5bbfe
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
WinRT passes the executable and Appx server info to the CRT main, and
supports several additional activation arguments as well. This handles the
arguments passed to main as well as the case where a modern app is
launched from an external application (e.g. Qt Creator).
Task-number: QTBUG-30198
Change-Id: Ia843e98c7843d5705f5f6d1c809de0b6bcdb5d26
Done-with: Kamil Trzcinski
Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
Test the Daylight Time transitions. QDateTime does not correctly deal
with many of these scenarios so those tests are marked as QEXPECTFAIL.
These bugs will be progressively addressed in coming commits.
Change-Id: I01eba9d6143a792f081542cb198e221efcf28e98
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>