summaryrefslogtreecommitdiffstats
path: root/examples/widgets/animation/sub-attaq
Commit message (Collapse)AuthorAgeFilesLines
* QtWidgets: replace 0 with \nullptr in documentationChristian Ehrlicher2019-01-281-1/+1
| | | | | | | | | | Replace 0 with \nullptr in the documentation. As a drive-by also replace some 0 with nullptr in the corresponding code. Change-Id: I8d7e9c838da1399988a830669d58fc7f2f010696 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Cleanup Widgets examples - foreachChristian Ehrlicher2019-01-234-7/+11
| | | | | | | | | Cleanup the Widgets examples - replace foreach with range-based for loop in the remaining directories Change-Id: I321e6c0f414401a1ae4fb65762b97d894b725afa Reviewed-by: Paul Wicking <paul.wicking@qt.io> Reviewed-by: Luca Beldi <v.ronin@yahoo.it>
* Cleanup Widgets examples - nullptrChristian Ehrlicher2019-01-239-20/+25
| | | | | | | | | Cleanup the widgets examples - replace 0 with nullptr Change-Id: Id4bf119b9a41f6d10117f3a613a6e604128fa196 Reviewed-by: Konstantin Shegunov <kshegunov@gmail.com> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Cleanup Widgets examples - new signal/slot syntaxChristian Ehrlicher2019-01-069-42/+43
| | | | | | | | | Cleanup the Widget examples - use the new signal/slot syntax where possible - animation, effects and graphicsview subdirectory Change-Id: I6cbaea6e628eb06f8e0ca6a0b795030a66b83878 Reviewed-by: Luca Beldi <v.ronin@yahoo.it> Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* Modernize the "animation" featureLiang Qi2018-10-122-10/+0
| | | | | | Change-Id: Ibc164b3df3cf87db569ef4813de458a9067b7f7d Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
* sub-attaq example: Fix crash with software Open GLFriedemann Kleint2018-03-141-2/+7
| | | | | | | | | Check whether an Open GL context could be created, else fall back to raster. Task-number: QTBUG-64797 Change-Id: I91bba41b0efca85293a1a4af054842b9f309b126 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* Change almost all other uses of qrand() to QRandomGeneratorThiago Macieira2017-11-083-7/+7
| | | | | | | | | | | | | | | | | | | The vast majority is actually switched to QRandomGenerator::bounded(), which gives a mostly uniform distribution over the [0, bound) range. There are very few floating point cases left, as many of those that did use floating point did not need to, after all. (I did leave some that were too ugly for me to understand) This commit also found a couple of calls to rand() instead of qrand(). This commit does not include changes to SSL code that continues to use qrand() (job for someone else): src/network/ssl/qsslkey_qt.cpp src/network/ssl/qsslsocket_mac.cpp tests/auto/network/ssl/qsslsocket/tst_qsslsocket.cpp Change-Id: Icd0e0d4b27cb4e5eb892fffd14b5285d43f4afbf Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* examples: remove some unneeded QStringRef::toString() callsMarc Mutz2017-04-071-4/+5
| | | | | | | | | | - when appending to another string - when just comparing - when just calling toInt() Change-Id: I6960784569b83bfd3e3640a8c04f2f909c293449 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* Examples: Remove a redundant virtual specifier for overridersAlexander Volkov2016-11-254-8/+8
| | | | | | | | It's a good practice to use override without virtual: https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md#Rh-override Change-Id: I5c2d73600e6c706424589c0487133c03a4ef3629 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Examples: Replace 'Q_DECL_OVERRIDE' by 'override'hjk2016-06-157-30/+30
| | | | | | | | Examples should demonstrate best practice, and we can use the keyword directly nowadays. Change-Id: I1f122e5caceca17290757ffbaf3d660e7daa9ae4 Reviewed-by: Topi Reiniö <topi.reinio@theqtcompany.com>
* Updated license headersJani Heikkinen2016-01-2127-450/+909
| | | | | | | | | | | | From Qt 5.7 -> examples are lisenced under BSD license, see http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/ Updated license headers to use new BSD header instead of LGPL21 one (in those files which will be under BSD) Change-Id: I3ad61caaf07802eb9da7d29eca3fe49d8a51b6a8 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com> Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* Update copyright headersJani Heikkinen2015-02-1127-189/+189
| | | | | | | | | | | | | | | | | | Qt copyrights are now in The Qt Company, so we could update the source code headers accordingly. In the same go we should also fix the links to point to qt.io. Outdated header.LGPL removed (use header.LGPL21 instead) Old header.LGPL3 renamed to header.LGPL3-COMM to match actual licensing combination. New header.LGPL-COMM taken in the use file which were using old header.LGPL3 (src/plugins/platforms/android/extract.cpp) Added new header.LGPL3 containing Commercial + LGPLv3 + GPLv2 license combination Change-Id: I6f49b819a8a20cc4f88b794a8f6726d975e8ffbe Reviewed-by: Matti Paaso <matti.paaso@theqtcompany.com>
* Update license headers and add new license filesMatti Paaso2014-09-2427-513/+297
| | | | | | | | | - Renamed LICENSE.LGPL to LICENSE.LGPLv21 - Added LICENSE.LGPLv3 - Removed LICENSE.GPL Change-Id: Iec3406e3eb3f133be549092015cefe33d259a3f2 Reviewed-by: Iikka Eklund <iikka.eklund@digia.com>
* Examples: Add Q_DECL_OVERRIDE to overridden functionsOlivier Goffart2014-07-157-30/+30
| | | | | | | | | | | | | | | | | | Q_DECL_OVERRIDE (which expands to 'override' for supported compiler) helps to declare the intent (that it is an overridden function) and force compilation error when there is no such virtual function in the base class. The examples should show the best practice of having it, as it may save the programmer quite some time in case of change of API or typo in the function name or arguments. This change was done automatically with clang-modernize -add-override -override-macros And fixed MSVC compilation by removing inline for TorrentViewDelegate::paint Change-Id: Ice66ae93fae571266f908703d5b8892b2c1ebb1a Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
* Fix warning about unused memberJędrzej Nowacki2014-03-061-2/+1
| | | | | | | sub-attaq/boat_p.h:134:9: warning: private field 'key' is not used [-Wunused-private-field] Change-Id: I3f4cb1325aaac71d2bf0e7807381742937d173f7 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Fix warnings about unused variables in sub-attaq-example (CLANG).Friedemann Kleint2013-03-063-10/+4
| | | | | Change-Id: Icad46a03a8d5875c128bd1f1bc97127e0ee05622 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* Remove QT_{BEGIN,END}_HEADER macro usageSergio Ahumada2013-01-291-4/+0
| | | | | | | | | | | The macro was made empty in ba3dc5f3b56d1fab6fe37fe7ae08096d7dc68bcb and is no longer necessary or used. Discussed-on: http://lists.qt-project.org/pipermail/development/2013-January/009284.html Change-Id: Id2bb2e2cabde059305d4af5f12593344ba30f001 Reviewed-by: Laszlo Papp <lpapp@kde.org> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com> Reviewed-by: hjk <hjk121@nokiamail.com>
* Update copyright year in Digia's license headersSergio Ahumada2013-01-1827-27/+27
| | | | | Change-Id: Ic804938fc352291d011800d21e549c10acac66fb Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* add and use qtHaveModule() functionOswald Buddenhagen2012-12-211-1/+1
| | | | | | | | | | | this is much more elegant than the so far propagated !isEmpty(QT.foo.name). also replace feature-specific tests (no-gui and no-widgets) and the obsolete contains(QT_CONFIG, foo) syntax. Change-Id: Ia4b3c8febcabf9eeca67b1f9173a523820b1038b Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com> Reviewed-by: Tasuku Suzuki <stasuku@gmail.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
* centralize and fixup example sources install targetsOswald Buddenhagen2012-11-291-10/+1
| | | | | | | | | | | | | it's confusing for the users if the examples' project files contain code to install their own sources. also, this constitutes an enormous code duplication, and lots of mistakes. consequently, automate it. more or less as a side effect, this also removes the entirely meaningless target installs in subdirs projects. Task-number: QTBUG-28184 Change-Id: I9fc1367a06db9e2c46aeb67d68729a4f67163ef9 Reviewed-by: hjk <qthjk@ovi.com>
* Examples: Install to $$[QT_INSTALL_EXAMPLES]/$submodule/$examplehjk2012-11-261-2/+2
| | | | | | | | This makes the structure of the examples after an 'make install' similar to the one in a 'developer build'. Change-Id: I9120bd741fab332e64e30adc01cefe87e5633454 Reviewed-by: Martin Smith <martin.smith@digia.com>
* Fix building of examples.Friedemann Kleint2012-11-211-3/+4
| | | | | | | | | | | - Correct install path of widget examples to contain widgets directory in target tree. - Add missing resources. Task-number: QTBUG-27977 Change-Id: If4cb117998892b0b165d7678367553d3a7553b91 Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
* Change copyrights from Nokia to DigiaIikka Eklund2012-09-2227-654/+654
| | | | | | | | Change copyrights and license headers from Nokia to Digia Change-Id: If1cc974286d29fd01ec6c19dd4719a67f4c3f00e Reviewed-by: Lars Knoll <lars.knoll@digia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
* examples: Mark ctor's as explicitSergio Ahumada2012-09-173-9/+9
| | | | | | | | | Make C++ class constructors that can be used with only one required argument 'explicit' to minimize wrong use of the class. Change-Id: Ida9f9c2f0c8608c35b0137b2512a6747afd69515 Reviewed-by: Mitch Curtis <mitch.curtis@nokia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Moving .qdoc files under examples/widgets/docGabriel de Dietrich2012-08-2071-0/+6215
Updated those .qdoc files to refer to the new relative examples emplacement. Images and snippets to be moved later. Also grouped all widgets related examples under widgets. Change-Id: Ib29696e2d8948524537f53e8dda88f9ee26a597f Reviewed-by: J-P Nurmi <j-p.nurmi@nokia.com>