Commit Graph

292 Commits

Author SHA1 Message Date
Gatis Paeglis
deed9c75b4 Change path for 'mousebuttons' widgets example
Task-number: QTBUG-26121
Change-Id: Icaeb6038d166fb0ffadf1657ddef21c18b3d3be6
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
2012-06-14 03:03:38 +02:00
Gatis Paeglis
aa9942a530 Add install path for qpa windows example
Task-number: QTBUG-26150
Change-Id: I8e981318e05cca6628160aea31281f8e3baaa50f
Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
2012-06-14 03:03:38 +02:00
Stephen Kelly
f9caf48bee Use a QVector<int> instead of a QSet<int> in itemviews/models.
The QSet<int> is a more expensive container to use and create, so
it should be avoided.

This is source incompatible compared to earlier Qt 5 for
QAbstractItemView subclasses which reimplement dataChanged, but this
patch changes nothing compared to already-present SiC compared
to Qt 4.

Change-Id: Id95391dfd62a0a7f487a8765790b007badefb937
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-06-12 04:30:07 +02:00
Thiago Macieira
693468a54d Replace deprecated QGraphicsScene::itemAt() with items()
Change-Id: I33ee03db775d3cf6807372e0963748cf6a4e07db
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
2012-06-09 10:45:01 +02:00
Friedemann Kleint
e454000abc Fix assert in painting demos when switching to OpenGL.
Fix creation order. The ArthurFrame receives a paint
event with OpenGL set to true when the glw-member is still 0.

Task-number: QTBUG-26084
Change-Id: Ib4b568d22ae925542e3a775403e4c983ea0b4de5
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-06-09 10:45:01 +02:00
Kent Hansen
6b95e54f1f Fix compilation of examples with -no-widgets
Change-Id: Ie0e19daf6c6476b5c5130f4930dfa3df92917384
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-06-07 07:27:53 +02:00
Kent Hansen
ef30a59121 Remove widgets dependency from xmlstreamlint example
Change-Id: I2c7609077bd18864ffd9b2ba5086eb590aff3df0
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-06-07 00:39:12 +02:00
Kent Hansen
1f8b8d56b2 Remove widgets dependency from qtconcurrent/map autotest
Change-Id: I734ae73a530ab6eb27271586040ef910e6ad0e2c
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-06-07 00:39:09 +02:00
Kent Hansen
fa7c9bbe1c Remove useless "QT += widgets"
These .pro files have TEMPLATE=subdirs, so there's no reason to be
adding libraries here.

Change-Id: I0fb0a44107710ee746d354106d0c46006958ee62
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-06-05 16:01:29 +02:00
Janne Anttila
adbf443c47 Fix digiflip example build.
digiflip examples depends on qtwidgets, let's link to it also.

Change-Id: I4f4434c747d143942909797491153a4f358e6fef
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-05-31 02:06:42 +02:00
Morten Johan Sorvig
d725c3ee23 Remove the MacMainWindow example.
setUnifiedTitleAndToolBarOnMac will not be supported
on Qt 5, which removes the point of having this example.

The replacement for setUnifiedTitleAndToolBarOnMac
will be a NSToolBar wrapper in the MacExtras module,
and this example will probably re-appear in some form
there.

Change-Id: I46d5e70a7c45625d9334911bb48059e86f05282d
Reviewed-by: Christoph Schleifenbaum <christoph.schleifenbaum@kdab.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
2012-05-30 01:54:45 +02:00
Thiago Macieira
291b05e4b2 QApplication::syncX doesn't do anything in Qt 5 anymore
Change-Id: I325f8badeb5bd7120c691b49fdf51dc9b2649f68
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-05-29 11:35:21 +02:00
Jędrzej Nowacki
db06953ca1 Replace QVariant::typeToName usage by QMetaType::typeName call.
Type information is kept in QMetaType class. QVariant is delegating
operations, so it is better to use QMetaType directly.

Change-Id: I91209fa1c9dc4303d6bd47c96824d3cd64ce5291
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-05-28 03:30:21 +02:00
Friedemann Kleint
57f243594e OpenGL/HelloWindow example: Fix resource leaks.
Change-Id: Icf776b5581b3a632e8cef19af1059503146c158c
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
2012-05-25 21:42:14 +02:00
Mitch Curtis
b1f12913a6 Fixed unused paramater warning in download example.
Change-Id: I9688ff6a583591f04aa81bb2714c33fc02da77c7
Reviewed-by: Martin Petersson <Martin.Petersson@nokia.com>
2012-05-22 10:27:54 +02:00
Mitch Curtis
730dfc74d3 Fixed "No such signal" error in download example output.
The signal sslErrors is not defined by QNetworkReply when QT_NO_SSL
is undefined. The solution was to add the an ifndef guard around the
call to connect so that the signal is only used when it is defined.

Change-Id: I9f104ec630ed448af65669b0861df233de5172ac
Reviewed-by: Martin Petersson <Martin.Petersson@nokia.com>
2012-05-22 10:27:46 +02:00
Mitch Curtis
899f1d35a4 Fixed unused variable warning in anchorlayout example.
Change-Id: I54c6e471531485e33b20b6a6da7f52dab5c3a32a
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-05-19 01:45:04 +02:00
Mitch Curtis
a490cd61fa Fixed unused variable warning in chart example.
Change-Id: I0985ff1b1224b29a394ae2a594aeaa783d650ffa
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-05-19 01:45:04 +02:00
Mitch Curtis
9e13d169a4 Fixed unused parameter warning in hellowindow example.
Change-Id: I48ea19b5548a179d8116685fa481c4d1b3804bba
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
2012-05-18 21:25:18 +02:00
Mitch Curtis
91a5e272c5 Fixed unused variable warning in diagramscene example.
Change-Id: I85cc038602e22c140f0564b15ebcb3872750b162
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-05-18 21:12:16 +02:00
Marius Storm-Olsen
2d23374a6f Merge "Merge branch 'docs-refactoring' into master" into refs/staging/master 2012-05-10 11:34:25 +02:00
hjk
7f2c22e891 gettingStarted, part 3-5: sanitize parameter names and compile fix
Change-Id: I12795439de71a41728f98b3d3438324664b27a0f
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-05-10 09:16:35 +02:00
Marius Storm-Olsen
9456528aac Merge branch 'docs-refactoring' into master
Change-Id: Iebd1966abace3cdf7f9428dcfc1ded5b124ab113
2012-05-10 09:11:23 +02:00
hjk
cc8d9fb85e gettingStarted: sanitize parameter names and compile fix for Qt 5
Change-Id: I3f30ccee89b8add8718a9a36f0f16fa7b2e9bad1
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-05-09 17:16:55 +02:00
Marius Storm-Olsen
9fde9ab167 Properly implement a 'make docs' target for subdirs and apps/libs
Only call qdoc for projects which sets the QMAKE_DOCS variable to
point to a qdocconf file.

Exclude examples/ and tests/ from the qdoc run, by adding
    no_docs_target
to CONFIG for those projects.

Change-Id: Ic856c8f19db59309302d0602b3e99735609e525a
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2012-05-09 08:34:42 +02:00
Girish Ramakrishnan
36547f4eff Expose QPA API under qpa/*
The main reasons for doing this are:
1. _qpa.h end up in the master QtGui include file. QtGui is meant for
userland applications. qpa code is neither binary nor source compatible.
Inadvertant use of QPA api makes the user code binary-incompatible.
2. syncqt creates forwarding headers for non-private header files. This
gives people the impression that this is public API.

As discussed on the mailing list, even though QPA api is internal and subject
to change, it needs to  treated differently from private headers since they
will be used by  in-qtbase and out-of-qtbase plugins.

This commit does the following:
1. The _qpa in QPA header files is dropped.
2. syncqt now treats any file with qplatform prefix as a special file and
moves it to qpa/ directory. The recommended way of using QPA API in plugins
is: #include <qpa/qplatformfoo.h>. This allows the user include QPA API
from multiple modules (for example, qplatformfoo might be in QtPrintSupport)
3. The user needs to explicitly add QT += <module>-private to get access to
the qpa api.
4. Creates compat headers for the olden style qplatformfoo_qpa.h and QPlatformFoo
includes.

This commit does not change the cpp filenames. This requires a more careful
merging of existing non qpa cpp files and existing cpp files on a case by
case basis. This can be done at anytime.

The following files are not renamed as part of this changed but will be fixed
as part of a future change:
src/gui/kernel/qgenericpluginfactory_qpa.h
src/gui/kernel/qgenericplugin_qpa.h
src/gui/kernel/qwindowsysteminterface_qpa.h

files were renamed using

    for x in `find . -name "qplatform*_qpa.h"`; do git mv $x "${x/_qpa.h/.h}"; done
    for x in `find . -name "qplatform*_qpa_p.h"`; do git mv $x "${x/_qpa_p.h/_p.h}"; done

includes were renamed using script

for file in `find . -name "*.h" -or -name "*.cpp" -or -name "*.mm"`; do
    sed -i -e 's,.*#.*include.*<\(Qt.*/\)\?\(QPlatform.*\)>,#include <qpa/\L\2.h>,g' \
        -e 's,.*#.*include.*"\(Qt.*/\)\?\(QPlatform.*\)",#include <qpa/\L\2.h>,g' \
        -e 's,.*#.*include.* "\(qplatform.*\)_qpa.h",#include <qpa/\L\1.h>,g' \
        -e 's,.*#.*include.*"\(qplatform.*\)_qpa_p.h",#include <qpa/\L\1_p.h>,g' \
        -e 's,.*#.*include.*<\(Qt.*/\|Qt.*/private/\|private/\)\?\(qplatform.*\)_qpa\(.*\)>,#include <qpa/\2\3>,g' \
        -e 's,.*#.*include.*"\(Qt.*/\|Qt.*/private/\|private/\)\?\(qplatform.*\)_qpa\(.*\)",#include <qpa/\2\3>,g' \
        $file
done

Change-Id: I04a350314a45746e3911f54b3b21ad03315afb67
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
2012-05-07 20:25:24 +02:00
Stephen Kelly
8ec1594e63 Rename setResizeMode to setSectionResizeMode.
The overload of this method was renamed
in b64426248d but this one was not.

Change-Id: I60a6ddf0fcf9deea31ccf51e7b0db16c66023356
Reviewed-by: David Faure <faure@kde.org>
Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
2012-05-07 17:55:47 +02:00
Thiago Macieira
e563ca1a75 Change remaining uses of {to,from}Ascii to {to,from}Latin1 [platformsupport]
This operation should be a no-op anyway, since at this point in time,
the fromAscii and toAscii functions simply call their fromLatin1 and
toLatin1 counterparts.

Task-number: QTBUG-21872
Change-Id: Ie1a4e5ceca21c31e7357f28b90abc9129b122104
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-05-04 15:27:59 +02:00
Thiago Macieira
dd5b373d41 Change remaining uses of {to,from}Ascii to {to,from}Latin1 [QtNetwork]
This operation should be a no-op anyway, since at this point in time,
the fromAscii and toAscii functions simply call their fromLatin1 and
toLatin1 counterparts.

Task-number: QTBUG-21872
Change-Id: I94cc301ea75cc689bcb6e2d417120cf14e36808d
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
Reviewed-by: Richard J. Moore <rich@kde.org>
2012-05-04 12:46:05 +02:00
Thiago Macieira
5f22899a17 Use org.example instead of com.trolltech for the D-Bus examples
We could use org.qtproject, but since this is an example anyway, and
since example.org and example.com are reserved to IANA by RFC 2606
anyway, let's use that.

Task-number: QTBUG-23274
Change-Id: Icdb1ac0390f88b72fa21b02ab362f1a98f26266c
Reviewed-by: Lorn Potter <lorn.potter@nokia.com>
2012-04-22 21:32:33 +02:00
Olivier Goffart
910b446fb2 Examples: Don't use deprecated methods
Change-Id: Ib6e795f6b5bb6a3ac19882a5fb224460ef1fc8ad
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2012-04-21 17:29:40 +02:00
Samuel Rødal
528cb10d53 Made hellowindow example respect the expose event.
The expose event is sent when the window can start rendering.

Change-Id: Ifdfb01a107e3bf665fb7be65802cdaabea4c5a34
Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
2012-04-20 08:14:22 +02:00
Andreas Holzammer
90292529b9 Compile fix if QT_NO_CLIPBOARD defined
Change-Id: Ie8ecaa2ba8f99d0b531b3a81b5f0005508e677eb
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-04-19 16:20:28 +02:00
Andreas Holzammer
4acb8bfc59 Compile fix if QT_NO_CLIPBOARD defined
Change-Id: I818122f2b2d2119248ad2e84b138aab8ab621a41
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-04-19 16:20:02 +02:00
Oswald Buddenhagen
143c4d3e13 Merge remote-tracking branch 'origin/master' into api_changes
Conflicts:
	configure
	src/widgets/styles/qwindowsxpstyle.cpp
	tests/auto/gui/kernel/qwindow/qwindow.pro
	tests/auto/gui/kernel/qwindow/tst_qwindow.cpp

Change-Id: I624b6d26abce9874c610c04954c1c45bc074bef3
2012-04-10 15:31:45 +02:00
Robin Burchell
c82d40749d Fix multicast join/leave when binding to QHostAddress::Any.
On OS X and Windows, this was not working, because the socket was being bound
in v6 mode (due to ::Any being for dual mode), but the address passed was a v4
address, meaning it took the wrong codepath. Linux, strangely, apparently works
anyway.

This is fixable in OS X (by using the v6 join path when bound in v6/dual mode),
but the same fix doesn't work on Windows, failing with WSAEADDRNOTAVAIL.

Don't allow this behaviour, and provide a sane error message telling the user
what to do instead.

Done-with: Shane Kearns
Task-number: QTBUG-25047
Change-Id: Iaf5bbee82e13ac92e11b60c558f5af9ce26f474b
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
2012-04-02 12:49:38 +02:00
Kent Hansen
3b512ae142 Merge master into api_changes
Change-Id: I93551e4d13a1b0815b359b9415060e9089477db1
2012-03-23 14:10:58 +01:00
Samuel Rødal
55fa3c189f Got rid of Map / Unmap events in favor of Expose event.
Since change 2e4d8f67a8 the need for Map and Unmap events has
gone away, as now the Expose event is used to notify the application
about when it can start rendering.

The Map and Unmap events weren't really used except by QWidget to set
the WA_Mapped flag, which we now set based on the expose / unexpose.

Also guarantee that a Resize event is always sent before the first
Expose, by re-introducing an asynchronous expose event handler. Since
an expose is required before rendering to a QWindow, show a warning if
QOpenGLContext::swapBuffers() or QBackingStore::flush() if called on a
window that has not received its first expose.

Change-Id: Ia6b609aa275d5b463b5011a96f2fd9bbe52e9bc4
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-03-22 11:43:36 +01:00
Jędrzej Nowacki
10df7967d9 Disable some tests and examples when --no-widgets is specified
There are many tests, examples that depends on widgets. This patch
disables some of them if Qt is configured without widgets.

Change-Id: I5460dadca736c54221874adcd518a7021725d90a
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-03-19 20:16:04 +01:00
Donald Carr
81043dcb55 Remove all QWS centric examples
Change-Id: I1bd9c40c7cc70e088a23283d1c3e89d12c1c5f7d
Reviewed-by: Donald Carr <donald.carr@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
2012-03-15 15:18:16 +01:00
Sergio Martins
62dfed9a7f Use QRect::united(), QRect::unite() is deprecated.
Change-Id: Ia7aac74596c2f251c96fecf157d2aa4a935cf602
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2012-03-14 11:37:18 +01:00
Friedemann Kleint
8be558e99d Fix icon suffixes in systray example.
Change-Id: If464befa88f26a881557724b4fc175f0a82c90b6
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-03-13 10:11:22 +01:00
Friedemann Kleint
502673ab3a Re-add the Systray example.
Remove its dependency on QtSvg by converting the icons to
(optimized) png files.

Change-Id: If63257938dc816d7ab76a3042b9ac88ef3d51b07
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-03-12 17:33:15 +01:00
Marc Mutz
a27d5be4dc examples: compile w/QT_NO_CAST_FROM_BYTEARRAY, at least on Unix
This is all pretty straight-forward, adding .constData() or
using QString::fromLatin1() instead of QLatin1String().

Change-Id: I984706452db7d0841620a0f64e179906123f3849
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2012-03-08 09:58:26 +01:00
Marc Mutz
a03a71e332 examples: use QVector<QPointF> instead of QList<QPointF>
QPointF is in the category of types for which QList
is needlessly inefficient (elements are copy-constructed
onto the heap and held through pointers). Use a vector
instead. This is consistent with the QPainter API.

Change-Id: Id0e910c067a60d12fbc175e7ee7da824834be374
Reviewed-by: hjk <qthjk@ovi.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-03-08 05:31:40 +01:00
Jędrzej Nowacki
b460eca941 Example build fix.
buttontester.pro has to be renamed to mousebuttons.pro because it lives
in mousebuttons subdirectory, to which examples/widgets/widgets.pro is
pointing by SUBDIRS variable.

Change-Id: I04bbd85713321337fbe8cbccfa6284f12b677279
Reviewed-by: Rick Stockton <rickstockton@reno-computerhelp.com>
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2012-03-07 12:51:54 +01:00
Rick Stockton
4a80a7ced1 add widget mousebuttons example 'mousetester'.
This is an xev-like program. A user clicks a mouse button inside the
Window, and the program displays (a) the "raw" button number; (b)
the corresponding Qt::MouseButton name; and (c) the type of mouse Event.

Task-number: QTBUG-24112
Change-Id: I8a76ff37b5b85639f662706072cc4a2ce490754b
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2012-03-06 08:24:22 +01:00
Mark Brand
e999ca25c6 add strategy support to sqlbrowser example
Several useful options added to context menu.

Also added yellow background for unsubmitted
changes.

Change-Id: I132cd4498a5fb7275ea10c0497910aba99c06a2b
Reviewed-by: Honglei Zhang <honglei.zhang@nokia.com>
Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
2012-03-06 06:34:33 +01:00
Lars Knoll
96232be146 Merge remote-tracking branch 'origin/api_changes'
Conflicts:
	dist/changes-5.0.0
	mkspecs/features/qt_module_config.prf
	qmake/project.cpp
	qmake/property.cpp

Change-Id: I6e4af40743a9aeff8ed18533a48036e332acc296
2012-03-04 21:45:05 +01:00
Sergio Ahumada
db1abf9f76 Change bugreports.qt.nokia.com -> bugreports.qt-project.org
Change-Id: Ia795098f24cf358b15067f54cd08dff0bd792bc5
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-03-02 23:16:25 +01:00
Marc Mutz
1cd4d6b181 QEvent (and subclasses): make ctors explicit
Do this regardless of whether the event subclass
is public API or only used in examples. Examples
are examples, used by others as templates or even
copied verbatim, so they should also follow sound
engineering rules.

Anyway, there's only one in examples/...

Change-Id: I586ff16407a956c9e89288fdd4377eed73f45c0f
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-03-01 08:44:34 +01:00
Rohan McGovern
99b997c4d5 Cleaned up examples/opengl/cube/cube.pro, removed message()
It's arbitrary and confusing to put a message(OpenGL support is enabled)
in this one OpenGL example and no others, especially since the message
is output during configure.

Change-Id: I7b55868d10c288f3459a7fda594fea1e6f45bf9a
Reviewed-by: Toby Tomkins <toby.tomkins@nokia.com>
2012-02-29 03:09:38 +01:00
Friedemann Kleint
efde205586 Use new plugin system in qtbase.
- AccessibleWidgets
- Windows printer support
- Examples

Change-Id: Icc162bd7fc284b3c76d9966210f983728085c743
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-02-27 13:28:21 +01:00
Olivier Goffart
ffa072655d Fix compilation of examples with QStringBuilder
In sub-attack an interview, one can't make two implicit conversions at
once, so explicitly convert to the right type.

The change in the torrent example is required because of
https://codereview.qt-project.org/16168 (commit 9491272)
But in that case, using a QByteArray is better anyway.

Change-Id: Ieed22ac7f0d700d5ba5d1e70af3db4dd6c139c8f
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-02-25 21:30:45 +01:00
Marc Mutz
88016d30a0 examples: compile w/o opengl
Fixes remnants of an automated QtGui -> QtWidgets port.

Change-Id: I31f63bdd6ae71aee8e70b20e24def30e0eafb725
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-02-24 22:39:40 +01:00
Oswald Buddenhagen
d91cf1e53b clean up qmake-generated projects
remove "header" and assignmets which are defaults or bogus,
reorder some assignments.

Change-Id: I67403872168c890ca3b696753ceb01c605d19be7
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2012-02-24 05:18:30 +01:00
Shane Kearns
3f91cde588 Test for QT_NO_SSL instead of QT_NO_OPENSSL
Change the ifdefs in our own code (except openssl backend) to use the
new configure flag.

Change-Id: I8774734771c66b22164b5fae8fdb27814ac3df7b
Reviewed-by: Richard J. Moore <rich@kde.org>
2012-02-21 15:28:40 +01:00
Shane Kearns
304fc533bd Fortune client example - list all IP addresses
The first IP address on the machine might not be a usable one.
Changed the QLineEdit to a QComboBox, and populated it with
all IP addresses of the machine, along with the machine names
if they are configured.

Task-number: QTBUG-13121
Change-Id: I7c443f5ce6efb0d0b525c5abad1671d3dcbba33c
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2012-02-17 11:44:29 +01:00
Lars Knoll
96501b0a18 Move QtConcurrent into its own module
Task-number: QTBUG-20892

Change-Id: I614500aafb6428915509983608bbb0ade4e4f016
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-02-05 17:49:16 +01:00
Samuli Piippo
c8156cab81 Exclude helloconcurrent when QtConcurrent is not configured
Task-number: QTBUG-23874
Change-Id: I374a08ce947e804ebb1da08c413e340e4719d9d0
Reviewed-by: Jonas Gastal <jgastal@profusion.mobi>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-02-05 17:49:10 +01:00
Giuseppe D'Angelo
f0cac3f42f Fix the chart itemview example
Commit 054a4aa7dd (being a SIC)
breaks QAbstractItemViews that used to override the
dataChanged(QModelIndex, QModelIndex) method, so this change
updates the dataChanged signature accordingly.

Change-Id: I632b6625c12dcb09abcb737ea2648efeeedeee8e
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2012-02-03 01:15:52 +01:00
Gunnar Sletta
75711510b1 Improve QSurface / QWindow API a bit and use that to avoid errors
Change-Id: Iadba1c3a7b8e6bc7f145455132cefed2a905c11d
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-02-02 17:20:24 +01:00
Bradley T. Hughes
a71d956013 Reimplement QAbstractSocket::setReadBufferSize() properly
This function takes a qint64 argument, not an int argument.

peerwireclient.h:119:10: warning: 'PeerWireClient::setReadBufferSize'
     hides overloaded virtual function [-Woverloaded-virtual]
    void setReadBufferSize(int size);
         ^
src/network/socket/qabstractsocket.h:162:18: note: hidden overloaded
     virtual function 'QAbstractSocket::setReadBufferSize' declared here
    virtual void setReadBufferSize(qint64 size);
                 ^

Change-Id: I29b67b216147771ff2d662d309d2c31d977e9d3f
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
Reviewed-by: Jonas Gastal <jgastal@profusion.mobi>
2012-02-02 14:18:36 +01:00
aavit
4fce5d1795 Moving tiff image format support and libtiff out of qtbase
The tiff plugin and bundled libtiff is moving to the qtimageformats
project on Gerrit.

Task-number: QTBUG-23887
Change-Id: I4c848232fdccddd7e7f54215f9eaa78dc4c3a53d
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-01-31 14:31:04 +01:00
Xizhi Zhu
ba9302b8a9 Remove Symbian specific code from qtbase.
Change-Id: I27d37d914b71e1e43c94e2a975ffec49e1ecd456
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-01-31 07:08:31 +01:00
Jeremy Lainé
e54dc7c2b5 Add support for DNS lookups using native APIs
The QDnsLookup class provides asynchronous APIs for performing
DNS lookups. For now, the following lookups are supported:
- A and AAAA
- CNAME as defined per RFC 1035
- MX as defined per RFC 1035
- NS as defined per RFC 1035
- PTR as defined per RFC 1035
- SRV as defined per RFC 2782
- TXT as defined per RFC 1035

Task-number: QTBUG-10481
Change-Id: I46c1741ec23615863eeca3a1231d5e3f8942495e
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-01-30 16:39:46 +01:00
Jason McDonald
5635823e17 Remove "All rights reserved" line from license headers.
As in the past, to avoid rewriting various autotests that contain
line-number information, an extra blank line has been inserted at the
end of the license text to ensure that this commit does not change the
total number of lines in the license header.

Change-Id: I311e001373776812699d6efc045b5f742890c689
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2012-01-30 03:54:59 +01:00
Gunnar Sletta
4ecf82795d Remove use of QT_MODULE from library
These defines were there to aid in the commercial
licensing scheme we used long ago, and are no longer needed.

Keep a QT_MODULE(x) define so other modules continue compiling.

Change-Id: I8fd76cd5270df8f14aee746b6cf32ebf7c23fec7
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-01-25 10:19:44 +01:00
aavit
48f9ba388b Remove support for the MNG file format and the bundled libmng
The MNG file format is generally abandoned, and libmng has been
unmaintained for several years.

The MNG plugin and bundled libmng has been moved to the
qtimageformats project on Gerrit.

Task-number: QTBUG-21869
Change-Id: I946432347014ffde2b72307a5f8b166ca5553602
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-01-25 02:22:18 +01:00
Samuel Rødal
b39df8bf92 Made window orientation API more flexible.
Previously we only had QWindow::setOrientation() which was a hint about
the orientation the window's contents were rendered in.

However, it's necessary to separate between the orientation
corresponding to the window buffer layout and orientation of the
contents. A game for example might typically want to use a landscape
buffer even on a portrait device. Thus, we replace
QWindow::orientation() with QWindow::reportContentOrientationChange() and
QWindow::requestWindowOrientation().

Change-Id: I1f07362192daf36c45519cb05b43ac352f1945b5
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-01-24 15:38:48 +01:00
Jason McDonald
7827c1861f Update obsolete contact address.
Replace Nokia contact email address with Qt Project website.

Change-Id: Id689fdb78727abafba033bed7b0402e2cf27aba1
Reviewed-by: Jonas Gastal <jgastal@profusion.mobi>
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2012-01-23 04:04:33 +01:00
Jason McDonald
629d6eda5c Update contact information in license headers.
Replace Nokia contact email address with Qt Project website.

Change-Id: I431bbbf76d7c27d8b502f87947675c116994c415
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2012-01-23 04:04:33 +01:00
Friedemann Kleint
e752a98b5a QPA/windows example: Fix positioning for virtual desktops.
Position window within screen geometry.

Change-Id: Id931f386c9ef5564887a2f54b71921f062320f54
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-01-20 17:21:25 +01:00
Lars Knoll
253c801c56 Remove QDir::convertSeparators()
This method has been deprecated since Qt 4.2.
QDir::toNativeSeparators() replaces it since then.

Change-Id: I49e6e1bfd50f26aa30134e599ee82067709549a7
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
2012-01-19 16:41:44 +01:00
Jonas M. Gastal
bdce610022 Fixes examples/tests to use qinptr in QTcpServer::incomingConnection.
This is a fix for problems introduced by bf7f170.

Change-Id: If5dd8e031ef2efea578b3efb188c2e950e1ba41a
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
2012-01-13 20:55:00 +01:00
Jonas M. Gastal
1453f74cc5 Make QFtp private.
All references to QFtp in documentation have been removed, QFtp's
documentaiton was marked internal. The QFtp example was removed.

Task-number: QTBUG-23199
Change-Id: Ifff83cac069fb350e8ebeae63e605850e65c0c30
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
2012-01-12 14:38:55 +01:00
Jason McDonald
5313c28b30 Update year in Nokia copyright headers.
The previous change missed some headers from years prior to 2011, and a
few new files were merged after the previous change.

Change-Id: Ib7d1a2b7062228c2a5373da64242b2ee1f0981e1
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2012-01-10 07:12:41 +01:00
Jason McDonald
4c66ab91a9 Remove execute permission from files that don't need it.
Change-Id: Ib92875289cdd9831f35301c566fb567acc725bb6
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-01-10 01:24:22 +01:00
Jonas M. Gastal
b3ce4470ae Removing QHttp class, its tests and its usage in examples.
Task-number: QTBUG-22750
Change-Id: I161fad772bfb26797e6ee9d69da925b6747c371f
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-01-06 23:07:26 +01:00
Pekka Vuorela
8ad583b7f9 Removed QApplication::setInputContext()
Obsoleted by platform input context. Setting a custom QInputContext
wouldn't work properly anymore.

Change-Id: I966573a82fdd7530544878513a655eae7b3ad67b
Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com>
2012-01-05 11:40:08 +01:00
Jason McDonald
1fdfc2abfe Update copyright year in license headers.
Change-Id: I02f2c620296fcd91d4967d58767ea33fc4e1e7dc
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2012-01-05 06:36:56 +01:00
Stephen Kelly
f29e55448b Change the default value of QSortFilterProxyModel::dynamicSortFilter
The value is changed to true. It is a common bug that developers expect
this proxy model to reflect the source model when the source changes.
That requires setDynamicSortFilter(true), so we change the default to
optimize for the common case.

Change-Id: I9bf7efdbda10309fa77aed9391c33054aaae4a29
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-01-02 16:43:02 +01:00
Samuel Rødal
e68642fe10 Added multi-screen support to hellowindow example.
Change-Id: I025de342952bffeffa0705eb4cfcf869f32241cc
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
2011-12-06 20:14:10 +01:00
Samuel Rødal
c7ba279815 Added rotation animation to paintedwindow example.
This serves as a useful test case for the QScreen orientation API.

Change-Id: I009ebd8b6d345453620420d84f3ff9d2d2e2663e
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
2011-12-01 10:51:10 +01:00
Friedemann Kleint
67e613963d Polish the HelloWindow example.
- Add window menu (enabling the close button on Windows)
- Query threaded Open GL capability.

Change-Id: I938f154e242dba584e2f597ac44294ab5d3b7141
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-11-28 15:08:01 +01:00
Samuel Rødal
f65cda93e9 Added command line argument to make hellowindow example single window.
Useful when testing on embedded platforms with no support for multiple
top-level windows.

Change-Id: I212ca69c3f5d5d338e860169b14e3f9f3951712b
Reviewed-by: Andy Nichols <andy.nichols@nokia.com>
2011-11-21 12:57:49 +01:00
Andy Shaw
36ea62e64f Compile fix for Mac OS X 10.7 with 10.6 sdk
Since it is an example it is cleaner to just include the header file
as it will be available on other platforms anyway.  Also ensured that
the Qt includes were first before the system ones.

Task-number: QTBUG-22641

Merge-request: 1462
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
(cherry picked from commit 4fffdabc948ff6afc6008d4cb723a6a2e10eef79)
Change-Id: I4fffdabc948ff6afc6008d4cb723a6a2e10eef79
2011-11-18 20:25:53 +01:00
Bradley T. Hughes
3c74720f74 Assign function argument to class member, not to itself
The 'worker' function argument shadows the class member of the same
name, and 'worker = worker;' assigns the function argument to itself,
not to the member as intended.

examples/tutorials/threads/movedobject/thread.cpp:69: warning:
explicitly assigning a variable of type 'QObject *' to itself [-Wself-
    worker = worker;
    ~~~~~~ ^ ~~~~~~

Change-Id: If4adf486a86a4ba4e7f7040a7771a70b7dd9aa86
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2011-11-09 15:28:36 +01:00
Friedemann Kleint
e0cae9af5e qtbase/examples: Add options to standarddialogs example.
Categorize dialogs using a toolbox and add an
options groupbox for dialogs that have options flags.

Besides example usage, this allows people implementing
platform native dialogs to play around with the options.

Change-Id: Icc0fd00382332b11783271ef15a0583c18758784
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2011-11-07 13:26:41 +01:00
Bradley T. Hughes
e87d1130fb Reimplement GLTexture::failed() properly in GLRenderTargetCube
The GLRenderTargetCube::failed() method needs to be const.

Change-Id: I9bfa031e284b62c86a9be786aea3b851582b71f4
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
2011-10-31 20:34:43 +01:00
Samuel Rødal
ba92fe9222 Re-added hellogl_es and ES 1 support for QOpenGLContext.
Change-Id: I576cf3595cdeeefb4ed840bb3b2b7097b3609cc7
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
2011-10-31 12:37:51 +01:00
Friedemann Kleint
1cae2fdb86 Examples, plugins: Remove remains of qpa in profiles.
Change-Id: I0fc45c6c4df6d1f07472aec30b9e64b55db8e543
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2011-10-28 15:04:54 +02:00
Samuel Rødal
77d30df7e5 Get rid of legacy glTexParameterf calls.
ES 1.0 didn't have glTexParameteri, which is why we sometimes used
glTexParameterf. However, we shouldn't use glTexParameterf because
that's treating integer values as floating point, which is not type
safe. ES 1.1+ and ES 2.x have glTexParameteri, and we don't really care
about supporting ES 1.0 in any case in Qt 5.

Change-Id: I6b586b31ddc418ba319c4cc88f6bb3978fdbd040
Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com>
2011-10-28 12:14:10 +02:00
David Faure
dfa24768a3 Deprecate QDesktopServices::storageLocation/displayName
Which required porting the related unittests to qstandardpaths

Change-Id: I6eb63c46845f05cd29cc42b59872707526277c90
Reviewed-by: Thiago Macieira (Intel) <thiago.macieira@intel.com>
2011-10-23 15:28:25 +02:00
Simon Hausmann
6a7da1fb58 Fix compilation on Harmattan
Commit 87274e272d removed the maemo "specific"
bearer monitory example .ui file, but the .pro file wasn't updated.

Change-Id: I9daa000fe3e4b69789519f53541c106d01748ffd
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2011-10-21 16:54:45 +02:00
Shane Kearns
296bc32841 Fix FTP example to handle failure to open network session
The example code only dealt with successful opening of the session.
If the session open failed, the application is stuck because the
connect button is disabled.
Moved the session open to be part of connection.
Handled session open failure by puttin the UI back in the default
state where connection button is enabled.

Task-Number: QTBUG-9909
Reviewed-By: Miikka Heikkinen
(cherry picked from commit 104c22a68c422152ff3cf03eb3615e7826fefbd0)

Change-Id: Ifa40fcd8b83c43cda364b3ec5e58f80b539aa244
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
2011-10-20 23:56:52 +02:00
Friedemann Kleint
87274e272d QtBase examples: Remove Maemo/Symbian-specific code.
- Maemo/Symbian are no longer supported and QWidget-based examples
  are no longer supposed to run on mobile platforms, so, remove any
  Maemo/Symbian or mobile-specific code from source files and
  profiles.
- Remove Maemo/Symbian vibration examples.
- Change Q_WS_MAC/WIN to Q_OS_MAC/WIN where appropriate.

Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>

Change-Id: I488a0adadb98934567aa6416206a80465c9c3a81
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2011-10-18 15:47:49 +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
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
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
Kent Hansen
a1d19b0917 Make examples build with Qt-in-namespace
Change-Id: Ie4710b8f3afb44191927bab94eb47e00207cb831
Reviewed-on: http://codereview.qt-project.org/5684
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
2011-09-28 12:18:53 +02:00
Lars Knoll
9e05e44bb4 Fix compilation
Change-Id: I6eec01349126393183ec8df99a50f96c192ee0c2
Reviewed-on: http://codereview.qt-project.org/5099
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-09-19 21:05:28 +02:00
Jason Barron
36ee35406d Get the 'dockwidgets' example to compile.
Required printersupport.

Change-Id: Idd525e847f793631b70204d25c4fc949279801bf
Reviewed-on: http://codereview.qt-project.org/4915
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-09-15 09:11:35 +02:00
Jason McDonald
85675b31bf Add missing license headers
Examples get the BSD license header.

Change-Id: I4802cc00815c69e2f113aa8973d61203357212e3
Reviewed-on: http://codereview.qt-project.org/4849
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2011-09-15 03:27:45 +02:00
Lars Knoll
f9748f8cce Remove uilib and QtUiTools from QtBase
The code gets moved into the qttools repository,
where it belongs naturally.

Change-Id: Ia50bfe212ead3365d5c3bcb24d2c5e92e2e9de8e
2011-09-13 20:11:40 +02:00
Gunnar Sletta
b62bd0584a Merge branch 'refactor'
Conflicts:
	mkspecs/qws/linux-lsb-g++/qmake.conf
	src/gui/image/qpixmap_mac.cpp
	src/gui/painting/qpaintengine_x11.cpp
	src/gui/painting/qtessellator.cpp
	src/gui/text/qfontengine_qws.cpp
	src/gui/text/qfontengine_x11.cpp
	src/gui/widgets/qlinecontrol.cpp
	src/opengl/qgl.h
	src/opengl/qgl_x11egl.cpp
	src/plugins/plugins.pro

Change-Id: If52dcd55cd55f2983a756c2f843967702b60a310
2011-09-13 08:54:45 +02:00
suzuki toshiya
5dd78ba08f Replace 'i < len-1 && func(i+1)' by 'i+1 < len && func(i+1)'
Merge-request: 1299
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>

(cherry picked from commit 81f0c44f6a4fd4cfa41af5d5b292008185bf3981)

Conflicts:
	src/qt3support/itemviews/q3listbox.cpp
	src/qt3support/sql/q3datatable.cpp
	src/qt3support/text/q3richtext.cpp
	src/scripttools/debugging/qscriptcompletiontask.cpp
	src/scripttools/debugging/qscriptdebuggercodeview.cpp

Change-Id: Ie70590e77e69fbb9b2322c48c3963fd9cbba19e6
Reviewed-on: http://codereview.qt-project.org/4581
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2011-09-12 16:03:47 +02:00
Lars Knoll
a15d079187 Fix compilation
Change-Id: I0b562f810bc12e728f59976ad8467a5ce9fd9bec
Reviewed-on: http://codereview.qt-project.org/4666
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-09-12 13:41:58 +02:00
Samuel Rødal
1b18315001 Improved and made public the QOpenGLPaintDevice API.
The new API is more flexible, allowing the use of QOpenGLPaintDevice
with any QOpenGLContext, and putting more responsibility on the user for
ensuring the correct FBO is current (the user knows best anyhow).

Task-number: QTBUG-21263

Change-Id: I50b954125f552baef52fbb3fe2ed907a11ad519c
Reviewed-on: http://codereview.qt-project.org/4325
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Paul Olav Tvete <paul.tvete@nokia.com>
2011-09-08 11:07:56 +02:00
Samuel Rødal
a7d682dd9c Fixed hellowindow making context current in wrong thread.
Make the context a child of the Renderer, which is already moved to the
correct thread.

Change-Id: Iafda090e15b322c03e2c10b1905050f636b90197
Reviewed-on: http://codereview.qt.nokia.com/3915
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
2011-08-31 09:26:48 +02:00
Gunnar Sletta
df0ff8fd4e Merge branch 'master' into refactor 2011-08-31 08:14:48 +02:00
Bradley T. Hughes
22ea360fb9 Compile fix on Mac OS X
The file is called shapeitem.cpp (lowercase i), not shapeItem.cpp (with
uppercase I)

Change-Id: I0dd230158cf8c8323bfa779901475535e7c7d694
Reviewed-on: http://codereview.qt.nokia.com/3883
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-08-30 15:27:19 +02:00
Samuel Rødal
6e28e8441b Copy core GL functionality to QtGui with QGL -> QOpenGL naming.
Change-Id: Ibc989afa4a30dd184d41d1a1cd89f97196e48855
Reviewed-on: http://codereview.qt.nokia.com/3710
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
2011-08-29 10:25:24 +02:00
Friedemann Kleint
ca56c9400c Temporarily disable printers on Windows, fix export.
Change-Id: I351692b53cf559cd3be64cec8907bd544ba41593
Reviewed-on: http://codereview.qt.nokia.com/3653
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Oliver Wolff <oliver.wolff@nokia.com>
2011-08-26 12:13:56 +02:00
Friedemann Kleint
5e6605f7b0 Fix building of examples.
Change-Id: Iebb56c81fd13deaa82d8883e3f1529f1a78ebea8
Reviewed-on: http://codereview.qt.nokia.com/3603
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2011-08-25 15:54:16 +02:00
Gunnar Sletta
04d0a9626c Merge branch 'master' into refactor
Conflicts:
	src/gui/kernel/qapplication_qpa.cpp
	src/gui/kernel/qcursor_qpa.cpp
	src/gui/kernel/qwindowsysteminterface_qpa.cpp
	src/gui/kernel/qwindowsysteminterface_qpa.h
	src/gui/kernel/qwindowsysteminterface_qpa_p.h
	src/gui/text/qtextcontrol.cpp
	src/plugins/platforms/wayland/wayland.pro
	src/widgets/accessible/qaccessible2.h
	src/widgets/widgets/qwidgetlinecontrol_p.h

Change-Id: I5e6f4eb184159dccc67e8f13673edb884d179c74
2011-08-25 12:48:52 +02:00
Paul Olav Tvete
1bf7fc2f1a make 'make install' install
Change-Id: I766e7917f6362b1f9cc26d18381e8d76eaf6ff83
Reviewed-on: http://codereview.qt.nokia.com/3261
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-08-23 14:34:48 +02:00
Samuel Rødal
66d9b4d2f8 Make the hellowindow example multi-threaded to stress the GL backend.
Change-Id: I9e158c0889b050f9ed76ea21176102fc792eef83
Reviewed-on: http://codereview.qt.nokia.com/3150
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Paul Olav Tvete <paul.tvete@nokia.com>
2011-08-19 13:57:30 +02:00
Lars Knoll
f4f1b53b96 Move printing into it's own library
Create a libQtPrintSupport library that contains our current
printing infrastructure. Long term this will get replaced
with a libQtPrint, as the current architecture is not
really maintainable.

Change-Id: I7362fff6786b58c5b4e9213c23eda36d15048aa2
Reviewed-on: http://codereview.qt.nokia.com/3209
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
2011-08-19 09:16:42 +02:00
Lars Knoll
699e8fe3a6 Use the paged paintdevice in the print() method of QTextDocument.
This is required to be able to move the printing system into
it's own library.

Change-Id: If70a55be4c4413f9cd917a30d1b368f32c1145e4
Reviewed-on: http://codereview.qt.nokia.com/3207
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
2011-08-19 09:16:22 +02:00
Paul Olav Tvete
78056064cc Build fix after setPreferredPaintEngine was removed
Change-Id: I286529e0e1917ee3c808eba7dad0957dd4d8194f
Reviewed-on: http://codereview.qt.nokia.com/3083
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-08-17 11:59:53 +02:00
Samuel Rødal
0d5170256c Get rid of OpenGL 1.x engine and platform code from QtOpenGL.
Change-Id: I646b8e26d5e7214432a044866764d57cc11b2390
Reviewed-on: http://codereview.qt.nokia.com/3006
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
2011-08-16 15:44:26 +02:00
Liang Qi
92d88e4755 Support -qtnamespace and -qtlibinfix in qtbase examples
Task-number: QTBUG-19971
Change-Id: Ie20eb2fc133658dd34e1ec25a3b80c36f0f01aa3
Reviewed-on: http://codereview.qt.nokia.com/2754
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Liang Qi <liang.qi@nokia.com>
2011-08-08 16:41:27 +02:00
Samuel Rødal
92c998afb6 Merge remote branch 'gerrit/master' into refactor
Conflicts:
	src/gui/kernel/qapplication_x11.cpp
	src/gui/widgets/qlinecontrol.cpp
	src/gui/widgets/qlinecontrol_p.h
	src/gui/widgets/qtabwidget.h

Change-Id: I90ba893a5553b9ff5658ca0a3221ecf76be4c736
2011-08-03 11:03:22 +02:00
Jason McDonald
c8a31a3100 Eliminate reference to Trolltech.
Task-number: QTBUG-19653

Change-Id: If3c822dd59ccbdd03037068acfe902ed9688a874
Reviewed-on: http://codereview.qt.nokia.com/2482
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2011-08-02 13:14:55 +02:00
Jason McDonald
d692b8663c Fix obsolete contact email
Replace the old Trolltech contact email address with the current Qt
contact email address.

Task-number: QTBUG-20370
Change-Id: If5b9c3a044e1ee46264548eea456c704ced8e363
Reviewed-on: http://codereview.qt.nokia.com/2153
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2011-07-28 10:03:45 +02:00
Samuel Rødal
c3da77798b Added workable QScreen API on top of QPlatformScreen.
QPlatformIntegration::screens() no longer has to be implemented,
implementations should call QPlatformIntegration::screenAdded() for each
screen instead. This is for being able to support adding screens at
run-time later on, by connecting it to a signal in QGuiApplication.

The QGuiGLContext API has changed a bit, by not sending in all the
parameters in the constructor but instead having a create() function.
The createPlatformGLContext() factory in QPlatformIntegration takes a
QGuiGLContext * instead of a QSurfaceFormat and a share context, similar
to how the window and backing store factory functions work.

The XCB plugin has experimental support for connecting to multiple X
displays simultaneously, creating one or more QScreen for each.

Change-Id: I248a22a4fd3481280710110272c04a30a8021e8f
Reviewed-on: http://codereview.qt.nokia.com/2103
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
2011-07-25 13:52:09 +02:00
Friedemann Kleint
e80b661952 Build fix for examples.
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>

Change-Id: I36f5a4088a39673a8e74a4d53ac83a42696af096
Reviewed-on: http://codereview.qt.nokia.com/2095
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2011-07-25 10:36:19 +02:00
Samuel Rødal
7b3b6b5afa Merge remote branch 'gerrit/master' into refactor
Conflicts:
	examples/opengl/cube/main.cpp
	examples/widgets/applicationicon/main.cpp
	examples/widgets/orientation/main.cpp
	src/gui/image/qicon.cpp
	src/gui/image/qimage.h
	src/gui/image/qpixmap.h
	src/gui/image/qpixmap_mac.cpp
	src/gui/kernel/qapplication.cpp
	src/gui/kernel/qpalette.cpp
	src/gui/kernel/qwidget.cpp
	src/gui/styles/qmacstyle_mac.mm
	src/gui/widgets/qmenubar.cpp
	src/gui/widgets/qslider.cpp
	src/opengl/qwindowsurface_gl.cpp
	tests/auto/qvariant/qvariant.pro
	tests/benchmarks/corelib/kernel/qobject/qobject.pro
	tests/benchmarks/gui/animation/qanimation/qanimation.pro
	tests/benchmarks/gui/graphicsview/qgraphicsanchorlayout/qgraphicsanchorlayout.pro
	tests/benchmarks/gui/graphicsview/qgraphicsitem/qgraphicsitem.pro
	tests/benchmarks/gui/graphicsview/qgraphicsscene/qgraphicsscene.pro
	tests/benchmarks/gui/graphicsview/qgraphicsview/qgraphicsview.pro
	tests/benchmarks/gui/graphicsview/qgraphicswidget/qgraphicswidget.pro
	tests/benchmarks/gui/image/qimagereader/qimagereader.pro
	tests/benchmarks/gui/itemviews/qtableview/qtableview.pro
	tests/benchmarks/gui/kernel/qapplication/qapplication.pro
	tests/benchmarks/gui/kernel/qwidget/qwidget.pro
	tests/benchmarks/gui/painting/qpainter/qpainter.pro
	tests/benchmarks/gui/painting/qtbench/qtbench.pro
	tests/benchmarks/gui/painting/qtracebench/qtracebench.pro
	tests/benchmarks/gui/text/qtext/qtext.pro

Change-Id: I4b911c795ecb29d73b6a7fd18819711b49478a30
2011-07-21 14:42:46 +02:00
David Boddie
f5c4cbb6d4 Doc: Speculative attempt to fix build breakage.
Case sensitivity problems strike again.
(cherry picked from commit 9aa5f949f092032589917a0bfe16e78828d0dabe)

Change-Id: I5c9472c385fb045db8ab8ea54ec69bebb934ec6c
Reviewed-on: http://codereview.qt.nokia.com/407
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: David Boddie
2011-07-21 08:54:05 +02:00
David Boddie
9c2de0d8c0 Doc: Fixed file name of a header file to use lower case characters.
(cherry picked from commit c68d24b7bafa3058d44c0a30ade329972403b6c6)

Change-Id: If733804fbab8baf5c4a5331005834ddeecec3ff4
Reviewed-on: http://codereview.qt.nokia.com/406
Reviewed-by: David Boddie
2011-07-21 08:54:02 +02:00
David Boddie
4686b7af03 Doc: Added missing license headers for documentation and examples.
Change-Id: I696f6ce2ee9b6055c549e615de952773d171f3e7
Reviewed-on: http://codereview.qt.nokia.com/408
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: David Boddie
2011-07-20 15:12:53 +02:00
Samuel Rødal
310519d6d1 Rename QPixmapData to QPlatformPixmap.
Makes the API symmetric with the other Lighthouse APIs.

Change-Id: I8a399f3c968ea35d4624711b31f2ac5bb94b7893
Reviewed-on: http://codereview.qt.nokia.com/1735
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
2011-07-19 09:50:37 +02:00
Ritt Konstantin
d17c76feee drop an obsolete QChar::NoCategory enum value
there is no such category in the Unicode specs. the QChar::NoCategory
was a subject of bugs since it was introduced. int 4.6 it's meaning was
limited to mention ucs4 > UNICODE_LAST_CODEPOINT only (which is useless anyways)
in order to preserve the old (wrong) behavior.
fix it now for qtbase

Change-Id: I630534824e071090b39772881e747c1fdb758719
Reviewed-on: http://codereview.qt.nokia.com/1584
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-07-13 13:31:13 +02:00
Samuel Rødal
2371147354 Merge remote branch 'gerrit/master' into refactor
Conflicts:
	src/gui/image/qicon.cpp
	src/gui/image/qicon.h
	src/gui/image/qicon_p.h
	src/gui/text/qfontdatabase.cpp
	src/plugins/platforms/wayland/gl_integration/qwaylandglwindowsurface.cpp
	src/plugins/platforms/wayland/gl_integration/wayland_egl/qwaylandglcontext.cpp
	src/plugins/platforms/wayland/gl_integration/xcomposite_egl/qwaylandxcompositeeglwindow.cpp
	sync.profile

Change-Id: Ie0a23a12177ff51bf562e15b2dd41f071afb19b4
2011-07-12 12:52:22 +02:00
Casper van Donderen
6efe729881 Remove more references to demos.
Change-Id: I431184cd0534c86047706fdaa1045b2935de5d7a
Reviewed-on: http://codereview.qt.nokia.com/1307
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: David Boddie
2011-07-08 15:36:26 +02:00
Olli Werwolff
554f0ec3de Remove multimedia subdir from examples
Change-Id: I099c5a8785798a41968ec2793384ee58ac0fde39
Reviewed-on: http://codereview.qt.nokia.com/1269
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2011-07-07 10:33:23 +02:00
Lars Knoll
314fdbce8c Merge remote branch 'gerrit/master' into refactor
Conflicts:
	config.tests/unix/opengldesktop/opengldesktop.cpp
	examples/itemviews/interview/interview.pro
	examples/mainwindows/mainwindow/mainwindow.pro
	examples/openvg/README
	examples/richtext/textedit/textedit.pro
	examples/tools/undo/undo.pro
	src/corelib/global/qglobal.h
	src/corelib/kernel/qcoreapplication.h
	src/corelib/kernel/qcoreevent.h
	src/corelib/kernel/qmetatype.h
	src/gui/kernel/qevent.cpp
	src/gui/kernel/qevent.h
	src/gui/painting/qpaintengine_raster.cpp
	src/gui/painting/qpaintengine_raster_p.h
	src/gui/text/qfontdatabase.cpp
	src/opengl/qgl.h
	src/openvg/qpaintengine_vg.cpp
	src/plugins/platforms/wayland/qwaylandwindow.cpp
	tests/auto/qmainwindow/qmainwindow.pro

Change-Id: I6bfb586740a68379bb99f4612ec993393a5f3234
2011-07-06 14:08:02 +02:00
Casper van Donderen
a97d4dcb24 Remove references to QT_INSTALL_DEMOS & DemosPath.
The distinction between 'examples' and 'demos' is completely blurred at
this point. We've decided, with the SDK people, to scrap the existing
terminology in favor of the word 'example' only -- distinguishing
between code snippets, walkthroughs, "demonstrations" can be done
via keywords or some other method.

Removing QT_INSTALL_DEMOS from all .pro files in Qt is still in
progress.

Change-Id: I86fc0e40d54baa54c5641fc6acbd8b67e4ad2789
Reviewed-on: http://codereview.qt.nokia.com/1034
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2011-07-06 13:29:44 +02:00
Casper van Donderen
192eae5797 Remove references to demos from docs.
Change-Id: I1ae723af883c305ea64a4e46cc3ce889dd3c021b
Reviewed-on: http://codereview.qt.nokia.com/1032
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: David Boddie
2011-07-05 19:57:54 +02:00
Casper van Donderen
6f262a60d1 Add the richtext and tools demo-examples to build.
Change-Id: I3a64dc0fb11f9ebbcb0cb2f97598370ca5962a3c
Reviewed-on: http://codereview.qt.nokia.com/773
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: David Boddie
2011-06-28 14:20:51 +02:00
Peter Hartmann
9b46943686 SSL example: update secure socket client example to use new cert API
issuerInfo and subjectInfo now return a QStringList instead of a QString

Change-Id: I04174a7f6319ae156ac8de964d04c0525c9c5a9a
Reviewed-on: http://codereview.qt.nokia.com/799
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
2011-06-27 20:44:36 +02:00
Casper van Donderen
59d1278c9e Add the mainwindows demos-examples to the build.
Change-Id: I6ec0be8f058ad127c759fff3c4082a596db53405
Reviewed-on: http://codereview.qt.nokia.com/752
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Kevin Wright <kevin.wright@nokia.com>
2011-06-27 13:47:53 +02:00
Casper van Donderen
b138e14c40 Add the itemviews demos-examples to the build.
Change-Id: I032216c228193040568ef5d547685b587d2a43e6
Reviewed-on: http://codereview.qt.nokia.com/751
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Kevin Wright <kevin.wright@nokia.com>
2011-06-27 13:47:53 +02:00
Jørgen Lind
18a3f6169b Merge remote-tracking branch 'base/master' into refactor
Conflicts:
	demos/demos.pro
	demos/embedded/digiflip/digiflip.pro
	examples/examples.pro
	examples/graphicsview/embeddeddialogs/embeddeddialogs.pro
	src/gui/kernel/qplatformglcontext_qpa.cpp
	src/plugins/platforms/wayland/gl_integration/xcomposite_egl/qwaylandxcompositeeglcontext.cpp
	src/plugins/platforms/wayland/gl_integration/xcomposite_glx/qwaylandxcompositeglxcontext.cpp
	src/plugins/platforms/wayland/qwaylanddisplay.cpp
	src/plugins/platforms/wayland/qwaylandwindow.cpp

Change-Id: I2a4ec9e2ca9c9aa9d57b55f98985e810b77bb745
2011-06-27 12:27:54 +02:00
Casper van Donderen
89459bc7cf Add the painting demos-examples to build.
Change-Id: Ia6f23719af0ec3091573909b5666ec795ee22410
Reviewed-on: http://codereview.qt.nokia.com/685
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2011-06-27 10:59:28 +02:00
Casper van Donderen
d15d0b125b Add the shared painting and affine example to the build.
Change-Id: I85e66c9a33a1c908b7588beb219cc9540698ab68
Reviewed-on: http://codereview.qt.nokia.com/623
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
2011-06-27 10:59:28 +02:00
Casper van Donderen
ebfbac6145 Add the embedded demos-examples to the build.
Change-Id: Ib0a1e650913416e3ec05f1a86c139844a814f8bf
Reviewed-on: http://codereview.qt.nokia.com/686
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: David Boddie
2011-06-24 16:47:24 +02:00
Casper van Donderen
64cb29a252 Add the graphicsview demo-examples to the build.
Change-Id: I2f97985db9e547c37db00c32b2e1a1658f076f75
Reviewed-on: http://codereview.qt.nokia.com/684
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: David Boddie
2011-06-24 16:47:24 +02:00
Casper van Donderen
21aba79915 Update sql and animation demos to be an example.
Change-Id: I683383e2dab9428ea3fe4cfffba24bb7fefbc7c7
Reviewed-on: http://codereview.qt.nokia.com/618
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: David Boddie
2011-06-24 16:47:24 +02:00