Commit Graph

1719 Commits

Author SHA1 Message Date
Laszlo Agocs
3c2aea92cf Destroy generic plugins on exit.
Change-Id: I9037cabae74f9a7d8743630d0f530aaa1593266f
Reviewed-by: Paul Olav Tvete <paul.tvete@nokia.com>
2011-10-19 08:52:05 +02:00
Jason McDonald
8f02339e76 Remove DEPENDS_ON from qtestlib API.
The DEPENDS_ON macro didn't do anything and has misled many users to
think that they can write test functions that depend on other test
functions.

Task-number: QTBUG-21851
Change-Id: Ibe65b2d5d88bb81b6a0ebbe0b220f7d409a1446c
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2011-10-19 07:24:13 +02:00
Jason McDonald
ae1810658b Move QTRY_VERIFY/QTRY_COMPARE into testlib.
These functions have lived in tests/shared/util.h for a long time, but
they really belong in qtestlib.

Change-Id: I60d569d002dea220b51563931d8b7aa77a20b98b
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2011-10-19 07:23:44 +02:00
Jason McDonald
757b0529c4 Remove QTEST_NOOP_MAIN from qtestlib API.
This macro is no longer used in Qt's tests and encourages writing tests
in a way that makes test reporting less accurate -- remove it to prevent
further misuse.  If a test can be determined at compile-time to be
inapplicable, it should be omitted from the build via .pro file logic.
If that is not possible (e.g. there is no suitable qmake variable), the
test's initTestCase() function should call QSKIP to skip the entire test
with a meaningful explanation.

Task-number: QTBUG-21851
Change-Id: Icacc8c5567a700191b6ef3fa94ee52ede94c5b34
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2011-10-19 05:56:55 +02:00
alex
cd7623c19f Remove Sensors and Location related macros/defines from qglobal.h.
This reduces interdependencies between QtCore and other modules.
Individual modules handle this by themselves.

Change-Id: I82cb96326b8ccb0b6acb88d899ed811f80f47ec1
Reviewed-by: Lincoln Ramsay <lincoln.ramsay@nokia.com>
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2011-10-19 04:31:08 +02:00
Morten Sorvig
946805f07f Cocoa: Add initial accessibility implementation.
See qcocoaaccessiblity.h for details.

For now only the first level of the hierarchy is
made accessible.

Also add tools/accessibilityinspector which is an
utility for inspecting and debugging the Qt
accessibility tree.

Change-Id: Iff520bec26b3761feb0c2e00471feb379daaa735
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
2011-10-19 03:04:40 +02:00
Friedemann Kleint
b419e567c0 Windows platform: Improve Open GL.
- Pass on version to ARB.
- Query obtained ARB format more fine-grained depending on version,
  indicate failures
- Fix GDI contexts and introduce gl=gdi to activate the GDI
  functionality
- Adapt window flags after setParent if top level state changes
- Remove unused OpenGL flag from integration/context

Change-Id: I59ca74ee1fa727bd2bcfd605b3907bc82cca18fa
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2011-10-18 15:47:49 +02:00
Friedemann Kleint
08e2485860 QSurfaceFormat: Use version in comparison and debug, fix setter.
Change-Id: Id123ca9366b97a172e08a4608ccdffafb7caaf09
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-18 15:47:49 +02:00
Lars Knoll
36eb5fb732 Make some more methods private
Change-Id: I0644ee287201866596dccd96e443e7e62fd89360
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-18 14:15:54 +02:00
Konstantin Ritt
74110936f0 make fromWCharArray() and toWCharArray() inlined
because we may have the size of wchar_t varying,
we need to know which is the correct encoding: UTF-16 or UCS-4

Merge-request: 49
Change-Id: Ib5a1e7dea51d0cd8394e686634a36aae984fa072
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2011-10-18 14:15:50 +02:00
Lars Knoll
044770f9b0 Move QShortcutMap to QtGui
QShortcut stays in QtWidgets, what we need in QtGui
is only the basic functionality of the shortcut map.
QML can integrate directly with the map where required.

Change-Id: Ie39e9242f24cbebf824e5c3d2926880325ea4187
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-18 14:15:39 +02:00
Lars Knoll
5d4756fc1b Move the widget dependent code away from the shortcutmap
qshortcut.cpp now has the honour of hosting the code that
detects whether the a given shortcutcontext is actually
valid.

Change-Id: I59d299bbd2fd62fca074a51d96e85b81a50ae73c
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-18 14:15:35 +02:00
Laszlo Agocs
12e471b7fd Do not call swapBuffers when surfaceHandle is NULL.
Calling swapBuffers with the surfaceHandle of 0 returned by QWindow
during application exit causes a crash when using GLX. The patch
avoids swapBuffer calls to platformGLContext when there is no surface
handle anymore.

Change-Id: I09c5bbafd4e7af6648ca54a58ed0267d0a2f343d
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-18 14:09:16 +02:00
Casper van Donderen
0e341948ae Remove stale documentation.
Change-Id: I85139e0334b648bee0d18129cef9387dcc6c3222
Reviewed-by: Jerome Pasion <jerome.pasion@nokia.com>
2011-10-18 10:26:39 +02:00
Friedemann Kleint
41b01096cc Remove Q_WS_ in text codecs.
Change-Id: Id27d82f91a21107f31f73d7f2920629a512dc2a1
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
2011-10-18 08:21:33 +02:00
Friedemann Kleint
da68749fdb OpenGL: Remove Q_WS_ defines.
Change-Id: I351a910968ff7f46550af5b3742959cb0cab540d
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-18 08:21:19 +02:00
Jocelyn Turcotte
4ab691ad65 Fix TouchEnd events not being received on Harmattan.
TouchEnd is sent when all the touch points have a TouchPointReleased state,
and we would clear all touch points on finger release before sending them
up the stack.

Change-Id: I14e7347090ce9a1865743202f6926ae2fc035bd3
Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>
2011-10-17 18:03:13 +02:00
Jocelyn Turcotte
4521e2ec61 Add multipoint touch support for Harmattan to the xcb platform plugin.
Proper multipoint touch support was only introduced in XInput2.1, but Harmattan uses
a tweaked version of XInput2.0 that transfers touch data through mouse events.

This patch applies on the xcb plugin a subset of the changes that were applied on the
Qt 4.7 that was shipped to Harmattan to get similar multipoint touch support.

Change-Id: Ifda7ad40de29d7ded1443d4f78b3ec3807303a9f
Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>
2011-10-17 18:03:13 +02:00
Jocelyn Turcotte
09cad13e49 Fix TouchPoint::lastPos() after TouchPointStationary only events.
lastPos is copied from the last point's position, and the position has
to be resolved according the the receiving item's transformation.

However, if a QTouchEvent contains only stationary points, it won't be
delivered, it's pos()/rect() will still be uninitialized, and the
touch point of the next event will be delivered with the uninitialized
pos() as it's lastPos().

This patch makes sure that the lastPos() won't be filled with a
previous incomplete stationary point state even if the platform is
sending us stationary-point-only touch events.

Change-Id: Ia7d10423c8fbe78348edbb0a89fbfa66d1b8b5d1
Reviewed-by: Denis Dzyubenko <denis.dzyubenko@nokia.com>
2011-10-17 18:03:13 +02:00
Simon Hausmann
fa607d6272 Fix scaled text rendering with the raster paint engine & FreeType
Before commit 070d9c00c4, the raster paint engine used
to call loadGlyphs() on the FT engine, which ensures that the glyphs are loaded
and (more importantly) that the correct transformation matrix is applied on the
freetype face. After commit 070d9c0 lockedAlphaMapForGlyph is called for each glyph,
which unfortunately doesn't respect the provided transformation matrix. Therefore
when drawing scaled text, it was never actually scaled.

This patch applies the combination of the fontengine transform and the requested
transform on the freetype face actually used, similarly to loadGlyphs.

Change-Id: I0956a9e71784582db6bb90475a001a63800773f4
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
2011-10-17 16:04:33 +02:00
Casper van Donderen
c3b7a0291d Use a QFunctionPointer for getProcAddress()
qdoc does not understand the void (*) syntax, there is a typedef to
QFunctionPointer that does work.

Change-Id: Idbe9d43d00f8676304d088d72795b6ddb7e4ee72
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-17 13:31:45 +02:00
Friedemann Kleint
bf96c83b15 Replace Q_WS_WIN by Q_OS_WIN in uic/network.
Change-Id: I592936859f6932fcd1aa47f0617ba9f8efee86dc
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2011-10-17 13:31:45 +02:00
Laszlo Agocs
5d8d7b1dbc Add a warning and a return value to xcb's createGLPlatformContext
There was no value returned previously when none of GLX, EGL, DRI was
enabled. Now we show a warning message and return null (resulting in a
crash). Previously not returning a value resulted in obscure crashes
with strange-looking call stacks, now it will be clear what the
problem is.

This is particularly important because not having libx11-xcb-dev
installed results in silently disabled xlib support which in turn
disallows the usage of glx too. The result is an obscure crash in any
GL (e.g. QML2) app. Now there will be a proper warning message at
least.

Change-Id: I15cf3a6c16ca373d4ada7abb6d3c8f7e30c1e03d
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-17 10:29:57 +02:00
Laszlo Agocs
86ea95259d Do not fail user time window creation when xcb is using xlib
QXcbWindow::updateNetWmUserTime() creates a new window using the
actual window as its parent. This operation was failing when Xlib
usage and GLX (or EGL) was enabled because in these cases the real
window was created with a different visual using XCreateWindow.

For the user time window however we were passing the xcb_screen's
root_visual always, and this cannot work when Xlib+GLX/EGL is in use,
resulting in a BAD_MATCH (followed by some annoying flicker on the
screen on Ubuntu at least, or a full log off (X crash?) on Fedora).

The patch saves the visual id used to create the actual window and
passes that when creating the user time window. This way the creation
of the user time window succeeds with Xlib+GLX too.

Change-Id: If3925d9ac1670d385dcc7c2b475c196908569f06
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-17 10:28:25 +02:00
Lars Knoll
5ad123c136 Less friends is good, at least for C++ code :)
Change-Id: Ia46359ee80eb30b8e16a02b7d5376cc9610fac84
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-17 01:57:26 +02:00
Martin Petersson
e07d7ab265 QHttpNetworkConnection: fix compile warning
Change-Id: I05f114dcb1c43a98c416d02b3e764dcb40d56e09
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
2011-10-14 23:40:08 +02:00
Eskil Abrahamsen Blomfeldt
23e5594735 Add QGlyphRun::SplitLigature flag
If the glyph run is generated based on characters which split a
ligature glyph, it needs to include the ligature glyph in the run,
and when painting, we need to clip the painter to the reported
bounding rect of the run in order to avoid painting too much of
the ligature. To make it possible to reduce clipping to a
minimum, we need a flag to inform of whether the glyph run contains
a split ligature or not.

Change-Id: Id787e0bec6d6e8e06cc818700ae0fca22cf81e98
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
2011-10-14 23:39:46 +02:00
Harald Fernengel
b2a45e02a2 Disable ELF interpreter check when cross-compiling
It's not a good idea to look at the host's /bin/ls when cross-compiling

Change-Id: I1fe67b17abd92f01c1d89146227c5419eaa3242f
Reviewed-by: Arvid Picciani <arvid.picciani@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2011-10-14 21:21:28 +02:00
Laszlo Agocs
b091ec9a22 Avoid using 0 as the default winId in QPlatformWindow.
When the platform plugin does not reimplement QPlatformWindow::winId()
to return a non-zero value, the default implementation provides a WId
of 0. This breaks various scenarios with QWidgets which, for example
in nativeParentWidget(), rely on internalWinId() being non-zero for
TLWs.

As a result, apps like collidingmice will crash with the 'minimal'
platform plugin when they try to do markDirtyOnScreen for the graphics
view's viewport widget because viewport()->nativeParentWidget()
unexpectedly returns null, even though it should return the
QGraphicsView.

The patch makes the default value WId(1) in order to to avoid this.

Change-Id: Iafef2e510e32b5610b8cef742313e9119ed64963
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-14 19:42:26 +02:00
Laszlo Agocs
be1e6d17b9 Make the window active in eglfs and minimal plaform plugins.
Without a call to QWindowSystemInterface::handleWindowActivated() or
QPlatformWindow::requestWindowActivated() QGuiApplication's
activeWindow() and focusWindow() will return 0 all the time, and this
breaks key event delivery when key events are received not from a
windowing system but directly from e.g. evdev. In such cases the only
choice is to send the event to the active window but if there isn't
one the event will be lost.

These platforms will have one fullscreen window at a time so marking
it the active one should be a safe assumption.

Change-Id: Ia6f0e9f021fbd61bbd368ddc46f8a13fccda1c2f
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-14 19:42:17 +02:00
Lars Knoll
cfb2f5fdd1 Remove commented out reference to QShortcutMap
Change-Id: I62ca413c4f5e11e5ba91dcbb05d8088ca1d7a2b9
Reviewed-on: http://codereview.qt-project.org/6582
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-14 16:22:00 +02:00
Lars Knoll
046740f5ce Remove dependencies of QShortcutMap onto widgets
This is the first towards bringing shortcut support
back into QtGui.

Change-Id: Ic2cf376d08c326402fb90a0cf170a987b07ac304
Reviewed-on: http://codereview.qt-project.org/6577
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-14 13:13:01 +02:00
Frederik Gladhorn
736b3a6aca Accessibility plugin for mac and xcb.
Instead of creating new instances of the class whenever
accessibility() is called, create one on startup.

Change-Id: Idd5b06ee935d7acf4934b98882d254a1ef0ca04e
Reviewed-on: http://codereview.qt-project.org/6435
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
2011-10-14 11:41:16 +02:00
Jocelyn Turcotte
bb22b49650 Fix OpenGL on Harmattan showing only the first frame.
swapBuffers would wait until DRI2_InvalidateBuffers was received from the
X server, but would never receive it since we are not running the xlib event loop.

This patch calls the XESetWireToEvent xlib callback of an unhandled event from the
xcb event loop directly, if one is available for its response type.

Change-Id: I3b4ef3f6e3efbae25f49f161e229e9b15e951778
Reviewed-on: http://codereview.qt-project.org/6557
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-14 00:25:20 +02:00
Laszlo Agocs
472028c1d4 Calculate an area in the touchscreen qpa plugin.
Instead of ignoring the touch major/minor and returning a rectangle
with width and height of 1, the size of the area is now calculated
based on the major. This is incomplete and far from perfect but at
least it makes visualizers, like the fingerpaint example app, work out
of the box.

Change-Id: I3bb70b4d7247f289e5cae4e7de2460ecf2c9d009
Reviewed-on: http://codereview.qt-project.org/6566
Reviewed-by: Paul Olav Tvete <paul.tvete@nokia.com>
2011-10-13 17:36:01 +02:00
Friedemann Kleint
1582407fc7 Remove Q_WS_ and Q_OS_SYMBIAN from QtGui.
Change-Id: I2ac3376513c3fbfc81a2e695a73a0d948d2696bc
Reviewed-on: http://codereview.qt-project.org/6607
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-13 15:07:41 +02:00
Friedemann Kleint
30cb91e17d Fix struct/class mismatch.
Change-Id: I282c9d9e10b0783cc10d32de031a30d07b802a55
Reviewed-on: http://codereview.qt-project.org/6610
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2011-10-13 14:49:08 +02:00
Morten Sorvig
8346c192ad Cocoa: Update QPlatformWindow geometry on move
Change-Id: I976e4da646480d10cc6af444288c421d0645f689
Reviewed-on: http://codereview.qt-project.org/6541
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
2011-10-13 12:57:22 +02:00
Laszlo Agocs
75246bbda7 Migrate the touchscreen generic qpa plugin to QWindow.
This plugin was still using QApplication and QDesktopWidget. The code
is now migrated to QGuiApplication, QWindow, and QScreen.

Change-Id: I22a7e15982efea16cbf560d09c8831cd82ed29d0
Reviewed-on: http://codereview.qt-project.org/6528
Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
2011-10-13 08:05:48 +02:00
Martin Petersson
2b58e3db35 QNetworkAccessManager: hostInfo lookup should use proxy if set
startHostInfoLookup will try to detect if IPv4 or IPv6 will be used
when connecting to the host. If a proxy is set we should lookup
the proxy hostname instead, in case host name can't be resolved
via DNS and should be resolved by the proxy.

Task-number: QTBUG-21889
Change-Id: I2012798784fc40f153469a1298e261c52981297e
Reviewed-on: http://codereview.qt-project.org/6447
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
2011-10-12 18:01:19 +02:00
Shane Kearns
82d897febf Fix construction races in QtNetwork
When two threads construct a QNetworkAccessManager at exactly the
same time on an SMP system, there are construction races for some
Q_GLOBAL_STATIC data. This is normal and expected - the losing
thread deletes its instance as part of the Q_GLOBAL_STATIC macro.

For QNetworkAccessBackendFactoryData, a guard mechanism intended
to prevent the data being reconstructed by destructors of other
global static classes was being set by the loser.
To fix this, the bool is changed to a QAtomicInt. In the normal
case, it will have value 0->1 on startup and 1->0 on shutdown.
In the race case, it will have values 0->1->2->1 on startup and
1->0 on shutdown.

Task-Number: QTBUG-20343

Change-Id: Ie3fe38944d10809d1ccdbe772df82d67faffe19c
Reviewed-on: http://codereview.qt-project.org/6181
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
2011-10-11 19:16:10 +02:00
Friedemann Kleint
32ec981745 Windows: Adapt to new Lighthouse API
- Implement debug/deprecated options of QSurfaceFormat
- Implement stylehints
- Fixed input context to position the input window correctly.

Change-Id: Icba22f183c6895e30bd34d60cf6d2307ed3188cd
Reviewed-on: http://codereview.qt-project.org/6446
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2011-10-11 17:38:34 +02:00
Joona Petrell
e941b37fcc Move input panel visibility ownership from QInputPanel to QPlatformInputContext
Now QInputPanel::visible() can be set true even when platform doesn't provide
a virtual keyboard. Like keyboard geometry, visibility should be dictated by
the platform plugin and not QInputPanel, whose role is more like that of a mediator.
QInputPanel::show() and ::hide() calls should be treated as requests that may fail.
Changed the QInputPanel's visible property to read-only as a setter that may
fail is not really a setter, show() and hide() should be used instead.

Enabling the new functionality cannot be activated immediatelly without breaking
existing keyboards, added a temporary function handlesInputPanelVisibility that
handovers the responsiblity of updating input panel visibility to QInputContextPlatform
only once QInputContextPlatform says that it is able to handle it.

Change-Id: Ideecaf7225cc3971f33a0ac976bd92cf7767475b
Reviewed-on: http://codereview.qt-project.org/6429
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Pekka Vuorela <pekka.ta.vuorela@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-10-11 16:03:25 +02:00
Casper van Donderen
0e6a401028 Remove stale documentation and fix qdoc errors.
Change-Id: I51bb0c52eb32d9d672d115f31b16d414f81708e2
Reviewed-on: http://codereview.qt-project.org/6433
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
2011-10-11 16:03:12 +02:00
Pekka Vuorela
bd34df230d QTextEdit - Fix selectionChange emission bug
QTextEdit did not emit selectionChange signal if selection
availability did not change, but the start or end of the selection did.
This was causing unit test to fail.

Change-Id: Iea0cb0bae767bc8d2dd36141362f9a084af97266
Reviewed-on: http://codereview.qt-project.org/6426
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-10-11 16:03:01 +02:00
Pekka Vuorela
76ca6642a9 Removed obsolete custom input context support
Removed from QWidgetPrivate and QWidgetTextControl. Now using only
application specific input context.

Change-Id: Id25882e72026f58dab51a18e5d04a11225429963
Reviewed-on: http://codereview.qt-project.org/6427
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-10-11 16:01:57 +02:00
Kent Hansen
e5ce564b1d Rename QMetaType::construct() to create()
create() is symmetric with destroy().

Also rename the internal methods and fields to be
consistent (qDeleteHelper already had the "right"
name, though!).

This change will allow us to use construct() and
destruct() for something else: Placement new-style
allocation (QTBUG-12574).

The old construct() is still kept for now, until
the other repositories have been updated to use
create().

Change-Id: Iceb184af6cffcb0a634359cfc3516c718ba0c2f5
Reviewed-on: http://codereview.qt-project.org/6342
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-10-11 16:01:45 +02:00
Jiang Jiang
612ac2b8c8 Don't crash when no usable font is available
We will fallback to box engine when no usable font is available,
and QRawFont (which scenegraph depends on) won't allocate glyph
index array on certain occasions. In those cases, QFontEngineBox
needs to support GlyphIndicesOnly flag.

Change-Id: I408ddd1b2f1a5f7ac2b6681cb7bf531bbbfc68e6
Reviewed-on: http://codereview.qt-project.org/6360
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
2011-10-11 16:01:12 +02:00
Kim Motoyoshi Kalland
93c8522dc3 Import symbol from QtGui rather than export from QtWidgets.
The symbol is exported in qguivariant.cpp.

Change-Id: I3ba3446251aa3ba9e901bd3e9c2157d8b22d9866
Reviewed-on: http://codereview.qt-project.org/6364
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-10-11 16:00:45 +02:00
Kent Hansen
7a4eec5dbb Fix typo in qfontengine_win
Task-number: QTBUG-20482

Change-Id: I3fd072af019a0e531d60a1751a6a32ea5962aac1
Reviewed-on: http://codereview.qt-project.org/6049
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
2011-10-11 16:00:17 +02:00
Lorn Potter
0cb7a66989 add qmetaobjectbuilder to qtbase.
Use the QMetaObjectBuilder code from declarative and add it to libQtCore.

    Consolidating various QMetaObjectBuilder implimentations to avoid
    code duplications in those modules.

    This is currently still a private API only.

Change-Id: Ie363b4fd769c41efbb3caa7fb1d6f77af13c3c9c
Reviewed-on: http://codereview.qt-project.org/6287
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Alex <alex.blasche@nokia.com>
2011-10-11 07:02:14 +02:00
Aaron Kennedy
27833629c6 Update V8
Change-Id: I359ec3f57a120ebd02d03c56d0944397b5407ed8
Reviewed-on: http://codereview.qt-project.org/6386
Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
Sanity-Review: Aaron Kennedy <aaron.kennedy@nokia.com>
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
2011-10-11 07:02:14 +02:00
Kent Hansen
ccbb3afe28 Remove duplicate check in qtextcontrol cursorMoveKeyEvent()
No reason to check for QKeySequence::MoveToPreviousLine twice.

Task-number: QTBUG-20482
Change-Id: Ib1504be33908fa7cbc27226060f94794c454681c
Reviewed-on: http://codereview.qt-project.org/6050
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
2011-10-11 00:42:17 +02:00
Friedemann Kleint
d5bf2f3314 QtBase: Move idc to Active Qt.
Remove include path to Active Qt from qt.prf.

Change-Id: I476152ce56e47b573f5c835ec1347e772c4e9c3e
Reviewed-on: http://codereview.qt-project.org/6355
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
2011-10-10 16:54:52 +02:00
Bradley T. Hughes
78470cd621 Make all uses of QBasicAtomicInt and Pointer use load() and store()
Change Ie3271abd1728af599f9ab17c6f4868e475f17bb6 didn't build on Mac in
debug mode. This commit fixes the build.

Change-Id: I925af83ea577228b60679af804aa7875a779ec3f
Reviewed-on: http://codereview.qt-project.org/6331
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-10-10 16:54:52 +02:00
Samuel Rødal
ac03f59ccc Removed src/gui/opengl/qopenglcolormap.*
The QGLColormap API was used by QGLWidget, not very relevant in the Qt 5
core API.

Change-Id: I3c75ac09cbc292e707aea62759c09277f834de8d
Reviewed-on: http://codereview.qt-project.org/6333
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-10-10 16:54:52 +02:00
Samuel Rødal
d45502c2aa Fixed some doc errors in QOpenGLFramebufferObject.
Change-Id: Ic132bc31f87900a492a80767aa247c71c48c4a10
Reviewed-on: http://codereview.qt-project.org/6334
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2011-10-10 16:54:52 +02:00
Samuel Rødal
0e611c34d7 Fixed missing snippets for QOpenGLShaderProgram.
Change-Id: Ie44edb3379f6fef4c4c8b69bb5e36fc19154ab26
Reviewed-on: http://codereview.qt-project.org/6332
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2011-10-10 16:54:52 +02:00
Christiaan Janssen
56921b1f88 QUnifiedTimer: Add callback for timer ticks. Used for profiling
Change-Id: Ia7cf823dee7f0b491db2f041d29cdfc0e385f18e
Reviewed-on: http://codereview.qt-project.org/6253
Reviewed-by: Kai Koehne <kai.koehne@nokia.com>
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-10 15:04:22 +02:00
Olli Werwolff
de6445272d Use freetype font engine on Windows
As windows' fontdatabases also uses functionalities from
qbasicunixfontdatabase it was renamed to qbasicfontdatabase. But instead
of iterating over the font directories' files it uses system calls to
obtain the list of fonts and uses registry values to find the according
filenames to add.
The native font engine was still kept. It can be activated by adding
fontengine=native as platformargument.

Change-Id: I7197bed5d18b8a33d4aa97ce91bfa1cd281b80ea
Reviewed-on: http://codereview.qt-project.org/5839
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
Sanity-Review: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
2011-10-10 13:17:44 +02:00
Jani Uusi-Rantala
c280fa59cb Easier shader debugging
- Dumps out also the source code of the failed shader if available

Change-Id: I9ae80e6a6749446c5ff54db1bc324cc7411a81a7
Signed-off-by: Jani Uusi-Rantala <jani.uusi-rantala@nokia.com>
Reviewed-on: http://codereview.qt-project.org/6269
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-10 13:17:44 +02:00
Jani Uusi-Rantala
38e4fa0a04 Enable using the new Qt::ScreenOrientation enum as flags
Going to be useful later on in multiple places...

- Respecified Qt::ScreenOrientation as bit values
- Added Qt::ScreenOrientations QFlags definitions

Change-Id: Ib7648d23de79ea5f88d617015bc98efcf903a8f3
Signed-off-by: Jani Uusi-Rantala <jani.uusi-rantala@nokia.com>
Reviewed-on: http://codereview.qt-project.org/6268
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-10 13:17:44 +02:00
Jani Uusi-Rantala
2374bf3915 Minor build fix for newer XCB versions
- Defines XCB_WM_STATE_WITHDRAWN as XCB_ICCCM_WM_STATE_WITHDRAWN if necessary

Change-Id: I4212a0e1d7f14ac6695d23d6586dd97f898d3f2b
Signed-off-by: Jani Uusi-Rantala <jani.uusi-rantala@nokia.com>
Reviewed-on: http://codereview.qt-project.org/6267
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
2011-10-10 10:35:03 +02:00
Morten Sorvig
9fa6e8f627 Clean-up a macro for Cocoa
Remove the usage of Q_MAC_USE_COCOA and Carbon code paths.

Change-Id: Ib569ad8c6d9ffe258f454b3c3b06e95294a10112
Reviewed-on: http://codereview.qt-project.org/5100
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
Sanity-Review: Morten Johan Sørvig <morten.sorvig@nokia.com>
2011-10-10 07:47:58 +02:00
Charles Yin
33233ca3e3 update QmlTest option usage help
Change-Id: I8ccd49bcaac126af2bad2382d481857f1e48c18b
Reviewed-on: http://codereview.qt-project.org/6274
Reviewed-by: Charles Yin <charles.yin@nokia.com>
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
2011-10-10 04:13:20 +02:00
Samuel Rødal
8ba313ee5a Make sure window state is synced back to Qt from the XCB plugin.
We should properly react to the property notify events.

Task-number: QTBUG-21856
Change-Id: I0d2aa90b7d8da3b96acf4d88684b0200de7d7413
Reviewed-on: http://codereview.qt-project.org/6266
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-10-07 22:27:13 +02:00
Samuel Rødal
c5006a6fe2 Fixed potential issue in XCB plugin.
Use the actual atom instead of the enum value of the atom when
signaling that the event loop should exit.

Change-Id: Ib98c6a46cadcecc727b28411b4c0c12c434ea828
Reviewed-on: http://codereview.qt-project.org/6265
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-10-07 22:25:33 +02:00
Samuel Rødal
c66b7cf55b Added Orientation API to QScreen and QWindow.
QScreen now has a primary and current orientation, and a QWindow can set
its orientation as well. The current screen orientation is just a hint
to the application.

Change-Id: I4635982cfac2d16634d4edd5c6ab78e9d0ac55a4
Reviewed-on: http://codereview.qt-project.org/5988
Reviewed-by: Paul Olav Tvete <paul.tvete@nokia.com>
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-10-07 22:23:30 +02:00
Simon Hausmann
090d825e1d Fix QMouse/Wheel/TouchEvent::modifiers with the XCB back-end
The modifiers are provided by X and need to be propagated through the
QWindowSystemInterface.

Change-Id: I127d0b6e9918b558ca15d9302c4cc0cbd94eb757
Reviewed-on: http://codereview.qt-project.org/6244
Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
Sanity-Review: Samuel Rødal <samuel.rodal@nokia.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
Sanity-Review: Qt Sanity Bot <qt_sanity_bot@ovi.com>
2011-10-07 18:27:53 +02:00
Samuel Rødal
b26442f485 Fixed crash due to uninitialized pointer in OpenGL texture glyph cache.
Change-Id: I384f82f1549a81e19566484e12c75ce8df1f314f
Reviewed-on: http://codereview.qt-project.org/6149
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
2011-10-07 12:13:34 +02:00
Kent Hansen
db6db2f9d4 qwindowsstyle: Remove duplicate flag in mask
Adding State_Sunken once should be enough for everyone.

Task-number: QTBUG-20482
Change-Id: Ic5c1bf47283d9c344eda41c766749d4106a8da67
Reviewed-on: http://codereview.qt-project.org/6051
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
2011-10-07 08:39:57 +02:00
Lincoln Ramsay
a7d80babb5 Don't default to XCB if it is not enabled.
Default to wayland unless it's not enabled.
Default to minimal otherwise.

Change-Id: I0fa523eae395821a7cb0cabbb27ca073e594246f
Reviewed-on: http://codereview.qt-project.org/5945
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2011-10-07 02:41:07 +02:00
Pierre Rossi
614b9efcf5 Fix QFont::defaultFamily() in the new QPA world.
This is so that the results of LayoutTests in WebKit are
more in line with what things were like in Qt 4.8.

Change-Id: I25962e03bd8e0316cb303c0d94c25ac4e73ea9a8
Reviewed-on: http://codereview.qt-project.org/6162
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
2011-10-07 00:43:26 +02:00
Thiago Macieira
028a860ac5 Fix the QNetworkConnectionManagerPrivate initialisation code.
The current code was meant to be a thread-safe initialisation that
also ran a couple of extra steps. But it wasn't. While it's ok to call
qAddPostRoutine(), the call to updateConfigurations() was
thread-unsafe. It is possible that another thread got the pointer to
the Private before updateConfigurations() finished.

So instead protect the initialisation with a mutex.

It's possible that the value of the pointer becomes visible to
other processors before the other contained values, so use
atomics here.

To call qAddPostRoutine safely from the main thread, use the trick
of deleteLater() (which is thread-safe) in another thread connecting
to a slot.

Change-Id: If9bab88138755df95a791f34b0be8684207979d7
Reviewed-on: http://codereview.qt-project.org/5028
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-10-06 22:45:14 +02:00
Pekka Vuorela
8fb15f3a75 Removed some dead code from QWidgetLineControl
There was a big processEvents() method which was actually getting
called for a single type of events.

Change-Id: I66ac70c7ac6e2f9136b24541d42a4185f8797583
Reviewed-on: http://codereview.qt-project.org/6132
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com>
2011-10-06 22:42:33 +02:00
Konstantin Ritt
2bf2bb3daf fix QChar::isSpace() to handle codepoint U+0085
according to the Unicode specs, code point U+0085 should be treated
like a white space character (an exceptional Cc one)

Change-Id: Ib17ae0c4d3cdafe667cafa38b645138ef24c238c
Merge-request: 32
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
Reviewed-on: http://codereview.qt-project.org/6158
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
2011-10-06 19:24:26 +02:00
Shane Kearns
df08cb7090 Fix incorrect QFileInfo permissions on windows
Requesting the write permission marked the read permission as known
without having retrieved it. A subsequent request for read permission
would return false.

Task-Number: QTBUG-20714
Reviewed-By: mread
(cherry picked from commit bf69c7e0af67ec877da4fee244386e538fa1c01d)

Change-Id: I74fd118fcdd3b222098eda2718823a36931424a1
Reviewed-on: http://codereview.qt-project.org/6159
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
2011-10-06 17:33:44 +02:00
Shane Kearns
0b67ad9db2 Merge fixes for QDir::operator==
There were two fixes in 4.8 which each fixed a part of the problem.
Comparing canonical paths is more correct, but is only possible where
both directories exist. If neither directory exists, then compare
absolute paths instead.
Changed a regression test, because /tmp is a symbolic link on MacOS.
I.E. "/tmp/.." is canonically "/private" and not "/" as expected.

Task-Number: QTBUG-20495
Reviewed-By: joao
(cherry-picked from ad35d25e78c8252a72108a4ba931934047c4707e)

Change-Id: Ia4986e8337f0e512e1a3398a5a4dd36e62680b9c
Reviewed-on: http://codereview.qt-project.org/5813
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
2011-10-06 17:32:57 +02:00
Pekka Vuorela
1189ebff32 Make QLineEdit unit test pass again
Widget failed to update cursor position if selection remained the same, but
changed direction, and did not emit selectionChanged if change resulted
from input method event.

Change-Id: I6a4ae48d41efa5e126980749f89982f92e3ec499
Reviewed-on: http://codereview.qt-project.org/6131
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-10-06 14:37:36 +02:00
Konstantin Ritt
bb1f50b7b1 QHostInfo: fix a race condition under CE
Merge-request: 1339
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>

Change-Id: Id1f977ad8f746ac848c355880cac688e256721d8
Reviewed-on: http://codereview.qt-project.org/6145
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2011-10-06 14:37:22 +02:00
João Abecasis
d3ef642614 Fix QDir::operator==(const QDir &) const
We can't rely on absolute paths when comparing directories for equality
as these don't take into account symbolic links and may also bypass ../
and ./ simplification.

Instead, canonical paths must be computed and can then be compared
according to the case sensitivity rules for the platform or file engine,
as is done in QFileInfo.

Task-number: QTBUG-20495
Reviewed-by: Prasanth Ullattil
(cherry-picked from dcee6e1371d899eb79717b8e3f3eec08b765db82)

Change-Id: Ib5f2a6ee11311c55782ea5dd0e9c3b45f9231686
Reviewed-on: http://codereview.qt-project.org/5812
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
2011-10-06 11:24:20 +02:00
Morten Sorvig
cdef653519 Compile on 10.6
Change-Id: Ifce1ab6ced179f68a3d08162940e9092b90beb11
Reviewed-on: http://codereview.qt-project.org/6124
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
2011-10-06 11:24:20 +02:00
Kent Hansen
11f80c022f Remove duplicate check in utf endian detection
This was excessive paranoia.

Task-number: QTBUG-20482
Change-Id: Ia0c76651773e12f25ec5d62675d6f317b8d2df13
Reviewed-on: http://codereview.qt-project.org/6045
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-10-06 11:24:20 +02:00
Kent Hansen
8f114af67b Fix typo in qbezier shift implementation
Multiplying by zero was not the intention.

Task-number: QTBUG-20482
Change-Id: I3c4dfd69da4d98ed65f318d1fa0c3cf827017688
Reviewed-on: http://codereview.qt-project.org/6048
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
2011-10-06 09:36:39 +02:00
Samuel Rødal
7d2cfbe5aa Improved logical and physical DPI APIs.
Made physicalSize() return QSizeF instead, to prevent rounding errors.
Added logicalSize() as the base to compute font pixel sizes instead, and
added convenience functions in QScreen to access the logical and
physical sizes and DPI metrics.

Task-number: QTBUG-21736
Task-number: QTBUG-21737
Change-Id: Ic705dc98eb3632617659e65a0c9a552673dc0c65
Reviewed-on: http://codereview.qt-project.org/5888
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2011-10-06 09:36:39 +02:00
Kent Hansen
29948e6665 Remove redundant assignment in QXmlStreamReader
Setting tos to 0 once should be enough for everyone.

Task-number: QTBUG-20482
Change-Id: I7aa46ff5d4ed8064e3fb2cebc3dfcaa4e73741f8
Reviewed-on: http://codereview.qt-project.org/6053
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com>
2011-10-06 09:36:39 +02:00
Martin Jones
083a30b1d6 Add QTest::keyRelease() accepting a Qt::Key value
Change-Id: Id7943820a71472ab1e3c81ea76701738d7600815
Reviewed-on: http://codereview.qt-project.org/6085
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Martin Jones <martin.jones@nokia.com>
2011-10-06 03:32:06 +02:00
Frederik Gladhorn
74448afd03 Use child/parent function in QAccessibleWidget and test.
This also uncovered a missing implementation of child for
dock widgets.

Change-Id: Iac4c5a51d4626769af11b277a9a345e1e31dc490
Reviewed-on: http://codereview.qt-project.org/5987
Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
2011-10-06 01:28:12 +02:00
Shane Kearns
aa52c26f09 QNAM - fix poor performance of HEAD request with authentication
QHttpNetworkReply was waiting for a body to be sent for 401 and 407
responses, whereas with a HTTP HEAD request, there will be no body.

This delayed the authentication signal until after the http channel
is closed by the server after a timeout. For example with the server
used for autotesting, the authentication signal is delayed 15 seconds.

When the server has a very long timeout, the authentication signal may
not be emitted at all.

Task-Number: QT-5304
Reviewed-By: Martin Petersson
(cherry picked from commit 8610ee14b8636641651a8ba6040cca16c4141ed6)

Change-Id: Ie4ce6c598df86ce59910f793fd5ae7c1ccf39f9d
Reviewed-on: http://codereview.qt-project.org/6032
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Martin Petersson <Martin.Petersson@nokia.com>
2011-10-05 18:25:09 +02:00
Friedemann Kleint
88ffab79cb QtGui: Add command line arguments to the platform plugin.
Set -platformargument foo[=bar] as a dynamic property
on the native interface.

Change-Id: Ica8b25478da0ce9508b90370f15812fd11ff5d13
Reviewed-on: http://codereview.qt-project.org/6031
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Oliver Wolff <oliver.wolff@nokia.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-05 18:25:09 +02:00
Bradley T. Hughes
a4a94544f2 Don't use implicit QAtomic* casts in QFreeList
Pair the _next.testAndSetRelease() call in QFreeList<T>::release() with
_next.loadAcquire(), to ensure that the update to the bucket
being released is properly fenced.

QFreeList<T>:next() does not need a release fence, only an acquire fence,
which is placed on the memory bucket address load.

Change-Id: Ib5b9d6ef6107f87aa8e3ea2dd3a7f9116c75da70
Reviewed-by: Thiago Macieira
Reviewed-on: http://codereview.qt-project.org/5802
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
2011-10-05 16:31:37 +02:00
Kent Hansen
0e339e2ef5 Fix boolean logic issues in qcoreapplication_win
Task-number: QTBUG-20482

Change-Id: Iadbde59953a86d5f74d68c7cdc36b7706525612c
Reviewed-on: http://codereview.qt-project.org/6046
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
2011-10-05 15:21:51 +02:00
Kent Hansen
31b89a8b31 Remove duplicate check for glDeleteProgram
It's already checked for earlier in the expression.

Task-number: QTBUG-20482
Change-Id: Iad7e8fa80aab98d47d90ecb0c497245450cdfa40
Reviewed-on: http://codereview.qt-project.org/6052
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-05 15:13:25 +02:00
Kent Hansen
5049cff496 Add missing Q_OBJECT macro to GoToStateTransition
The missing macro caused qFindChild() to return any
QAbstractTransition.

Task-number: QTBUG-21813
Change-Id: I80507aa86c8c32d7fa59a1b5ae551043f5f90315
Reviewed-on: http://codereview.qt-project.org/6044
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
2011-10-05 15:00:38 +02:00
Jiang Jiang
57c6f22858 Add font family alias resolving to QPA
By default it doesn't do anything special, but for fontconfig font db
it will do some tricks to convert alias like serif to actualy font
family names like Times.

Change-Id: I73058d187a5422e6f93bc1b728cecdc0250d5e1e
Reviewed-on: http://codereview.qt-project.org/5984
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>
2011-10-05 14:55:26 +02:00
Samuel Rødal
11070a090a Added QWindow::isActive() and focus in / out events.
Renamed QGuiApplication::activeWindow() to
QGuiApplication::focusWindow(), implemented QWindow::isActive() as a
style hint, and added focus in / out events.

Change-Id: I71866e76c5a817def3e17bcc20a4fc32081a0e7a
Reviewed-on: http://codereview.qt-project.org/5811
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
2011-10-05 12:49:29 +02:00
Zeno Albisser
c46f59fadf Cocoa: Fix a variable shadowing issue that caused a crash on mac
Change-Id: I2d5ceb9502c769b5a585cdc6f1053168dfadbf12
Reviewed-on: http://codereview.qt-project.org/6000
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>
2011-10-04 18:31:21 +02:00
Friedemann Kleint
b4855d33f0 Declarative: Fix linking of the testlib plugin (Windows).
qtdeclarative/src/imports/testlib uses the exported variable
QTest::printAvailableFunctions.

As it is a plugin, it has only QT_DLL defined and not QT_SHARED
and thus sees Q_TESTLIB_EXPORT=''.

Change-Id: I34646e920a812fb907b60e0c4c9399499d689a01
Reviewed-on: http://codereview.qt-project.org/5990
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Charles Yin <charles.yin@nokia.com>
2011-10-04 17:24:32 +02:00
Alexis Menard
de4c9b3e31 Implement showFullScreen, showNormal, and showMaximized/Minimized in QWindow.
The implementation was just missing to call the proper APIs.

Merge-request: 65
Change-Id: I52f7825360bf55d37762421562484af684bf2dc8
Reviewed-on: http://codereview.qt-project.org/5986
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-04 15:22:36 +02:00
Morten Sorvig
5066c914bd Cocoa: Add env variable for disabling foreground.
Setting QT_MAC_DISABLE_FOREGROUND_APPLICATION_TRANSFORM
prevents the process from having an dock icon and
taking focus.

Change-Id: Id127967d8ec1dadda790128f36a7c1f50d581433
Reviewed-on: http://codereview.qt-project.org/5968
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Zeno Albisser <zeno.albisser@nokia.com>
2011-10-04 13:29:13 +02:00
Simon Hausmann
4ebc83745d Fix compilation on Harmattan
Include Xlib.h for XInitThreads and add the SUPPORT_X11 macro
to DEFINES for Harmattan's EGL library.

Change-Id: I34ad284fe5b671f3924e406a18b8c5520df8346a
Reviewed-on: http://codereview.qt-project.org/5935
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-04 11:21:25 +02:00
Simon Hausmann
76a7f2048e Fix XCB back-end on Harmattan
Use RGB16 as image format on 16-bpp displays.

Based on patch by Jocelyn

Change-Id: Ic91ab33132769da59a2097abb43b64a2d09c0009
Reviewed-on: http://codereview.qt-project.org/5971
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-04 11:21:25 +02:00
Bradley T. Hughes
992a37234c Don't crash by modifying read-only shared_null
Functions that modify the d-pointer must detach or otherwise take
measures to not modify the const, read-only shared_null.

The setSharable(bool) function takes care to detach when setting
sharable to false, but should avoid setting the sharable data member
unless d is not the shared null.

Similarly, QMap<Key, T>::setInsertInOrder() needs to detach if it is
shared with the shared_null (the logic has been updated to be the same
as setSharable()).

Change-Id: Ida5cb9818b86695f1b9f0264418b955c56424898
Reviewed-on: http://codereview.qt-project.org/5929
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
2011-10-04 11:21:25 +02:00
Sergio Ahumada
22948130e8 testlib: Fix header guard files
Change-Id: Ia33423f9bd3f85259da908706d73cc2da4d8964d
Reviewed-on: http://codereview.qt-project.org/5937
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
2011-10-04 09:30:04 +02:00
Holger Hans Peter Freyther
68da915373 [fontdatabase] Use the CONFIG += qpa/genericunixfontdatabase
Late follow up of fc9a648dc0 that
tries to make plugins indifferent of where the source is located
in relation to qtbase.

Change-Id: I9a5944fe737056216c7174d8d9151c8d0e776a22
Merge-request: 64
Reviewed-on: http://codereview.qt-project.org/5933
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-03 17:25:57 +02:00
Simon Hausmann
5aaedccc43 Fix compilation on Harmattan
Improved fix from e327401743dba9112faca77fd764869709ae4367 to add the
necessary includes in the header file, where the types are also needed.
The same header file is also included from the xcb plugin.

Change-Id: I52a891be1ecc67d49a088a4db698270a06db6b54
Reviewed-on: http://codereview.qt-project.org/5932
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-03 17:25:57 +02:00
Simon Hausmann
ab247307af Fix compilation on Harmattan
The inclusion of qbearerengine_p.h requires network-private

Change-Id: Ie28136dc6ee423721978d073fd401fecde2a7d35
Reviewed-on: http://codereview.qt-project.org/5930
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-03 17:25:57 +02:00
Simon Hausmann
43c548d2a6 Fix compilation on Harmattan
Include X11 headers to get VisualID and other "types".

Change-Id: Idbb323329d346726b98312b1e02c9b199f2b7a65
Reviewed-on: http://codereview.qt-project.org/5928
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-03 15:31:42 +02:00
Sergio Ahumada
9557395c96 Fix ́́macros' function test of tst_headers'
Task-number: QTQAINFRA-324
Change-Id: I3202d9ee42de8174c5170f1b853884b19d5895e3
Reviewed-on: http://codereview.qt-project.org/5925
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-03 15:31:42 +02:00
Andreas Aardal Hanssen
e4207a79d1 Fix bug in QGraphicsItem::isVisibleTo().
Task-number: QTBUG-21612
Reviewed-by: James Perrett
Reviewed-by: Magne Pettersen Zachrisen

Change-Id: I570c673a817c3c01593fcd7fa46d545f34e2c38d
Merge-request: 1396
Reviewed-by: Jan-Arve Saether <jan-arve.saether@nokia.com>
Reviewed-on: http://codereview.qt-project.org/5927
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
2011-10-03 15:31:42 +02:00
Frederik Gladhorn
5ea2eab00d Simplify QAccessibleAbstractScrollArea and Calendar.
Change-Id: Iea1df37fd9fd486295458ec7627f5b6908053cdf
Reviewed-on: http://codereview.qt-project.org/5727
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
2011-10-03 15:31:42 +02:00
Morten Sorvig
9ac51af083 Cocoa: Send proper mouse coordinates.
Clear up coordinate system confusion. Also change
QApplicationPrivate::pickMouseReceiver to indicate
that, yes, it does modify the 3rd argument in
addition to returning the mouse receiver widget.

Change-Id: If2c44eff65aedfdc78c6da1728f31d6e2db71f9d
Reviewed-on: http://codereview.qt-project.org/5919
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@nokia.com>
2011-10-03 15:31:42 +02:00
Paul Olav Tvete
75a66c3d76 Moving wayland plugin to the qtwayland submodule
The wayland platform plugin now lives in its own Qt module, together with
the qtcompositor library.

Change-Id: I4e85292cf41da4ef021ea832545ac37f5ed4e991
Reviewed-on: http://codereview.qt-project.org/5836
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
Reviewed-by: Andy Nichols
2011-10-03 13:42:05 +02:00
Holger Hans Peter Freyther
598d37a2f0 qpixmap: Use the primaryScreen for QPixmap::defaultDepth
Currently tst_QPixmap::testMetrics can fail if the native
display resolution is below 32 bpp. Upate the documentation,
use the primary screen to find the depth.

Tested-on: XCB and directFB plugin.

Change-Id: I29c08db25d8f6bcee01f9315ed90685fef668e0c
Merge-request: 61
Reviewed-on: http://codereview.qt-project.org/5917
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-03 11:55:32 +02:00
Samuel Rødal
677cf76340 Prevent QPixmapCache potentially growing indefinitely.
QPixmapCache has until now refused to throw out shared pixmaps, i.e.
ones that still have shallow copies lying around. This leads to problems
when someone inserts two shallow copies using different keys, causing
the cache itself containing multiple shallow copies and thus forever
refusing to throw out those entries.

It's rather easy for this to accidentally happen in a user application
since QPixmap::load() or QPixmap(const QString &fileName, ...)
automatically cache the pixmap in the QPixmapCache, thus if the user
then calls QPixmapCache::insert() on the same pixmap or a shallow copy
it is locked in the QPixmapCache forever.

The only reason for not throwing out a pixmap that's shared would be to
prevent re-loading a pixmap from file when a user has a direct reference
to it in his application, but in that case the user is unlikely to
re-load the pixmap from file in any case. Therefore it seems the best
fix is to get rid of this limitation.

Task-number: QTBUG-21359
Reviewed-by: John Brooks
Reviewed-by: Olivier Goffart
(cherry picked from commit 7ab0bed3a56d46c386e65abc381264c57137cb43)

Change-Id: I46dce19227e19a25e0287cf7372177430da15a66
Reviewed-on: http://codereview.qt-project.org/4563
Reviewed-by: Paul Olav Tvete <paul.tvete@nokia.com>
2011-10-03 11:55:32 +02:00
Frederik Gladhorn
91ba742329 Rename description to localizedDescription in Action interface.
Change-Id: I9e15dabd47bb7dc27cb3748f6763789d8ccc7b42
Reviewed-on: http://codereview.qt-project.org/5622
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
2011-10-03 09:59:27 +02:00
Frederik Gladhorn
b67708f3d3 Use interfaces in QAccessibleWidget childAt.
Simplify the implementation of childAt.
Using rect(child) depends on the virtual children.

For QAccessibleMenuBar the implementation would assert.

Change-Id: I6ef018a063beee67d7436dff148e8b0219ff2a3c
Reviewed-on: http://codereview.qt-project.org/5742
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
2011-10-03 09:58:27 +02:00
Frederik Gladhorn
5ea07a9cd1 Fix selection update in QTableView accessibility.
Change-Id: Ib9353f8be3614798767578c34f1bc6d1a9e66c13
Reviewed-on: http://codereview.qt-project.org/5740
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
2011-10-03 09:56:09 +02:00
Casper van Donderen
e86df8cc4b Move the documentation for the classes to their modules.
All documented classes under src/widgets should now be
under the QtWidgets module in the documentation. The
QtPrintSupport classes should now be under the QtPrintSupport
module in the documentation.

Change-Id: I236b15443b8b93a61578a1d10f52b64dba938f29
Reviewed-on: http://codereview.qt-project.org/5520
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2011-10-03 09:56:09 +02:00
Morten Sorvig
7f57f29125 Cocoa: Fix spelling errors in comments.
This could be the basis for a "english spelling
for norwegians" course.

Change-Id: I1d6de11b6673ec0a8ba3c2ff12dd8472fb467703
Reviewed-on: http://codereview.qt-project.org/5691
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
2011-10-03 09:56:09 +02:00
Morten Sorvig
a7b92e8401 Cocoa: Fix window resizing
Set the geomeotry on the platform window on resize. (There
used to be a callback form the QWindow earlier.)

Change-Id: I2298a03d1e015279b28a02da9f05f90f25148efb
Reviewed-on: http://codereview.qt-project.org/5834
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
2011-10-03 09:56:09 +02:00
Jan-Arve Saether
a06cb56dde Use QGuiApp::activeWindow()->accessibleRoot() to find focus child
queryAccessibleInterface will return 0 if the object is a QWindow, so
it would never find the focus child.

Change-Id: Ib5bb6a0e4ffbf1b8491b71d1ba5a039e7a6584e0
Reviewed-on: http://codereview.qt-project.org/5842
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
2011-10-03 09:56:09 +02:00
Jan-Arve Saether
2d8863bfa0 Small cleanup.
Change-Id: I8661e28fca2069bf4034f7a9d2b5e1bbde2d542a
Reviewed-on: http://codereview.qt-project.org/5843
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
2011-10-03 09:56:09 +02:00
Jan-Arve Saether
7e1a12d07d Fix QWindowsAccessible::GetWindow()
Since we added QAI::window() we now have a more reliable way of
getting hold of a HWND.

Change-Id: I330ecee67f041d5b204ef4bc1401ce4cc76de2b7
Reviewed-on: http://codereview.qt-project.org/5840
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
2011-10-03 09:56:09 +02:00
Thiago Macieira
5bfeab8749 Make all uses of QBasicAtomicInt and Pointer use load() and store()
Most of these changes are search-and-replace of d->ref ==, d->ref !=
and d->ref =.

The QBasicAtomicPointer in QObjectPrivate::Connection didn't need to
be basic, so I made it QAtomicPointer.

Change-Id: Ie3271abd1728af599f9ab17c6f4868e475f17bb6
Reviewed-on: http://codereview.qt-project.org/5030
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-10-03 07:57:41 +02:00
Thiago Macieira
5613c9722a Add placeholders for loadAcquire and storeRelease in the atomics
This should be replaced later with proper loadAcquire and storeRelease
functions in the architectures that require them. The code right now
is enough for x86, x86-64 and IA-64. It's probably not good for ARM
and MIPS.

Change-Id: Iaa28a18cad64772539662439c2c14690ec26940f
Reviewed-on: http://codereview.qt-project.org/5029
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-10-03 07:57:41 +02:00
Gunnar Sletta
0c59eb1156 Added QWindow::requestedFormat()
Change-Id: I9e69ddd8ceefeda87216fb3d2507c40bc7220cf5
Reviewed-on: http://codereview.qt-project.org/5846
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-03 07:57:41 +02:00
Gunnar Sletta
28a31f41d1 add a latency after simulating keyevets since they are queued up
Change-Id: Iaaaf01ab464cb2d310ed738de85ffdecd6cd854f
Reviewed-on: http://codereview.qt-project.org/5770
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Matthew Cattell <matthew.cattell@nokia.com>
Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
2011-10-03 07:57:41 +02:00
Friedemann Kleint
73945fb9f2 Windows plugin: Fix compilation with MinGW.
Change-Id: I6c522b121fbac31ac5fc60a9125e1565e78d50c0
Reviewed-on: http://codereview.qt-project.org/5890
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2011-10-03 07:57:41 +02:00
Lars Knoll
3fd9398052 Remove the remaining traces of QT3_SUPPORT
The only place that now still knows about it is moc,
so it can still parse old headers.

Change-Id: Iafec080f99c67560974e9ebc0cbfb27d9a4b2d6f
Reviewed-on: http://codereview.qt-project.org/5755
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2011-10-03 05:59:07 +02:00
Tor Arne Vestbø
95dfb6e668 Don't use un-guarded printfs for debug logging in XCB platform plugin
Using qDebug() instead of printf and friends allows clients to install a
message handler to supress the output.

The remaining printfs in the code are all guarded by custom debug ifdefs.

Change-Id: I38edc7452184783152f26b4dde6342c3bb9ef799
Reviewed-on: http://codereview.qt-project.org/5875
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-10-03 05:57:45 +02:00
Lars Knoll
3c54bd67da Remove QT_MOC_COMPAT signals
These are also obsolete since quite some time.

Change-Id: Id04543ff4a4464922a204f59989abaeedb18df14
Reviewed-on: http://codereview.qt-project.org/5756
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2011-09-30 00:31:02 +02:00
Laszlo Agocs
fc8b62222c Send key events to the active window when tlw in qpa event is null
Change-Id: Ie055918276d716b0f4f23b6a9d34c23c5459d960
Reviewed-on: http://codereview.qt-project.org/5777
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
2011-09-29 15:22:07 +02:00
David Faure
b863df7de9 Rename Qt::escape to QString::toHtmlEscaped, add compat method
Merge-request: 56
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>

Change-Id: I46bbb2df10968e88b5eb5ef8dae182a651b622b8
Reviewed-on: http://codereview.qt-project.org/5793
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
2011-09-29 15:22:07 +02:00
David Faure
7fb90066b3 Move Qt::escape to QtCore
Merge-request: 56
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>

Change-Id: I25c5f46cf53a653db26dbeb92865e61f69980bfd
Reviewed-on: http://codereview.qt-project.org/5792
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
2011-09-29 15:22:07 +02:00
Jan-Arve Saether
87ae97c11a Refactor accessibility for Qt5
* Moved most stuff to gui\accessible
* Moved widget-specific stuff to widgets\accessible
* Moved platform-specific code to either the bridge plugin (this was already the case)
  or to the platform plugin.
* Added several classes and functions. These have not yet gone through an API
  review. The plan is to do that in a later commit.
  Classes:
   - QPlatformAccessibility
   - QWindowsAccessibility
  Functions:
   - QWindow *QAccessibleInterface::window();
   - QPlatformAccessibility *QPlatformIntegration::accessibility()

* The bridge code can now either be a plugin or integrated into the platform plugin
* Mac accessibility is left out for now. Unix "should still work" (tm). These platforms
  should be fixed soon.

Change-Id: Ib49ffa73b647ee0af90864544c2769440157f562
Reviewed-on: http://codereview.qt-project.org/5330
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
2011-09-29 13:32:59 +02:00
Frederik Gladhorn
8ebd7d84fc Remove obsolete function isHeaderVisible.
This function was deprecated in Qt4 and has
been replaced by isNavigationBarVisible.
Same for the setter.

Change-Id: Ifdcbaa2db0d4d8d475d959a6409347fa19d443a9
Reviewed-on: http://codereview.qt-project.org/5788
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Gabriel de Dietrich <gabriel.dietrich-de@nokia.com>
2011-09-29 13:28:46 +02:00
Lars Knoll
db3418c10b Fix the qtranslator autotest
Properly propagate the language change event
to all widgets.

Change-Id: I6650205abe1acc6979e28ca5c5dde5ae33a406b9
Reviewed-on: http://codereview.qt-project.org/5758
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
2011-09-29 08:56:26 +02:00
Lars Knoll
e9ccc40c28 Get rid of the last traces of QMimeSource
The class has been deprecated since Qt 4.0, but
couldn't be removed as QDropEvent inherited from
it.

Change-Id: I9caa19b30977a319e79255900dee8b2425783f46
Reviewed-on: http://codereview.qt-project.org/5754
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
2011-09-29 08:54:06 +02:00
Eskil Abrahamsen Blomfeldt
353c12f3e6 Register whether a glyph run goes from RTL or LTR
This is needed by scene graph when embedding text objects in
RTL text. Since the number of flags required for
QGlyphRun is increasing, I've also refactored the
underline/overline/strikethrough settings to use a common
QFlags interface.

Task-number: QTBUG-20917
Change-Id: I070649c014f4a51cfd66a9579d2d221a8f22302f
Reviewed-on: http://codereview.qt-project.org/5739
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
2011-09-28 16:58:35 +02:00
David Faure
c7a0fd0950 QTemporaryFile: use QCoreApplication::applicationName() as base filename
Merge-request: 57
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>

Change-Id: I2a29b2ba925ea92a5299272b80164658775e9c0e
Reviewed-on: http://codereview.qt-project.org/5713
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
2011-09-28 14:02:08 +02:00
Lars Knoll
84251f84b6 Implement support for QGuiApp::setOverrideCursor()
Properly support application override cursors and move
the documentation into the proper place.

Change-Id: I0198b38e0d2e7b10f0fcae342b468e7f8341bf02
Reviewed-on: http://codereview.qt-project.org/5562
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Paul Olav Tvete <paul.tvete@nokia.com>
2011-09-28 14:02:08 +02:00
Pekka Vuorela
50f0aeee77 Adapted most QInputContext usage on widgets to QInputPanel
Including most of stuff excluding mouse event handling
which differs between the classes.

Change-Id: Iff1e56b9c50c3f84de2d1c43a3416a1952197a17
Reviewed-on: http://codereview.qt-project.org/5640
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-09-28 14:02:08 +02:00
Pekka Vuorela
3d71266fea Remove support for QWidget specific input contexts
QInputContext is migrated to QInputPanel, which allows only one
instance.

Change-Id: I4912164790d5a6bdff41e11cbe4bc4e2f9f111ec
Reviewed-on: http://codereview.qt-project.org/5641
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-09-28 14:02:08 +02:00
Pekka Vuorela
d0968472c6 Adapt QGraphicsView from QInputContext to QInputPanel
Change-Id: Icbb458af7914f0af3e37ac012aa7c1cbd5f3a023
Reviewed-on: http://codereview.qt-project.org/5631
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com>
2011-09-28 14:02:08 +02:00
Joona Petrell
940a526fc6 Add missing Q_ENUMS macro to QInputPanel
Change-Id: I4e27013a06ea4fc9899a8a737e90d6792e6fb3a0
Reviewed-on: http://codereview.qt-project.org/5699
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Pekka Vuorela <pekka.ta.vuorela@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-09-28 14:02:08 +02:00
Kent Hansen
dea76f3496 Make qtbase build with Qt-in-namespace again
Change-Id: I5faa8690a05d6ec352fc69c0b69848539f2ed216
Reviewed-on: http://codereview.qt-project.org/5460
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-09-28 12:18:37 +02:00
Jason McDonald
cb57d36f45 Make QTest::qWarn() use __FILE__ and __LINE__.
This change makes QTest::qWarn() consistent with similar testlib
functions, which take __FILE__ and __LINE__.

Change-Id: I12977cb30672899ab38877b4a656f0cc0c7ea02c
Reviewed-on: http://codereview.qt-project.org/3559
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2011-09-28 12:17:45 +02:00
Friedemann Kleint
24b99f819c Re-enable the Windows plugin.
Revert 732bfbe8e8.

Change-Id: Ia24d06b4e89936ede97c89b76214d1a9c9de9b53
Reviewed-on: http://codereview.qt-project.org/5679
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2011-09-28 12:17:24 +02:00
Pekka Vuorela
e3bdcb1d62 Use module prefixed include paths, avoids warnings in configure.
Change-Id: I081fa49073da532647836ddd1087c0f5fcf32775
Reviewed-on: http://codereview.qt-project.org/5634
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-09-28 03:18:26 +02:00