Commit Graph

1386 Commits

Author SHA1 Message Date
Jiang Jiang
3fb67767fc Reorder member varibles in QGlyphRunPrivate to eliminate warning
Reviewed-by: Eskil
(cherry picked from commit 74a1135341783449970d579b273d00c837ac14b0)

Change-Id: I8e1c6bdc7f0957d8f389531f5f5682c536cdc286
Reviewed-on: http://codereview.qt.nokia.com/374
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
2011-06-08 12:25:23 +02:00
Jiang Jiang
c2dddd8322 Fix warning in qtextengine compilation
enableHarfbuzz() should only be defined on Mac.

Reviewed-by: Eskil
(cherry picked from commit 5ce3fbb67b79c3732fd47b296ef9421398ca520c)

Change-Id: I9ecb5db49478c3f5beb5d41cf99320f0faedce2e
Reviewed-on: http://codereview.qt.nokia.com/375
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
2011-06-08 12:25:22 +02:00
Jiang Jiang
d9e3d1a540 Fix compile when configure with no fontconfig support
Task-number: QTBUG-19716
Reviewed-by: Eskil
(cherry picked from commit 5a598afa3f1928e9ad18257e2fa48fe3d5739917)

Change-Id: I05107970e3273fce48303c9956e1c9aa928832b9
Reviewed-on: http://codereview.qt.nokia.com/376
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
2011-06-08 12:25:21 +02:00
Lars Knoll
b6b244efda Fix behaviour after WM_TAKE_FOCUS
We should not call requestActivateWindow() in
reaction to WM_TAKE_FOCUS. Looks like it should
only be done if the focus should in fact go
to a modal child of the widget.
2011-06-08 11:44:41 +02:00
Olli Werwolff
819f9ca965 Use Q_WIDGETS_EXPORT for widgets library
Reviewed-by: Lars Knoll
2011-06-08 10:43:55 +02:00
Marius Storm-Olsen
ed5a7e22be Fix usage of QT_SOURCE_TREE
Functionality has been moved into qt_example.prf

Change-Id: I81423eb4c5645f03b131932b2d37eceee9fea086
Reviewed-on: http://codereview.qt.nokia.com/371
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2011-06-07 22:18:35 +02:00
Lars Knoll
6a243e5559 revert accidental commit 2011-06-07 16:45:28 +02:00
Lars Knoll
1729785d1e remove unused code 2011-06-07 16:44:23 +02:00
Lars Knoll
52e5fd336b cleanups code
Make QXcbClipboard and QXcbDrag a QXcbObject to simplify
the code.
Use the predefined atoms in xproto.h instead of our own
defines.
2011-06-07 16:29:35 +02:00
Lars Knoll
4386425ce3 Implement QDropEvent::source() again
QDropEvent::source() now returns a QObject
instead of a widget, matching the implementation
in QDrag.

Reviewed-by: Samuel
2011-06-07 15:50:54 +02:00
Lars Knoll
71304aefd0 reset certain global variables on deletion
qt_button_down needs to be reset to 0 if it
points to the widget being deleted.

Reviewed-by: Samuel
2011-06-07 15:50:54 +02:00
Lars Knoll
779e1aaa35 Protect against deleted windows
Check that the window is still there before
trying to deliver an event to it.

Reviewed-by: Samuel
2011-06-07 15:50:54 +02:00
Lars Knoll
689ac3631d Initialize variable
Reviewed-by: Samuel
2011-06-07 15:50:54 +02:00
Lars Knoll
1928e633a5 Fix some remaining issues with DnD
Do not set the event mask of the window
we drop onto to NO_EVENT. Always use the
clipboards requestor window to convert
selections.

Reviewed-by: Samuel
2011-06-07 15:50:54 +02:00
Lars Knoll
ff53b1dcec add WM support class
Add a QXcbWMSupport class to better integrate with
NET_WM compliant window managers.

Suppport NET_WM_USER_TIME on windows.

Reviewed-by: Samuel
2011-06-07 15:50:53 +02:00
Lars Knoll
c3f9de6296 Implement XDnD in the xcb plugin
Ported most of the code to support dragging
from qdnd_x11.cpp to xcb. Some features are still
not working 100% correct, but it's becoming
usable.

Reviewed-by: Samuel
2011-06-07 15:50:53 +02:00
Lars Knoll
30b7c6512c X11 DnD implementation
Initial code for DnD on X11. Only Xdnd based,
Motif DnD is being ignored.

The code is currently limited to dropping
stuff onto the application. Starting drags
is not yet implemented.

Reviewed-by: Samuel
2011-06-07 15:50:53 +02:00
Lars Knoll
92edbd2060 Add a startDrag to QPlatformDrag
This can be used to initialize data
when a drag starts. The Xdnd implementation
at least has a need for it.

Reviewed-by: Samuel
2011-06-07 15:50:53 +02:00
Thiago Macieira
dddfcd66f8 Fix regression that caused waitForXXX(-1) to fail.
Regression was introduced by 8d4cd52b6981a4e6deea7fdb77f56e40c4f3e6ba
when it failed to check when msecs == -1. This manifested visibly in KDE
failing to connect to any SSL site -- kioslaves are synchronous and use
waitForXXX(-1) (in this particular case, waitForEncrypted, which calls
waitForReadyRead).

Also, take the opportunity to convert these tests in QTcpSocket to use
port 80 (a defined service in the test server) instead of port 22.

Reviewed-by: Martin Petersson
(cherry picked from commit cb5b6799333794496269aa7e6515f96c2ac96d37)

Change-Id: I256a1e138e43fd45844976fe84cd2bc938552e47
Reviewed-on: http://codereview.qt.nokia.com/359
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
2011-06-07 15:14:56 +02:00
Morten Sorvig
28391442e7 Cocoa: Implement raise() and lower(). 2011-06-07 12:06:26 +02:00
Morten Sorvig
67f18cafcc Cocoa: Implement setWindowTitle. 2011-06-07 11:12:38 +02:00
Morten Sorvig
29b29d1b70 Fix Cocoa mouse position handling.
I'm not sure what "local" and "global" means for 
QWindowSystemInterface::handleMouseEvent. Sending
the mouse position in window coordinates for both
works.
2011-06-07 10:53:37 +02:00
Eskil Abrahamsen Blomfeldt
ae3b5b3ab4 Add function QGlyphRun::setRawData()
To provide an optimized way of constructing QGlyphRun objects with no
copying or allocation, we add function setRawData() (naming inspired by
QByteArray::setRawData()). Data retrieved from QRawFont can be passed
directly into this. The logic is now that the data pointers in
QGlyphRunPrivate should always point to the current valid data and is
what will be used in comparisons and drawing calls. The vectors are
optimizations to avoid unnecessary copying if the user wants to use
the QVector based API (which makes it easier to manage the memory.)
This reflected in the functions that return QVectors, which will
return the stored vector if and only if it is identical to the
current pointer. Otherwise we will have to copy the memory.

The internal addition operators in QGlyphRun have been removed since
they really provide no real optimization and have an unclear definition
if the two glyph runs are based on different fonts.

Reviewed-by: Jiang Jiang
(cherry picked from commit 86d88c5b719fd3d50336d9d8e7127b8045ee82ae)

Change-Id: Id5bb55ee3d93afb32ffca850f53382e856df7b3e
Reviewed-on: http://codereview.qt.nokia.com/342
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
2011-06-07 10:30:57 +02:00
Richard Moe Gustavsen
bc6f4d14f7 Buildfix for Mac OS
Since 'widgets' now is a separate library outside GUI, some
previously hidden symbols now needs to be exported. This patch
will make 'widgets' build.
2011-06-07 09:53:09 +02:00
Eckhart Koppen
eabaf61256 Added private header dependencies to MeeGo graphics system plugin
Depends on core, gui and opengl private headers

Change-Id: If3266c3b7233bf40b5ad80a8a99fd5f2c7eafcec
Reviewed-on: http://codereview.qt.nokia.com/336
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Eckhart Koppen <eckhart.koppen@nokia.com>
2011-06-06 19:11:25 +02:00
Samuel Rødal
078e4ef6c7 Made tst_QWidget::updateWhileMinimized() pass.
This requires adding a couple of window system interface events, namely
Map, Unmap, and Expose. When a widget is minimized on X11 it is
unmapped, and thus update requests should not be delivered. Instead the
event will delivered when the widget is mapped, which causes an Expose
event to be sent. The Unmap and Expose event thus need to be handled in
QWidgetWindow, and Map is also added for the purpose of API symmetry
(and for future needs).
2011-06-06 16:03:38 +02:00
Samuel Rødal
481067453f Fixed warning about missing return in qmessagebox.cpp 2011-06-06 16:03:38 +02:00
Gunnar Sletta
42b47a404b Use Raster pixmaps for the EglFS plugin
Change-Id: Id94df7b5ebe298104d05bee3ae58e06201c596f7
Reviewed-on: http://codereview.qt.nokia.com/334
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
2011-06-06 15:33:16 +02:00
Morten Sorvig
0bb276863f Set visibility state. 2011-06-06 14:49:13 +02:00
Jørgen Lind
fc9a648dc0 Make building of platform plugins indifferent if its out of source
This requires some source files to be shipped with the Qt install
They are now copied into QT_INSTALL_DATA/platform
2011-06-06 14:35:36 +02:00
axis
ec5cdf9c5d Added module CONFIG to uitools.
This seems to be necessary for installing, and has no side effects
that I can tell.

Change-Id: Ic778b8a3937621ddd401ddd83d05831460db8f39
Task: QTBUG-19585
Reviewed-on: http://codereview.qt.nokia.com/236
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2011-06-06 13:29:40 +02:00
Samuel Rødal
0273bc5d22 Made tst_QWidget::repaintWhenChildDeleted() pass.
Implement some missing functionality in QWidget::destroy().
2011-06-06 12:38:41 +02:00
Samuel Rødal
d75a9444aa Prevent tst_QWidget::showAndMoveChild() from failing on KDE.
Since we grab the desktop the KDE task bar appears on top of the window
we're interested in. It's preferable to make the window a bit smaller.
2011-06-06 12:38:41 +02:00
axis
ff65077074 Make qmake slightly more verbose with its syncqt output.
It can be hidden with -silent, however.

Change-Id: I6dbd3c743779b8d2070e41f007df26b530987429
Reviewed-on: http://codereview.qt.nokia.com/235
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Liang Qi <liang.qi@nokia.com>
2011-06-06 10:42:13 +02:00
Marius Storm-Olsen
ccd5228a93 Disable trying to compile network tests which require QtScript
Those tests should be moved to QtScript/tests/auto

Change-Id: Icc0c50ef35ac08e604ab18cb87b0c2b19f2fc72c
Reviewed-on: http://codereview.qt.nokia.com/197
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Markus Goetz
Reviewed-by: Liang Qi <liang.qi@nokia.com>
2011-06-06 10:42:12 +02:00
Laszlo Agocs
78264f333e Avoid setting the active window to null when there is a FocusIn queued. 2011-06-06 10:15:14 +02:00
Samuel Rødal
4f1a6ac732 Implemented QXcbScreen::topLevelAt(const QPoint &p).
This makes the tst_QWidget::widgetAt() auto-test pass.
2011-06-06 09:08:25 +02:00
Samuel Rødal
36b2c31ba8 Make XCB plugin work better in combination with auto-tests.
When an auto-test calls processEvents() indirectly via QTest::qWait(),
QAbstractEventDispatcher::aboutToBlock() doesn't get emitted since
the processEvents() implementation gets called without
the QEventLoop::WaitForMoreEvents flag set. Since the auto-tests depend
on all events getting delivered, we need to process the XCB events on
awake() as well.
2011-06-06 09:00:13 +02:00
Samuel Rødal
0ca326917a Made the tst_QWidget::widgetAt() test a bit more robust.
The QTRY_VERIFY() should include the whole test, not just whether we got
a widget or not, since it might be the wrong one.
2011-06-06 08:57:37 +02:00
axis
1835afe621 Moved common module profiles to be feature profiles.
This enables external modules to also make use of them without having
access to the complete QtBase source code.

Change-Id: I056e45cba6c6798b76670b8d238dadb2d9f9c092
Task: QTBUG-19585
Reviewed-on: http://codereview.qt.nokia.com/234
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2011-06-05 14:47:14 +02:00
Jiang Jiang
c25495dba7 Correct antialias disabling logic for Core Text
We should always turn antialias off when QFont::NoAntialias being
passed in styleStrategy. That corrects some QStaticText tests.

Change-Id: Iaffc5f3bb7f501dcb648cab41a8b6ffcf93f90ae
Reviewed-on: http://codereview.qt.nokia.com/328
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
2011-06-04 12:20:01 +02:00
Jiang Jiang
ea0e38c0dd Correct QStaticText tests after recent changes
Raster engine on Mac now correctly handles transformation, so no
need to XFAIL anymore. Also fixes a drawStaticText origin mistake,
the y origin should be the top left point rather than the baseline.

Change-Id: I6058e7099b336d9d5a6586344a07be3c7d76fb64
Reviewed-on: http://codereview.qt.nokia.com/329
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
2011-06-04 12:20:00 +02:00
axis
0e6be2aa5d Implemented module-local caching of module profiles.
We use syncqt to generate .qmake.cache also for submodules, which
contains the location of forwarding module profiles for that module.
This enables us to build without having to put module profiles into
mkspecs/modules until install time.

Also added support for -developer-build to syncqt.

What it does is to point build directories for binaries and
libraries to a common location in QtBase. This is more
convenient when doing development, since you don't need to set your
path to every module's bin/ directory, but it cannot be used with
release builds, since they need to build independently of QtBase,
in their own directory.

Change-Id: I959c62c11c644f2147a98da894a72452d9c44327
Task: QTBUG-19585
Task: QTBUG-19583
Reviewed-on: http://codereview.qt.nokia.com/232
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2011-06-03 22:20:40 +02:00
axis
55f2a05a20 Install some headers that were previously missing from install.
Change-Id: I58a5f58e6e03e3e266de23beee47de0c823f3240
Task: QTBUG-19585
Reviewed-on: http://codereview.qt.nokia.com/233
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2011-06-03 22:20:39 +02:00
axis
3c66ade66f Don't base QTDIR detection on .qmake.cache.
Change-Id: I4adc26c1c070d26277551d302f4638b819ddc311
Task: QTBUG-19585
Reviewed-on: http://codereview.qt.nokia.com/231
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2011-06-03 19:36:04 +02:00
axis
d3e048da7e Make sure that we error out if we cannot write forwarding profile.
Change-Id: Ic0b62532dd8a52cf6ab7a7c10c5ffbe3c9039ec1
Task: QTBUG-19585
Reviewed-on: http://codereview.qt.nokia.com/229
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2011-06-03 18:18:02 +02:00
axis
44595bdb19 Changes needed for Qt to accept module .qmake.cache files.
Also introduced the QMAKE_EXTRA_MODULE_FORWARDS for specifying a
folder where forwarding profiles will be put.

Change-Id: I8cb242838a5a4d42dc5e3cfd0bd858ab0d2696cd
Task: QTBUG-19585
Reviewed-on: http://codereview.qt.nokia.com/230
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2011-06-03 18:18:01 +02:00
Jiang Jiang
ce041a6516 Add basic static text drawing capability to lance
Task-number: QTBUG-17514
Change-Id: Ife7cd8f940424d805f634ca190bcbf6fd83d8682
Reviewed-on: http://codereview.qt.nokia.com/321
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: aavit <qt_aavit@ovi.com>
2011-06-03 15:13:11 +02:00
Samuel Rødal
7e4116cc8a Basic QDesktopWidget support.
Makes it possible to use grabWindow on the desktop widget with the xcb
plugin, which gives us a few more passing tests in tst_QWidget.
2011-06-03 14:35:09 +02:00
Samuel Rødal
a9910abac9 Remove tst_QWidget::painterRedirection().
We've removed support for painter redirection, QWidget::render() should
be used instead.
2011-06-03 14:01:19 +02:00