Commit Graph

906 Commits

Author SHA1 Message Date
Friedemann Kleint
d482a92858 Polish the HTTP example.
- Remove unneeded member variables.
- Use new connection syntax.
- Streamline code.
- Add a QCheckBox for launching the file after download
  and make the default file name and download directory configureable.
- Make status messages more verbose.
- Set Password echo mode on authentication dialog.
- Extract the progress dialog to a separate class
  that is directly connected to the QNetworkReply, which
  is created on demand. Set set minimum  and duration on it.
  This fixes a crash that currently occurs when clicking "Abort"
  on the SSL error dialog and "Cancel" on the progress dialog that is
  then re-shown due to its internal force timer/minimum duration handling.
- Resize according to screen size.

Task-number: QTBUG-48332
Change-Id: Ia2611e63fe96d6f49e4cdd06049a206ddb2c2864
Reviewed-by: David Faure <david.faure@kdab.com>
2015-11-05 13:54:13 +00:00
Liang Qi
4159ee8405 Merge remote-tracking branch 'origin/5.6' into dev
Conflicts:
	config.tests/unix/ptrsize.test
	configure
	src/corelib/global/qnamespace.h
	src/network/socket/qabstractsocket.cpp
	tests/auto/other/networkselftest/networkselftest.pro

Change-Id: Ic78abb4a34f9068567cea876861d4220f5a07672
2015-11-04 20:18:14 +01:00
Alejandro Exojo
115f303352 Fix the closeEvent of the systray example on OS X
The implementation of the close event handler requires handling the two
close events that are received on OS X when the user quits through the
application menu bar or the Command+Q shortcut. The first is an
spontaneous event, and the second a non-spontaneous one with the window
already closed.

Change-Id: I24e3d3f0de4d631bd2d5616c85ce747f085691e0
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-11-03 09:01:36 +00:00
Marc Mutz
1c9f53c4e5 examples: remove use of obsolete QStyleOption*V<N> typedefs
These are obsolete since Qt 5.0.

Change-Id: I297477eff129558553f52a04bb7828d95db27969
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-11-02 18:43:26 +00:00
Ulf Hermann
6c72a4a95b Fix building with QT_NO_BEARERMANAGEMENT
Some of the examples make no sense without bearer management and
QNetworkSession is not defined if QT_NO_BEARERMANAGEMENT, so
tst_qnetworkreply.cpp has to be adjusted.

Change-Id: Ic2f73746cba74f670ae5b5e99b0be1461ff6d182
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
2015-10-28 21:25:36 +00:00
Liang Qi
790aef362f Merge remote-tracking branch 'origin/5.6' into dev
Conflicts:
	.qmake.conf
	configure
	src/corelib/global/qglobal.h
	src/tools/qdoc/node.cpp
	src/tools/qdoc/qdocdatabase.cpp
	tests/auto/corelib/io/qsettings/tst_qsettings.cpp
	tools/configure/configureapp.cpp

Change-Id: I66028ae5e441a06b73ee85ba72a03a3af3e8593f
2015-10-23 14:45:03 +02:00
Rafael Roquetto
c9195ab36d TextEdit example: fix build when clipboard is disabled.
Change-Id: Ib25563e3dc299dc2d23bed8b3071af1ba81150e7
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
2015-10-19 14:56:45 +00:00
Friedemann Kleint
6ea67f52da Image viewer example: Fix broken error message formatting.
Task-number: QTBUG-48851
Change-Id: Ie86bcc498c9dc1f9754192a256a28fa467f6dbc9
Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
2015-10-19 14:50:32 +00:00
Alexander Volkov
59b860450f Polish the complexpingpong example
- Use QDBusServiceWatcher to detect that pong service became available
  (QDBusConnectionInterface::serviceOwnerChanged() signal is deprecated).
- Use new connection syntax.

Task-number: QTBUG-28082
Change-Id: I7b93b961ee6d45aaeefab77fa1d1943e38b4a4c0
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
2015-10-19 10:29:50 +00:00
Kai Koehne
c890fa4787 Remove webkit-guide from examples
Qt5WebKit is now deprecated and removed from the packages.

Change-Id: I176344cb2a6b43ffc44cc0e7ef1abb4e765a35b4
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-10-19 08:44:45 +00:00
Liang Qi
4456984da7 Merge remote-tracking branch 'origin/5.6' into dev
Conflicts:
	tests/auto/corelib/io/qfile/tst_qfile.cpp
	tests/auto/corelib/io/qprocess/tst_qprocess.cpp
	tests/auto/corelib/tools/qversionnumber/qversionnumber.pro

Change-Id: Ia93ce500349d96a2fbf0b4a37b73f088cc505c6e
2015-10-14 15:45:35 +02:00
Liang Qi
b7ac036b72 Merge remote-tracking branch 'origin/5.5' into 5.6
Conflicts:
	src/network/socket/qabstractsocket.cpp
	src/plugins/platforms/winrt/qwinrtscreen.cpp
	src/sql/drivers/mysql/qsql_mysql.cpp

Change-Id: Ifb73623d09f53340ee5e10283f1f86b580998902
2015-10-13 23:03:51 +02:00
Friedemann Kleint
f9bf737d74 Examples/Doc snippets: Fix single-character string literals.
Use character literals where applicable.

Change-Id: I79fa5018f05735201ae35ee94ba0d356fcad1056
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-10-13 16:37:07 +00:00
Friedemann Kleint
c8cd9f1b9a Polish DnD Examples.
- Remove class DragLabel in draggabletext and add a static creation
  function instead since it only has a constructor setting some
  properties.
- Use QRegularExpression instead of QRegExp
- Use new connection syntax.
- Ensure compilation with
  DEFINES += QT_NO_CAST_TO_ASCII QT_NO_CAST_FROM_ASCII
  demonstrating use of QLatin1String vs QStringLiteral.
- Streamline code.

Change-Id: I2e2ddeb40837dba379990836c77fb72ad7263e2d
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
2015-10-09 15:59:21 +00:00
Samuel Gaist
decc546368 Doc: remove unused code from OpenGL Window example
Change-Id: Ifb2c7206dee55102eba91b4c30543f3ac4838259
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-10-07 10:56:04 +00:00
Liang Qi
925d6eff3e Merge "Merge remote-tracking branch 'origin/5.5' into 5.6" into refs/staging/5.6 2015-10-02 17:24:58 +00:00
Liang Qi
d0eaa737e1 Merge remote-tracking branch 'origin/5.5' into 5.6
Conflicts:
	qmake/doc/src/qmake-manual.qdoc
	src/corelib/tools/qstring.h
	src/gui/image/qimagereader.cpp
	src/network/access/qnetworkaccessmanager.cpp
	src/tools/qdoc/doc/examples/examples.qdoc
	src/widgets/accessible/qaccessiblewidgetfactory_p.h
	src/widgets/doc/qtwidgets.qdocconf

Change-Id: I8fae62283aebefe24e5ca4b4abd97386560c0fcb
2015-10-02 16:59:55 +02:00
Topi Reinio
fbf3daef38 Doc: Update obsolete URLs to external documentation
Change-Id: I199de83971701c14e903e712fcdcd29aaff95c6d
Task-number: QTBUG-48420
Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com>
Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
2015-10-02 10:14:47 +00:00
Joni Poikelin
4b785eeaa9 Clean up debug code and unused functions from imagegestures example
Change-Id: I0dbbb5c6f3227e8cfe3e0f6eb27b2bf16b5d222b
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
2015-10-01 07:09:53 +00:00
Ulf Hermann
2b18939f83 Fix building with QT_NO_LIBRARY
If QT_NO_LIBRARY isn't set we cannot test QCoreApplication's library
path functions and none of the plugin and library related tests are
applicable. Also, examples that rely on dynamic plugin loading for
their core functionality obviously don't work.

Change-Id: I2d381ee1bc8d944e1181557895a7e92a364fd778
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2015-09-30 13:04:26 +00:00
Liang Qi
a1ad9a74eb Merge remote-tracking branch 'origin/5.6' into dev
Conflicts:
	src/corelib/io/io.pri
	src/corelib/io/qdatastream.cpp
	src/corelib/io/qdatastream.h
	src/network/socket/qabstractsocket.cpp
	src/plugins/platforminputcontexts/ibus/qibusplatforminputcontext.cpp
	src/plugins/platforms/cocoa/qcocoaaccessibilityelement.h
	src/widgets/styles/qgtkstyle.cpp
	tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-cache/qmimedatabase-cache.pro
	tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/qmimedatabase-xml.pro
	tests/auto/dbus/qdbusconnection/qdbusconnection.pro
	tests/auto/dbus/qdbuspendingcall/tst_qdbuspendingcall.cpp
	tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp

Change-Id: I347549a024eb5bfa986699e0a11f96cc55c797a7
2015-09-25 14:02:04 +02:00
Laszlo Agocs
b46ffbca0c Fix up QOpenGLWidget transparency support
The glColorMask call was troublesome. In addition, the Qt::WA_TranslucentBackground
was misinterpreted and recommended misleadingly in the documentation. The hellogl2
example's --transparent argument was disfunctional in practice.

Replace glColorMask with glBlendFuncSeparate. The hellogl2 example and the docs are
now corrected wrt enabling semi-transparency in a QOpenGLWidget that is not a top-level
(which is the most common case).

Task-number: QTBUG-47276
Change-Id: I6f40e732d455f5efcf158649ac9a52ff9f240e85
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
2015-09-24 12:51:37 +00:00
Friedemann Kleint
47e4ae86a8 Polish the settings editor example.
- Set QtProject as organization.
- Remove unneeded member variables.
- Use member initialization in the constructor.
- Use new connection syntax in createActions()
  to assemble the menu there, removing the createMenus()
  function.
- Introduce a QSharedPointer to ensure settings are deleted.
  Previously, the settings were parented on the tree widget,
  which is a hack of sorts.
- Fix OS X macros.

Change-Id: Ibbc6bfb03eb5c7eda077b1a3aa3f1707667f7f13
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-09-23 13:28:02 +00:00
Dmitry Shachnev
bb6d57479c Remove confusing license information from torrent.qdoc
The torrent example does not have its own code to work with SHA-1,
it uses QCryptographicHash instead.

Change-Id: Ided0e3dcded1096feb3366682c97530c4cec0a14
Reviewed-by: Lisandro Damián Nicanor Pérez Meyer <perezmeyer@gmail.com>
Reviewed-by: Sami Makkonen <sami.makkonen@digia.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-09-21 20:51:39 +00:00
Friedemann Kleint
8132cb655a Polish the Icons example.
- Remove unneeded member variables.
- Use new connection syntax in createActions()
  to assemble the menu there, removing the createMenus()
  function.
- Use a QButtonGroup for the sizes with the style metrics as id.
- Streamline code, rename variables for clarity.
- Introduce static functions returning the list of states/modes and
  their names in display order to IconPreviewArea, removing the
  duplicates.
- Split actions to open sample icons provided from source directory
  or standard pictures location to make sample icons more prominently
  visible.
- Check and display @2x images and add tooltips showing device pixel
  ratio and actual size.
- HighDPI: Add groupbox displaying screen name and device pixel
  ratio, connect to screen changed signal and update icons panel
  accordingly. Add check box for toggling Qt::AA_UseHighDpiPixmaps.
- Adjust documentation

Task-number: QTBUG-18680
Task-number: QTBUG-46615
Change-Id: Ice96e9898f168ef2a30e9f46cb260ed57ae015f0
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-09-14 19:20:06 +00:00
Friedemann Kleint
8ccf523018 Re-add systray.qdoc and images.
The system tray example initially was in QtSvg after the Qt 5
modularization split since it depended on it. In the meantime, it
has been moved back to qtbase.

Fixes qdoc warning:

qtbase/src/widgets/util/qsystemtrayicon.cpp:56: warning: Can't link to 'System Tray Icon Example'

Change-Id: Ie3c13baf4ac91ecf0c814885f71ac44dc05b427c
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
2015-09-11 07:47:31 +00:00
Shrikant Dhumal
924d4aefd5 Fixed build breaks that result after disabling "contextmenu" feature
Change-Id: I261f927ee720e0c65abd18417e1ac48dbee820df
Reviewed-by: Jake Petroules <jake.petroules@theqtcompany.com>
2015-09-09 07:33:58 +00:00
Jake Petroules
353b160a4a Link to AppKit instead of Cocoa.
Cocoa is basically just AppKit + CoreData. Since we do not use CoreData
in Qt, there is no reason to link to it or (transitively) import its
headers.

This is just a mechanical replacement of -framework Cocoa with
-framework AppKit and <Cocoa/Cocoa.h> with <AppKit/AppKit.h>

Change-Id: Ibcfc8a03c0ddff27a67fbc87dd7bd58a4b648956
Reviewed-by: Mika Lindqvist <postmaster@raasu.org>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
2015-09-05 11:49:17 +00:00
Nico Vertriest
69e1b1de93 Doc: System Tray Icon example
Moved from qtsvg to qtbase

Task-number: QTBUG-47201
Change-Id: Iab185ea2e270893c0937d1ff87fdb544d226d603
Reviewed-by: Martin Smith <martin.smith@digia.com>
2015-09-04 11:01:48 +00:00
Friedemann Kleint
c726bc85da Port examples/opengl to new connection syntax.
Change-Id: I486a4a2326bf57ec5ea08bccdcef79c3e5553db5
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-09-02 10:21:56 +00:00
Friedemann Kleint
01c6f7200a Polish the screen shot example.
- Remove unneeded member variables.
- Set window sizes depending on screen geometry for High DPI screens.
- Flesh out code for saving the image, setting the supported
  mime types on the file dialog.
- Streamline constructor code, remove create...() functions.
- Use new connection syntax in createActions(),
- Obtain the screen from the widget.
- Adapt documentation. Remove note saying that widgets do not need
  the parent parameter (since creating parentless widgets can
  result in flicker in some cases), explain that QScreen pointers
  should be checked.

Change-Id: I0332bbf10eafe861fe3fd5573522694ab5c0183a
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-09-01 06:06:33 +00:00
Friedemann Kleint
3363398802 Polish the systray example.
- Port it to new connection syntax.
- Replace module include by class includes.

Change-Id: I1b8d682bb7bb2e05b6b2b77a9c0d01730ea09cf2
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-09-01 06:06:30 +00:00
Friedemann Kleint
fe1ea010b9 Polish rich text example.
- Introduce Qt 5 signals & slot syntax.
- Use mime types in the file dialogs.
- Streamline the code creating the actions.
- Introduce QCommandLineParser.
- Query the available size when determining
  the initial size instead of using hard-coded values
  for High-DPI screens.

Change-Id: Ifc84a41ed55a4a674b6eafdb6120ac42441405b6
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-08-31 19:55:33 +00:00
Sean Harmer
c48cc28c36 Compile in namespaced builds
Change-Id: I2894fbadec50286c0831bf381d149b54ade9182d
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-08-31 10:33:57 +00:00
Friedemann Kleint
79a4cb1e4f Fix some qdoc-warnings.
qtbase/src/widgets/kernel/qaction.cpp:1257: warning: Can't link to 'QApplication::setAttribute()'
qtbase/src/widgets/kernel/qapplication.cpp:519: warning: Can't link to 'arguments()'
qtbase/src/widgets/kernel/qapplication.cpp:1939: warning: Can't link to 'quit()'
qtbase/src/widgets/kernel/qapplication.cpp:2946: warning: Can't link to 'quit()'
qtbase/src/widgets/kernel/qapplication.cpp:2946: warning: Can't link to 'exit()'
qtbase/src/widgets/kernel/qapplication.cpp:2946: warning: Can't link to 'processEvents()'
qtbase/src/widgets/widgets/qmenu.cpp:1354: warning: Can't link to 'Recent Files Example'
qtbase/examples/widgets/doc/src/tetrix.qdoc:28: warning: Can't link to 'QApplication::quit()'
qtbase/src/testlib/qtestcase.cpp:268: warning: Undocumented parameter 'timeout' in QTRY_VERIFY2_WITH_TIMEOUT()
qtbase/src/corelib/global/qnamespace.qdoc:2427: warning: Can't link to 'QApplication::setLayoutDirection()'
qtbase/src/corelib/global/qnamespace.qdoc:751: warning: Can't link to 'QApplication::setDesktopSettingsAware()'

Change-Id: Ic8170a40fb1cd84e3fb4dd75d9429f4b485f8bd9
Reviewed-by: Martin Smith <martin.smith@digia.com>
2015-08-27 19:27:38 +00:00
Friedemann Kleint
bc2dabf8ff Extend the image viewer example.
Add:
- Save As
- Copy
- Paste from clipboard into new image

Change-Id: Ibbc308e9bbd2ce407119cd9358874f5c22a6bb83
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-08-24 08:26:55 +00:00
Friedemann Kleint
5549ba4fa5 Polish the imageviewer example.
- Remove unneeded member variables.
- Use member initialization in the constructor.
- Use new connection syntax in createActions()
  to assemble the menu there, removing the createMenus()
  function.
- Fix coding style issue (braces)
- Avoid empty label showing up by setting the scroll
  area invisible until an image is loaded.
- Set a new image only if image read succeeds.
- Add status bar with information message.

Task-number: QTBUG-46848
Change-Id: I32d5af70d8eb71ec16dd58a0b98c32eb2bd988d7
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-08-21 10:37:22 +00:00
Friedemann Kleint
2f50102f85 Polish widgets/dialogs/standarddialogs example.
Add missing options for QFileDialog, QFontDialog.
Resize and position depending on screen size in order
to look correct on high resolution screens.

Change-Id: I1d9af481270d6a3e49878aaf32b59aea8fa543b4
Reviewed-by: hjk <hjk@theqtcompany.com>
2015-08-18 20:03:21 +00:00
Rafael Roquetto
b907dcaefe Fix mainwindow examples when clipboard support is disabled.
Some platforms, such as QNX, do not implement QT_CLIPBOARD.

Change-Id: I3a8b484b4c00c28a91d3727054672c3788f98381
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
2015-08-11 16:23:23 +00:00
Friedemann Kleint
af38340720 Port examples/widgets/itemviews to new connection syntax.
Rename some slots to avoid ugly casts.

Change-Id: I5d7b2c044ab6a725f7259e5e34f00c3d06fff050
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2015-07-31 14:21:15 +00:00
Shawn Rutledge
e026fdc4a7 Tablet example: update the cursor according to the tool
Change-Id: Ibbe530856bb833e465dd9fa1da5425c018fecc21
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-07-31 04:33:27 +00:00
Shawn Rutledge
6a991f9cce Tablet example: smoother, rotation stylus, better airbrush
The drawing is antialiased and with rounded caps and joins.
Rotation stylus acts like a felt marker.
Airbrush sprays a radial gradient of color, and its alpha can
depend on the tangential pressure if so chosen.

Task-number: QTBUG-46694
Change-Id: I4fb16eb621707e3c56a75aa302dd0d3bf418a745
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-07-31 04:33:20 +00:00
Friedemann Kleint
ad4d25589f Add recent file handling to SDI/MDI and remove the recentfiles example.
The existing recentfiles example was basically a clone of the SDI
example with a "Recent" menu added. Assuming it is better to have
it all in one place, the functionality is merged into the existing
SDI/MDI examples.

- Implement recently opened files handling using a submenu and a
  QSettings array in the SDI/MDI examples.
- Remove recentfiles example.

Change-Id: Id5a1ab9fa1c2e6b9ec81309cfe74cf86f450392a
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-07-31 04:30:35 +00:00
Paul Olav Tvete
80dbdf0de3 Make the gles3 example more impressive
Add some extra rotations and offsets, to show off the power of
what you can do with a single draw call. Also use QGLWindow instead
of QGLWidget. This improves performance from 23 FPS to 30 FPS on a
4k monitor with integrated Intel graphics.

Change-Id: Iedac1c14cc6057959aa15faaacdf29da91f36ab1
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-07-24 10:18:16 +00:00
Laszlo Agocs
4535c7911d Expose GLES 3.0 and 3.1 functions
Using the approach we already do for some GLES 3.0 functions we can provide a cross-platform,
cross-GL-GLES wrapper for ES 3.0 and 3.1 functions too.

Applications only have to take extra care about the version requests (context version
and version directives in shader code), the rest of their code can stay the same across
desktop/mobile/embedded, even when ES 3 functions are used.

The new functions are placed to a new subclass which is placed between QOpenGLFunctions
and the internal QOpenGLExtensions. This is necessary because, unlike with QOpenGLFunctions,
there is no guarantee that these functions are always available in all configurations.

When running on desktop OpenGL, we resolve as usual. If the OpenGL version contains the
function in question, either in core or as an extension, it will all just work. This is
handy because it does not rely on 4.x extensions like GL_ARB_ESx_compatibility, and so
ES 3.0 functions will be functional on OpenGL 3.x systems too by just setting a 3.x version
number in the QSurfaceFormat.

We will no longer qFatal on broken systems where the driver returns a 3.0 or 3.1 context without
the corresponding functions present. Instead, we show a warning and gracefully fall back to
resolving as usual, via eglGetProcAddress or similar. For functions that are available in ES2 as
an extension this may just work fine.

Added also an example that runs identically both with OpenGL and OpenGL ES 3 and utilizes some
ES 3.0 features like instanced drawing.

[ChangeLog] Added QOpenGLExtraFunctions providing OpenGL ES 3.0 and 3.1 function wrappers in
a cross-platform manner.

Task-number: QTBUG-46161
Change-Id: I9f929eb61946c35c415b178c4d6ab2c1c958684e
Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
2015-07-23 07:59:07 +00:00
Friedemann Kleint
0e72782363 Port examples/widgets/dialogs to new connection syntax.
Change-Id: Ife8a24b43db400909099765b43f016b4be4bd6ef
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-07-22 04:12:45 +00:00
Friedemann Kleint
bdbd26a3b7 Polish the widgets/mainwindows/mdi example.
- Introduce Qt 5 signals & slot syntax and remove the QSignalMapper
  used to map the triggered() signals of the per-MDI-child actions
  of the window menu to the activation slot by a functor to demonstrate
  the flexibility of the new connection syntax (the functor can
  in turn be replaced by a lambda expression once we have C++ 11).
- Merge MainWindow::createMenus()/createQToolBars()
  into MainWindow::createActions(), removing the need
  to store the actions as member variables.
  Use QMenu::addAction() for brevity.
- Use QIcon::fromTheme() to obtain system icons and use
  resource icons as fallback.
- Rewrite settings code to use
  QWidget::saveGeometry(), Widget::restoreGeometry() since
  saving size and position does not work well with multiple
  screens. Query the available size when determining
  the initial size instead of using hard-coded values
  for High-DPI screens.
- Fix minor issues in code, use multi-argument version
  of QString::arg(), QDir::toNativeSeparators() to
  present file paths to the user and static method invocation.

Change-Id: I3d5078ddbe3cb4eba65e188430ba3580cecb2c79
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2015-07-20 22:07:13 +00:00
Friedemann Kleint
a92a72dd11 Polish the examples/widgets/dockwidgets example.
- Introduce Qt 5 signals & slot syntax.
- Use QIcon::fromTheme() to obtain system icons and use
  resource icons as fallback.
- Fix minor issues in code, use multi-argument version
  of QString::arg(), QDir::toNativeSeparators() to
  present file paths to the user, static method
  invocations.
- Use QMimeDatabase for file dialog.

Change-Id: Ib7f947aaaa0c8034f0853b1c740ebf195821dae0
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2015-07-20 13:25:06 +00:00
Friedemann Kleint
956b7023eb Port examples/widgets/mainwindows/menus to new connection syntax.
Change-Id: Ia7fa905cdda131d7c4a2c8a57557ea694eef3541
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2015-07-20 13:24:59 +00:00
Simon Hausmann
dcc301abfa Merge "Merge remote-tracking branch 'origin/5.5' into HEAD" into refs/staging/dev 2015-07-17 14:43:34 +00:00
Simon Hausmann
b2603b7665 Merge remote-tracking branch 'origin/5.5' into HEAD
Conflicts:
	src/plugins/platforms/windows/qwindowsopengltester.cpp

Change-Id: Ia7abeba9395ccf84e2fa81b91a5725a86dedb9fe
2015-07-17 16:35:42 +02:00
David Faure
31a1b3df1d QtConcurrent example: remove unneeded explicit template type
I show this code during trainings and this explicit template type
just makes the line of code more complex than it has to be.

Change-Id: I294c65f48967e54c67d9c3b8e1de96c3c2495a5b
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2015-07-17 14:29:42 +00:00
Friedemann Kleint
2fe56e37ed Polish the examples/widgets/mainwindows example.
- Introduce Qt 5 signals & slot syntax.
- Replace QSignalMapper used for the corner/area
  actions by a by a functor.
- Improve command line parsing.
- Reorder class declarations.
- Remove commented-out code.
- Use QDialogButtonBox in dialogs.
- Fix minor issues in code, use multi-argument version
  of QString::arg(), QDir::toNativeSeparators() to
  present file paths to the user, static method
  invocations.

Change-Id: I865c56639c74135b59740797e9a9dfbfca2e72b6
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2015-07-17 14:15:11 +00:00
Friedemann Kleint
fdb8ef6507 Polish the widgets/mainwindows/sdi example.
- Introduce Qt 5 signals & slot syntax.
- Use QCommandLineParser to obtain file arguments, factor
  out positioning into tile() function to be able to
  use it from command line and open/new slots.
- Merge MainWindow::createMenus()/createQToolBars()
  into MainWindow::createActions(), removing the need
  to store the actions as member variables.
  Use QMenu::addAction() for brevity.
- Use QIcon::fromTheme() to obtain system icons and use
  resource icons as fallback.
- Rewrite settings code to use
  QWidget::saveGeometry(), Widget::restoreGeometry() since
  saving size and position does not work well with multiple
  screens. Query the available size when determining
  the initial size instead of using hard-coded values
  for High-DPI screens.
- Fix minor issues in code, use multi-argument version
  of QString::arg(), QDir::toNativeSeparators() to
  present file paths to the user and and static method invocation.
- Fix snippet references accordingly.

Change-Id: I3ea0372bc7ff82247192f54620289352fb68d60f
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2015-07-17 14:14:56 +00:00
Friedemann Kleint
0d81316dcc Use QImageReader::setAutoTransform() in examples.
Change-Id: If80616d680f1aa6c9d5cd1a4080710e5ad67d603
Reviewed-by: Rainer Keller <rainer.keller@theqtcompany.com>
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
2015-07-13 20:16:35 +00:00
Friedemann Kleint
b693900da5 Polish the widgets/mainwindows/application example.
- Introduce Qt 5 signals & slot syntax
- Use QCommandLineParser to obtain file arguments
- Merge MainWindow::createMenus()/createQToolBars()
  into MainWindow::createActions(), removing the need
  to store the actions as member variables.
  Use QMenu::addAction() for brevity.
- Use QIcon::fromTheme() to obtain system icons and use
  resource icons as fallback.
- Rewrite settings code to use
  QWidget::saveGeometry(), Widget::restoreGeometry() since
  saving size and position does not work well with multiple
  screens. Query the available size when determining
  the initial size instead of using hard-coded values
  for High-DPI screens.
- Fix minor issues in code, use multi-argument version
  of QString::arg(), QDir::toNativeSeparators() to
  present file paths to the user.
- Fix snippet references accordingly.

Change-Id: I1bc49a8913aa6d669e0e666f04be3f1f42eaba10
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-07-13 10:18:40 +00:00
Liang Qi
0aa2d318b1 Merge remote-tracking branch 'origin/5.5' into dev
Conflicts:
	src/corelib/global/qglobal.cpp
	src/corelib/global/qglobal.h
	src/corelib/global/qsysinfo.h
	src/corelib/global/qsystemdetection.h
	src/corelib/kernel/qobjectdefs.h
	src/plugins/plugins.pro
	tests/auto/widgets/itemviews/qlistview/qlistview.pro

Change-Id: Ib55aa79d707c4c1453fb9d697f6cf92211ed665c
2015-07-01 11:05:26 +02:00
Nico Vertriest
a7f2af0911 Replace MAC OS X with OS X
Task-number: QTBUG-46374
Change-Id: I7bc633ab551740bd328a24b0ccae1d534af47138
Reviewed-by: Martin Smith <martin.smith@digia.com>
2015-06-30 07:33:31 +00:00
Benjamin Summerton
2a526b12ce Updated Hello GL2 Example to new Signal/Slot syntax
The Hello GL2 Example was using the older Signal/Slot syntax that made
use of the macros `SIGNAL()` and `SLOT()`.  I changed it to the newer
one.

Change-Id: I8e55015383847a04b07f751fe9fc94b81956a896
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-06-29 11:30:01 +00:00
Nico Vertriest
e1b7c55a43 Doc: rearrange tables with overflow
Task-number: QTBUG-46475
Change-Id: Id599b2eb0dee0c003475c094ad61700150e37e65
Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com>
2015-06-26 11:26:24 +00:00
Holger Hans Peter Freyther
ae4bc7e97e Remove bogus call and comment from addressbook
QMap::empty() does not empty the list but is the STL
version to ask if the map is empty. Remove the comment
and code as operator>> of QDataStream will clear the
map.

Fixes Coverity CID#89073

Change-Id: I259e518b44afd42b698368b42aedcc3b84240aca
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
2015-06-08 07:22:20 +00:00
Dmitry Shachnev
657a8cf5be Remove exec bits from files that should not be executable
Change-Id: I66f49c6db82eadc3b11cc9b1cf01375e9596a8e6
Reviewed-by: Lisandro Damián Nicanor Pérez Meyer <perezmeyer@gmail.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
2015-06-07 22:50:19 +00:00
Oswald Buddenhagen
d32f47b703 fix usage of wince scope
Fix style issues along the way.

Change-Id: Ic6a6de28e198eb0b14c198b802e78845703909b9
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-06-05 10:29:10 +00:00
Simon Hausmann
ccad00121d Merge "Merge remote-tracking branch 'origin/5.5' into dev" into refs/staging/dev 2015-06-04 05:56:06 +00:00
Joerg Bornemann
3ce99adfa4 use INSTALLS instead of DEPLOYMENT
The DEPLOYMENT variable has been deprecated.

Change-Id: I1c7c07b36a2e665ae302e4f43f7f2dc752f3c1f4
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2015-06-03 11:26:46 +00:00
Simon Hausmann
e2f66f9215 Merge remote-tracking branch 'origin/5.5' into dev
Conflicts:
	src/corelib/global/qnamespace.qdoc
	src/corelib/io/qwindowspipereader.cpp
	src/corelib/io/qwindowspipereader_p.h
	src/corelib/statemachine/qstatemachine.cpp
	src/corelib/statemachine/qstatemachine_p.h
	src/plugins/platforms/xcb/qxcbconnection.h
	tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp
	tests/auto/tools/qmake/tst_qmake.cpp
	tests/manual/touch/main.cpp

Change-Id: I917d694890e79ee3da7d65134b5b085e23e0dd62
2015-06-03 10:23:56 +02:00
Liang Qi
754efa57d8 Merge "Merge remote-tracking branch 'origin/5.5.0' into 5.5" into refs/staging/5.5 2015-06-02 23:39:22 +00:00
Richard Moe Gustavsen
e5d85ff44e imageviewer example: support loading images on iOS
Use the last path from QSP to hint that we want to
load photos from the global photo library. This
should currently only make a difference on iOS.

Change-Id: I7a6217dbbbc2e247b69bf406c02001458c757211
Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
2015-06-02 07:46:14 +00:00
Jani Heikkinen
7bc9310a22 Merge "Merge remote-tracking branch 'origin/5.4' into 5.5" into refs/staging/5.5.0 2015-06-02 04:20:54 +00:00
Liang Qi
fcfd31c9fd Merge remote-tracking branch 'origin/5.4' into 5.5
Conflicts:
	qmake/generators/mac/pbuilder_pbx.cpp
	src/corelib/global/qglobal.h

Change-Id: I2c0f7544bf194f2d0f59218fd583c822901487b0
2015-06-01 17:46:58 +02:00
Laszlo Agocs
78e3354083 Clip QOpenGLWidget and QQuickWidget correctly
Introduce support for the widgets' clipRect(). Right now render-to-texture widgets
in scroll areas placed close to each other result in broken (non-existent) clipping.
Similarly, stack-on-top widgets fail to clip when placed inside a scroll area.

This is now corrected and the qopenglwidget example is enhanced to utilize a scroll
area.

Task-number: QTBUG-45860
Change-Id: I859a63d61a50d64ba9e87244f83c5969dce12337
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
2015-06-01 13:38:14 +00:00
Venugopal Shivashankar
18be63de2a Doc: Added the missing \brief and \image for example docs
The Qt TestLib examples are just tutorials so updated
the qdocconf to use the default thumbnail in the
Qt Creator welcome screen.

Task-number: QTBUG-41996
Change-Id: Ia04a42a92e414c97a426b6095a62621a348e7de0
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Reviewed-by: Martin Smith <martin.smith@digia.com>
2015-05-27 10:27:54 +00:00
Alexander Volkov
431e5d9f47 fingerpaint example: Use the maximum diameter for the touch spot by default
The result doesn't look good when you paint with the MinimumDiameter (3 px).
Also don't paint released touch points, because we can't get neither the
touch rect not the pressure for them.

Change-Id: I8d17c4884ae41545b2cd3f208afa73262133456c
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-05-23 11:28:00 +00:00
Friedemann Kleint
cab7e7858a Make OpenGL legacy examples hellogl and overpainting work with Dynamic GL.
Call GL functions using QOpenGLFunctions_1_1.

Task-number: QTBUG-46103
Change-Id: I1cbacf9c192c17d96d96aa861bb16e2918a0c053
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-05-23 08:59:14 +00:00
Friedemann Kleint
9d85490ea2 Fix exclusion for legacy Open GL examples.
Add dynamic GL and remove warning about ANGLE since that
package no longer exists.

Task-number: QTBUG-46103
Change-Id: Icf93d1105434395a3c9ad61bb8c921fcedfc7137
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-05-15 13:39:56 +00:00
Morten Johan Sørvig
a4cba90e19 Set correct target.path for legacy GL examples
Fix Library not loaded/image not found error on application
startup.

With @rpath enabled (commit 6e18f57a) qmake now requires
a correct target.path in order to emit correct -rpath @loader_path
linker directives.

Change-Id: Ia32b038ad2d64819477be5cd9d1ed36768e2251b
Reviewed-by: Jake Petroules <jake.petroules@petroules.com>
2015-05-14 07:57:11 +00:00
Olivier Goffart
ac1b6c0145 Add QMainWindow::GroupedDragging DockOption
If this setting is enabled, the entire group of docked tabs will
be draggable by the title bar of the group and and individual dock
can be dragged by dragging the tab.

When tabs are detached, the docks that are contained are reparented to
a QDockWidgetGroupWindow.

[ChangeLog][QtWidgets][QMainWindow] Added GroupedDragging as a DockOption
which allow users to drag all the tabs together when dragging the
title of a QDockWidget which is tabbed with others.

Change-Id: I5285685b129770498eb3e4fd5f4556e41225a595
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
2015-05-12 10:07:20 +00:00
Laszlo Agocs
1adedb7baa Make the windowcontainer example more robust
The QWindow tends to get mouse releases on Windows when
maximizing the window for example. This is likely a problem
in the platform, but the example should be improved too to
be more robust and ignore such unwanted events.

Task-number: QTBUG-42842
Change-Id: Iecf916a2f753ed1b37d644721ee212ca7c728c49
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
2015-05-12 08:58:47 +00:00
David Faure
ae8406d82f Deprecate ItemIsTristate in favor of ItemIsAutoTristate.
This makes the behavior much more clear. You can get a tristate checkbox
just by setting the CheckStateRole to PartiallyChecked, no tristate flag needed.

The flag, on the other hand, enables the automatic-tristate behavior in
QTreeViews (and only there), hence the new name for it.

Change-Id: I18d292a8b8294c863eab806f3874d15dfb72556c
Reviewed-by: Jarek Kobus <jaroslaw.kobus@theqtcompany.com>
2015-05-07 09:14:18 +00:00
Samuel Gaist
929cc27ffe Add QRegularExpression based regexp tool
Currently only the QRegExp based regexp tool is available to help build
regular expression. This patch aims to add the equivalent that use the
new QRegularExpression class.

Change-Id: Ie5f711640b32a6d10ce44d2c7795062c1aacce3f
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
2015-04-02 13:19:30 +00:00
Laszlo Agocs
20870dad20 Add OpenGL 4.5 to contextinfo example
Change-Id: I6f6c5b55769fd818aaf94580246952a574124c0d
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
2015-03-20 14:06:22 +00:00
Venugopal Shivashankar
3e6a14168b Example: Removed the code to handle 'num_entries' info.
The Google Suggest API doesn't return the 'num_queries'
anymore. Had to remove code related to 'num_queries' entry
so that the suggestion list shows up.

Task-number: QTBUG-42817
Change-Id: Ic918d1c86840fa4c1e18f32a984f5a9dd911261d
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-03-09 14:21:08 +00:00
Friedemann Kleint
d326952b51 Polish the Dir View example.
Add a command line parser so that the directory can be specified.
Resize depending on screen size and make first (name) column larger.

Change-Id: Ied5823b4e8f50345aae792628fb610b8604e37d3
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-03-06 18:09:42 +00:00
Shawn Rutledge
a9515cd02f doc: imagegestures example: document the pinch handler
The swipe handler is simple, and also doesn't currently work on every
platform.  But the pinch handler is the one that needs explanation,
because the difference between incremental and absolute values of the
rotation and scale properties is tricky.

Change-Id: Ie3c7f4941d4a17734c9a920a8dd978f86fb03c4b
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-03-03 13:30:25 +00:00
Shawn Rutledge
d568797226 imagegestures example: scaleFactor is relative; get values directly
QPinchGesture::scaleFactor is relative to the previous zoom factor,
so either we need to multiply the total zoom by scaleFactor,
or set it based on totalScaleFactor, which is simpler. Pinch-zoom is
now working in this example.
There's also no reason to use getProperty() when the accessors are
directly accessible in QPinchGesture.

Task-number: QTBUG-6010
Change-Id: I150dc0b18b4b871a08ec55c0f77463509ab26afe
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
2015-02-25 12:14:13 +00:00
Frederik Gladhorn
34b14a8472 Merge remote-tracking branch 'origin/5.4' into 5.5
Conflicts:
	examples/xml/htmlinfo/simpleexample.html
	examples/xml/rsslisting/rsslisting.cpp
	qmake/generators/win32/msbuild_objectmodel.cpp
	src/3rdparty/harfbuzz-ng/src/hb-private.hh
	src/corelib/global/qlogging.cpp
	src/corelib/io/qstorageinfo_unix.cpp
	src/corelib/thread/qwaitcondition_unix.cpp
	src/gui/kernel/qguiapplication.cpp
	src/plugins/platforms/linuxfb/qlinuxfbintegration.cpp
	src/testlib/doc/src/qt-webpages.qdoc
	tests/auto/other/qaccessibility/tst_qaccessibility.cpp

Change-Id: Ib272ff0bc30a1a5d51275eb3cd2f201dc82c11ff
2015-02-24 21:02:08 +01:00
Jani Heikkinen
cb95fff1c7 Fixed license headers
Change-Id: Ibebe1318d1c2de97601aa07269705c87737083ee
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2015-02-17 18:46:09 +00:00
Allan Sandfeld Jensen
515e802ae2 Use C++ <cmath> instead of <math.h>
Including math.h can pollute the default namespace, and break
some compilers if cmath versions of the method are declared as using.

Switching to C++ math functions also greatly simplifies handling of
float qreal as C++ automatically chooses the right method.

[ChangeLog][QtCore][QtMath] qmath.h no longer includes math.h, so any
sources depending on that indirect inclusion may fail to build.

Change-Id: I4d0e331dafba354ec05dc5052e61ef4ff8d387fe
Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
2015-02-16 16:21:15 +00:00
Jani Heikkinen
2b75c156b6 Updated BSD licensed file headers
Change-Id: I6441ff931dbd33b698d762e6f6784898f3f60fe7
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2015-02-15 07:41:17 +00:00
Kai Koehne
9ddfa43e02 MSVC: Remove use of -Zm argument
We've been setting the -Zm argument since the dawn of times (even before
the first git commit). Anyhow, MSDN from VS2008 onwards indicates
that this is not needed:

"In earlier versions of Visual C++, the compiler used several discrete
heaps, and each had a finite limit. Currently, the compiler dynamically
grows the heaps as necessary up to a total heap size limit, and requires a
fixed-size buffer only to construct precompiled headers. Consequently, the
/Zm compiler option is rarely necessary."

[ChangeLog][Compiler Specific Changes] Visual Studio: -Zm200 (an option to
specify the precompiled header memory allocation limit) is not added anymore
by qmake to the compiler calls. If you encounter an C1076 compiler error you
might need to re-add it in your .pro file.

Change-Id: Ia4bec7eba09d893a7d81886a1814602b9ce7563c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
2015-02-13 21:23:19 +00:00
Marc Mutz
f2e3fdc803 examples: migrate to QString::asprintf
Not that many, if any, uses of sprintf here were idiomatic Qt,
but that's for another commit.

Change-Id: Ic34470d9799942f786770ba9541b29c34d67c6f8
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2015-02-12 19:40:09 +00:00
Jani Heikkinen
83a5694dc2 Update copyright headers
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>
2015-02-11 06:49:51 +00:00
Sergio Ahumada
07c27a13ac Replace blog.qt.digia.com with blog.qt.io
Change-Id: I7f1c897d8c96780ee330bca18edd9fe893ee7c90
Reviewed-by: Tero Kojo <tero.kojo@theqtcompany.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-02-06 15:49:48 +00:00
Tor Arne Vestbø
5432f2c7a1 Remove traces of the Maemo platform
Change-Id: I6b551de331aa0386ea53d8e96f50b669777d2d69
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
2015-02-04 17:14:35 +00:00
Tor Arne Vestbø
c5db8fc74a Make it more obvious that Q_WS_ is dead code, and should perhaps be ported
We still have a bunch of Q_WS_ ifdefs in our code, which are easy to
mistake for Q_OS_ ifdefs when quickly scanning the code. By renaming
the ifdefs we make it clear that the code in question is dead.

In incremental follow-ups, we can then selectively either remove, or
port, the pieces that are dead code.

Change-Id: Ib5ef3e9e0662d321f179f3e25122cacafff0f41f
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2015-02-03 11:49:14 +00:00
Shawn Rutledge
ed8dbe6493 systray example: revert the heart icon to its previous version
Change e910c36a3f unintentially included
a cropped version of this icon to test what happens with non-square
tray icons.  Now reverting to the original version.

Change-Id: If49de2f54bfce7f11576317908f8742abffc105a
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
2015-01-28 12:51:03 +00:00
David Faure
b65a415e67 Simplify fontsampler example by using the automatic tristate feature.
All the features implemented here are done by QTreeWidget, which also
sets PartiallyChecked when appropriate.

Change-Id: I8c8b515478708d1b7a853e7b8d963dd8fc9863fb
Reviewed-by: Jarek Kobus <jaroslaw.kobus@theqtcompany.com>
2015-01-25 12:38:04 +01:00
Shawn Rutledge
e910c36a3f D-Bus tray icon: ensure that the image is square before sending
Sometimes KDE doesn't render non-square icons properly when they have
been received over the D-Bus protocol.

Change-Id: Icc6fa3d64a1598ea8f719192ae18d32f287d6a79
Reviewed-by: Dmitry Shachnev <mitya57@gmail.com>
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
2015-01-23 05:34:11 +01:00
Frederik Gladhorn
b6191b16d4 Merge remote-tracking branch 'origin/5.4' into dev
Conflicts:
	src/corelib/global/global.pri
	src/corelib/global/qcompilerdetection.h
	src/corelib/global/qglobal.h
	src/corelib/tools/qdatetime.cpp
	src/plugins/platforms/xcb/qxcbscreen.h
	src/plugins/platforms/xcb/qxcbwindow.h
	src/widgets/dialogs/qcolordialog.cpp
	src/widgets/dialogs/qcolordialog_p.h
	tools/configure/configureapp.cpp

Change-Id: Ie9d6e9df13e570da0a90a67745a0d05f46c532af
2015-01-21 11:10:14 +01:00
Sze Howe Koh
c49641a117 Doc: Fix typos
Change-Id: I29d5576902a5d1ea25558e980081952d9157f7f0
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-01-19 10:48:03 +01:00
Tobias Koenig
699455b90a Haiku: Make examples compile on Haiku
Change-Id: I469619b5d749be1043e0bc43e9199a39ace61f16
Reviewed-by: Augustin Cavalier <waddlesplash@gmail.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2015-01-14 05:37:12 +01:00
Kai Koehne
883f672db5 QOpenGLWindow example: Remove unused code
Change-Id: Ide47a9edf726298b2032e45d6865511801f94fcb
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-01-13 12:59:38 +01:00
Rafael Roquetto
8fdd1bb8cb QNX: Enable QSharedMemory and QSystemSemaphore support.
Commit 96995db4af implements the necessary bits for this to work
under QNX.

Change-Id: Ie9e2f421f4f27fcaf40697dd363e9ed047754f0d
Reviewed-by: Tobias Koenig <tobias.koenig@kdab.com>
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
2015-01-13 11:54:12 +01:00
Jørgen Lind
cd7532ad7b Fix a couple of bugs in the QOpenGLWindow example
Also make the fragment shader a bit simpler

Change-Id: Ie50940da0a4f896504c9f5962cdb6c455983302f
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-01-10 19:40:31 +01:00
Frederik Gladhorn
aaff94c2df Merge remote-tracking branch 'origin/5.4' into dev
Conflicts:
	src/corelib/tools/qbytearray.cpp
	src/gui/kernel/qplatformsystemtrayicon.cpp
	src/gui/kernel/qplatformsystemtrayicon.h
	src/plugins/platforms/xcb/xcb-plugin.pro

Change-Id: I00355d3908b678af8a61c38f9e814a63df808c79
2014-12-29 16:37:38 +01:00
Giuseppe D'Angelo
8815a75ef0 Remove a memory leak in the custom sort filter model example
Change-Id: Ie14f07bc2ee2215da2a81a75d816d4763fac085f
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2014-12-23 16:39:03 +01:00
Simon Hausmann
e281537f20 Merge remote-tracking branch 'origin/5.4' into dev
Conflicts:
	src/corelib/global/qglobal.h
	src/platformsupport/platformcompositor/qopenglcompositor.cpp
	src/platformsupport/platformcompositor/qopenglcompositorbackingstore.cpp
	tests/auto/gui/kernel/qwindow/tst_qwindow.cpp

Change-Id: I5422868500be695584a496dbbbc719d146bc572d
2014-12-18 12:12:58 +01:00
Alex Blasche
8eb4b281d9 Change bugreports.qt-project.org -> bugreports.qt.io
The Qt bug tracker URL changes as part of the qt.io transition

Change-Id: Icb4ab198943b93639b5e3a8d99262303785c6459
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
2014-12-18 09:46:09 +01:00
Simon Hausmann
015002fec9 Merge remote-tracking branch 'origin/5.4' into dev
Conflicts:
	doc/global/template/style/online.css
	mkspecs/android-g++/qmake.conf

Change-Id: Ib39ea7bd42f5ae12e82a3bc59a66787a16bdfc61
2014-12-10 07:58:06 +01:00
Friedemann Kleint
09e674849a QCommandLineParser: Show usage and errors in message boxes on Windows.
Use the Windows MessageBox API if no console window can be obtained.

[ChangeLog][QtCore][QCommandLineParser] Message boxes are used
to display errors and usage if no console window can be obtained
on Windows.

Change-Id: I63ee8e4d8bd78db83e688fd69374779102562aa3
Reviewed-by: David Faure <david.faure@kdab.com>
2014-11-27 09:34:29 +01:00
Nico Vertriest
5ed2f422fc Doc: corrected autolink errors corelib/io
Task-number: QTBUG-40362
Change-Id: I1cdbde1f6b003556ba4b5e97a49c6d918518da0d
Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com>
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
2014-11-26 10:47:46 +01:00
Frederik Gladhorn
34aba4724f Merge remote-tracking branch 'origin/5.4' into dev
Conflicts:
	src/corelib/io/qiodevice.cpp
	src/plugins/bearer/linux_common/qofonoservice_linux.cpp
	src/plugins/bearer/linux_common/qofonoservice_linux_p.h
	src/plugins/platforms/android/qandroidplatformtheme.cpp
	src/tools/bootstrap/bootstrap.pro
	src/widgets/styles/qmacstyle_mac.mm

Change-Id: Ia02aab6c4598ce74e9c30bb4666d5e2ef000f99b
2014-11-24 13:39:13 +01:00
Alessandro Portale
82e266a83b New Qt logo
This patch replaces the old Qt logo with the new, flatter one.

The PNGs were optimized via: optipng  -o7 -strip "all"

Task-number: QTBUG-41685
Change-Id: I51983a45144373bf7aee31a32990ecbb2582f488
Reviewed-by: Robert Loehning <robert.loehning@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
2014-11-05 08:10:42 +01:00
Kai Koehne
a5c624622b Fix compiler warning in securesocketclient example
The warning was introduced in a133cea2 .

Change-Id: Ia8180b6c7d83f57cba79519bf4c0e3bf97966c16
Reviewed-by: Richard J. Moore <rich@kde.org>
2014-10-30 10:52:51 +01:00
Kai Koehne
68d4eec30b Use exising host / port for securesocketclient example
Change-Id: I321622b393ea1f452805299d74a28d12270b2238
Reviewed-by: Richard J. Moore <rich@kde.org>
2014-10-30 10:52:42 +01:00
Jerome Pasion
7567e09389 Doc: Updated thumbnail images for some examples.
-Application Example
-Analog Clock
-Analog Clock Window
-Scribble
-Digital Clock

-Thumbnail images were created with an obscure window manager and
they look out of place in the Welcome Mode in Qt Creator.
-Used Windows 7 as the platform.
-Images within the documentation not updated because they are still
relevant.

Task-number: QTBUG-33597
Change-Id: I255fc4960e9adcec273f21287ef2182656c6b007
Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com>
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
2014-10-28 19:31:53 +01:00
Lorn Potter
44654675ed Do not add invalid configurations to bearermonitor
If the list of configurations takes time in the backend,
the defaultConfiguration will be invalid at this time, but will
be updated by the backend.

Change-Id: I2886a8f6c569c993814172ccaa46e4bb5ba5e0d6
Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
2014-10-27 19:14:55 +01:00
Alexander Volkov
41ece1cbc1 Fix includes in mousebuttons example
Remove QtWidgets from buttontester.h and QtGui from main.cpp.

Change-Id: Ie5925a33c58c1abd9747ab0ab7040e7d1b0769a9
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2014-10-27 15:30:51 +01:00
Frederik Gladhorn
2eb26c1709 Merge remote-tracking branch 'origin/5.4' into dev
Conflicts:
	src/gui/text/qfontdatabase.cpp

Change-Id: I6ac1f55faa22b8e7b591386fb67f0333d0ea443d
2014-10-27 13:00:36 +01:00
Alexander Volkov
309e82021d Doc: Include QtWidgets instead of QtGui
Change-Id: Ib7f3183efd446abb7cc191f33128b4e230ee372c
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
2014-10-27 09:43:59 +01:00
Laszlo Agocs
c1fc540273 Further restrict the threaded opengl example
Mesa llvmpipe (e.g. the opengl32sw.dll we are shipping) cannot
handle threading either.

Change-Id: Id822736c4a9eef39e56776dcd1f398fc31ebc0f4
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2014-10-23 18:11:08 +02:00
Kai Koehne
a133cea211 SecureSocketClient: Show general connection errors
So far the example didn't show any errors when the connection to the
server couldn't be established (e.g. because the host/port number was
wrong, but also because the SSL handshake already failed).

The fix shows a modal error dialog in this case.

Change-Id: Ia517bf79c5fb2ccdb1edabded28f86759f3e6dcf
Reviewed-by: Richard J. Moore <rich@kde.org>
2014-10-23 17:12:48 +02:00
Frederik Gladhorn
3361fcbc28 Merge remote-tracking branch 'origin/5.4' into dev
Change-Id: If7e51514ed6832750e3ad967e4d322ccf920d2bb
2014-10-20 19:12:25 +02:00
Laszlo Agocs
59c68e6830 Remove unused variable in opengl examples
To avoid warnings with some compilers

Change-Id: Iabe4f38c0bee29ab17149120d12ce198b49547c8
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2014-10-20 11:53:33 +02:00
Topi Reinio
cf8f369f85 Move Qt Core examples under a common subdirectory
Qt Core examples were scattered into several subdirectories under
qtbase/examples. This caused an issue with the example manifest
file generated by QDoc; it expects to find all examples under a
common directory in order to produde correct paths to the example
.pro files. Qt Creator will not find the examples without a valid
manifest file.

This change moves the examples and edits the documentation files
accordingly.

Task-number: QTBUG-41963
Change-Id: I51d86782e0ba21c5c9bae5f15401ec774abe5cf8
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@digia.com>
2014-10-17 14:57:13 +02:00
Laszlo Agocs
0ff3e7d155 Make hellowindow multi display capable on embedded
Platforms like eglfs allow a single window per screen. Thus the behavior of
--multiple is not suitable since it tries to open multiple windows on the
primary screen. Instead, introduce --multiscreen.

Add also --timeout to quit the app after 10 seconds. This is essential on
platforms that do not have windows with decorations that can be used to
close windows.

With eglfs' kms/drm hooks, starting with --multiscreen will now show a
rotating logo on all connected displays, with some random background color.

Change-Id: I53f2651f05620e752c289038a9b3ff4508273173
Reviewed-by: Louai Al-Khanji <louai.al-khanji@digia.com>
Reviewed-by: Andy Nichols <andy.nichols@digia.com>
2014-10-16 14:41:19 +02:00
Friedemann Kleint
eaf04207bd Improve threadedqopenglwidget example.
Retrieve vendor/renderer name similar to context info
and exclude renderers that do not support threaded
Open GL (ANGLE/noveau).

Change-Id: I690c2fc277538bf28bf1f6032c2e017ede15e434
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
2014-10-10 13:17:13 +02:00
Frederik Gladhorn
881ceeff42 Merge remote-tracking branch 'origin/5.4' into dev
Change-Id: I05fcd8dc66d9ad0dc76bb7f5bae05c9876bfba14
2014-10-09 17:56:52 +02:00
Friedemann Kleint
858935fa66 Fix executable name of mousebuttons example.
Change-Id: Icf41ade3a4d2d14535e6fd42212b27ac01c5177f
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2014-10-09 08:35:32 +02:00
Friedemann Kleint
bd09405792 Add debug output for QGestureEvent and QGesture classes.
Task-number: QTBUG-15768
Task-number: QTBUG-40461
Change-Id: I3fe29f71ddf39c76efaca02d2b70494378d147dc
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2014-09-30 16:16:51 +02:00
Nico Vertriest
54853c5f66 Doc: Use title case in section1 titles
Using Python script title-cased.py

Task-number: QTBUG-41250
Change-Id: I00d3d7a0b30db7304a7904efd6d63abd9a7b493b
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2014-09-30 13:52:51 +02:00
Laszlo Agocs
7824a9ba31 Make qopenglwidget example functional without timers too
Change-Id: I6a89eaf794202c45a5ad3152d304e46041704730
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
2014-09-30 09:38:44 +02:00
Oswald Buddenhagen
189dc655bb Merge remote-tracking branch 'origin/5.4' into dev
Conflicts:
	src/corelib/tools/qbytearray.cpp
	src/gui/image/qimage.cpp
	src/gui/image/qppmhandler.cpp
	src/gui/kernel/qguiapplication.cpp
	src/gui/painting/qpaintengine_raster.cpp

Change-Id: I7c1a8e7ebdfd7f7ae767fdb932823498a7660765
2014-09-29 14:08:49 +02:00
Allan Sandfeld Jensen
cc3875c2e4 Balloon tip must follow systemtray icon
If the a message notification is created at the same time as the system
tray icon is embedded it may start at a wrong location, since the icon
location it bases its own location is not yet final.

This patch adds code to update the balloon tip location when the system
tray icon is moved or resized.

The bug and fix can be tested by the systray example by disabling the
icon and letting show message trigger both showing it and the message.

Change-Id: Ie1dc10489ad420e581e32afeb757c236fb5129ab
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2014-09-25 16:12:55 +02:00
Friedemann Kleint
8f2519660b Polish the mdi example.
Add a command line parser to be able to pass on files.

Task-number: QTBUG-35146
Change-Id: I32cbb9ec1e87667076e40a81c66674cf16836b54
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2014-09-24 23:07:25 +02:00
Matti Paaso
974c210835 Update license headers and add new license files
- Renamed LICENSE.LGPL to LICENSE.LGPLv21
- Added LICENSE.LGPLv3
- Removed LICENSE.GPL

Change-Id: Iec3406e3eb3f133be549092015cefe33d259a3f2
Reviewed-by: Iikka Eklund <iikka.eklund@digia.com>
2014-09-24 12:26:19 +02:00
Frederik Gladhorn
c5a3e5edd9 Merge remote-tracking branch 'origin/5.3' into 5.4
The isAlwaysAskOption was removed in 3862171315
so manually removed code in
src/plugins/bearer/connman/qconnmanengine.cpp

Conflicts:
	src/corelib/global/qglobal.h
	src/corelib/tools/qcollator_macx.cpp
	src/corelib/tools/qstring.cpp
	src/gui/kernel/qwindow.cpp
	src/gui/kernel/qwindow_p.h
	src/gui/text/qtextengine.cpp
	src/platformsupport/fontdatabases/fontconfig/qfontenginemultifontconfig_p.h
	src/plugins/platforms/android/qandroidinputcontext.cpp
	src/plugins/platforms/xcb/qglxintegration.cpp
	src/plugins/platforms/xcb/qglxintegration.h
	src/plugins/platforms/xcb/qxcbconnection_xi2.cpp
	src/testlib/qtestcase.cpp
	src/testlib/qtestlog.cpp
	src/widgets/dialogs/qfiledialog.cpp
	src/widgets/kernel/qwindowcontainer.cpp
	tests/auto/corelib/tools/qcollator/tst_qcollator.cpp
	tests/auto/gui/text/qtextscriptengine/tst_qtextscriptengine.cpp
	tests/auto/widgets/kernel/qwidget_window/tst_qwidget_window.cpp
	tests/auto/widgets/widgets/qlineedit/tst_qlineedit.cpp

Change-Id: Ic5d4187f682257a17509f6cd28d2836c6cfe2fc8
2014-09-23 11:23:36 +02:00
Tomi Korpipää
66e23d23a7 Changed font-family to Times New Roman
Task-number: QTBUG-40839
Change-Id: I3be6de829b6f26b26e7ec654ccb117bdb58cdf41
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
2014-09-19 07:48:28 +02:00
Alex Blasche
935e6a2b33 Make qtconcurrent map example compile on exotic compilers
Task-number: QTBUG-9015
Change-Id: I1019765312c8d55728023642601199506269be6d
Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
2014-09-18 08:16:00 +02:00
Mika Salmela
1fb43025f2 Fix cancel operation for example "Application"
On the save dialog the cancel option is detected now from exec()
method.

Change-Id: I977626b83fe770ddc148b57551becd04e5fd9dd5
Task-number: QTBUG-41020
Reviewed-by: Alessandro Portale <alessandro.portale@digia.com>
2014-09-17 12:03:14 +02:00
Oswald Buddenhagen
d572ab1bb4 Merge remote-tracking branch 'origin/5.4' into dev
Change-Id: Id4997327cc01bd4bb397a463bdffbd15e80398ef
2014-09-10 11:42:50 +02:00
Rolf Eike Beer
892af51834 examples: fix build without OpenGL
Task-number: QTBUG-41200
Change-Id: I18df5a3c6f38d6b9a66b84a71777f1e4daa3ba3a
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2014-09-10 10:52:56 +02:00
Laszlo Agocs
f4ae4f41b0 hellowindow: Set all the state for each frame
Trying to be smart and minimizing the amount of GL calls per frame
to provide a good example was a mistake (in a way): There are
components, like the eglfs mouse cursor, that change the context state.
To make sure the example work in these cases, set the state upon
each frame.

Change-Id: Ief1fd7bbb0fb1955a64dac97a071b7a3d9d506d4
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
2014-09-04 14:06:42 +02:00
Frederik Gladhorn
2dfc786c26 Merge remote-tracking branch 'origin/5.4' into dev
Change-Id: I2811ff0b9d4097f0be60ff16e9664a5060cff23e
2014-09-01 11:35:53 +02:00
Laszlo Agocs
8688656641 Use QMenuBar::addMenu in the qopenglwidget example
Like in all other places. This way the resulting QMenu is correctly
parented so it will show up at the proper position even on platforms
which do not have a way to position top-level windows.

Task-number: QTBUG-29025
Change-Id: I2aa6fe73699379029c44a3f379366a2133753190
Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
2014-08-25 17:40:18 +02:00
Laszlo Agocs
a0cc43fbc8 Set a size in qopenglwindow example
Use showMaximized(). Just calling show() without setting a size can result
in a zero-sized, invisible window on some platforms.

Change-Id: Ifa48258060e3d651c2fac3a1409a26a2c3db6bdb
Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
2014-08-24 23:01:39 +02:00
Giuseppe D'Angelo
75b62f3a17 Merge "Merge remote-tracking branch 'origin/5.3' into 5.4" into refs/staging/5.4 2014-08-19 00:42:00 +02:00
Bernd Weimer
cf32311d74 fingerpaint example: be sensitive to pressure only when supported
Fix fingerpaint example for platforms that don't support touch device
area and pressure by setting default size of drawn ellipse.

Change-Id: I884c688aa8ef98debf24876dbefaa4cff43a86a2
Reviewed-by: Fabian Bumberger <fbumberger@rim.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2014-08-18 15:38:21 +02:00
Frederik Gladhorn
d5bf787fc0 Merge remote-tracking branch 'origin/5.4' into dev
Change-Id: Ia03a010d1fbfc89c04144c1c106336f0e1c45ec1
2014-08-18 15:25:11 +02:00
Allan Sandfeld Jensen
a0b021d136 Fix selection of fonts based on styleName
By carrying the styleName through from QFontDef to
bestFoundry and giving it to bestStyle that can use it
we can accurately match fonts based on styleName. This
makes it possible to match styles such as DejaVu Sans
Condensed and Ubuntu Medium.

The example fontsampler is updated so it can actually
sample all the different styles it lists.

Change-Id: I381effc74130311f98794cd07d30be10dee4fe45
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2014-08-14 14:39:20 +02:00
Laszlo Agocs
6f7bc2a707 Avoid transparency in qopenglwindow example
On systems that give alpha configs by default writing alpha values of
less than 1.0 is a bad idea since it will lead to the content behind the
window becoming visible, even though this is not the example's intention.

Change-Id: I23cdfc1fb78d77b1cbc192d2aba5d6665a7acfcc
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
2014-08-14 11:02:45 +02:00
Jędrzej Nowacki
b3f4e5cbe2 Use QString::splitRef in customtype example
There is no need to allocate all these strings

Change-Id: I398e1cc05bd3ad24df067a967a5e24fbc6d452ce
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2014-08-14 09:24:05 +02:00
Ivan Komissarov
b9d0116356 Add the StorageView example
The StorageView example demonstrates the QStorageInfo API.

Change-Id: Ifaabadbe64fdf26d13a4ce4690e6b54514667c9f
Reviewed-by: Ivan Komissarov <ABBAPOH@gmail.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2014-08-14 08:20:45 +02:00
Laszlo Agocs
5621a7c501 Fix composition for windows with alpha
While we will cover the entire surface with our textured quads, the clear
is still necessary in order to make top-levels with TranslucentBackground
render correctly: We don't want to blend transparent areas with undefined
content that is in the surface's framebuffer.

Blending is problematic for alpha values. We now prevent the blended alpha
from being written out. This ensures that in examples like qquickviewcomparison,
where the backingstore image contains an alpha of 0.5 while the QQuickWidget
texture 1.0, the result is still an alpha value of 1.0 in the final image.
Writing out an alpha of 0.5 would break on systems where windows get an alpha
buffer by default.

hellogl2 can now take a --transparent parameter which makes the QOpenGLWidget
being cleared to transparent in order to verify it works in combination
with Qt::WA_TranslucentBackground.

The swapped red and blue problem is also corrected. RGBA8888 does not need
swizzling. The only format that needs this is RGB32.

Task-number: QTBUG-40716
Change-Id: I54a9fd3a91a1b59575b38cdb908835315514e40f
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
2014-08-13 16:14:19 +02:00
Frederik Gladhorn
ca524e5b70 Merge remote-tracking branch 'origin/5.3' into 5.4
Manually included changes from
3a347a4e70
in src/opengl/qgl.cpp.

Conflicts:
	src/opengl/qgl_qpa.cpp
	src/plugins/platforms/android/androidjnimain.cpp

Change-Id: Ic26b58ee587d4884c9d0fba45c5a94b5a45ee929
2014-08-12 13:05:02 +02:00
Laszlo Agocs
611558d877 Modernize the OpenGL examples
Change them to use QOpenGLWidget and QOpenGLTexture.
Advocate also the usage of VBOs.

Hopeless examples, that rely on the fixed pipeline and will
not compile or work in ES and dynamic builds, are moved to
a "legacy" directory. The documentation pages for these are
removed. This long due change avoids the confusion newcomers
experience when trying to get started with Qt 5 and OpenGL.

hellowindow's behavior is changed to open a single window only
by default. The old default behavior, that opened three windows
on platforms that supported both MultipleWindows & ThreadedOpenGL,
can be requested by passing --multiple. --single is removed since it
is the default now. This plays much nicer with drivers that have
issues with threading.

In addition, say hello to hellogl2.

This is the old hellogl example updated to use QOpenGLWidget and
OpenGL 2. It also has a mainwindow with multiple (un)dockable widgets
containing the OpenGL widgets. This helps testing the behavior when
the top-level of the QOpenGLWidget changes and provides a very
important example of how to do proper resource management in this case.
(must use aboutToBeDestroyed() of the context, since the context goes
away and is replaced by a new one on every dock/undock)

As a bonus, the logo is now real 3D, no more orthographic nonsense.

Launch with --multisample to request 4x MSAA.

Launch with --coreprofile to request 3.2 Core. In this particular example
the shaders are present in both versions and there is a VAO so the application
is functional with core profile contexts.

Change-Id: Id780a80cb0708ef164cc172450ed74050f065596
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
2014-08-12 07:47:23 +02:00
Gabriel de Dietrich
909d3f5c73 Font Database: Add support for private, system UI font families
We introduce QPlatformFontDatabase::isPrivateFontFamily() to allow
testing for private, system UI font families. Both QFontComboBox
and QFontDialog need to filter out those private font families
which, by definition, should be hidden from the end user.

(The textedit example had to be updated to fix the issue where the
default font would be private. In 5.4, we will be adding an equivalent,
public API in QFontDatabase, and a better solution for the textedit
example and QTexEdit in general).

In particular, on OS X and iOS, private fonts are used for the system
UI font. Those have their font family name prefixed by a dot.
QCoreTextFontDatabase knows about this, and makes sure those are
tested positive as private font families. In order to have a cleaner
layer separation, we moved the QPA theme font resolution from the
platform theme classes into QCoreTextFontDatabase for both Cocoa and
iOS QPA plugins.

In both cases, we use CoreText's CTFontCreateUIFontForLanguage(), that
nicely maps to the HITheme API we were using so far on Mac. That means
one HITheme dependency less. We also cache the font descriptors we get
for these font for each time QCTFD::populateFamilies() gets called.
(While not common, this currently happens in auto-tests, like
tst_QFontDatabase, and could happen in actual applications -- specially
when adding and removing application fonts.)

Change-Id: Ic6f0b60f9f597afee1a43596a669742dc546b97f
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
2014-08-11 10:46:13 +02:00
Laszlo Agocs
78221fe762 Clean up the QOpenGLWindow example
1. Use includes without module prefixes, as is the custom in examples.
2. No inline functions to make it more readable.
3. Pause animation on pressing P and document our signal connection a bit more.

Change-Id: I68dc3d4c74b639cf3fec17b63b7f49626db58bdb
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
2014-08-07 09:19:15 +02:00
Laszlo Agocs
4ff12977d8 Add missing precision qualifiers in qopenglwindow example
Make GLES implementations happy.

Change-Id: Ib389e379f23794eee0fa71ca26b863e56cee662e
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
2014-08-07 09:03:50 +02:00
Laszlo Agocs
34fbc61f22 Introduce QRasterWindow
A simple convenience class providing a QWindow that has a
paintEvent and supports opening a painter on itself. It
behaves exactly like QOpenGLWindow in this respect, which is not
surprising since they share the same base class (QPaintDeviceWindow).

QRasterWindow does not however have any OpenGL dependencies and will
be present in -no-opengl builds too.

[ChangeLog] Added QRasterWindow, a thin convenience wrapper for a
QWindow on which a QPainter can be opened.

Done-with: Jorgen Lind <jorgen.lind@digia.com>
Change-Id: I37e82720492945d7b85d5f713eea8d5f7556e511
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@digia.com>
2014-08-05 16:47:42 +02:00
Laszlo Agocs
e48737ae77 Introduce QOpenGLWindow
[ChangeLog] Added QOpenGLWindow. This serves as a convenience class for
creating windows showing OpenGL content via an API similar to QGLWidget
and without any widget dependencies.

Done-with: Jorgen Lind <jorgen.lind@digia.com>
Task-number: QTBUG-36899
Change-Id: I52e9bc61acb129dbfd3841b3adeffab2dbcf7f05
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
2014-08-05 16:47:37 +02:00
Laszlo Agocs
e453484bca Make QOpenGLWidget public
QOpenGLWidget is now public.

In addition Qt::WA_AlwaysStackOnTop is introduced to support the
special case of semi-transparent QOpenGLWidget or QQuickWidget on
top of regular widgets.

hellogl_es2 becomes the qopenglwidget example. This example performs
painting both via QPainter and native GL commands and has the OpenGL
widget combined with other, normal widgets.

The widget stack receives some changes when it comes to renderToTexture
widgets like QQuickWidget and QOpenGLWidget. Calling update() will now
result in a paint event, which is essential for QOpenGLWidget since we
want it to behave like a regular widget. The dirty region handling is
extended specially for such widgets due to performance reasons.
(an OpenGL content update must not result in any backingstore painting,
and is thus handled as a different kind of dirtiness)

[ChangeLog] Added QOpenGLWidget. This widget serves as a replacement for QGLWidget.

Task-number: QTBUG-36899
Task-number: QTBUG-40086
Change-Id: Ibf7f82fea99b39edfffd2fc088e7e0eadbca25cf
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
2014-08-01 17:13:59 +02:00
Laszlo Agocs
770f914083 Make hellogl work properly regardless of vsync
Task-number: QTBUG-39370
Change-Id: I5b7acb8367f18bfa9318c292657ff7fa0f21f664
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
2014-07-31 18:35:39 +02:00
Olivier Goffart
3b0c2b7c1b Examples: Add Q_DECL_OVERRIDE to overridden functions
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>
2014-07-15 08:44:44 +02:00
Frederik Gladhorn
f035786021 Merge remote-tracking branch 'origin/5.3' into dev
Change-Id: Ia12ffdb27ecdf25c2a2bdb0eed1945387502108a
2014-07-10 10:11:11 +02:00
Nico Vertriest
1b6bc6d34d Doc: moved saxbookmarks example files
Moved to qtbase/examples/xml/saxbookmarks
Png and qdoc file.
Updated qtxml.qdocconf accordingly.

Change-Id: Iafe50a09aee22f518adf9ec2ebf289e766e24ff4
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2014-07-09 12:17:34 +02:00
Nico Vertriest
71e1976bcc Doc: moved streambookmarks example files
Moved to qtbase/examples/xml/streambookmarks.
Files: qxmlstreambookmarks.qdoc and png files

Change-Id: I6edf975f1e0666a4283e65c933d31923695f8b4c
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2014-07-08 14:38:30 +02:00
Frederik Gladhorn
39a290af6c Merge remote-tracking branch 'origin/5.3' into dev
Conflicts:
	src/gui/accessible/qaccessiblecache_mac.mm
	src/gui/accessible/qaccessiblecache_p.h
	src/plugins/platforms/cocoa/qcocoaaccessibilityelement.h
	src/plugins/platforms/cocoa/qcocoawindow.h
	src/plugins/platforms/cocoa/qcocoawindow.mm
	src/widgets/kernel/qwidget_qpa.cpp

Manually moved change in qwidget_qpa.cpp to qwidget.cpp
    (cd07830e3b)

Change-Id: Ia51f471f9b53de2f3b07d77ea89db9303ac8961d
2014-07-03 23:56:45 +02:00
Topi Reinio
4827623acb Address Book example: Fix QTableView column sorting
Rearrange the code so that QTableView::setSortingEnabled() is
called after setting up the sort filter. This ensures that
new entries added to the model always follow the column
header's sort order.

Task-number: QTBUG-39585
Change-Id: Iaec8aa9342981817a019473ba12bad52cdbdfbb8
Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2014-07-02 08:41:11 +02:00
Frederik Gladhorn
a09a8d509a Merge remote-tracking branch 'origin/5.3' into dev
Conflicts:
	mkspecs/qnx-x86-qcc/qplatformdefs.h
	src/corelib/global/qglobal.h
	src/network/socket/qnativesocketengine_winrt.cpp
	src/plugins/platforms/android/androidjniaccessibility.cpp
	src/plugins/platforms/windows/qwindowswindow.cpp

Manually adjusted:
	mkspecs/qnx-armle-v7-qcc/qplatformdefs.h
	to include 9ce697f2d5

Thanks goes to Sergio for the qnx mkspecs adjustments.

Change-Id: I53b1fd6bc5bc884e5ee2c2b84975f58171a1cb8e
2014-07-01 16:25:19 +02:00
Laszlo Agocs
53c6c90c44 Disable some more qtbase examples for dynamic gl builds
Examples using OpenGL 1.x cannot be migrated. Therefore, similarly to ES
builds, we just disable them.

Change-Id: I76e888d2ecfb2582ae35853d9dcdd0cb686fddc6
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
2014-06-30 10:35:27 +02:00
Sergio Ahumada
5721c0811a Merge remote-tracking branch 'origin/stable' into 5.3
Change-Id: Icd073d40ce10ab4733b997036815795dd3fbaac1
2014-06-14 18:11:52 +02:00
Friedemann Kleint
3f39c0f76c Polish the image viewer example.
- Open files passed on the command line.
- Point the file dialog to the pictures location
  and use a filter string for the supported types.
- Set the window title according to file name.

Task-number: QTBUG-37203
Task-number: QTBUG-39287
Change-Id: I4e5e43875c3a7544c862c054181e75942939c1d5
Reviewed-by: David Faure <david.faure@kdab.com>
2014-06-12 14:23:48 +02:00
Sergio Ahumada
7ffbfed7c7 Merge remote-tracking branch 'origin/stable' into 5.3
Change-Id: I147a75ac74bd7b19dbeb99e1ec2836cc5bfc2806
2014-06-11 16:44:33 +02:00
Jerome Pasion
857c82f8a4 Doc: Updated Layout examples.
-added links to and from the overviews.
-added information on how to run the example.
-updated copyright.

Task-number: QTBUG-33597
Change-Id: Ib049cb94f136caa6916878959ae830248bd236b5
Reviewed-by: Martin Smith <martin.smith@digia.com>
Reviewed-by: Nico Vertriest <nico.vertriest@digia.com>
2014-06-10 15:56:59 +02:00
J-P Nurmi
0fcce50af0 Merge remote-tracking branch 'origin/stable' into dev
Conflicts:
	mkspecs/features/qt.prf
	src/plugins/platforms/xcb/qxcbwindow.h
	src/tools/qdoc/qdocindexfiles.cpp
	src/widgets/kernel/qwidget_qpa.cpp

Change-Id: I214f57b03bc2ff86cf3b7dfe2966168af93a5a67
2014-06-05 22:26:44 +02:00
Oswald Buddenhagen
c54f7720d0 fix qmaccocoaviewcontainer example
- fix build on 10.6
- actually build it at all

Change-Id: Ib929f8b56e55f00191f7fcfb2be25975e46a1af2
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2014-06-05 17:11:58 +02:00
Jerome Pasion
3e38944118 doc: Updated Qt D-Bus Examples.
-transferred group page from qtdoc repository
-added description in example pages
-set the example documentation to use the standard Qt thumbnail
-added an entry in the help index for the example page

Change-Id: I9d5747bc329b5ecc15acd2eb3139696931166c6f
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2014-05-28 16:52:04 +02:00
David Faure
739fc9f24e simpletreemodel example: rename parent() to parentItem() for clarity
I show this example during trainings, and parent() is too much like
QObject::parent(), QModelIndex::parent() and our model's parent()
[which calls this method], so it's less confusing if this is called
something clearer like parentItem().

Change-Id: I101342051349d94c4a3bc3d4bc332194d6779293
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2014-05-25 12:32:56 +02:00
Jake Petroules
f2891be008 Add a menu item to mainwindow example to toggle unified toolbars.
Change-Id: Id7d7433849565b1acfc690cf5e23e8105c6af993
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
2014-05-21 21:07:58 +02:00
Jake Petroules
32742959a2 Use the new unified toolbar implementation in examples on OS X.
Change-Id: Ica3476d16a4baab1f75e253eb406505f88018d47
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
2014-05-12 21:40:43 +02:00
hjk
82a6d37b99 Wiggly example: Modernize/compactify code
Change-Id: Iacfb308baac8eea60d56bf559113b36acb79d82a
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2014-05-12 18:00:25 +02:00
Laszlo Agocs
a57b8409a2 Fix up examples for dynamic opengl builds
Change-Id: Id311b00fe7783a3175dc1c4a38f627c78c470761
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2014-05-12 10:34:34 +02:00
Steven Ceuppens
c0b75d3e6b Update AddressBook Example
Adding parent to QDialog
As proposed on qt-project.org forum:
http://qt-project.org/forums/viewthread/41686/

Change-Id: Ib66d24e4afd0be803a1080c37bc6c0a189844786
Reviewed-by: Sze Howe Koh <szehowe.koh@gmail.com>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
2014-04-28 13:54:44 +02:00
Oswald Buddenhagen
a4ec90175c purge vestiges of opengl es 1 support
amends 0d5170256c.

Change-Id: Ifa178d38f602bb7c66ef13334673ff47e332af5b
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
2014-04-04 19:32:21 +02:00
Kai Koehne
1bc0df35d1 Updated outdated README for thread examples
Change-Id: I3fa8ac350dc89546793d49a31cc5a152c1f55958
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
2014-03-31 12:46:38 +02:00
Friedemann Kleint
c0701f3789 Polish the image gestures example.
- Add a command line parser to properly evaluate help option and
  directory argument, add options to disable gestures.
- Add logging category so that the user can actually see what is
  happening.
- Scale large images.
- Use qreal instead of float.
- Minor polishing: set window title, position file dialog at
  pictures location.

Task-number: QTBUG-37759
Task-number: QTBUG-37203

Change-Id: Ibaf54a13034b150386a8aee476f83a9eba298298
Reviewed-by: Indrajit Tapadar <indrajit.tapadar@digia.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2014-03-28 12:59:13 +01:00
Topi Reinio
ddf2e2367c Doc: Move IPC example documentation
Examples under examples/ipc were not part of any module
documentation. This change adds the above folder to
Qt Core documentation, and moves the corresponding
files so that the example documentation is built
correctly.

Change-Id: If1f34ce7ef04a02df8a87f820bb2e68ffa723dd4
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
2014-03-27 15:16:20 +01:00
Sergio Ahumada
c761d2721a Doc: Remove empty and duplicated file
This example already exists under

  examples/dbus/remotecontrolledcar/doc/src/dbus-remotecontrolledcar.qdoc

Change-Id: If50efa704fb29ed111d6d589ea74cd2575131372
Reviewed-by: Sze Howe Koh <szehowe.koh@gmail.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2014-03-27 08:21:06 +01:00
Morten Johan Sørvig
d2da291c93 Save using a window-modal sheet on Mac OS X.
Change-Id: Icd150787f9ff0878fafd459b3741d1b1e008f8bc
Reviewed-by: Jake Petroules <jake.petroules@petroules.com>
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
2014-03-20 12:53:31 +01:00
Kai Koehne
02ae29f39b Fix compiler warning in example
Fix warning

main.cpp:160:
warning: no return statement in function returning non-void
[-Wreturn-type]
 }
  ^

Change-Id: I4b74e8f56136077ef9a71b803d2756394fcd7658
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2014-03-20 10:36:34 +01:00
Friedemann Kleint
51e5378113 Use QCommandLineParser in example dnslookup.
Show how use QCommandLineParser with additional
parameter checking for custom options and positional
arguments.

Also explain how to display help in GUI applications.

Change-Id: I03513e09b7dd5b150259593da0af2ef2a281cab2
Reviewed-by: David Faure <david.faure@kdab.com>
2014-03-15 10:44:41 +01:00
Laszlo Agocs
406290856d contextinfo: Make it more responsive and improve error handling
Change-Id: If05cd906edc8b7f1fd4744d8d0a392aeec46a454
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
2014-03-14 18:21:02 +01:00
Laszlo Agocs
6a9f917b6a contextinfo example: Print the format() both for context and surface
And make the output a bit nicer.

Change-Id: I5f0f82374b6e9f9feca70a60c30967adb35d48ec
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
2014-03-14 18:20:46 +01:00
Friedemann Kleint
23a79b9119 Remove calls to setlocale in QtOpenGL cube example.
This is causing compilation errors on some Windows CE
configurations:

mainwidget.cpp(130) : error C3861: 'setlocale': identifier not found
mainwidget.cpp(149) : error C3861: 'setlocale': identifier not found

Change-Id: Ie863cd7c9c53cfef4074dabffe157d9068654a1c
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
2014-03-14 15:26:05 +01:00
Nico Vertriest
267eab3f39 Doc: correction link, example and parameter issues qtbase
Moved codecs folder to qtbase/examples
Corrected quote in dropsite.qdoc
Replaced snippet statement by include statement
Added doc for undocumented parameters

Task-number: QTBUG-34749

Change-Id: If4de95b8d39e5680fd0f63f8d2b6685a4b0a8052
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
2014-03-10 16:02:19 +01:00
Laszlo Agocs
625002f706 Build the cube opengl example both for desktop and ES
No reason to restrict it to desktop only, the code works on ES2 too.

Task-number: QTBUG-35730

Change-Id: I915a88cbf3c95a941d6bafd88ed57fef0b6a25b9
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
2014-03-07 14:48:11 +01:00
Laszlo Agocs
7b1058ac92 Do not attempt to open multiple windows in hellowindow on embedded
Platforms like eglfs will not allow opening more than one OpenGL-based
window. To prevent aborting the hellowindow example when invoked without
--single, enhance the capability check to include also WindowManagement
in addition to ThreadedOpenGL.

Change-Id: I147d90b31d9fd94912c36339d36af3f311aaa874
Reviewed-by: Andy Nichols <andy.nichols@digia.com>
2014-03-06 12:21:14 +01:00
Jędrzej Nowacki
2701585722 Fix warning about unused member
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>
2014-03-06 12:21:14 +01:00
Andrew Knight
04ef22b9ee CustomSortFilterModel example: fix build with QT_NO_CURSOR
Change-Id: Icb40e49365114fedd5f1ef118dbd61ff2c413863
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2014-03-06 12:21:14 +01:00
Laszlo Agocs
1e18df9c73 Extend QOpenGLFunctions with GL1 functions
This introduces the ability to indirectly invoke all common GL1-GLES2
functions via QOpenGLFunctions. The GL1 functions are not yet resolved,
since this would not work anyway when linking to an OpenGL implementation
directly. However this may change later but that will be a completely
internal change without affecting any public APIs.

Also migrate some of the opengl examples to use QOpenGLFunctions for
everything. Once dynamic GL loading becomes available on some platforms,
these examples should continue to function without any changes since they
do not anymore invoke any OpenGL functions directly.

Task-number: QTBUG-36483
Change-Id: Ie630029651e5a4863a480aac5306edd67ee36813
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
2014-03-04 15:59:05 +01:00
Laszlo Agocs
4b2f35d04c Dynamic GL: remove exporting symbols
Remove the opengl proxy for now. Later it will either be moved into
a separate library or replaced by a QOpenGLFunctions-based approach.

This means that the -opengl dynamic configuration is not usable
for the time being. The rest of the enablers remain in place.

The convenience function QOpenGLFunctions::isES() is now moved to
QOpenGLContext and is changed to check the renderable type. This is
extremely useful since besides supporting dynamic GL it solves also
the problem of GL_ARB_ES2_compatibility (i.e. it triggers the real ES
path when creating an ES-compatible context with a desktop OpenGL
implementation).

Task-number: QTBUG-36483
Task-number: QTBUG-37172
Change-Id: I045be3fc16e9043e1528cf48e6bf0903da4fa7ca
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
2014-03-04 15:59:05 +01:00
Laszlo Agocs
1219dbe543 Add an example for creating OpenGL contexts
Besides serving as an example for performing OpenGL rendering inside
a window container in a way that it works across all GL versions,
this is an extremely useful tool for developers and users alike
since it allows quick and easy checking of what sort of context a
particular driver returns for a particular QSurfaceFormat.

NB! Depending on the OpenGL driver, some surprises can be expected.
The handling of core/compatibility profiles, the fwdcompat bit,
the supported GLSL versions, etc. tend to be somewhat different
across the different OpenGL implementations.

Task-number: QTBUG-37071
Change-Id: Iae4328e66cd0bb19f74a77fefef93ea5a3221e31
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
2014-02-28 18:00:39 +01:00
Sze Howe Koh
b648195c31 Doc: Replace obsolete types with their newer counterparts
This patch ignores:
- Docs for obsolete types themselves
- Comparisons between new and obsolete types

Change-Id: Id9b1e628255113e7c44520abe0f8a4e0db4a283d
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
2014-02-25 16:36:34 +01:00
Friedemann Kleint
c05e5948a0 Fix division by zero in hellogl_es2 example.
Task-number: QTBUG-37027

Change-Id: Id18ee9c44650de9c434a82d3d10cf48e6ba9e78c
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
Reviewed-by: Kai Koehne <kai.koehne@digia.com>
2014-02-24 12:30:34 +01:00
Laszlo Agocs
ba77406c4d Avoid truncation warning in openglwindow example
msvc shows a warning about double -> float truncation. Avoid this.

Change-Id: I1b74cf407c81c881df5e95cc7d64a210888595e3
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
2014-02-21 15:52:59 +01:00
Laszlo Agocs
97c187da3c Dynamic GL switch on Windows
The patch introduces a new build configuration on Windows which
can be requested by passing -opengl dynamic to configure.

Platforms other than Windows (including WinRT) are not affected.
The existing Angle and desktop configurations are not affected.
These continue to function as before and Angle remains the default.

In the future, when all modules have added support for the dynamic
path, as described below, the default configuration could be changed
to be the dynamic one. This would allow providing a single set of
binaries in the official builds instead of the current two.

When requesting dynamic GL, Angle is built but QT_OPENGL_ES[_2] are
never defined. Instead, the code path that has traditionally been
desktop GL only becomes the dynamic path that has to do runtime
checks. Qt modules and applications are not linked to opengl32.dll or
libegl/glesv2.dll in this case. Instead, QtGui exports all necessary
egl/egl/gl functions which will, under the hood, forward all requests
to a dynamically loaded EGL/WGL/GL implementation.

Porting guide (better said, changes needed to prepare your code to
work with dynamic GL builds when the fallback to Angle is utilized):

1. In !QT_OPENGL_ES[_2] code branches use QOpenGLFunctions::isES() to
differentiate between desktop and ES where needed. Keep in mind that
it is the desktop GL header (plus qopenglext.h) that is included,
not the GLES one.

QtGui's proxy will handle some differences, for example calling
glClearDepth will route to glClearDepthf when needed. The built-in
eglGetProcAddress is able to retrieve pointers for standard GLES2
functions too so code resolving OpenGL 2 functions will function
in any case.

2. QT_CONFIG will contain "opengl" and "dynamicgl" in dynamic builds,
but never "angle" or "opengles2".

3. The preprocessor define QT_OPENGL_DYNAMIC is also available in
dynamic builds. The usage of this is strongly discouraged and should
not be needed anywhere except for QtGui and the platform plugin.

4. Code in need of the library handle can use
QOpenGLFunctions::platformGLHandle().

The decision on which library to load is currently based on a simple
test that creates a dummy window/context and tries to resolve an
OpenGL 2 function. If this fails, it goes for Angle. This seems to work
well on Win7 PCs for example that do not have proper graphics drivers
providing OpenGL installed but are D3D9 capable using the default drivers.

Setting QT_OPENGL to desktop or angle skips the test and forces
usage of the given GL. There are also two new application attributes
that could be used for the same purpose.

If Angle is requested but the libraries are not present, desktop is
tried. If desktop is requested, or if angle is requested but nothing
works, the EGL/WGL functions will still be callable but will return 0.
This conveniently means that eglInitialize() and such will report a failure.

Debug messages can be enabled by setting QT_OPENGLPROXY_DEBUG. This will
tell which implementation is chosen.

The textures example application is ported to OpenGL 2, the GL 1
code path is removed.

[ChangeLog][QtGui] Qt builds on Windows can now be configured for
dynamic loading of the OpenGL implementation. This can be requested
by passing -opengl dynamic to configure. In this mode no modules will
link to opengl32.dll or Angle's libegl/libglesv2. Instead, QtGui will
dynamically choose between desktop and Angle during the first GL/EGL/WGL
call. This allows deploying applications with a single set of Qt libraries
with the ability of transparently falling back to Angle in case the
opengl32.dll is not suitable, due to missing graphics drivers for example.

Task-number: QTBUG-36483
Change-Id: I716fdebbf60b355b7d9ef57d1e069eef366b4ab9
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
2014-02-14 10:51:44 +01:00
Frederik Gladhorn
a9c88c1f39 Merge remote-tracking branch 'origin/stable' into dev
Conflicts:
	src/gui/image/qimage.cpp
	src/gui/text/qtextengine.cpp
	src/plugins/platforms/linuxfb/qlinuxfbscreen.cpp
	src/printsupport/kernel/qprintengine_win.cpp

Change-Id: I09ce991a57f39bc7b1ad6978d0e0d858df0cd444
2014-02-12 16:28:07 +01:00
Frederik Gladhorn
df62c31807 Merge "Merge remote-tracking branch 'origin/stable' into dev" into refs/staging/dev 2014-02-11 15:12:00 +01:00
Kai Koehne
dc05fe7a5b Fix out-of-tree compilation of widget examples
'styles' are only defined in the qt build internals, when the
examples are compiled inside a configured Qt source. That's not
the case for the examples e.g. in the Qt SDK.

(windows is a default style on all platforms, anyway. So I
think the check is superfluous in the first place.)

Task-number: QTBUG-36655
Change-Id: I7114619efd479408dad99c8514f8e33ddcab7c7c
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2014-02-11 12:35:03 +01:00
Friedemann Kleint
59892468c9 widgets/mainwindows/mainwindow example: Use mouse release event for dock title.
Task-number: QTBUG-36364

Change-Id: Ie3352c8e72a636aee2099ca3138eb0ac77425e7e
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2014-02-07 22:12:10 +01:00
Frederik Gladhorn
a1fe728fa5 Merge remote-tracking branch 'origin/stable' into dev
Conflicts:
	src/gui/kernel/qguiapplication.cpp
	src/plugins/platforms/android/androidjnimain.cpp
	src/plugins/platforms/android/qandroidplatformintegration.cpp
	src/plugins/platforms/android/qandroidplatformintegration.h
	src/plugins/platforms/android/qandroidplatformopenglcontext.cpp
	src/plugins/platforms/cocoa/qcocoawindow.h
	src/plugins/platforms/cocoa/qcocoawindow.mm
	src/plugins/platforms/xcb/qxcbconnection_xi2.cpp
	src/sql/doc/src/sql-driver.qdoc
	src/widgets/widgets/qtoolbararealayout.cpp

Change-Id: Ifd7e58760c3cb6bd8a7d1dd32ef83b7ec190d41e
2014-02-07 13:07:25 +01:00
Mitch Curtis
1d5ee90969 Update some more screenshots in qtbase/examples/widgets.
The screenshots were taken on Windows 7 with the Aero theme.

Change-Id: I2517664e25389f4fb87408daec7b720dfb785bf0
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2014-01-31 16:18:07 +01:00
Nico Vertriest
0b26ad05bb Doc: corrected link/example errors
Update pro files after move gestures folder
Update snippet statements
Corrected path in imagegestures.pro

Task-number: QTBUG-34749

Change-Id: Icc19908914e36507e412ab63bf0cc2809aa48e17
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
2014-01-31 16:18:07 +01:00
Mitch Curtis
14addd2cbb Update some screenshots in qtbase/examples/widgets.
The screenshots were taken on Windows 7 with the Aero theme.

Change-Id: Ief04c3a9c0084a778606ba72f1f3199119d5c64e
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2014-01-31 14:46:31 +01:00
Friedemann Kleint
1fb42377a2 Fix MSVC-warnings about double to float truncation.
Change-Id: I4aef12bd8fe37dffb06fc7d0b6a330bfc42fa270
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
2014-01-24 20:26:39 +01:00
Friedemann Kleint
558ae43b1b Fix MSVC-warnings about stray */* in sources.
Change-Id: Ifa8de548dc8df79fa2b5d884383dc120661cb45a
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2014-01-24 18:50:05 +01:00
Nico Vertriest
4fab72a5eb Doc: corrected broken links
Links fixed:  Extra Filters
              Basic Tools
              blockingfortuneclient
              Thread Support
              Drag and drop examples
              qBinaryFind
              qmake common project types
              imagegestures
Task-number: QTBUG-34749
Change-Id: Ib93dda00716dc596db327fee5b97e110a9f27fa7
Reviewed-by: Martin Smith <martin.smith@digia.com>
2014-01-23 17:00:30 +01:00
Frederik Gladhorn
9033977d39 Merge remote-tracking branch 'origin/stable' into dev
Conflicts:
	src/corelib/global/qglobal.h
	src/corelib/tools/qstring.cpp
	src/gui/image/image.pri
	src/gui/image/qimage.cpp
	src/plugins/platforms/cocoa/qcocoawindow.h
	src/plugins/platforms/cocoa/qcocoawindow.mm
	src/plugins/platforms/eglfs/qeglfshooks_stub.cpp
	tests/auto/corelib/io/qstandardpaths/tst_qstandardpaths.cpp

Change-Id: I3b9ba029c8f2263b011f204fdf68c3231c6d4ce5
2014-01-20 18:18:59 +01:00
Jonathan Liu
b765a0b19d Doc: Fix typo in Fade Message Effect Example documentation
Change-Id: I3a64f296d01f2b0147f87b406163ff25c4d12ada
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
2014-01-16 02:38:11 +01:00
Oswald Buddenhagen
882bf3475c expand tabs and related whitespace fixes in *.{cpp,h,qdoc}
the diff -w for this commit is empty.

Started-by: Thiago Macieira <thiago.macieira@intel.com>
Change-Id: I77bb84e71c63ce75e0709e5b94bee18e3ce6ab9e
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2014-01-13 22:46:50 +01:00
Simon Hausmann
b5ab7ee0d7 Merge remote-tracking branch 'origin/stable' into dev
Change-Id: Id13badc270db98806048753fd7fb658aa17f1ede
2014-01-03 14:30:21 +01:00
Jeff Tranter
2e8c3f7444 Fix some typos in documentation.
Fix some spelling and grammatical errors in comments that show up in Qt documentation. No changes to code.

Change-Id: I2e946fda0bd9a2117f8e9b2fb300df9bf0a98a6c
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2014-01-02 17:21:09 +01:00
Frederik Gladhorn
f0fbff4c90 Merge remote-tracking branch 'origin/stable' into dev
Change-Id: I2defae1904154283446b069d151c3ef57302ec7b
2013-12-24 00:56:59 +01:00
Nico Vertriest
ac90b4c46f Doc: corrected broken links
Task-number: QTBUG-34749

Corrected link to drag and drop example.
Corrected link to {mandatory fields}
Created target referring to macros for defining plugins

Change-Id: I387a2d9bab428b2eacd8d371f08c72f42f7e2be2
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2013-12-20 10:38:01 +01:00
Nico Vertriest
04133551a5 Doc: Move XML example documentation to correct location
Moving the examples documentation to resolve doc linking
issues.

Task-number: QTBUG-34749
Change-Id: I2adb1b5d37911c7df6a78a03741d3d43ab24eafb
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2013-12-20 10:37:43 +01:00
Nico Vertriest
d9bad12fc8 Doc: solved link problem for dombookmarks.qdoc
Task-number: QTBUG-34749
Change-Id: I2f2fbf16314e069ab04e5c5ab4bcef9780c008a2
Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2013-12-16 19:29:52 +01:00
Simon Hausmann
25b390256b Merge "Merge remote-tracking branch 'origin/stable' into dev" into refs/staging/dev 2013-12-09 10:13:48 +01:00
Oliver Wolff
e4af81f13a WinRT: Fixed compilation of bearermonitor example
Change-Id: I761ad1d85d97d7746d826225f03f95c2f04f8b88
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@digia.com>
2013-12-06 15:06:47 +01:00
Frederik Gladhorn
f6dbdd9c16 Merge remote-tracking branch 'origin/stable' into dev
Conflicts:
	src/sql/drivers/sqlite/qsql_sqlite.cpp

Change-Id: Ia7cffd2c99ae3d5eea6b5740683c06e921336dcd
2013-12-05 18:52:38 +01:00
Nico Vertriest
eaff48d362 Doc: Moved Books SQL Example documentation
Moved qdoc and image file to correct qdoc folder.
Added brief and ingroup statements to books.qdoc.

Task-number: QTBUG-34749

Change-Id: I5806ffd6f116cccf10238e3e1a9fc627ad0e93a9
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2013-12-05 14:56:29 +01:00
Frederik Gladhorn
777cdb00e7 Merge remote-tracking branch 'origin/stable' into dev
Change-Id: Ibb342cc5fc55ff9a3f4b3ecbd53936b57bc13e63
2013-11-29 15:59:34 +01:00
Morten Johan Sørvig
af1dbfd223 Make OpenGL examples work on retina displays.
glViewport expects device pixels, but the various
geometry accessors returns values in device-independent
pixels.

Change-Id: I8004692de82251e4f1f25bf8f2698895f222ede3
Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
2013-11-29 10:05:24 +01:00
Frederik Gladhorn
4a8273a6fc Merge remote-tracking branch 'origin/stable' into dev
For the conflicts in msvc_nmake.cpp the ifdefs are extended since we
need to support windows phone in the target branch while it is not there
in the current stable branch (as of Qt 5.2).

Conflicts:
	configure
	qmake/generators/win32/msvc_nmake.cpp
	src/3rdparty/angle/src/libEGL/Surface.cpp
	src/angle/src/common/common.pri
	src/corelib/global/qglobal.h
	src/corelib/io/qstandardpaths.cpp
	src/plugins/platforms/qnx/qqnxintegration.cpp
	src/plugins/platforms/qnx/qqnxscreeneventhandler.h
	src/plugins/platforms/xcb/qglxintegration.h
	src/widgets/kernel/win.pri
	tests/auto/corelib/thread/qreadwritelock/tst_qreadwritelock.cpp
	tests/auto/corelib/tools/qdatetime/tst_qdatetime.cpp
	tests/auto/gui/text/qtextdocument/tst_qtextdocument.cpp
	tools/configure/configureapp.cpp

Change-Id: I00b579eefebaf61d26ab9b00046d2b5bd5958812
2013-11-26 22:35:48 +01:00
Mandeep Sandhu
60dc35e428 Examples: Add support for custom nameserver to dnslookup
Updated dnslookup example to take an optional nameserver argument
for doing DNS lookup against a specific nameserver.

Task-number: QTBUG-30166
Change-Id: I9f46f9f766b56f770d2c8372e3bfad5c71023c73
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2013-11-07 09:44:44 +01:00
Sze Howe Koh
16198d963d Doc: Fix broken links
Task-number: QTBUG-33360

Change-Id: Ic944cb2f575c35ebad64852ef5fc44a50ac03571
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2013-11-05 00:29:01 +01:00
Sze Howe Koh
6b8e866391 Doc: Clean up threading examples
- Example 3 (Clock) is a collection of anti-patterns.
    - It implements a slot in a QThread subclass and then forces the new
      thread to use Qt::DirectConnection to invoke the slot in the
      "wrong" thread.
    - It talks about getting away with non-thread-safe usage
    - It uses a thread as a timer and then admits that it's an over-
      complicated approach.
- Example 4 (Permanent Thread) is over-complicated yet incomplete. A
  better one exists in the QThread class ref.
- Example 1 (Thread Pool) is covered by the QThreadPool class ref.
- Example 2 (QtConcurrent::run()) is covered in the "Threading and
  Concurrent Programming Examples" page and the "QtConcurrentRun" page.
- The undocumented "Hello Thread" example is covered in the QThread
  class ref.
- These examples cannot be accessed from Qt Creator's Examples tool.
- These examples are neither widget-related nor tutorials, contrary to
  their source paths.

Task-number: QTBUG-33360
Change-Id: Ic79cb764ee925ddbcbeafee8e1d01db7fe0f6cfe
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
2013-11-05 00:29:01 +01:00
Oswald Buddenhagen
f6a5e3d1e8 remove remaining non-concurrent branches from concurrent samples
amends 677825f0ba.

Change-Id: I8bc3ade3a1602b9a2c0bdc837f4b19c67b2e0dba
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2013-10-29 15:37:30 +01:00
Oto Magaldadze
e913972d52 added QAbstractSpinBox::setGroupSeparatorShown function.
[ChangeLog][QtWidgets][QAbstractSpinBox] QTBUG-5142 - This will
allow a group (thousand) separator to be shown in QSpinBox
and QDoubleSpinBox widgets.

Task-number: QTBUG-5142

Change-Id: I2e23f5f83c93bb092a2dbd784e06d17d40d42909
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2013-10-29 12:12:16 +01:00
Frederik Gladhorn
840f6a40e6 Merge remote-tracking branch 'origin/stable' into dev
Change-Id: Ie56539b2e0be611a363b5f15ae5412a78d6945a2
2013-10-24 12:48:42 +02:00
Oswald Buddenhagen
f14e268694 don't erroneously claim that gui support is needed
Change-Id: Ia7b1f02cab9fa0fc9e487ca49d75e85ed0cfee9d
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2013-10-16 17:10:15 +02:00
Oswald Buddenhagen
677825f0ba remove non-concurrent branch from concurrent example
kinda stupid to have it ...

Change-Id: Icb31c524e04f43b0fb966c5500e22dfd574f969f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2013-10-16 17:10:15 +02:00
Oswald Buddenhagen
90c65880b0 skip gui-needing examples with -no-gui
Change-Id: I2413f14f0c2d9179868877615d6131bf4ca7ea16
Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
2013-10-11 21:03:34 +02:00
Frederik Gladhorn
d0eb444a49 Merge remote-tracking branch 'origin/stable' into dev
Change-Id: Ib8cfeee7d9ca15e8ad520e428b72c200827a8628
2013-10-11 16:12:35 +02:00
Tor Arne Vestbø
5466eb289f Remove warnings about examples not running in the Qt Simulator
The Qt Simulator is no longer supported with Qt 5.

Change-Id: I0f98351d482dd0554ea0754746d56f94ee6bf22f
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2013-10-09 21:45:31 +02:00
Sergio Ahumada
16a36239ab Merge branch 'stable' into dev
Change-Id: I06694436322a7810a163b27b8a059cee2b046f06
2013-09-27 11:15:09 +02:00
Gabriel de Dietrich
db9abc72ef QMacNativeWidget: Have example use a delegate
This would be the case in most if not all the real life use cases.

Change-Id: Ib7ebc6dbe471ce50f4bd1df9becba8e9806008e7
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
2013-09-26 22:25:10 +02:00
Andrew Knight
8cc0f19f83 WinRT: Don't build the network-chat example
WinRT doesn't support QProcess, so the network-chat example shouldn't be
built there.

Change-Id: I7885a992d3b8baffd5530c694063140535240f07
Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2013-09-26 17:26:56 +02:00
Morten Johan Sørvig
68b42cd595 Port QMacCocoaViewContainer to Qt 5.
Includes example.

Change-Id: Ifdda5c535d0ec41694712405d921b2c32cb8dfc8
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
2013-09-23 07:18:27 +02:00
Morten Johan Sørvig
f370f77e48 Port QMacNativeWidget to Qt 5
Also adds examples/widgets/mac subdir for Mac specific examples,
starting with one for this feature.

Change-Id: I4cc7d84ce3d7562259d6206faa5d6996c2392a3e
Reviewed-by: Liang Qi <liang.qi@digia.com>
2013-09-23 07:18:24 +02:00