summaryrefslogtreecommitdiffstats
path: root/src/widgets/kernel/qwidgetbackingstore_p.h
Commit message (Collapse)AuthorAgeFilesLines
* Add qtwidgetsglobal.h and qtwidgetsglobal_p.hLars Knoll2016-07-141-0/+1
| | | | | | | | | | | | | The new modular configuration system requires one global header per module, that is included by all other files in this module. That header will later on #include the configuration file for Qt Widgets. For now it defines the Q_WIDGETS_EXPORT macro for this library. Change-Id: I6698989b952b9bac94d086d9f219e03c000f7d53 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-06-131-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: config_help.txt configure mkspecs/features/uikit/sdk.prf src/corelib/global/qhooks.cpp src/corelib/io/qfilesystemwatcher.cpp src/corelib/io/qlockfile_unix.cpp src/corelib/tools/qalgorithms.h src/gui/kernel/qwindowsysteminterface.h src/gui/text/qtextdocument_p.cpp src/network/access/access.pri src/network/access/qnetworkaccessmanager.cpp src/network/access/qnetworkreplynsurlconnectionimpl.mm src/src.pro src/testlib/qtestcase.cpp src/widgets/kernel/qwidgetbackingstore_p.h src/widgets/styles/qwindowscestyle.cpp src/widgets/styles/qwindowsmobilestyle.cpp tests/auto/corelib/io/qdiriterator/qdiriterator.pro tests/auto/corelib/io/qfileinfo/qfileinfo.pro tests/auto/gui/kernel/qwindow/BLACKLIST tests/auto/widgets/dialogs/qfilesystemmodel/tst_qfilesystemmodel.cpp tools/configure/configureapp.cpp Change-Id: Ibf7fb9c8cf263a810ade82f821345d0725c57c67
| * Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-06-101-1/+1
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: configure mkspecs/macx-ios-clang/features/default_pre.prf mkspecs/macx-ios-clang/features/sdk.prf mkspecs/unsupported/freebsd-g++46/qplatformdefs.h src/widgets/styles/qgtkstyle.cpp tests/auto/corelib/io/qdiriterator/qdiriterator.pro tests/auto/corelib/io/qfileinfo/qfileinfo.pro Change-Id: Ia943555d1e59234a66f7dc65bdfda838e40001b5
| | * Fix QWidgetBackingStore::isDirty() for render-to-texture widgetsAllan Sandfeld Jensen2016-06-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The backing store would not report itself dirty if only render-to- texture widgets were dirty. This caused QOpenGLWidgets not be repainted after being remapped if they marked themselves dirty while unmapped. Task-number: QTBUG-50818 Task-number: QTBUG-51815 Change-Id: If43f7cbb6f4d44831b4c21b89f884d6bcaebf87c Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
* | | Remove QWidgetBackingStore::fullUpdatePendingAllan Sandfeld Jensen2016-06-091-2/+1
|/ / | | | | | | | | | | | | This was no longer used and always false. Change-Id: I981055e6cc736cfe3432914c173c8b3edc31b46e Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-02-181-0/+2
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This also reverts commit 018e670a26ff5a61b949100ae080f5e654e7bee8. The change was introduced in 5.6. After the refactoring, 14960f52, in 5.7 branch and a merge, it is not needed any more. Conflicts: .qmake.conf src/corelib/io/qstandardpaths_mac.mm src/corelib/tools/qsharedpointer_impl.h tests/auto/widgets/itemviews/qlistview/tst_qlistview.cpp Change-Id: If4fdff0ebf2b9b5df9f9db93ea0022d5ee3da2a4
| * Fix widget texture list locking to avoid animation issues on eglfsLaszlo Agocs2016-01-281-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QWidgetBackingStore::sync() has two variants. The widget texture list logic was only present in one of them. This led to problems on eglfs in cases when the other variant got invoked. (for instance using the scroll area in the qopenglwidget example) eglfs relies on the texture lists's lock status to properly serialize its somewhat asynchronous built-in compositing mechanism and therefore is the only platform affected. The patch moves the code to be invoked from both sync() variants. Task-number: QTBUG-50668 Change-Id: I4c62987b7bb3cc40f98a4e94447368d2f740dbfd Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
* | Updated license headersJani Heikkinen2016-01-151-14/+20
|/ | | | | | | | | | | From Qt 5.7 -> LGPL v2.1 isn't an option anymore, see http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/ Updated license headers to use new LGPL header instead of LGPL21 one (in those files which will be under LGPL v3) Change-Id: I046ec3e47b1876cd7b4b0353a576b352e3a946d9 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* Support mixing native child widgets with texture-based onesLaszlo Agocs2015-11-191-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently QOpenGLWidget and QQuickWidget do not support having native child widgets inside the same top-level window. In some cases this is inevitable, f.ex. multimedia may require native windows when used from widget apps. winId() calls made for various (valid or invalid) reasons are also problematic. There are no blockers for supporting this setup, however. By storing multiple texture lists (one for each subtree where the root is a native widget), adding the missing markDirtyOnScreen calls, letting each native widget access the correct texture list (i.e. the one corresponding to its children) when they are (separately) flushed, and fixing composeAndFlush() to take the update region and the (native child) offset into account, it can all be made functional. The change also fixes the issue of keeping GL-based compositing enabled even after all render-to-texture widgets in the window become hidden. Due to the changes of how such widgets are gathered, composeAndFlush() is not invoked anymore when no such widgets are discovered for a given native parent. This is great since having compositing enabled infinitely is an issue for applications like Qt Creator that implement certain views with QQuickWidgets but cannot afford the cost of texture uploads in other places (e.g. for the text editor) on slower machines. The openglwidget manual test is greatly enhanced to test various situations (MDI, scroll areas, tab widgets, QOpenGLWidget as native child, QOpenGLWidget with non-tlw native parent, etc.) Task-number: QTBUG-48130 Task-number: QTBUG-49172 Change-Id: Iad098359c8bcf749f01c050da0853415e1550eda Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
* Fix a memory leakTimur Pocheptsov2015-08-061-0/+2
| | | | | | | | | | We create dirtyOnScreenWidgets even if QT_NO_OPENGL is defined, but dtor deletes this object only if no QT_NO_OPENGL is defined. Also, copy ctor/assignment operator must be disabled for such a class. Task-number: QTBUG-47499 Change-Id: I9f8b5721ff6324fa7b28b715af68d0a5496c5eb5 Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
* Update copyright headersJani Heikkinen2015-02-111-7/+7
| | | | | | | | | | | | | | | | | | Qt copyrights are now in The Qt Company, so we could update the source code headers accordingly. In the same go we should also fix the links to point to qt.io. Outdated header.LGPL removed (use header.LGPL21 instead) Old header.LGPL3 renamed to header.LGPL3-COMM to match actual licensing combination. New header.LGPL-COMM taken in the use file which were using old header.LGPL3 (src/plugins/platforms/android/extract.cpp) Added new header.LGPL3 containing Commercial + LGPLv3 + GPLv2 license combination Change-Id: I6f49b819a8a20cc4f88b794a8f6726d975e8ffbe Reviewed-by: Matti Paaso <matti.paaso@theqtcompany.com>
* Update license headers and add new license filesMatti Paaso2014-09-241-19/+11
| | | | | | | | | - Renamed LICENSE.LGPL to LICENSE.LGPLv21 - Added LICENSE.LGPLv3 - Removed LICENSE.GPL Change-Id: Iec3406e3eb3f133be549092015cefe33d259a3f2 Reviewed-by: Iikka Eklund <iikka.eklund@digia.com>
* Make QOpenGLWidget publicLaszlo Agocs2014-08-011-1/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* Remove friend class QETWidget.Friedemann Kleint2014-05-161-1/+0
| | | | | | | The class no longer exists in Qt 5. Change-Id: Icd98c151f8e06910a3240d0bec6fff333a8ef3e3 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
* Make bool arguments to QWidgetBackingStore::markDirty enumsJorgen Lind2014-02-281-5/+15
| | | | | | | | This is so we get some typesafty when refactoring, and I think it makes the code more readable Change-Id: Ia7531950d5f780dc98f4eb435c1e0050d76cdb5f Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
* Compile fix for QT_NO_OPENGLPaul Olav Tvete2014-02-241-0/+3
| | | | | Change-Id: I5ea962b0d77198945a4f87ad821d3c3dcffd260c Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* QWidget: do not allocate a QOpenGLContext unless needed by QQuickWidgetPaul Olav Tvete2014-02-221-0/+3
| | | | | | Task-number: QTBUG-36871 Change-Id: I739f270e9344f888593e04c6221807dbcf6cb55e Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* QOpenGLWidget and new-style compositing on eglfsLaszlo Agocs2014-02-131-0/+20
| | | | | | | | | Integrate with QOpenGLTextureBlitter, QOpenGLWidget and friends. Change-Id: Ic2867b713a21a3d2820d546174fc9164b3dd220c Reviewed-by: Lars Knoll <lars.knoll@digia.com> Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com> Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
* Enabling QQuickWidget and QOpenGLWidgetPaul Olav Tvete2014-02-121-0/+6
| | | | | | | | | Enable child widgets (without a native window) that render to an FBO and are composed with the raster backingstore by the platform plugin. A preliminary version of QOpenGLWidget is included as private API. Change-Id: I8f984a4d7db285069ce3d6564707942c823d890d Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* Check whether exposed widget is mapped in QWidgetBackingStore::sync(QWidget*).Friedemann Kleint2014-02-121-0/+1
| | | | | | | | | | | Qt::WA_Mapped corresponds to 'exposed' in Qt 5, hence a parent window fully obscured by its children may not have the attribute set. In that case, go by the attribute of the child widget. Task-number: QTBUG-33520 Change-Id: Ia08f283172daaa58f58e5636004461b2c48784f7 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* Fix the ignored Qt::WA_StaticContents on WindowsChris Colbert2013-11-251-1/+7
| | | | | | | | | | | | | | | | | | | This restores the ability from the Qt 4.x series to honor the static contents region in the backbuffer when resizing a widget. The fix only applies when running under Windows. Task-number: QTBUG-34799 [ChangeLog][QtWidgets][Windows] Update QWidgetBackingStore and QWindowsBackingStore to support Qt::WA_StaticContents QWidgetBackingStore::staticContents() was updated for windows to *not* unconditionally return false. It now returns true if it has a non-empty static widgets list. QWindowsBackingStore::resize(...) was updated to honor the provided static contents region. It now copies the static region into the new backbuffer in a manner similar to what was done in Qt4. The difference is that this version accounts for the possibility of the new buffer having a smaller region than the old buffer. In Qt4 the ::prepareBuffer method was only called when the buffer was resized larger. Change-Id: I135ff8fb16f52759089f1e7353426303c4504db3 Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
* Fix license headers stating QtGui for QtWidgets files.Jake Petroules2013-03-191-1/+1
| | | | | Change-Id: I0ca49e3e1f9f603f0b0f7f3553e854b871efe303 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Update copyright year in Digia's license headersSergio Ahumada2013-01-181-1/+1
| | | | | Change-Id: Ic804938fc352291d011800d21e549c10acac66fb Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Disable static contents optimization for now.Samuel Rødal2012-11-151-1/+1
| | | | | | | | | | Since none of the platform backingstore implementations currently implement this, skip trying to use the optimization for now to avoid graphical glitches. Task-number: QTBUG-27971 Change-Id: Ic6d263bb552ef0b4786910d71f965d26d810b7eb Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
* Change copyrights from Nokia to DigiaIikka Eklund2012-09-221-24/+24
| | | | | | | | Change copyrights and license headers from Nokia to Digia Change-Id: If1cc974286d29fd01ec6c19dd4719a67f4c3f00e Reviewed-by: Lars Knoll <lars.knoll@digia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
* Fix backingstore crash with QAxWidgetsMiikka Heikkinen2012-05-181-1/+1
| | | | | | | | | | | | | | The crash was caused by the fact that backingStore parameter is always null (there seems to be no call in codebase that uses anything else but the default values for this function). Using "store" member variable instead of "backingStore" parameter gets rid of the crash, and it is how it was in Qt4 - probably the bug crept in when the paremeter and member variables were renamed in Qt5. Task-number: QTBUG-25803 Change-Id: I4b1ccf540fddd6baa1dffa7f8165272b54caf238 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Remove hasDirtyFromPreviousSync from backingstore.Girish Ramakrishnan2012-04-121-4/+1
| | | | | | | It's always false (used to be some qws specific variable). Change-Id: I3dc185dba4c778797f180410ce8d293336ecfd9c Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* remove references to qws from backingstoreGirish Ramakrishnan2012-04-121-11/+0
| | | | | | | | The backingstore code is already hard to read as-is. Let's simplify things by removing qws code. Change-Id: Ibefd3ea17d29970d1f7348461959fdc5b01c1f42 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Remove "All rights reserved" line from license headers.Jason McDonald2012-01-301-1/+1
| | | | | | | | | | As in the past, to avoid rewriting various autotests that contain line-number information, an extra blank line has been inserted at the end of the license text to ensure that this commit does not change the total number of lines in the license header. Change-Id: I311e001373776812699d6efc045b5f742890c689 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Update contact information in license headers.Jason McDonald2012-01-231-1/+1
| | | | | | | Replace Nokia contact email address with Qt Project website. Change-Id: I431bbbf76d7c27d8b502f87947675c116994c415 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Update copyright year in license headers.Jason McDonald2012-01-051-1/+1
| | | | | Change-Id: I02f2c620296fcd91d4967d58767ea33fc4e1e7dc Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Rename QWindowSurface -> QBackingStore and split into platform / public.Samuel Rødal2011-06-211-0/+268
Also get rid of GL window surface and related classes.