summaryrefslogtreecommitdiffstats
path: root/examples
Commit message (Collapse)AuthorAgeFilesLines
* Use new plugin system in qtbase.Friedemann Kleint2012-02-2719-28/+33
| | | | | | | | | - AccessibleWidgets - Windows printer support - Examples Change-Id: Icc162bd7fc284b3c76d9966210f983728085c743 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Fix compilation of examples with QStringBuilderOlivier Goffart2012-02-253-5/+5
| | | | | | | | | | | | 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>
* examples: compile w/o openglMarc Mutz2012-02-248-13/+20
| | | | | | | Fixes remnants of an automated QtGui -> QtWidgets port. Change-Id: I31f63bdd6ae71aee8e70b20e24def30e0eafb725 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* clean up qmake-generated projectsOswald Buddenhagen2012-02-2428-219/+23
| | | | | | | | remove "header" and assignmets which are defaults or bogus, reorder some assignments. Change-Id: I67403872168c890ca3b696753ceb01c605d19be7 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Test for QT_NO_SSL instead of QT_NO_OPENSSLShane Kearns2012-02-213-5/+5
| | | | | | | | 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>
* Fortune client example - list all IP addressesShane Kearns2012-02-172-18/+28
| | | | | | | | | | | 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>
* Move QtConcurrent into its own moduleLars Knoll2012-02-0510-5/+11
| | | | | | | Task-number: QTBUG-20892 Change-Id: I614500aafb6428915509983608bbb0ade4e4f016 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Exclude helloconcurrent when QtConcurrent is not configuredSamuli Piippo2012-02-051-1/+2
| | | | | | | Task-number: QTBUG-23874 Change-Id: I374a08ce947e804ebb1da08c413e340e4719d9d0 Reviewed-by: Jonas Gastal <jgastal@profusion.mobi> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Fix the chart itemview exampleGiuseppe D'Angelo2012-02-032-2/+3
| | | | | | | | | | | Commit 054a4aa7dddacbe31778c5c5e9ffc9d41f803353 (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>
* Improve QSurface / QWindow API a bit and use that to avoid errorsGunnar Sletta2012-02-021-0/+2
| | | | | Change-Id: Iadba1c3a7b8e6bc7f145455132cefed2a905c11d Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Reimplement QAbstractSocket::setReadBufferSize() properlyBradley T. Hughes2012-02-022-2/+2
| | | | | | | | | | | | | | | | | 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>
* Moving tiff image format support and libtiff out of qtbaseaavit2012-01-312-2/+2
| | | | | | | | | | 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>
* Remove Symbian specific code from qtbase.Xizhi Zhu2012-01-313-8/+0
| | | | | Change-Id: I27d37d914b71e1e43c94e2a975ffec49e1ecd456 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Add support for DNS lookups using native APIsJeremy Lainé2012-01-304-0/+229
| | | | | | | | | | | | | | | | 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>
* Remove "All rights reserved" line from license headers.Jason McDonald2012-01-301180-1181/+1144
| | | | | | | | | | 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>
* Remove use of QT_MODULE from libraryGunnar Sletta2012-01-251-1/+0
| | | | | | | | | | 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>
* Remove support for the MNG file format and the bundled libmngaavit2012-01-254-4/+3
| | | | | | | | | | | | | 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>
* Made window orientation API more flexible.Samuel Rødal2012-01-242-31/+26
| | | | | | | | | | | | | | | 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>
* Update obsolete contact address.Jason McDonald2012-01-234-6/+2
| | | | | | | | 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>
* Update contact information in license headers.Jason McDonald2012-01-231143-1143/+1143
| | | | | | | Replace Nokia contact email address with Qt Project website. Change-Id: I431bbbf76d7c27d8b502f87947675c116994c415 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* QPA/windows example: Fix positioning for virtual desktops.Friedemann Kleint2012-01-201-0/+4
| | | | | | | Position window within screen geometry. Change-Id: Id931f386c9ef5564887a2f54b71921f062320f54 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Remove QDir::convertSeparators()Lars Knoll2012-01-191-1/+1
| | | | | | | | | 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>
* Fixes examples/tests to use qinptr in QTcpServer::incomingConnection.Jonas M. Gastal2012-01-136-6/+6
| | | | | | | | 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>
* Make QFtp private.Jonas M. Gastal2012-01-1210-600/+0
| | | | | | | | | 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>
* Update year in Nokia copyright headers.Jason McDonald2012-01-1013-13/+13
| | | | | | | | 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>
* Remove execute permission from files that don't need it.Jason McDonald2012-01-10218-0/+0
| | | | | Change-Id: Ib92875289cdd9831f35301c566fb567acc725bb6 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Removing QHttp class, its tests and its usage in examples.Jonas M. Gastal2012-01-062-18/+32
| | | | | | Task-number: QTBUG-22750 Change-Id: I161fad772bfb26797e6ee9d69da925b6747c371f Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Removed QApplication::setInputContext()Pekka Vuorela2012-01-0510-987/+0
| | | | | | | | 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>
* Update copyright year in license headers.Jason McDonald2012-01-051175-1183/+1183
| | | | | Change-Id: I02f2c620296fcd91d4967d58767ea33fc4e1e7dc Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Change the default value of QSortFilterProxyModel::dynamicSortFilterStephen Kelly2012-01-023-4/+1
| | | | | | | | | | 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>
* Added multi-screen support to hellowindow example.Samuel Rødal2011-12-063-9/+36
| | | | | Change-Id: I025de342952bffeffa0705eb4cfcf869f32241cc Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Added rotation animation to paintedwindow example.Samuel Rødal2011-12-013-23/+141
| | | | | | | This serves as a useful test case for the QScreen orientation API. Change-Id: I009ebd8b6d345453620420d84f3ff9d2d2e2663e Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Polish the HelloWindow example.Friedemann Kleint2011-11-283-3/+7
| | | | | | | | - 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>
* Added command line argument to make hellowindow example single window.Samuel Rødal2011-11-211-19/+25
| | | | | | | | 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>
* Compile fix for Mac OS X 10.7 with 10.6 sdkAndy Shaw2011-11-181-2/+2
| | | | | | | | | | | | | 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
* Assign function argument to class member, not to itselfBradley T. Hughes2011-11-091-1/+1
| | | | | | | | | | | | | | 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>
* qtbase/examples: Add options to standarddialogs example.Friedemann Kleint2011-11-072-49/+133
| | | | | | | | | | | | 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>
* Reimplement GLTexture::failed() properly in GLRenderTargetCubeBradley T. Hughes2011-10-311-1/+1
| | | | | | | | 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>
* Re-added hellogl_es and ES 1 support for QOpenGLContext.Samuel Rødal2011-10-317-0/+482
| | | | | Change-Id: I576cf3595cdeeefb4ed840bb3b2b7097b3609cc7 Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* Examples, plugins: Remove remains of qpa in profiles.Friedemann Kleint2011-10-283-14/+6
| | | | | Change-Id: I0fc45c6c4df6d1f07472aec30b9e64b55db8e543 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Get rid of legacy glTexParameterf calls.Samuel Rødal2011-10-282-8/+8
| | | | | | | | | | | 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>
* Deprecate QDesktopServices::storageLocation/displayNameDavid Faure2011-10-231-2/+2
| | | | | | | Which required porting the related unittests to qstandardpaths Change-Id: I6eb63c46845f05cd29cc42b59872707526277c90 Reviewed-by: Thiago Macieira (Intel) <thiago.macieira@intel.com>
* Fix compilation on HarmattanSimon Hausmann2011-10-211-9/+3
| | | | | | | | Commit 87274e272d2a854563066489e20d019b4e6320de 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>
* Fix FTP example to handle failure to open network sessionShane Kearns2011-10-202-24/+35
| | | | | | | | | | | | | | | | 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>
* QtBase examples: Remove Maemo/Symbian-specific code.Friedemann Kleint2011-10-18501-4019/+26
| | | | | | | | | | | | | | | - 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>
* Clean-up a macro for CocoaMorten Sorvig2011-10-102-70/+0
| | | | | | | | | 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>
* Added Orientation API to QScreen and QWindow.Samuel Rødal2011-10-072-4/+44
| | | | | | | | | | | | 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>
* Get rid of the last traces of QMimeSourceLars Knoll2011-09-291-0/+1
| | | | | | | | | | | 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>
* Make examples build with Qt-in-namespaceKent Hansen2011-09-283-0/+6
| | | | | | | 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>
* Fix compilationLars Knoll2011-09-192-1/+2
| | | | | | Change-Id: I6eec01349126393183ec8df99a50f96c192ee0c2 Reviewed-on: http://codereview.qt-project.org/5099 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>