summaryrefslogtreecommitdiffstats
path: root/recipes-qt/qt5/qtdeclarative
diff options
context:
space:
mode:
authorMartin Jansa <martin.jansa@lge.com>2013-06-14 10:32:10 +0200
committerMartin Jansa <Martin.Jansa@gmail.com>2013-06-14 12:13:40 +0200
commitda60ee1856a65ddcc349c5b42ae88d29e31c1e94 (patch)
tree6578b35fde21be2798cd3b93803fde6c846c8c7d /recipes-qt/qt5/qtdeclarative
parente1223d648c15aed72398b5f992d40ae03487bb32 (diff)
downloadmeta-qt5-da60ee1856a65ddcc349c5b42ae88d29e31c1e94.tar.gz
qtdeclarative: move 5.0.2 specific patches to own directory
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Diffstat (limited to 'recipes-qt/qt5/qtdeclarative')
-rw-r--r--recipes-qt/qt5/qtdeclarative/0001-qmltestexample-fix-link.patch34
-rw-r--r--recipes-qt/qt5/qtdeclarative/0002-Fix-displacement-transition-bug-for-horizontal-case.patch32
-rw-r--r--recipes-qt/qt5/qtdeclarative/0003-Fix-wrong-calculation-of-viewPort-for-transitions.patch41
-rw-r--r--recipes-qt/qt5/qtdeclarative/0004-Fix-null-pointer-access-in-QQuickVisualDataModelPriv.patch37
-rw-r--r--recipes-qt/qt5/qtdeclarative/0005-Avoid-swizzling-on-OpenGL-ES-when-possible.patch88
5 files changed, 0 insertions, 232 deletions
diff --git a/recipes-qt/qt5/qtdeclarative/0001-qmltestexample-fix-link.patch b/recipes-qt/qt5/qtdeclarative/0001-qmltestexample-fix-link.patch
deleted file mode 100644
index 7ed95e4b..00000000
--- a/recipes-qt/qt5/qtdeclarative/0001-qmltestexample-fix-link.patch
+++ /dev/null
@@ -1,34 +0,0 @@
1From e22cb54286083886be5081332de2f64ab0b78b4b Mon Sep 17 00:00:00 2001
2From: =?UTF-8?q?Eric=20B=C3=A9nard?= <eric@eukrea.com>
3Date: Sun, 26 May 2013 14:26:19 +0200
4Subject: [PATCH] qmltestexample: fix link
5MIME-Version: 1.0
6Content-Type: text/plain; charset=UTF-8
7Content-Transfer-Encoding: 8bit
8
9else we get :
10ld: warning: libQt5Quick.so.5, needed by libQt5QuickTest.so, not found
11
12Upstream-Status: Inappropriate
13
14Signed-off-by: Eric BĂ©nard <eric@eukrea.com>
15---
16 examples/qmltest/qmltest/qmltest.pro | 2 +-
17 1 file changed, 1 insertion(+), 1 deletion(-)
18
19diff --git a/examples/qmltest/qmltest/qmltest.pro b/examples/qmltest/qmltest/qmltest.pro
20index b5893c5..1b00e6c 100644
21--- a/examples/qmltest/qmltest/qmltest.pro
22+++ b/examples/qmltest/qmltest/qmltest.pro
23@@ -14,7 +14,7 @@ TESTDATA += tst_basic.qml tst_item.qml
24 # This code exists solely for the purpose of building this example
25 # inside the examples/ hierarchy.
26
27-QT += qml qmltest
28+QT += qml qmltest quick
29
30 macx: CONFIG -= app_bundle
31
32--
331.8.1.4
34
diff --git a/recipes-qt/qt5/qtdeclarative/0002-Fix-displacement-transition-bug-for-horizontal-case.patch b/recipes-qt/qt5/qtdeclarative/0002-Fix-displacement-transition-bug-for-horizontal-case.patch
deleted file mode 100644
index 91740ac7..00000000
--- a/recipes-qt/qt5/qtdeclarative/0002-Fix-displacement-transition-bug-for-horizontal-case.patch
+++ /dev/null
@@ -1,32 +0,0 @@
1From eb11863cc40048e84cb383ae9e29b5929170a63d Mon Sep 17 00:00:00 2001
2From: Guenter Schwann <guenter.schwann@canonical.com>
3Date: Wed, 27 Feb 2013 15:52:03 +0100
4Subject: [PATCH 2/5] Fix displacement transition bug for horizontal case
5
6Task-number: QTBUG-29944
7
8Upstream-Status: Backport https://codereview.qt-project.org/49226
9Signed-off-by: Florian Haenel <florian.haenel@lge.com>
10Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
11
12Change-Id: I23381f7a1d2c8d3c6df007b5b11c12b0db3bb1e9
13---
14 src/quick/items/qquickitemview.cpp | 2 +-
15 1 file changed, 1 insertion(+), 1 deletion(-)
16
17diff --git a/src/quick/items/qquickitemview.cpp b/src/quick/items/qquickitemview.cpp
18index b73fb8c..1c74288 100644
19--- a/src/quick/items/qquickitemview.cpp
20+++ b/src/quick/items/qquickitemview.cpp
21@@ -2115,7 +2115,7 @@ void QQuickItemViewPrivate::prepareVisibleItemTransitions()
22 return;
23
24 // must call for every visible item to init or discard transitions
25- QRectF viewBounds(0, position(), q->width(), q->height());
26+ QRectF viewBounds(q->contentX(), q->contentY(), q->width(), q->height());
27 for (int i=0; i<visibleItems.count(); i++)
28 visibleItems[i]->prepareTransition(transitioner, viewBounds);
29 }
30--
311.8.2.1
32
diff --git a/recipes-qt/qt5/qtdeclarative/0003-Fix-wrong-calculation-of-viewPort-for-transitions.patch b/recipes-qt/qt5/qtdeclarative/0003-Fix-wrong-calculation-of-viewPort-for-transitions.patch
deleted file mode 100644
index 05451af5..00000000
--- a/recipes-qt/qt5/qtdeclarative/0003-Fix-wrong-calculation-of-viewPort-for-transitions.patch
+++ /dev/null
@@ -1,41 +0,0 @@
1From 3dfa028b27e171cb2494b22f0346be1390310ea6 Mon Sep 17 00:00:00 2001
2From: =?UTF-8?q?Florian=20H=C3=A4nel?= <florian.haenel@basyskom.com>
3Date: Wed, 5 Jun 2013 19:23:32 +0200
4Subject: [PATCH 3/5] Fix wrong calculation of viewPort for transitions
5
6Viewport is calculated wrong for horizontal layout in a second instance
7
8Task-number: QTBUG-29944
9Task-Number: QTBUG-31546
10
11Upstream-Status: Pending
12
13Looks like backport of https://codereview.qt-project.org/49226 but this
14one was applied in previous patch, this change looks the same but is
15in different part of qquickitemview.cpp and ISN'T applied yet in dev
16branch.
17
18Signed-off-by: Florian Haenel <florian.haenel@lge.com>
19Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
20
21Change-Id: I136ae4484278d14f796613505e3f38c65ec51ebe
22---
23 src/quick/items/qquickitemview.cpp | 2 +-
24 1 file changed, 1 insertion(+), 1 deletion(-)
25
26diff --git a/src/quick/items/qquickitemview.cpp b/src/quick/items/qquickitemview.cpp
27index 1c74288..b316af9 100644
28--- a/src/quick/items/qquickitemview.cpp
29+++ b/src/quick/items/qquickitemview.cpp
30@@ -1816,7 +1816,7 @@ void QQuickItemViewPrivate::layout()
31
32 prepareVisibleItemTransitions();
33
34- QRectF viewBounds(0, position(), q->width(), q->height());
35+ QRectF viewBounds(q->contentX(), q->contentY(), q->width(), q->height());
36 for (QList<FxViewItem*>::Iterator it = releasePendingTransition.begin();
37 it != releasePendingTransition.end(); ) {
38 FxViewItem *item = *it;
39--
401.8.2.1
41
diff --git a/recipes-qt/qt5/qtdeclarative/0004-Fix-null-pointer-access-in-QQuickVisualDataModelPriv.patch b/recipes-qt/qt5/qtdeclarative/0004-Fix-null-pointer-access-in-QQuickVisualDataModelPriv.patch
deleted file mode 100644
index 0182248e..00000000
--- a/recipes-qt/qt5/qtdeclarative/0004-Fix-null-pointer-access-in-QQuickVisualDataModelPriv.patch
+++ /dev/null
@@ -1,37 +0,0 @@
1From adb69cabeacbe14a4439473107000d6e94d8d033 Mon Sep 17 00:00:00 2001
2From: =?UTF-8?q?Florian=20H=C3=A4nel?= <florian.haenel@basyskom.com>
3Date: Mon, 3 Jun 2013 13:40:09 +0200
4Subject: [PATCH 4/5] Fix null-pointer access in QQuickVisualDataModelPrivate
5
6I observed null cachItem->contextData which lead to null-pointer access
7on cacheItem->contextData->destroy().
8
9Task-number: QTBUG-31439
10
11Upstream-Status: Backport https://codereview.qt-project.org/57789
12
13Signed-of-by: Florian Haenel <florian.haenel@lge.com>
14Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
15
16Change-Id: I91f28a3ee1ac83446ecde1801a1cb7962fb883f3
17---
18 src/quick/items/qquickvisualdatamodel.cpp | 3 ++-
19 1 file changed, 2 insertions(+), 1 deletion(-)
20
21diff --git a/src/quick/items/qquickvisualdatamodel.cpp b/src/quick/items/qquickvisualdatamodel.cpp
22index d2e50e8..a460e7f 100644
23--- a/src/quick/items/qquickvisualdatamodel.cpp
24+++ b/src/quick/items/qquickvisualdatamodel.cpp
25@@ -817,7 +817,8 @@ void QQuickVisualDataModelPrivate::incubatorStatusChanged(QVDMIncubationTask *in
26 delete cacheItem->object;
27 cacheItem->object = 0;
28 cacheItem->scriptRef -= 1;
29- cacheItem->contextData->destroy();
30+ if (cacheItem->contextData)
31+ cacheItem->contextData->destroy();
32 cacheItem->contextData = 0;
33 if (!cacheItem->isReferenced()) {
34 removeCacheItem(cacheItem);
35--
361.8.2.1
37
diff --git a/recipes-qt/qt5/qtdeclarative/0005-Avoid-swizzling-on-OpenGL-ES-when-possible.patch b/recipes-qt/qt5/qtdeclarative/0005-Avoid-swizzling-on-OpenGL-ES-when-possible.patch
deleted file mode 100644
index 92be7ef8..00000000
--- a/recipes-qt/qt5/qtdeclarative/0005-Avoid-swizzling-on-OpenGL-ES-when-possible.patch
+++ /dev/null
@@ -1,88 +0,0 @@
1From 9d85c3c5823c6f73db245d4de786d911fd96edfd Mon Sep 17 00:00:00 2001
2From: Florian Haenel <florian.haenel@lge.com>
3Date: Sat, 8 Jun 2013 00:34:35 +0200
4Subject: [PATCH 5/5] Avoid swizzling on OpenGL ES when possible
5
6Add support for APPLE_texture_format_BGRA8888,
7IMG_texture_format_BGRA8888,
8EXT_texture_format_BGRA8888 and EXT_bgra. The apple one acts
9just like the desktop EXT_bgra one, so they need slightly
10different handling than the ES extensions.
11
12This change also has the benefit that we no longer have a dedicated
13ES path.
14
15Upstream-Status: Backport https://codereview.qt-project.org/46549
16Signed-off-by: Florian Haenel <florian.haenel@lge.com>
17Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
18
19Change-Id: I5ecb0a02c3a7bd984d6752fa87163726118b93de
20---
21 src/quick/scenegraph/util/qsgtexture.cpp | 28 ++++++++++++++++++++++------
22 1 file changed, 22 insertions(+), 6 deletions(-)
23
24diff --git a/src/quick/scenegraph/util/qsgtexture.cpp b/src/quick/scenegraph/util/qsgtexture.cpp
25index 16cc461..3d574f3 100644
26--- a/src/quick/scenegraph/util/qsgtexture.cpp
27+++ b/src/quick/scenegraph/util/qsgtexture.cpp
28@@ -65,6 +65,10 @@
29 #include <QHash>
30 #endif
31
32+#ifndef GL_BGRA
33+#define GL_BGRA 0x80E1
34+#endif
35+
36 QT_BEGIN_NAMESPACE
37
38 inline static bool isPowerOfTwo(int x)
39@@ -523,7 +527,6 @@ QSGPlainTexture::~QSGPlainTexture()
40 glDeleteTextures(1, &m_texture_id);
41 }
42
43-#ifdef QT_OPENGL_ES
44 void qsg_swizzleBGRAToRGBA(QImage *image)
45 {
46 const int width = image->width();
47@@ -534,7 +537,6 @@ void qsg_swizzleBGRAToRGBA(QImage *image)
48 p[x] = ((p[x] << 16) & 0xff0000) | ((p[x] >> 16) & 0xff) | (p[x] & 0xff00ff00);
49 }
50 }
51-#endif
52
53 void QSGPlainTexture::setImage(const QImage &image)
54 {
55@@ -621,12 +623,26 @@ void QSGPlainTexture::bind()
56
57 updateBindOptions(m_dirty_bind_options);
58
59+ GLenum externalFormat = GL_RGBA;
60+ GLenum internalFormat = GL_RGBA;
61+
62+ const char *extensions = (const char *) glGetString(GL_EXTENSIONS);
63+ if (strstr(extensions, "GL_EXT_bgra")) {
64+ externalFormat = GL_BGRA;
65 #ifdef QT_OPENGL_ES
66- qsg_swizzleBGRAToRGBA(&tmp);
67- glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, w, h, 0, GL_RGBA, GL_UNSIGNED_BYTE, tmp.constBits());
68-#else
69- glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, w, h, 0, GL_BGRA, GL_UNSIGNED_BYTE, tmp.constBits());
70+ internalFormat = GL_BGRA;
71 #endif
72+ } else if (strstr(extensions, "GL_APPLE_texture_format_BGRA8888")) {
73+ externalFormat = GL_BGRA;
74+ } else if (strstr(extensions, "GL_EXT_texture_format_BGRA8888")
75+ || strstr(extensions, "GL_IMG_texture_format_BGRA8888")) {
76+ externalFormat = GL_BGRA;
77+ internalFormat = GL_BGRA;
78+ } else {
79+ qsg_swizzleBGRAToRGBA(&tmp);
80+ }
81+
82+ glTexImage2D(GL_TEXTURE_2D, 0, internalFormat, w, h, 0, externalFormat, GL_UNSIGNED_BYTE, tmp.constBits());
83
84 if (m_has_mipmaps) {
85 QOpenGLContext *ctx = QOpenGLContext::currentContext();
86--
871.8.2.1
88