summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDerick Hawcroft <derick.hawcroft@nokia.com>2009-11-23 03:36:20 (GMT)
committerDerick Hawcroft <derick.hawcroft@nokia.com>2009-11-23 03:36:20 (GMT)
commit0cadaf8932355d1fc9cc560d405a3915aeac7d5a (patch)
treef654169a39839dc43a703716fa40fb8d4a63d513 /src
parent0186faea383f3f8223bffd1844e5a47ca22770a5 (diff)
parentc74a5ae953899b9109ef56b2057b094152616480 (diff)
downloadQt-0cadaf8932355d1fc9cc560d405a3915aeac7d5a.zip
Qt-0cadaf8932355d1fc9cc560d405a3915aeac7d5a.tar.gz
Qt-0cadaf8932355d1fc9cc560d405a3915aeac7d5a.tar.bz2
Merge branch '4.6' of git@scm.dev.nokia.troll.no:qt/qt into 4.6
Diffstat (limited to 'src')
-rw-r--r--src/3rdparty/harfbuzz/src/harfbuzz-indic.cpp10
-rw-r--r--src/3rdparty/harfbuzz/tests/shaping/main.cpp34
-rw-r--r--src/3rdparty/javascriptcore/JavaScriptCore/JavaScriptCore.pro69
-rw-r--r--src/3rdparty/javascriptcore/JavaScriptCore/wtf/Platform.h10
-rw-r--r--src/3rdparty/phonon/ds9/mediaobject.cpp16
-rw-r--r--src/3rdparty/phonon/gstreamer/mediaobject.cpp4
-rw-r--r--src/3rdparty/phonon/mmf/mediaobject.cpp4
-rw-r--r--src/3rdparty/phonon/mmf/objectdump.cpp4
-rw-r--r--src/3rdparty/phonon/mmf/objectdump.h22
-rw-r--r--src/3rdparty/phonon/mmf/objectdump_global.h30
-rw-r--r--src/3rdparty/phonon/mmf/objectdump_symbian.cpp4
-rw-r--r--src/3rdparty/phonon/mmf/objecttree.cpp4
-rw-r--r--src/3rdparty/phonon/mmf/objecttree.h6
-rw-r--r--src/3rdparty/phonon/phonon/factory.cpp2
-rw-r--r--src/3rdparty/phonon/phonon/mediaobject.cpp12
-rw-r--r--src/3rdparty/phonon/phonon/seekslider.cpp4
-rw-r--r--src/3rdparty/phonon/waveout/mediaobject.cpp4
-rw-r--r--src/3rdparty/webkit/JavaScriptCore/ChangeLog12
-rw-r--r--src/3rdparty/webkit/VERSION2
-rw-r--r--src/3rdparty/webkit/WebCore/ChangeLog15
-rw-r--r--src/3rdparty/webkit/WebCore/platform/graphics/qt/FontFallbackListQt.cpp2
-rw-r--r--src/3rdparty/webkit/WebCore/platform/graphics/qt/MediaPlayerPrivatePhonon.cpp8
-rw-r--r--src/3rdparty/webkit/WebKit/qt/Api/qgraphicswebview.cpp16
-rw-r--r--src/3rdparty/webkit/WebKit/qt/Api/qwebview.cpp16
-rw-r--r--src/3rdparty/webkit/WebKit/qt/ChangeLog29
-rw-r--r--src/3rdparty/webkit/WebKit/qt/WebCoreSupport/FrameLoaderClientQt.cpp4
-rw-r--r--src/3rdparty/webkit/WebKit/qt/docs/webkitsnippets/qtwebkit_qwebinspector_snippet.cpp2
-rw-r--r--src/3rdparty/webkit/WebKit/qt/tests/qwebelement/tst_qwebelement.cpp2
-rw-r--r--src/3rdparty/webkit/WebKit/qt/tests/qwebframe/tst_qwebframe.cpp4
-rw-r--r--src/3rdparty/webkit/WebKit/qt/tests/qwebpage/tst_qwebpage.cpp11
-rw-r--r--src/corelib/animation/qvariantanimation.cpp19
-rw-r--r--src/corelib/codecs/qtextcodec.cpp6
-rw-r--r--src/corelib/global/qglobal.h2
-rw-r--r--src/corelib/io/qfilesystemwatcher_win.cpp8
-rw-r--r--src/corelib/io/qiodevice.cpp3
-rw-r--r--src/corelib/kernel/qtcore_eval.cpp26
-rw-r--r--src/corelib/statemachine/qstatemachine.h4
-rw-r--r--src/dbus/qdbusconnection.cpp3
-rw-r--r--src/dbus/qdbusconnection_p.h1
-rw-r--r--src/dbus/qdbusconnectioninterface.cpp5
-rw-r--r--src/dbus/qdbusintegrator.cpp19
-rw-r--r--src/dbus/qdbusserver.cpp4
-rw-r--r--src/gui/dialogs/qcolordialog.cpp8
-rw-r--r--src/gui/dialogs/qfiledialog.cpp46
-rw-r--r--src/gui/dialogs/qfileinfogatherer.cpp4
-rw-r--r--src/gui/dialogs/qfilesystemmodel.cpp12
-rw-r--r--src/gui/dialogs/qfontdialog.cpp4
-rw-r--r--src/gui/dialogs/qinputdialog.cpp20
-rw-r--r--src/gui/dialogs/qprintdialog_qws.cpp8
-rw-r--r--src/gui/dialogs/qprintpreviewdialog.cpp2
-rw-r--r--src/gui/dialogs/qsidebar.cpp28
-rw-r--r--src/gui/dialogs/qwizard.cpp8
-rw-r--r--src/gui/graphicsview/qgraphicsitemanimation.cpp1
-rw-r--r--src/gui/graphicsview/qgraphicsscene.cpp17
-rw-r--r--src/gui/graphicsview/qgraphicssceneindex.cpp4
-rw-r--r--src/gui/gui.pro2
-rw-r--r--src/gui/image/qpixmap_mac.cpp7
-rw-r--r--src/gui/image/qpixmap_mac_p.h1
-rw-r--r--src/gui/image/qpixmap_s60.cpp5
-rw-r--r--src/gui/image/qpixmap_s60_p.h2
-rw-r--r--src/gui/itemviews/qabstractitemview.cpp35
-rw-r--r--src/gui/itemviews/qabstractitemview_p.h2
-rw-r--r--src/gui/itemviews/qcolumnview.cpp24
-rw-r--r--src/gui/itemviews/qheaderview.cpp7
-rw-r--r--src/gui/itemviews/qlistview.cpp30
-rw-r--r--src/gui/itemviews/qtableview.cpp31
-rw-r--r--src/gui/itemviews/qtreeview.cpp11
-rw-r--r--src/gui/kernel/kernel.pri3
-rw-r--r--src/gui/kernel/qapplication.cpp76
-rw-r--r--src/gui/kernel/qapplication_p.h2
-rw-r--r--src/gui/kernel/qapplication_s60.cpp2
-rw-r--r--src/gui/kernel/qevent.h3
-rw-r--r--src/gui/kernel/qeventdispatcher_s60.cpp2
-rw-r--r--src/gui/kernel/qformlayout.cpp9
-rw-r--r--src/gui/kernel/qmultitouch_mac.mm1
-rw-r--r--src/gui/kernel/qwidgetaction.cpp4
-rw-r--r--src/gui/painting/qblendfunctions.cpp4
-rw-r--r--src/gui/painting/qpaintbuffer.cpp2
-rw-r--r--src/gui/painting/qtextureglyphcache.cpp2
-rw-r--r--src/gui/styles/qs60style.cpp68
-rw-r--r--src/gui/styles/qs60style_p.h4
-rw-r--r--src/gui/styles/qwindowsstyle.cpp2
-rw-r--r--src/gui/text/qfontmetrics.cpp22
-rw-r--r--src/gui/widgets/qabstractslider.cpp45
-rw-r--r--src/gui/widgets/qabstractslider_p.h33
-rw-r--r--src/gui/widgets/qcommandlinkbutton.cpp3
-rw-r--r--src/gui/widgets/qlineedit.cpp46
-rw-r--r--src/gui/widgets/qlineedit_p.cpp18
-rw-r--r--src/gui/widgets/qmdiarea.cpp4
-rw-r--r--src/gui/widgets/qmdisubwindow.cpp4
-rw-r--r--src/gui/widgets/qmenu.cpp22
-rw-r--r--src/gui/widgets/qmenu_p.h3
-rw-r--r--src/gui/widgets/qmenubar.cpp2
-rw-r--r--src/gui/widgets/qsizegrip.cpp29
-rw-r--r--src/gui/widgets/qtabwidget.cpp4
-rw-r--r--src/network/access/qhttp.cpp8
-rw-r--r--src/network/access/qhttpnetworkconnectionchannel.cpp10
-rw-r--r--src/network/socket/qnativesocketengine.cpp40
-rw-r--r--src/network/socket/qnativesocketengine_win.cpp34
-rw-r--r--src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp4
-rw-r--r--src/opengl/qpaintengine_opengl.cpp20
-rw-r--r--src/opengl/qwindowsurface_gl.cpp2
-rw-r--r--src/openvg/qpixmapdata_vg.cpp53
-rw-r--r--src/openvg/qpixmapdata_vg_p.h1
-rw-r--r--src/plugins/gfxdrivers/directfb/qdirectfbscreen.cpp4
-rw-r--r--src/plugins/phonon/mmf/mmf.pro6
-rw-r--r--src/qt3support/dialogs/q3filedialog.cpp5
-rw-r--r--src/qt3support/dialogs/q3filedialog.h4
-rw-r--r--src/qt3support/dialogs/q3filedialog_mac.cpp23
-rw-r--r--src/s60installs/bwins/QtCoreu.def11
-rw-r--r--src/s60installs/bwins/QtGuiu.def3
-rw-r--r--src/s60installs/bwins/QtWebKitu.def9
-rw-r--r--src/s60installs/eabi/QtCoreu.def14
-rw-r--r--src/s60installs/eabi/QtGuiu.def2
-rw-r--r--src/s60installs/eabi/QtWebKitu.def9
-rw-r--r--src/script/api/qscriptengine.cpp8
-rw-r--r--src/scripttools/debugging/qscriptdebuggercodefinderwidget.cpp2
-rw-r--r--src/scripttools/debugging/qscriptedit.cpp4
-rw-r--r--src/tools/uic/cpp/cppwriteinitialization.cpp4
119 files changed, 904 insertions, 576 deletions
diff --git a/src/3rdparty/harfbuzz/src/harfbuzz-indic.cpp b/src/3rdparty/harfbuzz/src/harfbuzz-indic.cpp
index 3008fca..3c9df93 100644
--- a/src/3rdparty/harfbuzz/src/harfbuzz-indic.cpp
+++ b/src/3rdparty/harfbuzz/src/harfbuzz-indic.cpp
@@ -1551,6 +1551,7 @@ static bool indic_shape_syllable(HB_Bool openType, HB_ShaperItem *item, bool inv
| PreSubstProperty
| BelowSubstProperty
| AboveSubstProperty
+ | PostSubstProperty
| HalantProperty
| PositioningProperties);
@@ -1608,14 +1609,7 @@ static bool indic_shape_syllable(HB_Bool openType, HB_ShaperItem *item, bool inv
// pres always applies
// blws always applies
// abvs always applies
-
- // psts
- // ### this looks slightly different from before, but I believe it's correct
- if (reordered[len-1] != halant || base != len-2)
- properties[base] &= ~PostSubstProperty;
- for (i = base+1; i < len; ++i)
- properties[i] &= ~PostSubstProperty;
-
+ // psts always applies
// halant always applies
#ifdef INDIC_DEBUG
diff --git a/src/3rdparty/harfbuzz/tests/shaping/main.cpp b/src/3rdparty/harfbuzz/tests/shaping/main.cpp
index 12fa7c4..827ac30 100644
--- a/src/3rdparty/harfbuzz/tests/shaping/main.cpp
+++ b/src/3rdparty/harfbuzz/tests/shaping/main.cpp
@@ -686,7 +686,7 @@ void tst_QScriptEngine::bengali()
void tst_QScriptEngine::gurmukhi()
{
{
- FT_Face face = loadFace("lohit.punjabi.1.1.ttf");
+ FT_Face face = loadFace("lohit_pa.ttf");
if (face) {
const ShapeTable shape_table [] = {
{ { 0xA15, 0xA4D, 0xa39, 0x0 },
@@ -998,6 +998,36 @@ void tst_QScriptEngine::malayalam()
QSKIP("couln't find AkrutiMal2Normal.ttf", SkipAll);
}
}
+
+ {
+ FT_Face face = loadFace("Rachana.ttf");
+ if (face) {
+ const ShapeTable shape_table [] = {
+ { { 0xd37, 0xd4d, 0xd1f, 0xd4d, 0xd30, 0xd40, 0x0 },
+ { 0x385, 0xa3, 0x0 } },
+ { { 0xd2f, 0xd4d, 0xd15, 0xd4d, 0xd15, 0xd41, 0x0 },
+ { 0x2ff, 0x0 } },
+ { { 0xd33, 0xd4d, 0xd33, 0x0 },
+ { 0x3f8, 0x0 } },
+ { { 0xd2f, 0xd4d, 0xd15, 0xd4d, 0xd15, 0xd41, 0x0 },
+ { 0x2ff, 0x0 } },
+
+ { {0}, {0} }
+ };
+
+
+ const ShapeTable *s = shape_table;
+ while (s->unicode[0]) {
+ QVERIFY( shaping(face, s, HB_Script_Malayalam) );
+ ++s;
+ }
+
+ FT_Done_Face(face);
+ } else {
+ QSKIP("couln't find Rachana.ttf", SkipAll);
+ }
+ }
+
}
void tst_QScriptEngine::sinhala()
@@ -1113,7 +1143,7 @@ void tst_QScriptEngine::nko()
void tst_QScriptEngine::linearB()
{
{
- FT_Face face = loadFace("PENUTURE.TTF");
+ FT_Face face = loadFace("penuture.ttf");
if (face) {
const ShapeTable shape_table [] = {
{ { 0xd800, 0xdc01, 0xd800, 0xdc02, 0xd800, 0xdc03, 0 },
diff --git a/src/3rdparty/javascriptcore/JavaScriptCore/JavaScriptCore.pro b/src/3rdparty/javascriptcore/JavaScriptCore/JavaScriptCore.pro
deleted file mode 100644
index 0cd2e1a..0000000
--- a/src/3rdparty/javascriptcore/JavaScriptCore/JavaScriptCore.pro
+++ /dev/null
@@ -1,69 +0,0 @@
-# JavaScriptCore - qmake build info
-CONFIG += building-libs
-include($$PWD/../WebKit.pri)
-
-TEMPLATE = lib
-CONFIG += staticlib
-TARGET = JavaScriptCore
-
-CONFIG += depend_includepath
-
-contains(QT_CONFIG, embedded):CONFIG += embedded
-
-CONFIG(QTDIR_build) {
- GENERATED_SOURCES_DIR = $$PWD/generated
- OLDDESTDIR = $$DESTDIR
- include($$QT_SOURCE_TREE/src/qbase.pri)
- INSTALLS =
- DESTDIR = $$OLDDESTDIR
- PRECOMPILED_HEADER = $$PWD/../WebKit/qt/WebKit_pch.h
- DEFINES *= NDEBUG
-}
-
-isEmpty(GENERATED_SOURCES_DIR):GENERATED_SOURCES_DIR = tmp
-GENERATED_SOURCES_DIR_SLASH = $${GENERATED_SOURCES_DIR}$${QMAKE_DIR_SEP}
-
-INCLUDEPATH += $$GENERATED_SOURCES_DIR
-
-!CONFIG(QTDIR_build) {
- CONFIG(debug, debug|release) {
- OBJECTS_DIR = obj/debug
- } else { # Release
- OBJECTS_DIR = obj/release
- }
-}
-
-CONFIG(release):!CONFIG(QTDIR_build) {
- contains(QT_CONFIG, reduce_exports):CONFIG += hide_symbols
- unix:contains(QT_CONFIG, reduce_relocations):CONFIG += bsymbolic_functions
-}
-
-linux-*: DEFINES += HAVE_STDINT_H
-freebsd-*: DEFINES += HAVE_PTHREAD_NP_H
-
-DEFINES += BUILD_WEBKIT
-
-win32-*: DEFINES += _HAS_TR1=0
-
-# Pick up 3rdparty libraries from INCLUDE/LIB just like with MSVC
-win32-g++ {
- TMPPATH = $$quote($$(INCLUDE))
- QMAKE_INCDIR_POST += $$split(TMPPATH,";")
- TMPPATH = $$quote($$(LIB))
- QMAKE_LIBDIR_POST += $$split(TMPPATH,";")
-}
-
-DEFINES += WTF_USE_JAVASCRIPTCORE_BINDINGS=1
-
-DEFINES += WTF_CHANGES=1
-
-include(JavaScriptCore.pri)
-
-QMAKE_EXTRA_TARGETS += generated_files
-
-lessThan(QT_MINOR_VERSION, 4) {
- DEFINES += QT_BEGIN_NAMESPACE="" QT_END_NAMESPACE=""
-}
-
-*-g++*:QMAKE_CXXFLAGS_RELEASE -= -O2
-*-g++*:QMAKE_CXXFLAGS_RELEASE += -O3
diff --git a/src/3rdparty/javascriptcore/JavaScriptCore/wtf/Platform.h b/src/3rdparty/javascriptcore/JavaScriptCore/wtf/Platform.h
index 188b68f..be74e2a 100644
--- a/src/3rdparty/javascriptcore/JavaScriptCore/wtf/Platform.h
+++ b/src/3rdparty/javascriptcore/JavaScriptCore/wtf/Platform.h
@@ -328,6 +328,16 @@
#define WTF_PLATFORM_BIG_ENDIAN 1
#endif
+/* PLATFORM(SPARC32) */
+#if defined(__sparc) && !defined(__arch64__) || defined(__sparcv8)
+#define WTF_PLATFORM_SPARC32 1
+#define WTF_PLATFORM_BIG_ENDIAN 1
+#endif
+
+#if PLATFORM(SPARC32) || PLATFORM(SPARC64)
+#define WTF_PLATFORM_SPARC
+#endif
+
/* PLATFORM(HPPA) */
/* a.k.a. PA-RISC */
#if defined(__hppa) || defined(__hppa__)
diff --git a/src/3rdparty/phonon/ds9/mediaobject.cpp b/src/3rdparty/phonon/ds9/mediaobject.cpp
index 106a4c8..34f92c2 100644
--- a/src/3rdparty/phonon/ds9/mediaobject.cpp
+++ b/src/3rdparty/phonon/ds9/mediaobject.cpp
@@ -361,17 +361,17 @@ namespace Phonon
m_graphs[i] = new MediaGraph(this, i);
}
- connect(&m_thread, SIGNAL(stateReady(Graph, Phonon::State)),
- SLOT(slotStateReady(Graph, Phonon::State)));
+ connect(&m_thread, SIGNAL(stateReady(Graph,Phonon::State)),
+ SLOT(slotStateReady(Graph,Phonon::State)));
- connect(&m_thread, SIGNAL(eventReady(Graph, long, long)),
- SLOT(handleEvents(Graph, long, long)));
+ connect(&m_thread, SIGNAL(eventReady(Graph,long,long)),
+ SLOT(handleEvents(Graph,long,long)));
- connect(&m_thread, SIGNAL(asyncRenderFinished(quint16, HRESULT, Graph)),
- SLOT(finishLoading(quint16, HRESULT, Graph)));
+ connect(&m_thread, SIGNAL(asyncRenderFinished(quint16,HRESULT,Graph)),
+ SLOT(finishLoading(quint16,HRESULT,Graph)));
- connect(&m_thread, SIGNAL(asyncSeekingFinished(quint16, qint64)),
- SLOT(finishSeeking(quint16, qint64)));
+ connect(&m_thread, SIGNAL(asyncSeekingFinished(quint16,qint64)),
+ SLOT(finishSeeking(quint16,qint64)));
//really special case
m_mediaObject = this;
m_thread.start();
diff --git a/src/3rdparty/phonon/gstreamer/mediaobject.cpp b/src/3rdparty/phonon/gstreamer/mediaobject.cpp
index eafaeec..b6d23ec 100644
--- a/src/3rdparty/phonon/gstreamer/mediaobject.cpp
+++ b/src/3rdparty/phonon/gstreamer/mediaobject.cpp
@@ -95,8 +95,8 @@ MediaObject::MediaObject(Backend *backend, QObject *parent)
m_backend->addBusWatcher(this);
connect(m_tickTimer, SIGNAL(timeout()), SLOT(emitTick()));
}
- connect(this, SIGNAL(stateChanged(Phonon::State, Phonon::State)),
- this, SLOT(notifyStateChange(Phonon::State, Phonon::State)));
+ connect(this, SIGNAL(stateChanged(Phonon::State,Phonon::State)),
+ this, SLOT(notifyStateChange(Phonon::State,Phonon::State)));
}
diff --git a/src/3rdparty/phonon/mmf/mediaobject.cpp b/src/3rdparty/phonon/mmf/mediaobject.cpp
index e42e0fa..21dcfe1 100644
--- a/src/3rdparty/phonon/mmf/mediaobject.cpp
+++ b/src/3rdparty/phonon/mmf/mediaobject.cpp
@@ -319,10 +319,10 @@ void MMF::MediaObject::createPlayer(const MediaSource &source)
}
connect(m_player.data(), SIGNAL(totalTimeChanged(qint64)), SIGNAL(totalTimeChanged(qint64)));
- connect(m_player.data(), SIGNAL(stateChanged(Phonon::State, Phonon::State)), SIGNAL(stateChanged(Phonon::State, Phonon::State)));
+ connect(m_player.data(), SIGNAL(stateChanged(Phonon::State,Phonon::State)), SIGNAL(stateChanged(Phonon::State,Phonon::State)));
connect(m_player.data(), SIGNAL(finished()), SIGNAL(finished()));
connect(m_player.data(), SIGNAL(tick(qint64)), SIGNAL(tick(qint64)));
- connect(m_player.data(), SIGNAL(metaDataChanged(const QMultiMap<QString, QString>&)), SIGNAL(metaDataChanged(const QMultiMap<QString, QString>&)));
+ connect(m_player.data(), SIGNAL(metaDataChanged(QMultiMap<QString,QString>)), SIGNAL(metaDataChanged(QMultiMap<QString,QString>)));
// We need to call setError() after doing the connects, otherwise the
// error won't be received.
diff --git a/src/3rdparty/phonon/mmf/objectdump.cpp b/src/3rdparty/phonon/mmf/objectdump.cpp
index 6b6b71e..3d10be4 100644
--- a/src/3rdparty/phonon/mmf/objectdump.cpp
+++ b/src/3rdparty/phonon/mmf/objectdump.cpp
@@ -16,8 +16,6 @@ along with this library. If not, see <http://www.gnu.org/licenses/>.
*/
-#ifndef QT_NO_DEBUG
-
#include <QByteArray>
#include <QDebug>
#include <QHash>
@@ -525,5 +523,3 @@ void dumpAncestors(const QObject& leaf, QVisitor& visitor)
QT_END_NAMESPACE
-#endif
-
diff --git a/src/3rdparty/phonon/mmf/objectdump.h b/src/3rdparty/phonon/mmf/objectdump.h
index e94b3ac..86aeaba 100644
--- a/src/3rdparty/phonon/mmf/objectdump.h
+++ b/src/3rdparty/phonon/mmf/objectdump.h
@@ -19,8 +19,6 @@ along with this library. If not, see <http://www.gnu.org/licenses/>.
#ifndef OBJECTDUMP_H
#define OBJECTDUMP_H
-#include "objectdump_global.h"
-
#include <QObject>
#include <QList>
#include <QByteArray>
@@ -34,7 +32,7 @@ namespace ObjectDump
/**
* Abstract base for annotator classes invoked by QVisitor.
*/
-class OBJECTDUMP_EXPORT QAnnotator : public QObject
+class QAnnotator : public QObject
{
Q_OBJECT
public:
@@ -45,7 +43,7 @@ public:
/**
* Annotator which replicates QObject::dumpObjectTree functionality.
*/
-class OBJECTDUMP_EXPORT QAnnotatorBasic : public QAnnotator
+class QAnnotatorBasic : public QAnnotator
{
Q_OBJECT
public:
@@ -55,7 +53,7 @@ public:
/**
* Annotator which returns widget information.
*/
-class OBJECTDUMP_EXPORT QAnnotatorWidget : public QAnnotator
+class QAnnotatorWidget : public QAnnotator
{
Q_OBJECT
public:
@@ -68,7 +66,7 @@ class QDumperPrivate;
/**
* Class used to dump information about individual QObjects.
*/
-class OBJECTDUMP_EXPORT QDumper : public QObject
+class QDumper : public QObject
{
Q_OBJECT
Q_DECLARE_PRIVATE(QDumper)
@@ -103,7 +101,7 @@ class QVisitorPrivate;
/**
* Visitor class which dumps information about nodes in the object tree.
*/
-class OBJECTDUMP_EXPORT QVisitor : public QObject
+class QVisitor : public QObject
{
Q_OBJECT
Q_DECLARE_PRIVATE(QVisitor)
@@ -152,12 +150,12 @@ private:
// Utility functions
//-----------------------------------------------------------------------------
-void OBJECTDUMP_EXPORT addDefaultAnnotators(QDumper& dumper);
-void OBJECTDUMP_EXPORT addDefaultAnnotators(QVisitor& visitor);
+void addDefaultAnnotators(QDumper& dumper);
+void addDefaultAnnotators(QVisitor& visitor);
-void OBJECTDUMP_EXPORT dumpTreeFromRoot(const QObject& root, QVisitor& visitor);
-void OBJECTDUMP_EXPORT dumpTreeFromLeaf(const QObject& leaf, QVisitor& visitor);
-void OBJECTDUMP_EXPORT dumpAncestors(const QObject& leaf, QVisitor& visitor);
+void dumpTreeFromRoot(const QObject& root, QVisitor& visitor);
+void dumpTreeFromLeaf(const QObject& leaf, QVisitor& visitor);
+void dumpAncestors(const QObject& leaf, QVisitor& visitor);
} // namespace ObjectDump
diff --git a/src/3rdparty/phonon/mmf/objectdump_global.h b/src/3rdparty/phonon/mmf/objectdump_global.h
deleted file mode 100644
index b8987e0..0000000
--- a/src/3rdparty/phonon/mmf/objectdump_global.h
+++ /dev/null
@@ -1,30 +0,0 @@
-/* This file is part of the KDE project.
-
-Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).
-
-This library is free software: you can redistribute it and/or modify
-it under the terms of the GNU Lesser General Public License as published by
-the Free Software Foundation, either version 2.1 or 3 of the License.
-
-This library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU Lesser General Public License for more details.
-
-You should have received a copy of the GNU Lesser General Public License
-along with this library. If not, see <http://www.gnu.org/licenses/>.
-
-*/
-
-#ifndef OBJECTDUMP_GLOBAL_H
-#define OBJECTDUMP_GLOBAL_H
-
-#include <QtCore/QtGlobal>
-
-#if defined(OBJECTDUMP_LIBRARY)
-# define OBJECTDUMP_EXPORT
-#else
-# define OBJECTDUMP_EXPORT
-#endif
-
-#endif
diff --git a/src/3rdparty/phonon/mmf/objectdump_symbian.cpp b/src/3rdparty/phonon/mmf/objectdump_symbian.cpp
index 41dd240..2efebdb 100644
--- a/src/3rdparty/phonon/mmf/objectdump_symbian.cpp
+++ b/src/3rdparty/phonon/mmf/objectdump_symbian.cpp
@@ -16,8 +16,6 @@ along with this library. If not, see <http://www.gnu.org/licenses/>.
*/
-#ifndef QT_NO_DEBUG
-
#include <QTextStream>
#include <QWidget>
#include <coecntrl.h>
@@ -160,5 +158,3 @@ void addDefaultAnnotators_sys(QVisitor& visitor)
QT_END_NAMESPACE
-#endif
-
diff --git a/src/3rdparty/phonon/mmf/objecttree.cpp b/src/3rdparty/phonon/mmf/objecttree.cpp
index 750db22..06b0ced 100644
--- a/src/3rdparty/phonon/mmf/objecttree.cpp
+++ b/src/3rdparty/phonon/mmf/objecttree.cpp
@@ -16,8 +16,6 @@ along with this library. If not, see <http://www.gnu.org/licenses/>.
*/
-#ifndef QT_NO_DEBUG
-
#include <QTextStream>
#include <QWidget>
#include "objecttree.h"
@@ -100,5 +98,3 @@ AncestorConstIterator::AncestorConstIterator(const QObject& leaf)
QT_END_NAMESPACE
-#endif
-
diff --git a/src/3rdparty/phonon/mmf/objecttree.h b/src/3rdparty/phonon/mmf/objecttree.h
index 98bdf14..96adb6f 100644
--- a/src/3rdparty/phonon/mmf/objecttree.h
+++ b/src/3rdparty/phonon/mmf/objecttree.h
@@ -19,8 +19,6 @@ along with this library. If not, see <http://www.gnu.org/licenses/>.
#ifndef OBJECTTREE_H
#define OBJECTTREE_H
-#include "objectdump_global.h"
-
#include <QObject>
#include <QStack>
@@ -32,7 +30,7 @@ namespace ObjectTree
/**
* Depth-first iterator for QObject tree
*/
-class OBJECTDUMP_EXPORT DepthFirstConstIterator
+class DepthFirstConstIterator
{
public:
DepthFirstConstIterator();
@@ -60,7 +58,7 @@ private:
/**
* Ancestor iterator for QObject tree
*/
-class OBJECTDUMP_EXPORT AncestorConstIterator
+class AncestorConstIterator
{
public:
AncestorConstIterator();
diff --git a/src/3rdparty/phonon/phonon/factory.cpp b/src/3rdparty/phonon/phonon/factory.cpp
index ab1f44f..9967c971 100644
--- a/src/3rdparty/phonon/phonon/factory.cpp
+++ b/src/3rdparty/phonon/phonon/factory.cpp
@@ -469,7 +469,7 @@ GET_STRING_PROPERTY(backendWebsite)
QObject *Factory::registerQObject(QObject *o)
{
if (o) {
- QObject::connect(o, SIGNAL(destroyed(QObject *)), globalFactory, SLOT(objectDestroyed(QObject *)), Qt::DirectConnection);
+ QObject::connect(o, SIGNAL(destroyed(QObject*)), globalFactory, SLOT(objectDestroyed(QObject*)), Qt::DirectConnection);
globalFactory->objects.append(o);
}
return o;
diff --git a/src/3rdparty/phonon/phonon/mediaobject.cpp b/src/3rdparty/phonon/phonon/mediaobject.cpp
index 13d303c..41e8dc2 100644
--- a/src/3rdparty/phonon/phonon/mediaobject.cpp
+++ b/src/3rdparty/phonon/phonon/mediaobject.cpp
@@ -453,9 +453,9 @@ void MediaObjectPrivate::setupBackendObject()
//pDebug() << Q_FUNC_INFO;
#ifndef QT_NO_PHONON_ABSTRACTMEDIASTREAM
- QObject::connect(m_backendObject, SIGNAL(stateChanged(Phonon::State, Phonon::State)), q, SLOT(_k_stateChanged(Phonon::State, Phonon::State)));
+ QObject::connect(m_backendObject, SIGNAL(stateChanged(Phonon::State,Phonon::State)), q, SLOT(_k_stateChanged(Phonon::State,Phonon::State)));
#else
- QObject::connect(m_backendObject, SIGNAL(stateChanged(Phonon::State, Phonon::State)), q, SIGNAL(stateChanged(Phonon::State, Phonon::State)));
+ QObject::connect(m_backendObject, SIGNAL(stateChanged(Phonon::State,Phonon::State)), q, SIGNAL(stateChanged(Phonon::State,Phonon::State)));
#endif // QT_NO_PHONON_ABSTRACTMEDIASTREAM
QObject::connect(m_backendObject, SIGNAL(tick(qint64)), q, SIGNAL(tick(qint64)));
QObject::connect(m_backendObject, SIGNAL(seekableChanged(bool)), q, SIGNAL(seekableChanged(bool)));
@@ -467,10 +467,10 @@ void MediaObjectPrivate::setupBackendObject()
QObject::connect(m_backendObject, SIGNAL(aboutToFinish()), q, SLOT(_k_aboutToFinish()));
QObject::connect(m_backendObject, SIGNAL(prefinishMarkReached(qint32)), q, SIGNAL(prefinishMarkReached(qint32)));
QObject::connect(m_backendObject, SIGNAL(totalTimeChanged(qint64)), q, SIGNAL(totalTimeChanged(qint64)));
- QObject::connect(m_backendObject, SIGNAL(metaDataChanged(const QMultiMap<QString, QString> &)),
- q, SLOT(_k_metaDataChanged(const QMultiMap<QString, QString> &)));
- QObject::connect(m_backendObject, SIGNAL(currentSourceChanged(const MediaSource&)),
- q, SLOT(_k_currentSourceChanged(const MediaSource&)));
+ QObject::connect(m_backendObject, SIGNAL(metaDataChanged(QMultiMap<QString,QString>)),
+ q, SLOT(_k_metaDataChanged(QMultiMap<QString,QString>)));
+ QObject::connect(m_backendObject, SIGNAL(currentSourceChanged(MediaSource)),
+ q, SLOT(_k_currentSourceChanged(MediaSource)));
// set up attributes
pINTERFACE_CALL(setTickInterval(tickInterval));
diff --git a/src/3rdparty/phonon/phonon/seekslider.cpp b/src/3rdparty/phonon/phonon/seekslider.cpp
index b5b25f0..41baf2d 100644
--- a/src/3rdparty/phonon/phonon/seekslider.cpp
+++ b/src/3rdparty/phonon/phonon/seekslider.cpp
@@ -72,12 +72,12 @@ void SeekSlider::setMediaObject(MediaObject *media)
d->media = media;
if (media) {
- connect(media, SIGNAL(stateChanged(Phonon::State, Phonon::State)),
+ connect(media, SIGNAL(stateChanged(Phonon::State,Phonon::State)),
SLOT(_k_stateChanged(Phonon::State)));
connect(media, SIGNAL(totalTimeChanged(qint64)), SLOT(_k_length(qint64)));
connect(media, SIGNAL(tick(qint64)), SLOT(_k_tick(qint64)));
connect(media, SIGNAL(seekableChanged(bool)), SLOT(_k_seekableChanged(bool)));
- connect(media, SIGNAL(currentSourceChanged(const Phonon::MediaSource&)), SLOT(_k_currentSourceChanged()));
+ connect(media, SIGNAL(currentSourceChanged(Phonon::MediaSource)), SLOT(_k_currentSourceChanged()));
d->_k_stateChanged(media->state());
d->_k_seekableChanged(media->isSeekable());
d->_k_length(media->totalTime());
diff --git a/src/3rdparty/phonon/waveout/mediaobject.cpp b/src/3rdparty/phonon/waveout/mediaobject.cpp
index 35d9e0b..db71942 100644
--- a/src/3rdparty/phonon/waveout/mediaobject.cpp
+++ b/src/3rdparty/phonon/waveout/mediaobject.cpp
@@ -247,7 +247,7 @@ namespace Phonon
m_stopped(0)
{
m_thread = new WorkerThread();
- connect(this, SIGNAL(outOfData(QIODevice*, QByteArray*, bool*)), m_thread, SLOT(stream(QIODevice*, QByteArray*, bool*)));
+ connect(this, SIGNAL(outOfData(QIODevice*,QByteArray*,bool*)), m_thread, SLOT(stream(QIODevice*,QByteArray*,bool*)));
m_thread->start();
m_soundBuffer1.waveHeader = new WAVEHDR;
m_soundBuffer2.waveHeader = new WAVEHDR;
@@ -258,7 +258,7 @@ namespace Phonon
MediaObject::~MediaObject()
{
stop();
- disconnect(this, SIGNAL(outOfData(QIODevice*, QByteArray*, bool*)), m_thread, SLOT(stream(QIODevice*, QByteArray*, bool*)));
+ disconnect(this, SIGNAL(outOfData(QIODevice*,QByteArray*,bool*)), m_thread, SLOT(stream(QIODevice*,QByteArray*,bool*)));
do { //The event loop of m_thread might not be started, yet
m_thread->quit(); //If the event loop is not started yet quit() does nothing
m_thread->wait(100);
diff --git a/src/3rdparty/webkit/JavaScriptCore/ChangeLog b/src/3rdparty/webkit/JavaScriptCore/ChangeLog
index 0cbb3a5..304f9ef 100644
--- a/src/3rdparty/webkit/JavaScriptCore/ChangeLog
+++ b/src/3rdparty/webkit/JavaScriptCore/ChangeLog
@@ -1,3 +1,15 @@
+2009-11-18 Harald Fernengel <harald.fernengel@nokia.com>
+
+ Reviewed by Simon Hausmann.
+
+ [Qt] Fix detection of linux-g++
+
+ Never use "linux-g++*" to check for linux-g++, since this will break embedded
+ builds which use linux-arm-g++ and friends. Use 'linux*-g++*' to check for any
+ g++ on linux mkspec.
+
+ * JavaScriptCore.pri:
+
2009-11-16 Joerg Bornemann <joerg.bornemann@trolltech.com>
Reviewed by Simon Hausmann.
diff --git a/src/3rdparty/webkit/VERSION b/src/3rdparty/webkit/VERSION
index 2653e83..f40dda4 100644
--- a/src/3rdparty/webkit/VERSION
+++ b/src/3rdparty/webkit/VERSION
@@ -8,4 +8,4 @@ The commit imported was from the
and has the sha1 checksum
- ca38203fba92cf48d59328403f64036907fd3433
+ 7bdf90f753d25fb1b5628b0980827df11110ad5a
diff --git a/src/3rdparty/webkit/WebCore/ChangeLog b/src/3rdparty/webkit/WebCore/ChangeLog
index abb372a..6daf411 100644
--- a/src/3rdparty/webkit/WebCore/ChangeLog
+++ b/src/3rdparty/webkit/WebCore/ChangeLog
@@ -1,3 +1,18 @@
+2009-11-18 Benjamin Poulain <benjamin.poulain@nokia.com>
+
+ Reviewed by Simon Hausmann.
+
+ [Qt] WebKit crashes when loading certain SVG images
+
+ Check if the familly exist before creating the PlatformData from it.
+
+ https://bugs.webkit.org/show_bug.cgi?id=29443
+
+ Test: svg/text/text-font-invalid.html
+
+ * platform/graphics/qt/FontFallbackListQt.cpp:
+ (WebCore::FontFallbackList::fontDataAt):
+
2009-11-14 Antonio Gomes <tonikitoo@webkit.org>
Reviewed by Antti Koivisto.
diff --git a/src/3rdparty/webkit/WebCore/platform/graphics/qt/FontFallbackListQt.cpp b/src/3rdparty/webkit/WebCore/platform/graphics/qt/FontFallbackListQt.cpp
index 8e1e4f6..0306abf 100644
--- a/src/3rdparty/webkit/WebCore/platform/graphics/qt/FontFallbackListQt.cpp
+++ b/src/3rdparty/webkit/WebCore/platform/graphics/qt/FontFallbackListQt.cpp
@@ -102,7 +102,7 @@ const FontData* FontFallbackList::fontDataAt(const WebCore::Font* _font, unsigne
const FontDescription& description = _font->fontDescription();
const FontFamily* family = &description.family();
while (family) {
- if (m_fontSelector) {
+ if (family->family().length() && m_fontSelector) {
FontData* data = m_fontSelector->getFontData(description, family->family());
if (data) {
if (data->isLoading())
diff --git a/src/3rdparty/webkit/WebCore/platform/graphics/qt/MediaPlayerPrivatePhonon.cpp b/src/3rdparty/webkit/WebCore/platform/graphics/qt/MediaPlayerPrivatePhonon.cpp
index f0d513c..9faa234 100644
--- a/src/3rdparty/webkit/WebCore/platform/graphics/qt/MediaPlayerPrivatePhonon.cpp
+++ b/src/3rdparty/webkit/WebCore/platform/graphics/qt/MediaPlayerPrivatePhonon.cpp
@@ -104,15 +104,15 @@ MediaPlayerPrivate::MediaPlayerPrivate(MediaPlayer* player)
foreach (QWidget* widget, qFindChildren<QWidget*>(m_videoWidget))
widget->installEventFilter(this);
- connect(m_mediaObject, SIGNAL(stateChanged(Phonon::State, Phonon::State)),
- this, SLOT(stateChanged(Phonon::State, Phonon::State)));
+ connect(m_mediaObject, SIGNAL(stateChanged(Phonon::State,Phonon::State)),
+ this, SLOT(stateChanged(Phonon::State,Phonon::State)));
connect(m_mediaObject, SIGNAL(metaDataChanged()), this, SLOT(metaDataChanged()));
connect(m_mediaObject, SIGNAL(seekableChanged(bool)), this, SLOT(seekableChanged(bool)));
connect(m_mediaObject, SIGNAL(hasVideoChanged(bool)), this, SLOT(hasVideoChanged(bool)));
connect(m_mediaObject, SIGNAL(bufferStatus(int)), this, SLOT(bufferStatus(int)));
connect(m_mediaObject, SIGNAL(finished()), this, SLOT(finished()));
- connect(m_mediaObject, SIGNAL(currentSourceChanged(const Phonon::MediaSource&)),
- this, SLOT(currentSourceChanged(const Phonon::MediaSource&)));
+ connect(m_mediaObject, SIGNAL(currentSourceChanged(Phonon::MediaSource)),
+ this, SLOT(currentSourceChanged(Phonon::MediaSource)));
connect(m_mediaObject, SIGNAL(aboutToFinish()), this, SLOT(aboutToFinish()));
connect(m_mediaObject, SIGNAL(totalTimeChanged(qint64)), this, SLOT(totalTimeChanged(qint64)));
}
diff --git a/src/3rdparty/webkit/WebKit/qt/Api/qgraphicswebview.cpp b/src/3rdparty/webkit/WebKit/qt/Api/qgraphicswebview.cpp
index 640a924..ceb5ee1 100644
--- a/src/3rdparty/webkit/WebKit/qt/Api/qgraphicswebview.cpp
+++ b/src/3rdparty/webkit/WebKit/qt/Api/qgraphicswebview.cpp
@@ -419,22 +419,22 @@ void QGraphicsWebView::setPage(QWebPage* page)
QWebFrame* mainFrame = d->page->mainFrame();
- connect(mainFrame, SIGNAL(titleChanged(const QString&)),
- this, SIGNAL(titleChanged(const QString&)));
+ connect(mainFrame, SIGNAL(titleChanged(QString)),
+ this, SIGNAL(titleChanged(QString)));
connect(mainFrame, SIGNAL(iconChanged()),
this, SIGNAL(iconChanged()));
- connect(mainFrame, SIGNAL(urlChanged(const QUrl&)),
- this, SIGNAL(urlChanged(const QUrl&)));
+ connect(mainFrame, SIGNAL(urlChanged(QUrl)),
+ this, SIGNAL(urlChanged(QUrl)));
connect(d->page, SIGNAL(loadStarted()),
this, SIGNAL(loadStarted()));
connect(d->page, SIGNAL(loadProgress(int)),
this, SIGNAL(loadProgress(int)));
connect(d->page, SIGNAL(loadFinished(bool)),
this, SLOT(_q_doLoadFinished(bool)));
- connect(d->page, SIGNAL(statusBarMessage(const QString&)),
- this, SIGNAL(statusBarMessage(const QString&)));
- connect(d->page, SIGNAL(linkClicked(const QUrl &)),
- this, SIGNAL(linkClicked(const QUrl &)));
+ connect(d->page, SIGNAL(statusBarMessage(QString)),
+ this, SIGNAL(statusBarMessage(QString)));
+ connect(d->page, SIGNAL(linkClicked(QUrl)),
+ this, SIGNAL(linkClicked(QUrl)));
}
/*!
diff --git a/src/3rdparty/webkit/WebKit/qt/Api/qwebview.cpp b/src/3rdparty/webkit/WebKit/qt/Api/qwebview.cpp
index 8ee43a1..1d4b46f 100644
--- a/src/3rdparty/webkit/WebKit/qt/Api/qwebview.cpp
+++ b/src/3rdparty/webkit/WebKit/qt/Api/qwebview.cpp
@@ -219,12 +219,12 @@ void QWebView::setPage(QWebPage* page)
d->page->setPalette(palette());
// #### connect signals
QWebFrame *mainFrame = d->page->mainFrame();
- connect(mainFrame, SIGNAL(titleChanged(const QString&)),
- this, SIGNAL(titleChanged(const QString&)));
+ connect(mainFrame, SIGNAL(titleChanged(QString)),
+ this, SIGNAL(titleChanged(QString)));
connect(mainFrame, SIGNAL(iconChanged()),
this, SIGNAL(iconChanged()));
- connect(mainFrame, SIGNAL(urlChanged(const QUrl &)),
- this, SIGNAL(urlChanged(const QUrl &)));
+ connect(mainFrame, SIGNAL(urlChanged(QUrl)),
+ this, SIGNAL(urlChanged(QUrl)));
connect(d->page, SIGNAL(loadStarted()),
this, SIGNAL(loadStarted()));
@@ -232,10 +232,10 @@ void QWebView::setPage(QWebPage* page)
this, SIGNAL(loadProgress(int)));
connect(d->page, SIGNAL(loadFinished(bool)),
this, SIGNAL(loadFinished(bool)));
- connect(d->page, SIGNAL(statusBarMessage(const QString &)),
- this, SIGNAL(statusBarMessage(const QString &)));
- connect(d->page, SIGNAL(linkClicked(const QUrl &)),
- this, SIGNAL(linkClicked(const QUrl &)));
+ connect(d->page, SIGNAL(statusBarMessage(QString)),
+ this, SIGNAL(statusBarMessage(QString)));
+ connect(d->page, SIGNAL(linkClicked(QUrl)),
+ this, SIGNAL(linkClicked(QUrl)));
connect(d->page, SIGNAL(microFocusChanged()),
this, SLOT(updateMicroFocus()));
diff --git a/src/3rdparty/webkit/WebKit/qt/ChangeLog b/src/3rdparty/webkit/WebKit/qt/ChangeLog
index 1294d66..457e9c2 100644
--- a/src/3rdparty/webkit/WebKit/qt/ChangeLog
+++ b/src/3rdparty/webkit/WebKit/qt/ChangeLog
@@ -1,3 +1,32 @@
+2009-11-18 Paul Olav Tvete <paul.tvete@nokia.com>
+
+ Reviewed by Simon Hausmann.
+
+ [Qt] Make the QWebElement::render() test pass when pixmaps aren't 32 bit.
+
+ * tests/qwebelement/tst_qwebelement.cpp:
+ (tst_QWebElement::render):
+
+2009-11-18 Simon Hausmann <simon.hausmann@nokia.com>
+
+ Reviewed by Tor Arne Vestbø.
+
+ Clarify and simplify the legal section in the overview documentation,
+ after review with our legal team.
+
+ * docs/qtwebkit.qdoc:
+
+2009-11-18 Simon Hausmann <simon.hausmann@nokia.com>
+
+ Reviewed and suggested by Tor Arne Vestbø.
+
+ Fix the autotest after commit ecbb2c0dd21bfc197e1f7b53150ec9b1a1d8cb8f
+ to compare the Qt::ImFont property's family against an explicitly
+ previously configured family.
+
+ * tests/qwebpage/tst_qwebpage.cpp:
+ (tst_QWebPage::inputMethods):
+
2009-11-16 Simon Hausmann <simon.hausmann@nokia.com>
Reviewed by Kenneth Rohde Christiansen.
diff --git a/src/3rdparty/webkit/WebKit/qt/WebCoreSupport/FrameLoaderClientQt.cpp b/src/3rdparty/webkit/WebKit/qt/WebCoreSupport/FrameLoaderClientQt.cpp
index 9e13339..5cabca0 100644
--- a/src/3rdparty/webkit/WebKit/qt/WebCoreSupport/FrameLoaderClientQt.cpp
+++ b/src/3rdparty/webkit/WebKit/qt/WebCoreSupport/FrameLoaderClientQt.cpp
@@ -177,8 +177,8 @@ void FrameLoaderClientQt::setFrame(QWebFrame* webFrame, Frame* frame)
m_webFrame->page(), SIGNAL(loadFinished(bool)));
connect(this, SIGNAL(loadFinished(bool)),
m_webFrame, SIGNAL(loadFinished(bool)));
- connect(this, SIGNAL(titleChanged(const QString&)),
- m_webFrame, SIGNAL(titleChanged(const QString&)));
+ connect(this, SIGNAL(titleChanged(QString)),
+ m_webFrame, SIGNAL(titleChanged(QString)));
}
QWebFrame* FrameLoaderClientQt::webFrame() const
diff --git a/src/3rdparty/webkit/WebKit/qt/docs/webkitsnippets/qtwebkit_qwebinspector_snippet.cpp b/src/3rdparty/webkit/WebKit/qt/docs/webkitsnippets/qtwebkit_qwebinspector_snippet.cpp
index 0ba1cad..a6b6620 100644
--- a/src/3rdparty/webkit/WebKit/qt/docs/webkitsnippets/qtwebkit_qwebinspector_snippet.cpp
+++ b/src/3rdparty/webkit/WebKit/qt/docs/webkitsnippets/qtwebkit_qwebinspector_snippet.cpp
@@ -10,7 +10,7 @@ void wrapInFunction()
QWebInspector *inspector = new QWebInspector;
inspector->setPage(page);
- connect(page, SIGNAL(webInspectorTriggered(const QWebElement&)), inspector, SLOT(show()));
+ connect(page, SIGNAL(webInspectorTriggered(QWebElement)), inspector, SLOT(show()));
//! [0]
}
diff --git a/src/3rdparty/webkit/WebKit/qt/tests/qwebelement/tst_qwebelement.cpp b/src/3rdparty/webkit/WebKit/qt/tests/qwebelement/tst_qwebelement.cpp
index a04e661..e9dae18 100644
--- a/src/3rdparty/webkit/WebKit/qt/tests/qwebelement/tst_qwebelement.cpp
+++ b/src/3rdparty/webkit/WebKit/qt/tests/qwebelement/tst_qwebelement.cpp
@@ -995,7 +995,7 @@ void tst_QWebElement::render()
QImage testImage(resource.width(), resource.height(), QImage::Format_ARGB32);
QPainter painter0(&testImage);
painter0.fillRect(imageRect, Qt::white);
- //render() uses pixmaps internally, and pixmaps might have bit depths
+ // render() uses pixmaps internally, and pixmaps might have bit depths
// other than 32, giving different pixel values due to rounding.
QPixmap pix = QPixmap::fromImage(resource);
painter0.drawPixmap(0, 0, pix);
diff --git a/src/3rdparty/webkit/WebKit/qt/tests/qwebframe/tst_qwebframe.cpp b/src/3rdparty/webkit/WebKit/qt/tests/qwebframe/tst_qwebframe.cpp
index b00cf09..d88d905 100644
--- a/src/3rdparty/webkit/WebKit/qt/tests/qwebframe/tst_qwebframe.cpp
+++ b/src/3rdparty/webkit/WebKit/qt/tests/qwebframe/tst_qwebframe.cpp
@@ -2291,7 +2291,7 @@ void tst_QWebFrame::requestedUrl()
qRegisterMetaType<QList<QSslError> >("QList<QSslError>");
qRegisterMetaType<QNetworkReply* >("QNetworkReply*");
- QSignalSpy spy2(page.networkAccessManager(), SIGNAL(sslErrors(QNetworkReply*, const QList<QSslError>&)));
+ QSignalSpy spy2(page.networkAccessManager(), SIGNAL(sslErrors(QNetworkReply*,QList<QSslError>)));
frame->setUrl(QUrl("qrc:/fake-ssl-error.html"));
QTest::qWait(200);
QCOMPARE(spy2.count(), 1);
@@ -2780,7 +2780,7 @@ void tst_QWebFrame::evaluateWillCauseRepaint()
view.page()->mainFrame()->evaluateJavaScript(
"document.getElementById('junk').style.display = 'none';");
- ::waitForSignal(view.page(), SIGNAL(repaintRequested( const QRect &)));
+ ::waitForSignal(view.page(), SIGNAL(repaintRequested(QRect)));
QTest::qWait(2000);
}
diff --git a/src/3rdparty/webkit/WebKit/qt/tests/qwebpage/tst_qwebpage.cpp b/src/3rdparty/webkit/WebKit/qt/tests/qwebpage/tst_qwebpage.cpp
index 7fc3640..32002e7 100644
--- a/src/3rdparty/webkit/WebKit/qt/tests/qwebpage/tst_qwebpage.cpp
+++ b/src/3rdparty/webkit/WebKit/qt/tests/qwebpage/tst_qwebpage.cpp
@@ -448,7 +448,7 @@ void tst_QWebPage::modified()
m_page->mainFrame()->setUrl(QUrl("data:text/html,<body>This is fourth page"));
QVERIFY(m_page->history()->count() == 2);
m_page->mainFrame()->setUrl(QUrl("data:text/html,<body>This is fifth page"));
- QVERIFY(::waitForSignal(m_page, SIGNAL(saveFrameStateRequested(QWebFrame*, QWebHistoryItem*))));
+ QVERIFY(::waitForSignal(m_page, SIGNAL(saveFrameStateRequested(QWebFrame*,QWebHistoryItem*))));
}
void tst_QWebPage::contextMenuCrash()
@@ -484,7 +484,7 @@ void tst_QWebPage::database()
QFile::remove(dbFileName);
qRegisterMetaType<QWebFrame*>("QWebFrame*");
- QSignalSpy spy(m_page, SIGNAL(databaseQuotaExceeded(QWebFrame *, QString)));
+ QSignalSpy spy(m_page, SIGNAL(databaseQuotaExceeded(QWebFrame*,QString)));
m_view->setHtml(QString("<html><head><script>var db; db=openDatabase('testdb', '1.0', 'test database API', 50000); </script></head><body><div></div></body></html>"), QUrl("http://www.myexample.com"));
QTRY_COMPARE(spy.count(), 1);
m_page->mainFrame()->evaluateJavaScript("var db2; db2=openDatabase('testdb', '1.0', 'test database API', 50000);");
@@ -1371,6 +1371,7 @@ void tst_QWebPage::inputMethods()
else
QVERIFY2(false, "Unknown view type");
+ page->settings()->setFontFamily(QWebSettings::SerifFont, "FooSerifFont");
page->mainFrame()->setHtml("<html><body>" \
"<input type='text' id='input1' style='font-family: serif' value='' maxlength='20'/><br>" \
"<input type='password'/>" \
@@ -1404,9 +1405,9 @@ void tst_QWebPage::inputMethods()
QVERIFY(inputs.at(0).geometry().contains(variant.toRect().topLeft()));
//ImFont
- //variant = page->inputMethodQuery(Qt::ImFont);
- //QFont font = variant.value<QFont>();
- //QCOMPARE(QString("-webkit-serif"), font.family());
+ variant = page->inputMethodQuery(Qt::ImFont);
+ QFont font = variant.value<QFont>();
+ QCOMPARE(page->settings()->fontFamily(QWebSettings::SerifFont), font.family());
QList<QInputMethodEvent::Attribute> inputAttributes;
diff --git a/src/corelib/animation/qvariantanimation.cpp b/src/corelib/animation/qvariantanimation.cpp
index c735778..d529f67 100644
--- a/src/corelib/animation/qvariantanimation.cpp
+++ b/src/corelib/animation/qvariantanimation.cpp
@@ -104,15 +104,32 @@ QT_BEGIN_NAMESPACE
\o \l{QMetaType::}{QLine}
\o \l{QMetaType::}{QLineF}
\o \l{QMetaType::}{QPoint}
+ \o \l{QMetaType::}{QPointF}
\o \l{QMetaType::}{QSize}
\o \l{QMetaType::}{QSizeF}
\o \l{QMetaType::}{QRect}
\o \l{QMetaType::}{QRectF}
+ \o \l{QMetaType::}{QColor}
\endlist
If you need to interpolate other variant types, including custom
types, you have to implement interpolation for these yourself.
- You do this by reimplementing interpolated(), which returns
+ To do this, you can register an interpolator function for a given
+ type. This function takes 3 parameters: the start value, the end value
+ and the current progress.
+
+ Example:
+ \code
+ QVariant myColorInterpolator(const QColor &start, const QColor &end, qreal progress)
+ {
+ ...
+ return QColor(...);
+ }
+ ...
+ qRegisterAnimationInterpolator<QColor>(myColorInterpolator);
+ \endcode
+
+ Another option is to reimplement interpolated(), which returns
interpolation values for the value being interpolated.
\omit We need some snippets around here. \endomit
diff --git a/src/corelib/codecs/qtextcodec.cpp b/src/corelib/codecs/qtextcodec.cpp
index 680fcd7..5d62095 100644
--- a/src/corelib/codecs/qtextcodec.cpp
+++ b/src/corelib/codecs/qtextcodec.cpp
@@ -1573,9 +1573,6 @@ QTextCodec *QTextCodec::codecForHtml(const QByteArray &ba)
cannot be detected from the content provided, \a defaultCodec is
returned.
- The behavior of this function is undefined if \a ba is not
- encoded in unicode.
-
\sa codecForHtml()
*/
QTextCodec *QTextCodec::codecForUtfText(const QByteArray &ba, QTextCodec *defaultCodec)
@@ -1620,9 +1617,6 @@ QTextCodec *QTextCodec::codecForUtfText(const QByteArray &ba, QTextCodec *defaul
that is capable of decoding the text to unicode. If the codec
cannot be detected, this overload returns a Latin-1 QTextCodec.
- The behavior of this function is undefined if \a ba is not
- encoded in unicode.
-
\sa codecForHtml()
*/
QTextCodec *QTextCodec::codecForUtfText(const QByteArray &ba)
diff --git a/src/corelib/global/qglobal.h b/src/corelib/global/qglobal.h
index 9558256..2e9f839 100644
--- a/src/corelib/global/qglobal.h
+++ b/src/corelib/global/qglobal.h
@@ -910,6 +910,8 @@ QT_END_INCLUDE_NAMESPACE
/* Symbian OS defines TRUE = 1 and FALSE = 0,
redefine to built-in booleans to make autotests work properly */
#ifdef Q_OS_SYMBIAN
+ #include <e32def.h> /* Symbian OS defines */
+
#undef TRUE
#undef FALSE
#endif
diff --git a/src/corelib/io/qfilesystemwatcher_win.cpp b/src/corelib/io/qfilesystemwatcher_win.cpp
index f3cc211..87fe630 100644
--- a/src/corelib/io/qfilesystemwatcher_win.cpp
+++ b/src/corelib/io/qfilesystemwatcher_win.cpp
@@ -201,10 +201,10 @@ QStringList QWindowsFileSystemWatcherEngine::addPaths(const QStringList &paths,
else
files->append(path);
- connect(thread, SIGNAL(fileChanged(const QString &, bool)),
- this, SIGNAL(fileChanged(const QString &, bool)));
- connect(thread, SIGNAL(directoryChanged(const QString &, bool)),
- this, SIGNAL(directoryChanged(const QString &, bool)));
+ connect(thread, SIGNAL(fileChanged(QString,bool)),
+ this, SIGNAL(fileChanged(QString,bool)));
+ connect(thread, SIGNAL(directoryChanged(QString,bool)),
+ this, SIGNAL(directoryChanged(QString,bool)));
thread->msg = '@';
thread->start();
diff --git a/src/corelib/io/qiodevice.cpp b/src/corelib/io/qiodevice.cpp
index e4e6a15..b84961f 100644
--- a/src/corelib/io/qiodevice.cpp
+++ b/src/corelib/io/qiodevice.cpp
@@ -1404,6 +1404,9 @@ bool QIODevicePrivate::putCharHelper(char c)
*/
bool QIODevice::getChar(char *c)
{
+ Q_D(QIODevice);
+ CHECK_READABLE(getChar, false);
+
char ch;
return (1 == read(c ? c : &ch, 1));
}
diff --git a/src/corelib/kernel/qtcore_eval.cpp b/src/corelib/kernel/qtcore_eval.cpp
index fe47a30..d5eb8c2 100644
--- a/src/corelib/kernel/qtcore_eval.cpp
+++ b/src/corelib/kernel/qtcore_eval.cpp
@@ -88,23 +88,12 @@ static const char will_shutdown_now[] =
"timeout and will shut down.\n"
"Contact http://qt.nokia.com/about/contact-us for pricing and purchasing information.\n";
-static int qt_eval_days_left()
+static int qt_eval_is_supported()
{
const char *const license_key = qt_eval_key_data + 12;
// fast fail
if (!qt_eval_key_data[0] || !*license_key)
- return -2;
-
- QDate today = QDate::currentDate();
- QDate build = QLibraryInfo::buildDate();
- return qMax(-1, today.daysTo(build) + 30);
-}
-
-static int qt_eval_is_supported()
-{
- const char *const license_key = qt_eval_key_data + 12;
- if (!qt_eval_key_data[0] || !*license_key)
return -1;
// is this an unsupported evaluation?
@@ -123,6 +112,16 @@ static int qt_eval_is_supported()
return -1;
}
+static int qt_eval_days_left()
+{
+ if (qt_eval_is_supported() < 0)
+ return -2;
+
+ QDate today = QDate::currentDate();
+ QDate build = QLibraryInfo::buildDate();
+ return qMax(-1, today.daysTo(build) + 30);
+}
+
static QString qt_eval_string()
{
const char *msg;
@@ -178,6 +177,9 @@ public:
void qt_core_eval_init(uint type)
{
+ if (!type)
+ return; // GUI app
+
switch (qt_eval_days_left()) {
case -2:
return;
diff --git a/src/corelib/statemachine/qstatemachine.h b/src/corelib/statemachine/qstatemachine.h
index ff2b667..13c43e5 100644
--- a/src/corelib/statemachine/qstatemachine.h
+++ b/src/corelib/statemachine/qstatemachine.h
@@ -70,7 +70,7 @@ class Q_CORE_EXPORT QStateMachine : public QState
Q_PROPERTY(bool animated READ isAnimated WRITE setAnimated)
#endif
public:
- class SignalEvent : public QEvent
+ class Q_CORE_EXPORT SignalEvent : public QEvent
{
public:
SignalEvent(QObject *sender, int signalIndex,
@@ -89,7 +89,7 @@ public:
friend class QSignalTransitionPrivate;
};
- class WrappedEvent : public QEvent
+ class Q_CORE_EXPORT WrappedEvent : public QEvent
{
public:
WrappedEvent(QObject *object, QEvent *event);
diff --git a/src/dbus/qdbusconnection.cpp b/src/dbus/qdbusconnection.cpp
index d7088ff..d3aff6d 100644
--- a/src/dbus/qdbusconnection.cpp
+++ b/src/dbus/qdbusconnection.cpp
@@ -1005,6 +1005,9 @@ void QDBusConnectionPrivate::setBusService(const QDBusConnection &connection)
busService = new QDBusConnectionInterface(connection, this);
ref.deref(); // busService has increased the refcounting to us
// avoid cyclic refcounting
+// if (mode != PeerMode)
+ QObject::connect(busService, SIGNAL(serviceOwnerChanged(QString,QString,QString)),
+ this, SIGNAL(serviceOwnerChanged(QString,QString,QString)));
QObject::connect(this, SIGNAL(callWithCallbackFailed(QDBusError,QDBusMessage)),
busService, SIGNAL(callWithCallbackFailed(QDBusError,QDBusMessage)),
diff --git a/src/dbus/qdbusconnection_p.h b/src/dbus/qdbusconnection_p.h
index ed29e4e..830dac3 100644
--- a/src/dbus/qdbusconnection_p.h
+++ b/src/dbus/qdbusconnection_p.h
@@ -123,6 +123,7 @@ public:
QObject* obj;
int midx;
QList<int> params;
+ QStringList argumentMatch;
QByteArray matchRule;
};
diff --git a/src/dbus/qdbusconnectioninterface.cpp b/src/dbus/qdbusconnectioninterface.cpp
index 414d318..3b38432 100644
--- a/src/dbus/qdbusconnectioninterface.cpp
+++ b/src/dbus/qdbusconnectioninterface.cpp
@@ -337,11 +337,6 @@ void QDBusConnectionInterface::connectNotify(const char *signalName)
QDBusAbstractInterface::connectNotify(SIGNAL(NameLost(QString)));
else if (qstrcmp(signalName, SIGNAL(serviceOwnerChanged(QString,QString,QString))) == 0) {
- static bool warningPrinted = false;
- if (!warningPrinted) {
- qWarning("Connecting to deprecated signal QDBusConnectionInterface::serviceOwnerChanged(QString,QString,QString)");
- warningPrinted = true;
- }
QDBusAbstractInterface::connectNotify(SIGNAL(NameOwnerChanged(QString,QString,QString)));
}
}
diff --git a/src/dbus/qdbusintegrator.cpp b/src/dbus/qdbusintegrator.cpp
index 2d27668..870ddd0 100644
--- a/src/dbus/qdbusintegrator.cpp
+++ b/src/dbus/qdbusintegrator.cpp
@@ -1230,6 +1230,7 @@ bool QDBusConnectionPrivate::prepareHook(QDBusConnectionPrivate::SignalHook &hoo
hook.owner = owner; // we don't care if the service has an owner yet
hook.path = path;
hook.obj = receiver;
+ hook.argumentMatch = argMatch;
// build the D-Bus signal name and signature
// This should not happen for QDBusConnection::connect, use buildSignature here, since
@@ -1502,6 +1503,24 @@ void QDBusConnectionPrivate::handleSignal(const QString &key, const QDBusMessage
continue;
if (hook.signature.isEmpty() && !hook.signature.isNull() && !msg.signature().isEmpty())
continue;
+ if (!hook.argumentMatch.isEmpty()) {
+ const QVariantList arguments = msg.arguments();
+ if (hook.argumentMatch.size() > arguments.size())
+ continue;
+
+ bool matched = true;
+ for (int i = 0; i < hook.argumentMatch.size(); ++i) {
+ const QString &param = hook.argumentMatch.at(i);
+ if (param.isNull())
+ continue; // don't try to match against this
+ if (param == arguments.at(i).toString())
+ continue; // matched
+ matched = false;
+ break;
+ }
+ if (!matched)
+ continue;
+ }
activateSignal(hook, msg);
}
diff --git a/src/dbus/qdbusserver.cpp b/src/dbus/qdbusserver.cpp
index e028940..d4e90f6 100644
--- a/src/dbus/qdbusserver.cpp
+++ b/src/dbus/qdbusserver.cpp
@@ -69,8 +69,8 @@ QDBusServer::QDBusServer(const QString &address, QObject *parent)
if (address.isEmpty())
return;
- QObject::connect(d, SIGNAL(newServerConnection(const QDBusConnection &)),
- this, SIGNAL(newConnection(const QDBusConnection &)));
+ QObject::connect(d, SIGNAL(newServerConnection(QDBusConnection)),
+ this, SIGNAL(newConnection(QDBusConnection)));
// server = q_dbus_server_listen( "unix:tmpdir=/tmp", &error);
QDBusErrorInternal error;
diff --git a/src/gui/dialogs/qcolordialog.cpp b/src/gui/dialogs/qcolordialog.cpp
index 44a82ef..a9126f6 100644
--- a/src/gui/dialogs/qcolordialog.cpp
+++ b/src/gui/dialogs/qcolordialog.cpp
@@ -1594,8 +1594,8 @@ void QColorDialogPrivate::init(const QColor &initial)
cs = new QColorShower(q);
QObject::connect(cs, SIGNAL(newCol(QRgb)), q, SLOT(_q_newColorTypedIn(QRgb)));
- QObject::connect(cs, SIGNAL(currentColorChanged(const QColor&)),
- q, SIGNAL(currentColorChanged(const QColor&)));
+ QObject::connect(cs, SIGNAL(currentColorChanged(QColor)),
+ q, SIGNAL(currentColorChanged(QColor)));
#if defined(Q_WS_S60)
if (!nonTouchUI)
pWidth -= cp->size().width();
@@ -1904,7 +1904,7 @@ void QColorDialog::setVisible(bool visible)
void QColorDialog::open(QObject *receiver, const char *member)
{
Q_D(QColorDialog);
- connect(this, SIGNAL(colorSelected(const QColor&)), receiver, member);
+ connect(this, SIGNAL(colorSelected(QColor)), receiver, member);
d->receiverToDisconnectOnClose = receiver;
d->memberToDisconnectOnClose = member;
QDialog::open();
@@ -2036,7 +2036,7 @@ void QColorDialog::done(int result)
d->selectedQColor = QColor();
}
if (d->receiverToDisconnectOnClose) {
- disconnect(this, SIGNAL(colorSelected(const QColor&)),
+ disconnect(this, SIGNAL(colorSelected(QColor)),
d->receiverToDisconnectOnClose, d->memberToDisconnectOnClose);
d->receiverToDisconnectOnClose = 0;
}
diff --git a/src/gui/dialogs/qfiledialog.cpp b/src/gui/dialogs/qfiledialog.cpp
index 3b1befd..45a410f 100644
--- a/src/gui/dialogs/qfiledialog.cpp
+++ b/src/gui/dialogs/qfiledialog.cpp
@@ -691,8 +691,8 @@ QFileDialog::Options QFileDialog::options() const
void QFileDialog::open(QObject *receiver, const char *member)
{
Q_D(QFileDialog);
- const char *signal = (fileMode() == ExistingFiles) ? SIGNAL(filesSelected(const QStringList&))
- : SIGNAL(fileSelected(const QString&));
+ const char *signal = (fileMode() == ExistingFiles) ? SIGNAL(filesSelected(QStringList))
+ : SIGNAL(fileSelected(QString));
connect(this, signal, receiver, member);
d->signalToDisconnectOnClose = signal;
d->receiverToDisconnectOnClose = receiver;
@@ -2145,11 +2145,11 @@ void QFileDialogPrivate::createWidgets()
model->setNameFilterDisables(false);
#endif
model->d_func()->disableRecursiveSort = true;
- QFileDialog::connect(model, SIGNAL(fileRenamed(const QString &, const QString &, const QString &)), q, SLOT(_q_fileRenamed(const QString &, const QString &, const QString &)));
- QFileDialog::connect(model, SIGNAL(rootPathChanged(const QString &)),
- q, SLOT(_q_pathChanged(const QString &)));
- QFileDialog::connect(model, SIGNAL(rowsInserted(const QModelIndex &, int, int)),
- q, SLOT(_q_rowsInserted(const QModelIndex &)));
+ QFileDialog::connect(model, SIGNAL(fileRenamed(QString,QString,QString)), q, SLOT(_q_fileRenamed(QString,QString,QString)));
+ QFileDialog::connect(model, SIGNAL(rootPathChanged(QString)),
+ q, SLOT(_q_pathChanged(QString)));
+ QFileDialog::connect(model, SIGNAL(rowsInserted(QModelIndex,int,int)),
+ q, SLOT(_q_rowsInserted(QModelIndex)));
model->setReadOnly(false);
qFileDialogUi.reset(new Ui_QFileDialog());
@@ -2159,8 +2159,8 @@ void QFileDialogPrivate::createWidgets()
initialBookmarks << QUrl::fromLocalFile(QLatin1String(""))
<< QUrl::fromLocalFile(QDir::homePath());
qFileDialogUi->sidebar->init(model, initialBookmarks);
- QFileDialog::connect(qFileDialogUi->sidebar, SIGNAL(goToUrl(const QUrl &)),
- q, SLOT(_q_goToUrl(const QUrl &)));
+ QFileDialog::connect(qFileDialogUi->sidebar, SIGNAL(goToUrl(QUrl)),
+ q, SLOT(_q_goToUrl(QUrl)));
QObject::connect(qFileDialogUi->buttonBox, SIGNAL(accepted()), q, SLOT(accept()));
QObject::connect(qFileDialogUi->buttonBox, SIGNAL(rejected()), q, SLOT(reject()));
@@ -2194,8 +2194,8 @@ void QFileDialogPrivate::createWidgets()
qFileDialogUi->fileTypeCombo->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Fixed);
QObject::connect(qFileDialogUi->fileTypeCombo, SIGNAL(activated(int)),
q, SLOT(_q_useNameFilter(int)));
- QObject::connect(qFileDialogUi->fileTypeCombo, SIGNAL(activated(const QString &)),
- q, SIGNAL(filterSelected(const QString &)));
+ QObject::connect(qFileDialogUi->fileTypeCombo, SIGNAL(activated(QString)),
+ q, SIGNAL(filterSelected(QString)));
qFileDialogUi->listView->init(this);
qFileDialogUi->listView->setModel(model);
@@ -2221,8 +2221,8 @@ void QFileDialogPrivate::createWidgets()
QActionGroup *showActionGroup = new QActionGroup(q);
showActionGroup->setExclusive(false);
- QObject::connect(showActionGroup, SIGNAL(triggered(QAction *)),
- q, SLOT(_q_showHeader(QAction *)));;
+ QObject::connect(showActionGroup, SIGNAL(triggered(QAction*)),
+ q, SLOT(_q_showHeader(QAction*)));;
QAbstractItemModel *abstractModel = model;
#ifndef QT_NO_PROXYMODEL
@@ -2251,7 +2251,7 @@ void QFileDialogPrivate::createWidgets()
// Selections
QItemSelectionModel *selections = qFileDialogUi->listView->selectionModel();
- QObject::connect(selections, SIGNAL(selectionChanged(const QItemSelection &, const QItemSelection &)),
+ QObject::connect(selections, SIGNAL(selectionChanged(QItemSelection,QItemSelection)),
q, SLOT(_q_selectionChanged()));
QObject::connect(selections, SIGNAL(currentChanged(QModelIndex,QModelIndex)),
q, SLOT(_q_currentChanged(QModelIndex)));
@@ -2289,11 +2289,11 @@ void QFileDialog::setProxyModel(QAbstractProxyModel *proxyModel)
QModelIndex idx = d->rootIndex();
if (d->proxyModel) {
- disconnect(d->proxyModel, SIGNAL(rowsInserted(const QModelIndex &, int, int)),
- this, SLOT(_q_rowsInserted(const QModelIndex &)));
+ disconnect(d->proxyModel, SIGNAL(rowsInserted(QModelIndex,int,int)),
+ this, SLOT(_q_rowsInserted(QModelIndex)));
} else {
- disconnect(d->model, SIGNAL(rowsInserted(const QModelIndex &, int, int)),
- this, SLOT(_q_rowsInserted(const QModelIndex &)));
+ disconnect(d->model, SIGNAL(rowsInserted(QModelIndex,int,int)),
+ this, SLOT(_q_rowsInserted(QModelIndex)));
}
if (proxyModel != 0) {
@@ -2306,8 +2306,8 @@ void QFileDialog::setProxyModel(QAbstractProxyModel *proxyModel)
d->completer->setModel(d->proxyModel);
d->completer->proxyModel = d->proxyModel;
#endif
- connect(d->proxyModel, SIGNAL(rowsInserted(const QModelIndex &, int, int)),
- this, SLOT(_q_rowsInserted(const QModelIndex &)));
+ connect(d->proxyModel, SIGNAL(rowsInserted(QModelIndex,int,int)),
+ this, SLOT(_q_rowsInserted(QModelIndex)));
} else {
d->proxyModel = 0;
d->qFileDialogUi->listView->setModel(d->model);
@@ -2317,8 +2317,8 @@ void QFileDialog::setProxyModel(QAbstractProxyModel *proxyModel)
d->completer->sourceModel = d->model;
d->completer->proxyModel = 0;
#endif
- connect(d->model, SIGNAL(rowsInserted(const QModelIndex &, int, int)),
- this, SLOT(_q_rowsInserted(const QModelIndex &)));
+ connect(d->model, SIGNAL(rowsInserted(QModelIndex,int,int)),
+ this, SLOT(_q_rowsInserted(QModelIndex)));
}
QScopedPointer<QItemSelectionModel> selModel(d->qFileDialogUi->treeView->selectionModel());
d->qFileDialogUi->treeView->setSelectionModel(d->qFileDialogUi->listView->selectionModel());
@@ -2327,7 +2327,7 @@ void QFileDialog::setProxyModel(QAbstractProxyModel *proxyModel)
// reconnect selection
QItemSelectionModel *selections = d->qFileDialogUi->listView->selectionModel();
- QObject::connect(selections, SIGNAL(selectionChanged(const QItemSelection &, const QItemSelection &)),
+ QObject::connect(selections, SIGNAL(selectionChanged(QItemSelection,QItemSelection)),
this, SLOT(_q_selectionChanged()));
QObject::connect(selections, SIGNAL(currentChanged(QModelIndex,QModelIndex)),
this, SLOT(_q_currentChanged(QModelIndex)));
diff --git a/src/gui/dialogs/qfileinfogatherer.cpp b/src/gui/dialogs/qfileinfogatherer.cpp
index 76d87ae..2729530 100644
--- a/src/gui/dialogs/qfileinfogatherer.cpp
+++ b/src/gui/dialogs/qfileinfogatherer.cpp
@@ -75,8 +75,8 @@ QFileInfoGatherer::QFileInfoGatherer(QObject *parent)
#endif
#ifndef QT_NO_FILESYSTEMWATCHER
watcher = new QFileSystemWatcher(this);
- connect(watcher, SIGNAL(directoryChanged(const QString &)), this, SLOT(list(const QString &)));
- connect(watcher, SIGNAL(fileChanged(const QString &)), this, SLOT(updateFile(const QString &)));
+ connect(watcher, SIGNAL(directoryChanged(QString)), this, SLOT(list(QString)));
+ connect(watcher, SIGNAL(fileChanged(QString)), this, SLOT(updateFile(QString)));
#endif
start(LowPriority);
}
diff --git a/src/gui/dialogs/qfilesystemmodel.cpp b/src/gui/dialogs/qfilesystemmodel.cpp
index b9012c7..8e78503 100644
--- a/src/gui/dialogs/qfilesystemmodel.cpp
+++ b/src/gui/dialogs/qfilesystemmodel.cpp
@@ -1864,12 +1864,12 @@ void QFileSystemModelPrivate::init()
{
Q_Q(QFileSystemModel);
qRegisterMetaType<QList<QPair<QString,QFileInfo> > >("QList<QPair<QString,QFileInfo> >");
- q->connect(&fileInfoGatherer, SIGNAL(newListOfFiles(const QString &, const QStringList &)),
- q, SLOT(_q_directoryChanged(const QString &, const QStringList &)));
- q->connect(&fileInfoGatherer, SIGNAL(updates(const QString &, const QList<QPair<QString, QFileInfo> > &)),
- q, SLOT(_q_fileSystemChanged(const QString &, const QList<QPair<QString, QFileInfo> > &)));
- q->connect(&fileInfoGatherer, SIGNAL(nameResolved(const QString &, const QString &)),
- q, SLOT(_q_resolvedName(const QString &, const QString &)));
+ q->connect(&fileInfoGatherer, SIGNAL(newListOfFiles(QString,QStringList)),
+ q, SLOT(_q_directoryChanged(QString,QStringList)));
+ q->connect(&fileInfoGatherer, SIGNAL(updates(QString,QList<QPair<QString,QFileInfo> >)),
+ q, SLOT(_q_fileSystemChanged(QString,QList<QPair<QString,QFileInfo> >)));
+ q->connect(&fileInfoGatherer, SIGNAL(nameResolved(QString,QString)),
+ q, SLOT(_q_resolvedName(QString,QString)));
q->connect(&delayedSortTimer, SIGNAL(timeout()), q, SLOT(_q_performDelayedSort()), Qt::QueuedConnection);
}
diff --git a/src/gui/dialogs/qfontdialog.cpp b/src/gui/dialogs/qfontdialog.cpp
index 60fae27..d035ef4 100644
--- a/src/gui/dialogs/qfontdialog.cpp
+++ b/src/gui/dialogs/qfontdialog.cpp
@@ -948,7 +948,7 @@ bool QFontDialogPrivate::sharedFontPanelAvailable = true;
void QFontDialog::open(QObject *receiver, const char *member)
{
Q_D(QFontDialog);
- connect(this, SIGNAL(fontSelected(const QFont&)), receiver, member);
+ connect(this, SIGNAL(fontSelected(QFont)), receiver, member);
d->receiverToDisconnectOnClose = receiver;
d->memberToDisconnectOnClose = member;
QDialog::open();
@@ -1038,7 +1038,7 @@ void QFontDialog::done(int result)
d->selectedFont = QFont();
}
if (d->receiverToDisconnectOnClose) {
- disconnect(this, SIGNAL(fontSelected(const QFont&)),
+ disconnect(this, SIGNAL(fontSelected(QFont)),
d->receiverToDisconnectOnClose, d->memberToDisconnectOnClose);
d->receiverToDisconnectOnClose = 0;
}
diff --git a/src/gui/dialogs/qinputdialog.cpp b/src/gui/dialogs/qinputdialog.cpp
index 86213b4..39ce1ab 100644
--- a/src/gui/dialogs/qinputdialog.cpp
+++ b/src/gui/dialogs/qinputdialog.cpp
@@ -95,7 +95,7 @@ class QInputDialogSpinBox : public QSpinBox
public:
QInputDialogSpinBox(QWidget *parent)
: QSpinBox(parent) {
- connect(lineEdit(), SIGNAL(textChanged(const QString&)), this, SLOT(notifyTextChanged()));
+ connect(lineEdit(), SIGNAL(textChanged(QString)), this, SLOT(notifyTextChanged()));
connect(this, SIGNAL(editingFinished()), this, SLOT(notifyTextChanged()));
}
@@ -130,7 +130,7 @@ class QInputDialogDoubleSpinBox : public QDoubleSpinBox
public:
QInputDialogDoubleSpinBox(QWidget *parent = 0)
: QDoubleSpinBox(parent) {
- connect(lineEdit(), SIGNAL(textChanged(const QString&)), this, SLOT(notifyTextChanged()));
+ connect(lineEdit(), SIGNAL(textChanged(QString)), this, SLOT(notifyTextChanged()));
connect(this, SIGNAL(editingFinished()), this, SLOT(notifyTextChanged()));
}
@@ -245,8 +245,8 @@ void QInputDialogPrivate::ensureLineEdit()
if (!lineEdit) {
lineEdit = new QLineEdit(q);
lineEdit->hide();
- QObject::connect(lineEdit, SIGNAL(textChanged(const QString&)),
- q, SLOT(_q_textChanged(const QString&)));
+ QObject::connect(lineEdit, SIGNAL(textChanged(QString)),
+ q, SLOT(_q_textChanged(QString)));
}
}
@@ -256,10 +256,10 @@ void QInputDialogPrivate::ensureComboBox()
if (!comboBox) {
comboBox = new QComboBox(q);
comboBox->hide();
- QObject::connect(comboBox, SIGNAL(editTextChanged(const QString&)),
- q, SLOT(_q_textChanged(const QString&)));
- QObject::connect(comboBox, SIGNAL(currentIndexChanged(const QString&)),
- q, SLOT(_q_textChanged(const QString&)));
+ QObject::connect(comboBox, SIGNAL(editTextChanged(QString)),
+ q, SLOT(_q_textChanged(QString)));
+ QObject::connect(comboBox, SIGNAL(currentIndexChanged(QString)),
+ q, SLOT(_q_textChanged(QString)));
}
}
@@ -276,8 +276,8 @@ void QInputDialogPrivate::ensureListView()
listView->setModel(comboBox->model());
listView->setCurrentIndex(QModelIndex()); // ###
QObject::connect(listView->selectionModel(),
- SIGNAL(currentRowChanged(const QModelIndex&, const QModelIndex&)),
- q, SLOT(_q_currentRowChanged(const QModelIndex&, const QModelIndex&)));
+ SIGNAL(currentRowChanged(QModelIndex,QModelIndex)),
+ q, SLOT(_q_currentRowChanged(QModelIndex,QModelIndex)));
}
}
diff --git a/src/gui/dialogs/qprintdialog_qws.cpp b/src/gui/dialogs/qprintdialog_qws.cpp
index 37f01be..05a290d 100644
--- a/src/gui/dialogs/qprintdialog_qws.cpp
+++ b/src/gui/dialogs/qprintdialog_qws.cpp
@@ -266,8 +266,8 @@ void QPrintDialogPrivate::setupDestination()
// print destinations
printerOrFile = new QButtonGroup(q);
- QObject::connect(printerOrFile, SIGNAL(buttonClicked(QAbstractButton *)),
- q, SLOT(_q_printerOrFileSelected(QAbstractButton *)));
+ QObject::connect(printerOrFile, SIGNAL(buttonClicked(QAbstractButton*)),
+ q, SLOT(_q_printerOrFileSelected(QAbstractButton*)));
printToPrinterButton = q->findChild<QRadioButton *>("printToPrinterButton");
printerOrFile->addButton(printToPrinterButton);
@@ -288,8 +288,8 @@ void QPrintDialogPrivate::setupPrinterSettings()
// color mode
colorMode = new QButtonGroup(q);
- QObject::connect(colorMode, SIGNAL(buttonClicked(QAbstractButton *)),
- q, SLOT(_q_colorModeSelected(QAbstractButton *)));
+ QObject::connect(colorMode, SIGNAL(buttonClicked(QAbstractButton*)),
+ q, SLOT(_q_colorModeSelected(QAbstractButton*)));
printColor = q->findChild<QRadioButton *>("printColor");
colorMode->addButton(printColor);
diff --git a/src/gui/dialogs/qprintpreviewdialog.cpp b/src/gui/dialogs/qprintpreviewdialog.cpp
index 1f0b51d..bb8437c 100644
--- a/src/gui/dialogs/qprintpreviewdialog.cpp
+++ b/src/gui/dialogs/qprintpreviewdialog.cpp
@@ -224,7 +224,7 @@ void QPrintPreviewDialogPrivate::init(QPrinter *_printer)
printer = new QPrinter;
preview = new QPrintPreviewWidget(printer, q);
}
- QObject::connect(preview, SIGNAL(paintRequested(QPrinter *)), q, SIGNAL(paintRequested(QPrinter *)));
+ QObject::connect(preview, SIGNAL(paintRequested(QPrinter*)), q, SIGNAL(paintRequested(QPrinter*)));
QObject::connect(preview, SIGNAL(previewChanged()), q, SLOT(_q_previewChanged()));
setupActions();
diff --git a/src/gui/dialogs/qsidebar.cpp b/src/gui/dialogs/qsidebar.cpp
index 396889d..879d1b1 100644
--- a/src/gui/dialogs/qsidebar.cpp
+++ b/src/gui/dialogs/qsidebar.cpp
@@ -293,20 +293,20 @@ void QUrlModel::setFileSystemModel(QFileSystemModel *model)
if (model == fileSystemModel)
return;
if (fileSystemModel != 0) {
- disconnect(model, SIGNAL(dataChanged(const QModelIndex &, const QModelIndex &)),
- this, SLOT(dataChanged(const QModelIndex &, const QModelIndex &)));
+ disconnect(model, SIGNAL(dataChanged(QModelIndex,QModelIndex)),
+ this, SLOT(dataChanged(QModelIndex,QModelIndex)));
disconnect(model, SIGNAL(layoutChanged()),
this, SLOT(layoutChanged()));
- disconnect(model, SIGNAL(rowsRemoved(const QModelIndex &, int, int)),
+ disconnect(model, SIGNAL(rowsRemoved(QModelIndex,int,int)),
this, SLOT(layoutChanged()));
}
fileSystemModel = model;
if (fileSystemModel != 0) {
- connect(model, SIGNAL(dataChanged(const QModelIndex &, const QModelIndex &)),
- this, SLOT(dataChanged(const QModelIndex &, const QModelIndex &)));
+ connect(model, SIGNAL(dataChanged(QModelIndex,QModelIndex)),
+ this, SLOT(dataChanged(QModelIndex,QModelIndex)));
connect(model, SIGNAL(layoutChanged()),
this, SLOT(layoutChanged()));
- connect(model, SIGNAL(rowsRemoved(const QModelIndex &, int, int)),
+ connect(model, SIGNAL(rowsRemoved(QModelIndex,int,int)),
this, SLOT(layoutChanged()));
}
clear();
@@ -381,14 +381,14 @@ void QSidebar::init(QFileSystemModel *model, const QList<QUrl> &newUrls)
setModel(urlModel);
setItemDelegate(new QSideBarDelegate(this));
- connect(selectionModel(), SIGNAL(currentChanged(const QModelIndex &, const QModelIndex &)),
- this, SLOT(clicked(const QModelIndex &)));
+ connect(selectionModel(), SIGNAL(currentChanged(QModelIndex,QModelIndex)),
+ this, SLOT(clicked(QModelIndex)));
#ifndef QT_NO_DRAGANDDROP
setDragDropMode(QAbstractItemView::DragDrop);
#endif
setContextMenuPolicy(Qt::CustomContextMenu);
- connect(this, SIGNAL(customContextMenuRequested(const QPoint &)),
- this, SLOT(showContextMenu(const QPoint &)));
+ connect(this, SIGNAL(customContextMenuRequested(QPoint)),
+ this, SLOT(showContextMenu(QPoint)));
urlModel->setUrls(newUrls);
setCurrentIndex(this->model()->index(0,0));
}
@@ -414,8 +414,8 @@ QSize QSidebar::sizeHint() const
void QSidebar::selectUrl(const QUrl &url)
{
- disconnect(selectionModel(), SIGNAL(currentChanged(const QModelIndex &, const QModelIndex &)),
- this, SLOT(clicked(const QModelIndex &)));
+ disconnect(selectionModel(), SIGNAL(currentChanged(QModelIndex,QModelIndex)),
+ this, SLOT(clicked(QModelIndex)));
selectionModel()->clear();
for (int i = 0; i < model()->rowCount(); ++i) {
@@ -425,8 +425,8 @@ void QSidebar::selectUrl(const QUrl &url)
}
}
- connect(selectionModel(), SIGNAL(currentChanged(const QModelIndex &, const QModelIndex &)),
- this, SLOT(clicked(const QModelIndex &)));
+ connect(selectionModel(), SIGNAL(currentChanged(QModelIndex,QModelIndex)),
+ this, SLOT(clicked(QModelIndex)));
}
#ifndef QT_NO_MENU
diff --git a/src/gui/dialogs/qwizard.cpp b/src/gui/dialogs/qwizard.cpp
index db1c9e9..472ca35 100644
--- a/src/gui/dialogs/qwizard.cpp
+++ b/src/gui/dialogs/qwizard.cpp
@@ -759,8 +759,8 @@ void QWizardPrivate::addField(const QWizardField &field)
QObject::connect(myField.object, myField.changedSignal,
myField.page, SLOT(_q_maybeEmitCompleteChanged()));
QObject::connect(
- myField.object, SIGNAL(destroyed(QObject *)), q,
- SLOT(_q_handleFieldObjectDestroyed(QObject *)));
+ myField.object, SIGNAL(destroyed(QObject*)), q,
+ SLOT(_q_handleFieldObjectDestroyed(QObject*)));
}
void QWizardPrivate::removeFieldAt(int index)
@@ -773,8 +773,8 @@ void QWizardPrivate::removeFieldAt(int index)
QObject::disconnect(field.object, field.changedSignal,
field.page, SLOT(_q_maybeEmitCompleteChanged()));
QObject::disconnect(
- field.object, SIGNAL(destroyed(QObject *)), q,
- SLOT(_q_handleFieldObjectDestroyed(QObject *)));
+ field.object, SIGNAL(destroyed(QObject*)), q,
+ SLOT(_q_handleFieldObjectDestroyed(QObject*)));
fields.remove(index);
}
diff --git a/src/gui/graphicsview/qgraphicsitemanimation.cpp b/src/gui/graphicsview/qgraphicsitemanimation.cpp
index be2f300..b67ee2e 100644
--- a/src/gui/graphicsview/qgraphicsitemanimation.cpp
+++ b/src/gui/graphicsview/qgraphicsitemanimation.cpp
@@ -45,6 +45,7 @@
support for QGraphicsItem.
\since 4.2
\ingroup graphicsview-api
+ \deprecated
The QGraphicsItemAnimation class animates a QGraphicsItem. You can
schedule changes to the item's transformation matrix at
diff --git a/src/gui/graphicsview/qgraphicsscene.cpp b/src/gui/graphicsview/qgraphicsscene.cpp
index 5b0643d..10d251d 100644
--- a/src/gui/graphicsview/qgraphicsscene.cpp
+++ b/src/gui/graphicsview/qgraphicsscene.cpp
@@ -2556,11 +2556,9 @@ void QGraphicsScene::addItem(QGraphicsItem *item)
item->d_ptr->resolveFont(d->font.resolve());
item->d_ptr->resolvePalette(d->palette.resolve());
- if (!item->d_ptr->explicitlyHidden) {
- if (d->unpolishedItems.isEmpty())
- QMetaObject::invokeMethod(this, "_q_polishItems", Qt::QueuedConnection);
- d->unpolishedItems.insert(item);
- }
+ if (d->unpolishedItems.isEmpty())
+ QMetaObject::invokeMethod(this, "_q_polishItems", Qt::QueuedConnection);
+ d->unpolishedItems.insert(item);
// Reenable selectionChanged() for individual items
--d->selectionChanging;
@@ -4422,9 +4420,12 @@ void QGraphicsScenePrivate::drawItemHelper(QGraphicsItem *item, QPainter *painte
bool allowPartialCacheExposure = !viewRect.contains(deviceRect);
#else
// Only if deviceRect is 20% taller or wider than the desktop.
- QRect desktopRect = QApplication::desktop()->availableGeometry(widget);
- bool allowPartialCacheExposure = (desktopRect.width() * 1.2 < deviceRect.width()
- || desktopRect.height() * 1.2 < deviceRect.height());
+ bool allowPartialCacheExposure = false;
+ if (widget) {
+ QRect desktopRect = QApplication::desktop()->availableGeometry(widget);
+ allowPartialCacheExposure = (desktopRect.width() * 1.2 < deviceRect.width()
+ || desktopRect.height() * 1.2 < deviceRect.height());
+ }
#endif
QRegion scrollExposure;
if (deviceData->cacheIndent != QPoint() || allowPartialCacheExposure) {
diff --git a/src/gui/graphicsview/qgraphicssceneindex.cpp b/src/gui/graphicsview/qgraphicssceneindex.cpp
index f0404fd..70ecd49 100644
--- a/src/gui/graphicsview/qgraphicssceneindex.cpp
+++ b/src/gui/graphicsview/qgraphicssceneindex.cpp
@@ -354,8 +354,8 @@ void QGraphicsSceneIndexPrivate::init()
if (!scene)
return;
- QObject::connect(scene, SIGNAL(sceneRectChanged(const QRectF&)),
- q_func(), SLOT(updateSceneRect(const QRectF&)));
+ QObject::connect(scene, SIGNAL(sceneRectChanged(QRectF)),
+ q_func(), SLOT(updateSceneRect(QRectF)));
}
/*!
diff --git a/src/gui/gui.pro b/src/gui/gui.pro
index 7c24002..4215f97 100644
--- a/src/gui/gui.pro
+++ b/src/gui/gui.pro
@@ -54,4 +54,4 @@ DEFINES += Q_INTERNAL_QAPP_SRC
symbian:TARGET.UID3=0x2001B2DD
# ro-section in gui can exceed default allocated space, so more rw-section little further
-symbian-sbsv2: MMP_RULES += "LINKEROPTION armcc --rw-base 0x800000"
+symbian-sbsv2: QMAKE_LFLAGS.ARMCC += --rw-base 0x800000"
diff --git a/src/gui/image/qpixmap_mac.cpp b/src/gui/image/qpixmap_mac.cpp
index 6175931..365c271 100644
--- a/src/gui/image/qpixmap_mac.cpp
+++ b/src/gui/image/qpixmap_mac.cpp
@@ -160,8 +160,8 @@ QSet<QMacPixmapData*> QMacPixmapData::validDataPointers;
QMacPixmapData::QMacPixmapData(PixelType type)
: QPixmapData(type, MacClass), has_alpha(0), has_mask(0),
- uninit(true), pixels(0), pixelsToFree(0), bytesPerRow(0),
- cg_data(0), cg_dataBeingReleased(0), cg_mask(0),
+ uninit(true), pixels(0), pixelsSize(0), pixelsToFree(0),
+ bytesPerRow(0), cg_data(0), cg_dataBeingReleased(0), cg_mask(0),
pengine(0)
{
}
@@ -637,8 +637,9 @@ void QMacPixmapData::macCreatePixels()
}
if (pixels)
- memcpy(base_pixels, pixels, numBytes);
+ memcpy(base_pixels, pixels, pixelsSize);
pixels = base_pixels;
+ pixelsSize = numBytes;
}
#if 0
diff --git a/src/gui/image/qpixmap_mac_p.h b/src/gui/image/qpixmap_mac_p.h
index a3fb95f..45ab8e2 100644
--- a/src/gui/image/qpixmap_mac_p.h
+++ b/src/gui/image/qpixmap_mac_p.h
@@ -107,6 +107,7 @@ private:
pixelsToFree later on instead of malloc'ing memory.
*/
quint32 *pixels;
+ uint pixelsSize;
quint32 *pixelsToFree;
uint bytesPerRow;
QRectF cg_mask_rect;
diff --git a/src/gui/image/qpixmap_s60.cpp b/src/gui/image/qpixmap_s60.cpp
index 17baa50..dc33ade 100644
--- a/src/gui/image/qpixmap_s60.cpp
+++ b/src/gui/image/qpixmap_s60.cpp
@@ -977,4 +977,9 @@ void QS60PixmapData::fromNativeType(void* pixmap, NativeType nativeType)
}
}
+QPixmapData *QS60PixmapData::createCompatiblePixmapData() const
+{
+ return new QS60PixmapData(pixelType());
+}
+
QT_END_NAMESPACE
diff --git a/src/gui/image/qpixmap_s60_p.h b/src/gui/image/qpixmap_s60_p.h
index b1b5824..8631ebd 100644
--- a/src/gui/image/qpixmap_s60_p.h
+++ b/src/gui/image/qpixmap_s60_p.h
@@ -87,6 +87,8 @@ public:
QS60PixmapData(PixelType type);
~QS60PixmapData();
+ QPixmapData *createCompatiblePixmapData() const;
+
void resize(int width, int height);
void fromImage(const QImage &image, Qt::ImageConversionFlags flags);
void copy(const QPixmapData *data, const QRect &rect);
diff --git a/src/gui/itemviews/qabstractitemview.cpp b/src/gui/itemviews/qabstractitemview.cpp
index 23bef12..c691fe2 100644
--- a/src/gui/itemviews/qabstractitemview.cpp
+++ b/src/gui/itemviews/qabstractitemview.cpp
@@ -138,10 +138,22 @@ void QAbstractItemViewPrivate::init()
#endif
}
+void QAbstractItemViewPrivate::setHoverIndex(const QPersistentModelIndex &index)
+{
+ Q_Q(QAbstractItemView);
+ if (hover == index)
+ return;
+
+ q->update(hover); //update the old one
+ hover = index;
+ q->update(hover); //update the new one
+}
+
void QAbstractItemViewPrivate::checkMouseMove(const QPersistentModelIndex &index)
{
//we take a persistent model index because the model might change by emitting signals
Q_Q(QAbstractItemView);
+ setHoverIndex(index);
if (viewportEnteredNeeded || enteredIndex != index) {
viewportEnteredNeeded = false;
@@ -1536,22 +1548,13 @@ bool QAbstractItemView::viewportEvent(QEvent *event)
{
Q_D(QAbstractItemView);
switch (event->type()) {
- case QEvent::HoverEnter: {
- QHoverEvent *he = static_cast<QHoverEvent*>(event);
- d->hover = indexAt(he->pos());
- update(d->hover);
- break; }
- case QEvent::HoverLeave: {
- update(d->hover); // update old
- d->hover = QModelIndex();
- break; }
- case QEvent::HoverMove: {
- QHoverEvent *he = static_cast<QHoverEvent*>(event);
- QModelIndex old = d->hover;
- d->hover = indexAt(he->pos());
- if (d->hover != old)
- d->viewport->update(visualRect(old)|visualRect(d->hover));
- break; }
+ case QEvent::HoverMove:
+ case QEvent::HoverEnter:
+ d->setHoverIndex(indexAt(static_cast<QHoverEvent*>(event)->pos()));
+ break;
+ case QEvent::HoverLeave:
+ d->setHoverIndex(QModelIndex());
+ break;
case QEvent::Enter:
d->viewportEnteredNeeded = true;
break;
diff --git a/src/gui/itemviews/qabstractitemview_p.h b/src/gui/itemviews/qabstractitemview_p.h
index c691f61..f1ba874 100644
--- a/src/gui/itemviews/qabstractitemview_p.h
+++ b/src/gui/itemviews/qabstractitemview_p.h
@@ -152,6 +152,8 @@ public:
const QEvent *event) const;
virtual void selectAll(QItemSelectionModel::SelectionFlags command);
+ void setHoverIndex(const QPersistentModelIndex &index);
+
void checkMouseMove(const QPersistentModelIndex &index);
inline void checkMouseMove(const QPoint &pos) { checkMouseMove(q_func()->indexAt(pos)); }
diff --git a/src/gui/itemviews/qcolumnview.cpp b/src/gui/itemviews/qcolumnview.cpp
index d27d061..da3e5a0 100644
--- a/src/gui/itemviews/qcolumnview.cpp
+++ b/src/gui/itemviews/qcolumnview.cpp
@@ -672,8 +672,8 @@ QAbstractItemView *QColumnViewPrivate::createColumn(const QModelIndex &index, bo
QAbstractItemView *view = 0;
if (model->hasChildren(index)) {
view = q->createColumn(index);
- q->connect(view, SIGNAL(clicked(const QModelIndex &)),
- q, SLOT(_q_clicked(const QModelIndex &)));
+ q->connect(view, SIGNAL(clicked(QModelIndex)),
+ q, SLOT(_q_clicked(QModelIndex)));
} else {
if (!previewColumn)
setPreviewWidget(new QWidget(q));
@@ -681,16 +681,16 @@ QAbstractItemView *QColumnViewPrivate::createColumn(const QModelIndex &index, bo
view->setMinimumWidth(qMax(view->minimumWidth(), previewWidget->minimumWidth()));
}
- q->connect(view, SIGNAL(activated(const QModelIndex &)),
- q, SIGNAL(activated(const QModelIndex &)));
- q->connect(view, SIGNAL(clicked(const QModelIndex &)),
- q, SIGNAL(clicked(const QModelIndex &)));
- q->connect(view, SIGNAL(doubleClicked(const QModelIndex &)),
- q, SIGNAL(doubleClicked(const QModelIndex &)));
- q->connect(view, SIGNAL(entered(const QModelIndex &)),
- q, SIGNAL(entered(const QModelIndex &)));
- q->connect(view, SIGNAL(pressed(const QModelIndex &)),
- q, SIGNAL(pressed(const QModelIndex &)));
+ q->connect(view, SIGNAL(activated(QModelIndex)),
+ q, SIGNAL(activated(QModelIndex)));
+ q->connect(view, SIGNAL(clicked(QModelIndex)),
+ q, SIGNAL(clicked(QModelIndex)));
+ q->connect(view, SIGNAL(doubleClicked(QModelIndex)),
+ q, SIGNAL(doubleClicked(QModelIndex)));
+ q->connect(view, SIGNAL(entered(QModelIndex)),
+ q, SIGNAL(entered(QModelIndex)));
+ q->connect(view, SIGNAL(pressed(QModelIndex)),
+ q, SIGNAL(pressed(QModelIndex)));
view->setFocusPolicy(Qt::NoFocus);
view->setParent(viewport);
diff --git a/src/gui/itemviews/qheaderview.cpp b/src/gui/itemviews/qheaderview.cpp
index 6f2cff9..5df8481 100644
--- a/src/gui/itemviews/qheaderview.cpp
+++ b/src/gui/itemviews/qheaderview.cpp
@@ -2396,7 +2396,12 @@ bool QHeaderView::viewportEvent(QEvent *e)
d->state = QHeaderViewPrivate::NoState;
d->pressed = d->section = d->target = -1;
d->updateSectionIndicator(d->section, -1);
- }
+ break; }
+ case QEvent::Wheel: {
+ QAbstractScrollArea *asa = qobject_cast<QAbstractScrollArea *>(parentWidget());
+ if (asa)
+ return QApplication::sendEvent(asa->viewport(), e);
+ break; }
default:
break;
}
diff --git a/src/gui/itemviews/qlistview.cpp b/src/gui/itemviews/qlistview.cpp
index c6622cb..d03cdd3 100644
--- a/src/gui/itemviews/qlistview.cpp
+++ b/src/gui/itemviews/qlistview.cpp
@@ -773,7 +773,7 @@ void QListView::rowsAboutToBeRemoved(const QModelIndex &parent, int start, int e
void QListView::mouseMoveEvent(QMouseEvent *e)
{
if (!isVisible())
- return;
+ return;
Q_D(QListView);
QAbstractItemView::mouseMoveEvent(e);
if (state() == DragSelectingState
@@ -832,16 +832,16 @@ void QListView::resizeEvent(QResizeEvent *e)
return;
bool listWrap = (d->viewMode == ListMode) && d->wrapItemText;
- bool flowDimensionChanged = (d->flow == LeftToRight && delta.width() != 0)
- || (d->flow == TopToBottom && delta.height() != 0);
+ bool flowDimensionChanged = (d->flow == LeftToRight && delta.width() != 0)
+ || (d->flow == TopToBottom && delta.height() != 0);
// We post a delayed relayout in the following cases :
// - we're wrapping
// - the state is NoState, we're adjusting and the size has changed in the flowing direction
- if (listWrap
+ if (listWrap
|| (state() == NoState && d->resizeMode == Adjust && flowDimensionChanged)) {
- d->doDelayedItemsLayout(100); // wait 1/10 sec before starting the layout
- } else {
+ d->doDelayedItemsLayout(100); // wait 1/10 sec before starting the layout
+ } else {
QAbstractItemView::resizeEvent(e);
}
}
@@ -966,15 +966,19 @@ void QListView::paintEvent(QPaintEvent *e)
bool alternateBase = false;
int previousRow = -2; // trigger the alternateBase adjustment on first pass
+ int maxSize = (flow() == TopToBottom)
+ ? qMax(viewport()->size().width(), d->contentsSize().width()) - 2 * d->spacing()
+ : qMax(viewport()->size().height(), d->contentsSize().height()) - 2 * d->spacing();
+
QVector<QModelIndex>::const_iterator end = toBeRendered.constEnd();
for (QVector<QModelIndex>::const_iterator it = toBeRendered.constBegin(); it != end; ++it) {
Q_ASSERT((*it).isValid());
option.rect = visualRect(*it);
if (flow() == TopToBottom)
- option.rect.setWidth(qMin(d->contentsSize().width() - 2 * d->spacing(), option.rect.width()));
+ option.rect.setWidth(qMin(maxSize, option.rect.width()));
else
- option.rect.setHeight(qMin(d->contentsSize().height() - 2 * d->spacing(), option.rect.height()));
+ option.rect.setHeight(qMin(maxSize, option.rect.height()));
option.state = state;
if (selections && selections->isSelected(*it))
@@ -1147,7 +1151,9 @@ QModelIndex QListView::moveCursor(CursorAction cursorAction, Qt::KeyboardModifie
}
return d->closestIndex(initialRect, intersectVector);
case MovePageUp:
- rect.moveTop(rect.top() - d->viewport->height());
+ // move current by (visibileRowCount - 1) items.
+ // rect.translate(0, -rect.height()); will happen in the switch fallthrough for MoveUp.
+ rect.moveTop(rect.top() - d->viewport->height() + 2 * rect.height());
if (rect.top() < rect.height())
rect.moveTop(rect.height());
case MovePrevious:
@@ -1173,7 +1179,9 @@ QModelIndex QListView::moveCursor(CursorAction cursorAction, Qt::KeyboardModifie
}
return d->closestIndex(initialRect, intersectVector);
case MovePageDown:
- rect.moveTop(rect.top() + d->viewport->height());
+ // move current by (visibileRowCount - 1) items.
+ // rect.translate(0, rect.height()); will happen in the switch fallthrough for MoveDown.
+ rect.moveTop(rect.top() + d->viewport->height() - 2 * rect.height());
if (rect.bottom() > contents.height() - rect.height())
rect.moveBottom(contents.height() - rect.height());
case MoveNext:
@@ -1445,7 +1453,7 @@ void QListView::doItemsLayout()
// so we set the state to expanding to avoid
// triggering another layout
QAbstractItemView::State oldState = state();
- setState(ExpandingState);
+ setState(ExpandingState);
if (d->model->columnCount(d->root) > 0) { // no columns means no contents
d->resetBatchStartRow();
if (layoutMode() == SinglePass)
diff --git a/src/gui/itemviews/qtableview.cpp b/src/gui/itemviews/qtableview.cpp
index 02e5fff..a3877b7 100644
--- a/src/gui/itemviews/qtableview.cpp
+++ b/src/gui/itemviews/qtableview.cpp
@@ -1064,14 +1064,29 @@ QTableView::~QTableView()
void QTableView::setModel(QAbstractItemModel *model)
{
Q_D(QTableView);
- connect(model, SIGNAL(rowsInserted(QModelIndex,int,int)),
- this, SLOT(_q_updateSpanInsertedRows(QModelIndex,int,int)));
- connect(model, SIGNAL(columnsInserted(QModelIndex,int,int)),
- this, SLOT(_q_updateSpanInsertedColumns(QModelIndex,int,int)));
- connect(model, SIGNAL(rowsRemoved(QModelIndex,int,int)),
- this, SLOT(_q_updateSpanRemovedRows(QModelIndex,int,int)));
- connect(model, SIGNAL(columnsRemoved(QModelIndex,int,int)),
- this, SLOT(_q_updateSpanRemovedColumns(QModelIndex,int,int)));
+ if (model == d->model)
+ return;
+ //let's disconnect from the old model
+ if (d->model && d->model != QAbstractItemModelPrivate::staticEmptyModel()) {
+ disconnect(d->model, SIGNAL(rowsInserted(QModelIndex,int,int)),
+ this, SLOT(_q_updateSpanInsertedRows(QModelIndex,int,int)));
+ disconnect(d->model, SIGNAL(columnsInserted(QModelIndex,int,int)),
+ this, SLOT(_q_updateSpanInsertedColumns(QModelIndex,int,int)));
+ disconnect(d->model, SIGNAL(rowsRemoved(QModelIndex,int,int)),
+ this, SLOT(_q_updateSpanRemovedRows(QModelIndex,int,int)));
+ disconnect(d->model, SIGNAL(columnsRemoved(QModelIndex,int,int)),
+ this, SLOT(_q_updateSpanRemovedColumns(QModelIndex,int,int)));
+ }
+ if (model) { //and connect to the new one
+ connect(model, SIGNAL(rowsInserted(QModelIndex,int,int)),
+ this, SLOT(_q_updateSpanInsertedRows(QModelIndex,int,int)));
+ connect(model, SIGNAL(columnsInserted(QModelIndex,int,int)),
+ this, SLOT(_q_updateSpanInsertedColumns(QModelIndex,int,int)));
+ connect(model, SIGNAL(rowsRemoved(QModelIndex,int,int)),
+ this, SLOT(_q_updateSpanRemovedRows(QModelIndex,int,int)));
+ connect(model, SIGNAL(columnsRemoved(QModelIndex,int,int)),
+ this, SLOT(_q_updateSpanRemovedColumns(QModelIndex,int,int)));
+ }
d->verticalHeader->setModel(model);
d->horizontalHeader->setModel(model);
QAbstractItemView::setModel(model);
diff --git a/src/gui/itemviews/qtreeview.cpp b/src/gui/itemviews/qtreeview.cpp
index a3cbc0d..3ad9fbb 100644
--- a/src/gui/itemviews/qtreeview.cpp
+++ b/src/gui/itemviews/qtreeview.cpp
@@ -215,6 +215,13 @@ void QTreeView::setModel(QAbstractItemModel *model)
Q_D(QTreeView);
if (model == d->model)
return;
+ if (d->model && d->model != QAbstractItemModelPrivate::staticEmptyModel()) {
+ disconnect(d->model, SIGNAL(rowsRemoved(QModelIndex,int,int)),
+ this, SLOT(rowsRemoved(QModelIndex,int,int)));
+
+ disconnect(d->model, SIGNAL(modelAboutToBeReset()), this, SLOT(_q_modelAboutToBeReset()));
+ }
+
if (d->selectionModel) { // support row editing
disconnect(d->selectionModel, SIGNAL(currentRowChanged(QModelIndex,QModelIndex)),
d->model, SLOT(submit()));
@@ -838,10 +845,10 @@ void QTreeView::setSortingEnabled(bool enable)
// because otherwise it will not call sort on the model.
sortByColumn(header()->sortIndicatorSection(), header()->sortIndicatorOrder());
connect(header(), SIGNAL(sortIndicatorChanged(int,Qt::SortOrder)),
- this, SLOT(_q_sortIndicatorChanged(int, Qt::SortOrder)), Qt::UniqueConnection);
+ this, SLOT(_q_sortIndicatorChanged(int,Qt::SortOrder)), Qt::UniqueConnection);
} else {
disconnect(header(), SIGNAL(sortIndicatorChanged(int,Qt::SortOrder)),
- this, SLOT(_q_sortIndicatorChanged(int, Qt::SortOrder)));
+ this, SLOT(_q_sortIndicatorChanged(int,Qt::SortOrder)));
}
d->sortingEnabled = enable;
}
diff --git a/src/gui/kernel/kernel.pri b/src/gui/kernel/kernel.pri
index 8859358..7d0e5c7 100644
--- a/src/gui/kernel/kernel.pri
+++ b/src/gui/kernel/kernel.pri
@@ -188,9 +188,8 @@ embedded {
HEADERS += \
kernel/qeventdispatcher_glib_qws_p.h
QMAKE_CXXFLAGS += $$QT_CFLAGS_GLIB
+ LIBS_PRIVATE +=$$QT_LIBS_GLIB
}
-
-
}
!embedded:!x11:mac {
diff --git a/src/gui/kernel/qapplication.cpp b/src/gui/kernel/qapplication.cpp
index 4b8f6a0..4764a2d 100644
--- a/src/gui/kernel/qapplication.cpp
+++ b/src/gui/kernel/qapplication.cpp
@@ -4105,8 +4105,17 @@ bool QApplication::notify(QObject *receiver, QEvent *e)
} else if (widget->isWindow() || widget->testAttribute(Qt::WA_NoMousePropagation)) {
break;
}
+ QPoint offset = widget->pos();
widget = widget->parentWidget();
- d->updateTouchPointsForWidget(widget, touchEvent);
+ touchEvent->setWidget(widget);
+ for (int i = 0; i < touchEvent->_touchPoints.size(); ++i) {
+ QTouchEvent::TouchPoint &pt = touchEvent->_touchPoints[i];
+ QRectF rect = pt.rect();
+ rect.moveCenter(offset);
+ pt.d->rect = rect;
+ pt.d->startPos = pt.startPos() + offset;
+ pt.d->lastPos = pt.lastPos() + offset;
+ }
}
touchEvent->setAccepted(eventAccepted);
@@ -5417,9 +5426,11 @@ void QApplicationPrivate::updateTouchPointsForWidget(QWidget *widget, QTouchEven
const QPointF delta = screenPos - screenPos.toPoint();
rect.moveCenter(widget->mapFromGlobal(screenPos.toPoint()) + delta);
- touchPoint.setRect(rect);
- touchPoint.setStartPos(widget->mapFromGlobal(touchPoint.startScreenPos().toPoint()) + delta);
- touchPoint.setLastPos(widget->mapFromGlobal(touchPoint.lastScreenPos().toPoint()) + delta);
+ touchPoint.d->rect = rect;
+ if (touchPoint.state() == Qt::TouchPointPressed) {
+ touchPoint.d->startPos = widget->mapFromGlobal(touchPoint.startScreenPos().toPoint()) + delta;
+ touchPoint.d->lastPos = widget->mapFromGlobal(touchPoint.lastScreenPos().toPoint()) + delta;
+ }
}
}
@@ -5463,16 +5474,20 @@ void QApplicationPrivate::translateRawTouchEvent(QWidget *window,
for (int i = 0; i < touchPoints.count(); ++i) {
QTouchEvent::TouchPoint touchPoint = touchPoints.at(i);
+ // explicitly detach from the original touch point that we got, so even
+ // if the touchpoint structs are reused, we will make a copy that we'll
+ // deliver to the user (which might want to store the struct for later use).
+ touchPoint.d = touchPoint.d->detach();
// update state
- QWidget *widget = 0;
+ QWeakPointer<QWidget> widget;
switch (touchPoint.state()) {
case Qt::TouchPointPressed:
{
if (deviceType == QTouchEvent::TouchPad) {
// on touch-pads, send all touch points to the same widget
widget = d->widgetForTouchPointId.isEmpty()
- ? 0
+ ? QWeakPointer<QWidget>()
: d->widgetForTouchPointId.constBegin().value();
}
@@ -5489,20 +5504,21 @@ void QApplicationPrivate::translateRawTouchEvent(QWidget *window,
if (deviceType == QTouchEvent::TouchScreen) {
int closestTouchPointId = d->findClosestTouchPointId(touchPoint.screenPos());
- QWidget *closestWidget = d->widgetForTouchPointId.value(closestTouchPointId);
+ QWidget *closestWidget = d->widgetForTouchPointId.value(closestTouchPointId).data();
if (closestWidget
- && (widget->isAncestorOf(closestWidget) || closestWidget->isAncestorOf(widget))) {
+ && (widget.data()->isAncestorOf(closestWidget) || closestWidget->isAncestorOf(widget.data()))) {
widget = closestWidget;
}
}
d->widgetForTouchPointId[touchPoint.id()] = widget;
- touchPoint.setStartScreenPos(touchPoint.screenPos());
- touchPoint.setLastScreenPos(touchPoint.screenPos());
- touchPoint.setStartNormalizedPos(touchPoint.normalizedPos());
- touchPoint.setLastNormalizedPos(touchPoint.normalizedPos());
+ touchPoint.d->startScreenPos = touchPoint.screenPos();
+ touchPoint.d->lastScreenPos = touchPoint.screenPos();
+ touchPoint.d->startNormalizedPos = touchPoint.normalizedPos();
+ touchPoint.d->lastNormalizedPos = touchPoint.normalizedPos();
if (touchPoint.pressure() < qreal(0.))
- touchPoint.setPressure(qreal(1.));
+ touchPoint.d->pressure = qreal(1.);
+
d->appCurrentTouchPoints.insert(touchPoint.id(), touchPoint);
break;
}
@@ -5513,12 +5529,14 @@ void QApplicationPrivate::translateRawTouchEvent(QWidget *window,
continue;
QTouchEvent::TouchPoint previousTouchPoint = d->appCurrentTouchPoints.take(touchPoint.id());
- touchPoint.setStartScreenPos(previousTouchPoint.startScreenPos());
- touchPoint.setLastScreenPos(previousTouchPoint.screenPos());
- touchPoint.setStartNormalizedPos(previousTouchPoint.startNormalizedPos());
- touchPoint.setLastNormalizedPos(previousTouchPoint.normalizedPos());
+ touchPoint.d->startScreenPos = previousTouchPoint.startScreenPos();
+ touchPoint.d->lastScreenPos = previousTouchPoint.screenPos();
+ touchPoint.d->startPos = previousTouchPoint.startPos();
+ touchPoint.d->lastPos = previousTouchPoint.pos();
+ touchPoint.d->startNormalizedPos = previousTouchPoint.startNormalizedPos();
+ touchPoint.d->lastNormalizedPos = previousTouchPoint.normalizedPos();
if (touchPoint.pressure() < qreal(0.))
- touchPoint.setPressure(qreal(0.));
+ touchPoint.d->pressure = qreal(0.);
break;
}
default:
@@ -5528,23 +5546,25 @@ void QApplicationPrivate::translateRawTouchEvent(QWidget *window,
Q_ASSERT(d->appCurrentTouchPoints.contains(touchPoint.id()));
QTouchEvent::TouchPoint previousTouchPoint = d->appCurrentTouchPoints.value(touchPoint.id());
- touchPoint.setStartScreenPos(previousTouchPoint.startScreenPos());
- touchPoint.setLastScreenPos(previousTouchPoint.screenPos());
- touchPoint.setStartNormalizedPos(previousTouchPoint.startNormalizedPos());
- touchPoint.setLastNormalizedPos(previousTouchPoint.normalizedPos());
+ touchPoint.d->startScreenPos = previousTouchPoint.startScreenPos();
+ touchPoint.d->lastScreenPos = previousTouchPoint.screenPos();
+ touchPoint.d->startPos = previousTouchPoint.startPos();
+ touchPoint.d->lastPos = previousTouchPoint.pos();
+ touchPoint.d->startNormalizedPos = previousTouchPoint.startNormalizedPos();
+ touchPoint.d->lastNormalizedPos = previousTouchPoint.normalizedPos();
if (touchPoint.pressure() < qreal(0.))
- touchPoint.setPressure(qreal(1.));
+ touchPoint.d->pressure = qreal(1.);
d->appCurrentTouchPoints[touchPoint.id()] = touchPoint;
break;
}
- Q_ASSERT(widget != 0);
+ Q_ASSERT(widget.data() != 0);
// make the *scene* functions return the same as the *screen* functions
- touchPoint.setSceneRect(touchPoint.screenRect());
- touchPoint.setStartScenePos(touchPoint.startScreenPos());
- touchPoint.setLastScenePos(touchPoint.lastScreenPos());
+ touchPoint.d->sceneRect = touchPoint.screenRect();
+ touchPoint.d->startScenePos = touchPoint.startScreenPos();
+ touchPoint.d->lastScenePos = touchPoint.lastScreenPos();
- StatesAndTouchPoints &maskAndPoints = widgetsNeedingEvents[widget];
+ StatesAndTouchPoints &maskAndPoints = widgetsNeedingEvents[widget.data()];
maskAndPoints.first |= touchPoint.state();
if (touchPoint.isPrimary())
maskAndPoints.first |= Qt::TouchPointPrimary;
diff --git a/src/gui/kernel/qapplication_p.h b/src/gui/kernel/qapplication_p.h
index 992e4be..14d7215 100644
--- a/src/gui/kernel/qapplication_p.h
+++ b/src/gui/kernel/qapplication_p.h
@@ -511,7 +511,7 @@ public:
QWidget *gestureWidget;
- QMap<int, QWidget *> widgetForTouchPointId;
+ QMap<int, QWeakPointer<QWidget> > widgetForTouchPointId;
QMap<int, QTouchEvent::TouchPoint> appCurrentTouchPoints;
static void updateTouchPointsForWidget(QWidget *widget, QTouchEvent *touchEvent);
void initializeMultitouch();
diff --git a/src/gui/kernel/qapplication_s60.cpp b/src/gui/kernel/qapplication_s60.cpp
index c7f0c00..85b6d00 100644
--- a/src/gui/kernel/qapplication_s60.cpp
+++ b/src/gui/kernel/qapplication_s60.cpp
@@ -712,7 +712,7 @@ TKeyResponse QSymbianControl::OfferKeyEvent(const TKeyEvent& keyEvent, TEventCod
Qt::KeyboardModifiers mods = mapToQtModifiers(keyEvent.iModifiers);
QKeyEventEx qKeyEvent(type == EEventKeyUp ? QEvent::KeyRelease : QEvent::KeyPress, keyCode,
mods, qt_keymapper_private()->translateKeyEvent(keyCode, mods),
- false, 1, keyEvent.iScanCode, s60Keysym, keyEvent.iModifiers);
+ (keyEvent.iRepeats != 0), 1, keyEvent.iScanCode, s60Keysym, keyEvent.iModifiers);
// WId wid = reinterpret_cast<RWindowGroup *>(keyEvent.Handle())->Child();
// if (!wid)
// Could happen if window isn't shown yet.
diff --git a/src/gui/kernel/qevent.h b/src/gui/kernel/qevent.h
index 9839269..461cc92 100644
--- a/src/gui/kernel/qevent.h
+++ b/src/gui/kernel/qevent.h
@@ -787,6 +787,8 @@ public:
private:
QTouchEventTouchPointPrivate *d;
+ friend class QApplication;
+ friend class QApplicationPrivate;
};
enum DeviceType {
@@ -818,6 +820,7 @@ protected:
Qt::TouchPointStates _touchPointStates;
QList<QTouchEvent::TouchPoint> _touchPoints;
+ friend class QApplication;
friend class QApplicationPrivate;
};
diff --git a/src/gui/kernel/qeventdispatcher_s60.cpp b/src/gui/kernel/qeventdispatcher_s60.cpp
index 9d18c9b..4c1429a 100644
--- a/src/gui/kernel/qeventdispatcher_s60.cpp
+++ b/src/gui/kernel/qeventdispatcher_s60.cpp
@@ -92,7 +92,7 @@ void QEventDispatcherS60::saveInputEvent(QSymbianControl *control, QWidget *widg
{
DeferredInputEvent inputEvent = {control, widget, event};
m_deferredInputEvents.append(inputEvent);
- connect(widget, SIGNAL(destroyed(QObject *)), SLOT(removeInputEventsForWidget(QObject *)));
+ connect(widget, SIGNAL(destroyed(QObject*)), SLOT(removeInputEventsForWidget(QObject*)));
}
bool QEventDispatcherS60::sendDeferredInputEvents()
diff --git a/src/gui/kernel/qformlayout.cpp b/src/gui/kernel/qformlayout.cpp
index 3e5dadc..33f5489 100644
--- a/src/gui/kernel/qformlayout.cpp
+++ b/src/gui/kernel/qformlayout.cpp
@@ -1124,14 +1124,15 @@ QStyle* QFormLayoutPrivate::getStyle() const
\value DontWrapRows
Fields are always laid out next to their label. This is
- the default policy for all styles except Qt Extended styles.
+ the default policy for all styles except Qt Extended styles
+ and QS60Style.
\value WrapLongRows
Labels are given enough horizontal space to fit the widest label,
and the rest of the space is given to the fields. If the minimum
size of a field pair is wider than the available space, the field
is wrapped to the next line. This is the default policy for
- Qt Extended styles.
+ Qt Extended styles and and QS60Style.
\value WrapAllRows
Fields are always laid out below their label.
@@ -1720,8 +1721,8 @@ QFormLayout::FieldGrowthPolicy QFormLayout::fieldGrowthPolicy() const
\brief the way in which the form's rows wrap
The default value depends on the widget or application style. For
- Qt Extended styles, the default is WrapLongRows; for the other styles,
- the default is DontWrapRows.
+ Qt Extended styles and QS60Style, the default is WrapLongRows;
+ for the other styles, the default is DontWrapRows.
If you want to display each label above its associated field
(instead of next to it), set this property to WrapAllRows.
diff --git a/src/gui/kernel/qmultitouch_mac.mm b/src/gui/kernel/qmultitouch_mac.mm
index 2f6f9ca..f736146 100644
--- a/src/gui/kernel/qmultitouch_mac.mm
+++ b/src/gui/kernel/qmultitouch_mac.mm
@@ -180,7 +180,6 @@ QCocoaTouch::getCurrentTouchPointList(NSEvent *event, bool acceptSingleTouch)
if (_touchCount != _currentTouches.size()) {
// Remove all instances, and basically start from scratch:
touchPoints.clear();
- QList<QCocoaTouch *> list = _currentTouches.values();
foreach (QCocoaTouch *qcocoaTouch, _currentTouches.values()) {
if (!_updateInternalStateOnly) {
qcocoaTouch->_touchPoint.setState(Qt::TouchPointReleased);
diff --git a/src/gui/kernel/qwidgetaction.cpp b/src/gui/kernel/qwidgetaction.cpp
index 7dc2c67..b72a41a 100644
--- a/src/gui/kernel/qwidgetaction.cpp
+++ b/src/gui/kernel/qwidgetaction.cpp
@@ -212,8 +212,8 @@ void QWidgetAction::releaseWidget(QWidget *widget)
if (!d->createdWidgets.contains(widget))
return;
- disconnect(widget, SIGNAL(destroyed(QObject *)),
- this, SLOT(_q_widgetDestroyed(QObject *)));
+ disconnect(widget, SIGNAL(destroyed(QObject*)),
+ this, SLOT(_q_widgetDestroyed(QObject*)));
d->createdWidgets.removeAll(widget);
deleteWidget(widget);
}
diff --git a/src/gui/painting/qblendfunctions.cpp b/src/gui/painting/qblendfunctions.cpp
index b92c5c2..1d15dac 100644
--- a/src/gui/painting/qblendfunctions.cpp
+++ b/src/gui/painting/qblendfunctions.cpp
@@ -739,10 +739,6 @@ template <typename T> void qt_scale_image_32bit(uchar *destPixels, int dbpl,
quint32 basex;
quint32 srcy;
- const int dstx = qCeil((tx1 + 0.5 - qMin(targetRect.left(), targetRect.right())) * ix) - 1;
- const int dsty = qCeil((ty1 + 0.5 - qMin(targetRect.top(), targetRect.bottom())) * iy) - 1;
-
-
if (sx < 0) {
int dstx = qFloor((tx1 + qreal(0.5) - targetRect.right()) * ix) + 1;
basex = quint32(srcRect.right() * 65536) + dstx;
diff --git a/src/gui/painting/qpaintbuffer.cpp b/src/gui/painting/qpaintbuffer.cpp
index b8700c3..51be3b3 100644
--- a/src/gui/painting/qpaintbuffer.cpp
+++ b/src/gui/painting/qpaintbuffer.cpp
@@ -1708,7 +1708,7 @@ void QPaintEngineExReplayer::process(const QPaintBufferCommand &cmd)
QPaintBufferResource::QPaintBufferResource(FreeFunc f, QObject *parent) : QObject(parent), free(f)
{
- connect(QPaintBufferSignalProxy::instance(), SIGNAL(aboutToDestroy(const QPaintBufferPrivate *)), this, SLOT(remove(const QPaintBufferPrivate *)));
+ connect(QPaintBufferSignalProxy::instance(), SIGNAL(aboutToDestroy(const QPaintBufferPrivate*)), this, SLOT(remove(const QPaintBufferPrivate*)));
}
QPaintBufferResource::~QPaintBufferResource()
diff --git a/src/gui/painting/qtextureglyphcache.cpp b/src/gui/painting/qtextureglyphcache.cpp
index a192e87..46fbaa9 100644
--- a/src/gui/painting/qtextureglyphcache.cpp
+++ b/src/gui/painting/qtextureglyphcache.cpp
@@ -101,7 +101,7 @@ void QTextureGlyphCache::populate(const QTextItemInt &ti,
Coord c = { 0, 0, // will be filled in later
glyph_width,
glyph_height, // texture coords
- metrics.x.truncate(),
+ metrics.x.round().truncate(),
-metrics.y.truncate() }; // baseline for horizontal scripts
listItemCoordinates.insert(glyph, c);
diff --git a/src/gui/styles/qs60style.cpp b/src/gui/styles/qs60style.cpp
index 7c3e11f..b5c0d4f 100644
--- a/src/gui/styles/qs60style.cpp
+++ b/src/gui/styles/qs60style.cpp
@@ -67,6 +67,7 @@
#include "qtoolbar.h"
#include "qtoolbutton.h"
#include "qfocusframe.h"
+#include "qformlayout.h"
#include "private/qtoolbarextension_p.h"
#include "private/qcombobox_p.h"
@@ -867,6 +868,13 @@ QSize QS60StylePrivate::partSize(QS60StyleEnums::SkinParts part, SkinElementFlag
return result;
}
+bool QS60StylePrivate::canDrawThemeBackground(const QBrush &backgroundBrush)
+{
+ //If brush is not changed from style's default values, draw theme graphics.
+ return (backgroundBrush.color() == Qt::transparent ||
+ backgroundBrush.style() == Qt::NoBrush) ? true : false;
+}
+
/*!
\class QS60Style
\brief The QS60Style class provides a look and feel suitable for applications on S60.
@@ -1380,8 +1388,10 @@ void QS60Style::drawControl(ControlElement element, const QStyleOption *option,
highlightRect = option->rect.adjusted(xBeginning, yBeginning, xEnd, yEnd);
}
if (vopt->showDecorationSelected &&
- (vopt->palette.highlight().color() == d->themePalette()->highlight().color()))
+ (vopt->palette.highlight().color() == QS60StylePrivate::themePalette()->highlight().color()))
QS60StylePrivate::drawSkinElement(QS60StylePrivate::SE_ListHighlight, painter, highlightRect, flags);
+ else
+ painter->fillRect(highlightRect, vopt->palette.highlight());
}
// draw the icon
@@ -1853,7 +1863,7 @@ void QS60Style::drawControl(ControlElement element, const QStyleOption *option,
case CE_ShapedFrame:
if (const QTextEdit *textEdit = qobject_cast<const QTextEdit *>(widget)) {
const QStyleOptionFrame *frame = qstyleoption_cast<const QStyleOptionFrame *>(option);
- if (frame->palette.base().color()==Qt::transparent)
+ if (QS60StylePrivate::canDrawThemeBackground(frame->palette.base()))
QS60StylePrivate::drawSkinElement(QS60StylePrivate::SE_Editor, painter, option->rect, flags);
else
QCommonStyle::drawControl(element, option, painter, widget);
@@ -1927,7 +1937,7 @@ void QS60Style::drawControl(ControlElement element, const QStyleOption *option,
if (option->state & State_Sunken && option->state & State_Enabled) {
painter->save();
painter->setOpacity(0.5);
- painter->setBrush(d->themePalette()->light());
+ painter->setBrush(QS60StylePrivate::themePalette()->light());
painter->setRenderHint(QPainter::Antialiasing);
const qreal roundRectRadius = 4 * goldenRatio;
painter->drawRoundedRect(option->rect, roundRectRadius, roundRectRadius);
@@ -1946,6 +1956,8 @@ void QS60Style::drawPrimitive(PrimitiveElement element, const QStyleOption *opti
{
Q_D(const QS60Style);
const QS60StylePrivate::SkinElementFlags flags = (option->state & State_Enabled) ? QS60StylePrivate::SF_StateEnabled : QS60StylePrivate::SF_StateDisabled;
+ bool commonStyleDraws = false;
+
switch (element) {
#ifndef QT_NO_LINEEDIT
case PE_PanelLineEdit:
@@ -1954,12 +1966,10 @@ void QS60Style::drawPrimitive(PrimitiveElement element, const QStyleOption *opti
if (widget && qobject_cast<const QComboBox *>(widget->parentWidget()))
break;
#endif
- QBrush editBrush = option->palette.brush(QPalette::Base);
- if (editBrush.color() == Qt::transparent)
- QS60StylePrivate::drawSkinElement(QS60StylePrivate::SE_FrameLineEdit,
- painter, option->rect, flags);
+ if (QS60StylePrivate::canDrawThemeBackground(option->palette.base()))
+ QS60StylePrivate::drawSkinElement(QS60StylePrivate::SE_FrameLineEdit, painter, option->rect, flags);
else
- QCommonStyle::drawPrimitive(element, option, painter, widget);
+ commonStyleDraws = true;
}
break;
#endif // QT_NO_LINEEDIT
@@ -1969,10 +1979,13 @@ void QS60Style::drawPrimitive(PrimitiveElement element, const QStyleOption *opti
const QS60StyleEnums::SkinParts skinPart = (option->state & QStyle::State_On) ?
QS60StyleEnums::SP_QgnIndiCheckboxOn : QS60StyleEnums::SP_QgnIndiCheckboxOff;
painter->save();
- QColor themeColor = d->s60Color(QS60StyleEnums::CL_QsnIconColors, 13, option);
- QColor buttonTextColor = option->palette.buttonText().color();
- if (themeColor != buttonTextColor)
- painter->setPen(buttonTextColor);
+
+ QColor themeColor = QS60StylePrivate::themePalette()->windowText().color();
+ QColor windowTextColor = option->palette.windowText().color();
+
+ if (themeColor != windowTextColor)
+ painter->setPen(windowTextColor);
+
QS60StylePrivate::drawSkinPart(skinPart, painter, option->rect, flags | QS60StylePrivate::SF_ColorSkinned );
painter->restore();
}
@@ -2019,6 +2032,8 @@ void QS60Style::drawPrimitive(PrimitiveElement element, const QStyleOption *opti
QColor buttonTextColor = option->palette.buttonText().color();
if (themeColor != buttonTextColor)
painter->setPen(buttonTextColor);
+ else
+ painter->setPen(themeColor);
// Draw radiobutton indicator as color skinned graphics.
QS60StyleEnums::SkinParts skinPart = (option->state & QStyle::State_On) ?
@@ -2032,14 +2047,13 @@ void QS60Style::drawPrimitive(PrimitiveElement element, const QStyleOption *opti
case PE_PanelButtonTool:
case PE_PanelButtonBevel:
case PE_FrameButtonBevel: {
- QBrush editBrush = option->palette.brush(QPalette::Base);
- if (editBrush.color() == Qt::transparent) {
+ if (QS60StylePrivate::canDrawThemeBackground(option->palette.base())) {
const bool isPressed = option->state & QStyle::State_Sunken;
const QS60StylePrivate::SkinElements skinElement =
isPressed ? QS60StylePrivate::SE_ButtonPressed : QS60StylePrivate::SE_ButtonNormal;
QS60StylePrivate::drawSkinElement(skinElement, painter, option->rect, flags);
} else {
- QCommonStyle::drawPrimitive(element, option, painter, widget);
+ commonStyleDraws = true;
}
}
break;
@@ -2067,7 +2081,7 @@ void QS60Style::drawPrimitive(PrimitiveElement element, const QStyleOption *opti
case PE_IndicatorSpinUp:
if (const QStyleOptionSpinBox *spinBox = qstyleoption_cast<const QStyleOptionSpinBox *>(option)) {
QStyleOptionSpinBox optionSpinBox = *spinBox;
- if (optionSpinBox.palette.base().color()==Qt::transparent) {
+ if (QS60StylePrivate::canDrawThemeBackground(optionSpinBox.palette.base())) {
const QS60StyleEnums::SkinParts part = (element == PE_IndicatorSpinUp) ?
QS60StyleEnums::SP_QgnGrafScrollArrowUp :
QS60StyleEnums::SP_QgnGrafScrollArrowDown;
@@ -2075,12 +2089,12 @@ void QS60Style::drawPrimitive(PrimitiveElement element, const QStyleOption *opti
optionSpinBox.rect.translate(0, (element == PE_IndicatorSpinDown) ? adjustment : -adjustment );
QS60StylePrivate::drawSkinPart(part, painter, optionSpinBox.rect,flags);
} else {
- QCommonStyle::drawPrimitive(element, &optionSpinBox, painter, widget);
+ commonStyleDraws = true;
}
}
#ifndef QT_NO_COMBOBOX
else if (const QStyleOptionFrame *cmb = qstyleoption_cast<const QStyleOptionFrame *>(option)) {
- if (cmb->palette.base().color()==Qt::transparent) {
+ if (QS60StylePrivate::canDrawThemeBackground( option->palette.base())) {
// We want to draw down arrow here for comboboxes as well.
const QS60StyleEnums::SkinParts part = QS60StyleEnums::SP_QgnGrafScrollArrowDown;
QStyleOptionFrame comboBox = *cmb;
@@ -2088,7 +2102,7 @@ void QS60Style::drawPrimitive(PrimitiveElement element, const QStyleOption *opti
comboBox.rect.translate(0, (element == PE_IndicatorSpinDown) ? adjustment : -adjustment );
QS60StylePrivate::drawSkinPart(part, painter, comboBox.rect,flags);
} else {
- QCommonStyle::drawPrimitive(element, cmb, painter, widget);
+ commonStyleDraws = true;
}
}
#endif //QT_NO_COMBOBOX
@@ -2119,12 +2133,10 @@ void QS60Style::drawPrimitive(PrimitiveElement element, const QStyleOption *opti
|| qobject_cast<const QMenu *> (widget)
#endif //QT_NO_MENU
) {
- if (option->palette.base().color()==Qt::transparent) {
- QS60StylePrivate::SkinElements skinElement = QS60StylePrivate::SE_OptionsMenu;
- QS60StylePrivate::drawSkinElement(skinElement, painter, option->rect, flags);
- } else {
- QCommonStyle::drawPrimitive(element, option, painter, widget);
- }
+ if (QS60StylePrivate::canDrawThemeBackground(option->palette.base()))
+ QS60StylePrivate::drawSkinElement(QS60StylePrivate::SE_OptionsMenu, painter, option->rect, flags);
+ else
+ commonStyleDraws = true;
}
break;
case PE_FrameWindow:
@@ -2256,6 +2268,9 @@ void QS60Style::drawPrimitive(PrimitiveElement element, const QStyleOption *opti
#endif //QT_NO_COLUMNVIEW
case PE_FrameTabBarBase: // since tabs are in S60 always in navipane, let's use common style for tab base in Qt.
default:
+ commonStyleDraws = true;
+ }
+ if (commonStyleDraws) {
QCommonStyle::drawPrimitive(element, option, painter, widget);
}
}
@@ -2387,6 +2402,9 @@ int QS60Style::styleHint(StyleHint sh, const QStyleOption *opt, const QWidget *w
case SH_RequestSoftwareInputPanel:
retValue = RSIP_OnMouseClickAndAlreadyFocused;
break;
+ case SH_FormLayoutWrapPolicy:
+ retValue = QFormLayout::WrapLongRows;
+ break;
default:
break;
}
diff --git a/src/gui/styles/qs60style_p.h b/src/gui/styles/qs60style_p.h
index cfe87ac..ea86bb2 100644
--- a/src/gui/styles/qs60style_p.h
+++ b/src/gui/styles/qs60style_p.h
@@ -453,6 +453,10 @@ public:
static QSize naviPaneSize();
+ //Checks that the current brush is transparent or has BrushStyle NoBrush,
+ //so that theme graphic background can be drawn.
+ static bool canDrawThemeBackground(const QBrush &backgroundBrush);
+
private:
static void drawPart(QS60StyleEnums::SkinParts part, QPainter *painter,
const QRect &rect, SkinElementFlags flags = KDefaultSkinElementFlags);
diff --git a/src/gui/styles/qwindowsstyle.cpp b/src/gui/styles/qwindowsstyle.cpp
index f894b82..30f2f35 100644
--- a/src/gui/styles/qwindowsstyle.cpp
+++ b/src/gui/styles/qwindowsstyle.cpp
@@ -2989,7 +2989,6 @@ void QWindowsStyle::drawComplexControl(ComplexControl cc, const QStyleOptionComp
#ifndef QT_NO_COMBOBOX
case CC_ComboBox:
if (const QStyleOptionComboBox *cmb = qstyleoption_cast<const QStyleOptionComboBox *>(opt)) {
- p->save();
QBrush editBrush = cmb->palette.brush(QPalette::Base);
if ((cmb->subControls & SC_ComboBoxFrame)) {
if (cmb->frame) {
@@ -3059,7 +3058,6 @@ void QWindowsStyle::drawComplexControl(ComplexControl cc, const QStyleOptionComp
proxy()->drawPrimitive(PE_FrameFocusRect, &focus, p, widget);
}
}
- p->restore();
}
break;
#endif // QT_NO_COMBOBOX
diff --git a/src/gui/text/qfontmetrics.cpp b/src/gui/text/qfontmetrics.cpp
index b8c1b33..3d3f1e1 100644
--- a/src/gui/text/qfontmetrics.cpp
+++ b/src/gui/text/qfontmetrics.cpp
@@ -1367,10 +1367,13 @@ qreal QFontMetricsF::rightBearing(QChar ch) const
*/
qreal QFontMetricsF::width(const QString &text) const
{
+ int pos = text.indexOf(QLatin1Char('\x9c'));
+ int len = (pos != -1) ? pos : text.length();
+
QTextEngine layout(text, d.data());
layout.ignoreBidi = true;
layout.itemize();
- return layout.width(0, text.length()).toReal();
+ return layout.width(0, len).toReal();
}
/*!
@@ -1587,7 +1590,7 @@ QRectF QFontMetricsF::boundingRect(const QRectF &rect, int flags, const QString&
*/
QSizeF QFontMetricsF::size(int flags, const QString &text, int tabStops, int *tabArray) const
{
- return boundingRect(QRectF(), flags, text, tabStops, tabArray).size();
+ return boundingRect(QRectF(), flags | Qt::TextLongestVariant, text, tabStops, tabArray).size();
}
/*!
@@ -1642,7 +1645,20 @@ QRectF QFontMetricsF::tightBoundingRect(const QString &text) const
*/
QString QFontMetricsF::elidedText(const QString &text, Qt::TextElideMode mode, qreal width, int flags) const
{
- QStackTextEngine engine(text, QFont(d.data()));
+ QString _text = text;
+ if (!(flags & Qt::TextLongestVariant)) {
+ int posA = 0;
+ int posB = _text.indexOf(QLatin1Char('\x9c'));
+ while (posB >= 0) {
+ QString portion = _text.mid(posA, posB - posA);
+ if (size(flags, portion).width() <= width)
+ return portion;
+ posA = posB + 1;
+ posB = _text.indexOf(QLatin1Char('\x9c'), posA);
+ }
+ _text = _text.mid(posA);
+ }
+ QStackTextEngine engine(_text, QFont(d.data()));
return engine.elidedText(mode, QFixed::fromReal(width), flags);
}
diff --git a/src/gui/widgets/qabstractslider.cpp b/src/gui/widgets/qabstractslider.cpp
index e0db9c2..988a7e7 100644
--- a/src/gui/widgets/qabstractslider.cpp
+++ b/src/gui/widgets/qabstractslider.cpp
@@ -219,6 +219,10 @@ QAbstractSliderPrivate::QAbstractSliderPrivate()
blocktracking(false), pressed(false),
invertedAppearance(false), invertedControls(false),
orientation(Qt::Horizontal), repeatAction(QAbstractSlider::SliderNoAction)
+#ifdef QT_KEYPAD_NAVIGATION
+ , isAutoRepeating(false)
+ , repeatMultiplier(1)
+#endif
{
}
@@ -371,6 +375,9 @@ int QAbstractSlider::maximum() const
abstract sliders provides and typically corresponds to the user
pressing an arrow key.
+ If the property is modified during an auto repeating key event, behavior
+ is undefined.
+
\sa pageStep
*/
@@ -598,10 +605,10 @@ void QAbstractSlider::triggerAction(SliderAction action)
d->blocktracking = true;
switch (action) {
case SliderSingleStepAdd:
- setSliderPosition(d->overflowSafeAdd(d->singleStep));
+ setSliderPosition(d->overflowSafeAdd(d->effectiveSingleStep()));
break;
case SliderSingleStepSub:
- setSliderPosition(d->overflowSafeAdd(-d->singleStep));
+ setSliderPosition(d->overflowSafeAdd(-d->effectiveSingleStep()));
break;
case SliderPageStepAdd:
setSliderPosition(d->overflowSafeAdd(d->pageStep));
@@ -702,7 +709,7 @@ void QAbstractSlider::wheelEvent(QWheelEvent * e)
// Calculate how many lines to scroll. Depending on what delta is (and
// offset), we might end up with a fraction (e.g. scroll 1.3 lines). We can
// only scroll whole lines, so we keep the reminder until next event.
- qreal stepsToScrollF = offset * QApplication::wheelScrollLines() * d->singleStep;
+ qreal stepsToScrollF = offset * QApplication::wheelScrollLines() * d->effectiveSingleStep();
// Check if wheel changed direction since last event:
if (d->offset_accumulated != 0 && (offset / d->offset_accumulated) < 0)
d->offset_accumulated = 0;
@@ -773,6 +780,38 @@ void QAbstractSlider::keyPressEvent(QKeyEvent *ev)
{
Q_D(QAbstractSlider);
SliderAction action = SliderNoAction;
+#ifdef QT_KEYPAD_NAVIGATION
+ if (ev->isAutoRepeat()) {
+ if (d->firstRepeat.isNull())
+ d->firstRepeat = QTime::currentTime();
+ else if (1 == d->repeatMultiplier) {
+ // This is the interval in milli seconds which one key repetition
+ // takes.
+ const int repeatMSecs = d->firstRepeat.msecsTo(QTime::currentTime());
+
+ /**
+ * The time it takes to currently navigate the whole slider.
+ */
+ const qreal currentTimeElapse = (qreal(maximum()) / singleStep()) * repeatMSecs;
+
+ /**
+ * This is an arbitrarily determined constant in msecs that
+ * specifies how long time it should take to navigate from the
+ * start to the end(excluding starting key auto repeat).
+ */
+ const int SliderRepeatElapse = 2500;
+
+ d->repeatMultiplier = currentTimeElapse / SliderRepeatElapse;
+ }
+
+ }
+ else if (!d->firstRepeat.isNull()) {
+ d->firstRepeat = QTime();
+ d->repeatMultiplier = 1;
+ }
+
+#endif
+
switch (ev->key()) {
#ifdef QT_KEYPAD_NAVIGATION
case Qt::Key_Select:
diff --git a/src/gui/widgets/qabstractslider_p.h b/src/gui/widgets/qabstractslider_p.h
index 9324d44..6591981 100644
--- a/src/gui/widgets/qabstractslider_p.h
+++ b/src/gui/widgets/qabstractslider_p.h
@@ -68,7 +68,13 @@ public:
void setSteps(int single, int page);
- int minimum, maximum, singleStep, pageStep, value, position, pressValue;
+ int minimum, maximum, pageStep, value, position, pressValue;
+
+ /**
+ * Call effectiveSingleStep() when changing the slider value.
+ */
+ int singleStep;
+
float offset_accumulated;
uint tracking : 1;
uint blocktracking :1;
@@ -83,8 +89,33 @@ public:
#ifdef QT_KEYPAD_NAVIGATION
int origValue;
+
+ /**
+ */
+ bool isAutoRepeating;
+
+ /**
+ * When we're auto repeating, we multiply singleStep with this value to
+ * get our effective step.
+ */
+ qreal repeatMultiplier;
+
+ /**
+ * The time of when the first auto repeating key press event occurs.
+ */
+ QTime firstRepeat;
+
#endif
+ inline int effectiveSingleStep() const
+ {
+ return singleStep
+#ifdef QT_KEYPAD_NAVIGATION
+ * repeatMultiplier
+#endif
+ ;
+ }
+
inline int bound(int val) const { return qMax(minimum, qMin(maximum, val)); }
inline int overflowSafeAdd(int add) const
{
diff --git a/src/gui/widgets/qcommandlinkbutton.cpp b/src/gui/widgets/qcommandlinkbutton.cpp
index 9adf280..8f47f25 100644
--- a/src/gui/widgets/qcommandlinkbutton.cpp
+++ b/src/gui/widgets/qcommandlinkbutton.cpp
@@ -326,7 +326,8 @@ int QCommandLinkButton::heightForWidth(int width) const
Q_D(const QCommandLinkButton);
int heightWithoutDescription = d->descriptionOffset() + d->bottomMargin();
// find the width available for the description area
- return heightWithoutDescription + d->descriptionHeight(width);
+ return qMax(heightWithoutDescription + d->descriptionHeight(width),
+ iconSize().height() + d->topMargin() + d->bottomMargin());
}
/*! \reimp */
diff --git a/src/gui/widgets/qlineedit.cpp b/src/gui/widgets/qlineedit.cpp
index 9f3fe4f..3800224 100644
--- a/src/gui/widgets/qlineedit.cpp
+++ b/src/gui/widgets/qlineedit.cpp
@@ -2004,38 +2004,48 @@ QMenu *QLineEdit::createStandardContextMenu()
Q_D(QLineEdit);
QMenu *popup = new QMenu(this);
popup->setObjectName(QLatin1String("qt_edit_menu"));
+ QAction *action = 0;
- QAction *action = popup->addAction(QLineEdit::tr("&Undo") + ACCEL_KEY(QKeySequence::Undo));
- action->setEnabled(d->control->isUndoAvailable());
- connect(action, SIGNAL(triggered()), SLOT(undo()));
+ if (!isReadOnly()) {
+ action = popup->addAction(QLineEdit::tr("&Undo") + ACCEL_KEY(QKeySequence::Undo));
+ action->setEnabled(d->control->isUndoAvailable());
+ connect(action, SIGNAL(triggered()), SLOT(undo()));
- action = popup->addAction(QLineEdit::tr("&Redo") + ACCEL_KEY(QKeySequence::Redo));
- action->setEnabled(d->control->isRedoAvailable());
- connect(action, SIGNAL(triggered()), SLOT(redo()));
+ action = popup->addAction(QLineEdit::tr("&Redo") + ACCEL_KEY(QKeySequence::Redo));
+ action->setEnabled(d->control->isRedoAvailable());
+ connect(action, SIGNAL(triggered()), SLOT(redo()));
- popup->addSeparator();
+ popup->addSeparator();
+ }
#ifndef QT_NO_CLIPBOARD
- action = popup->addAction(QLineEdit::tr("Cu&t") + ACCEL_KEY(QKeySequence::Cut));
- action->setEnabled(!d->control->isReadOnly() && d->control->hasSelectedText()
- && d->control->echoMode() == QLineEdit::Normal);
- connect(action, SIGNAL(triggered()), SLOT(cut()));
+ if (!isReadOnly()) {
+ action = popup->addAction(QLineEdit::tr("Cu&t") + ACCEL_KEY(QKeySequence::Cut));
+ action->setEnabled(!d->control->isReadOnly() && d->control->hasSelectedText()
+ && d->control->echoMode() == QLineEdit::Normal);
+ connect(action, SIGNAL(triggered()), SLOT(cut()));
+ }
action = popup->addAction(QLineEdit::tr("&Copy") + ACCEL_KEY(QKeySequence::Copy));
action->setEnabled(d->control->hasSelectedText()
&& d->control->echoMode() == QLineEdit::Normal);
connect(action, SIGNAL(triggered()), SLOT(copy()));
- action = popup->addAction(QLineEdit::tr("&Paste") + ACCEL_KEY(QKeySequence::Paste));
- action->setEnabled(!d->control->isReadOnly() && !QApplication::clipboard()->text().isEmpty());
- connect(action, SIGNAL(triggered()), SLOT(paste()));
+ if (!isReadOnly()) {
+ action = popup->addAction(QLineEdit::tr("&Paste") + ACCEL_KEY(QKeySequence::Paste));
+ action->setEnabled(!d->control->isReadOnly() && !QApplication::clipboard()->text().isEmpty());
+ connect(action, SIGNAL(triggered()), SLOT(paste()));
+ }
#endif
- action = popup->addAction(QLineEdit::tr("Delete"));
- action->setEnabled(!d->control->isReadOnly() && !d->control->text().isEmpty() && d->control->hasSelectedText());
- connect(action, SIGNAL(triggered()), d->control, SLOT(_q_deleteSelected()));
+ if (!isReadOnly()) {
+ action = popup->addAction(QLineEdit::tr("Delete"));
+ action->setEnabled(!d->control->isReadOnly() && !d->control->text().isEmpty() && d->control->hasSelectedText());
+ connect(action, SIGNAL(triggered()), d->control, SLOT(_q_deleteSelected()));
+ }
- popup->addSeparator();
+ if (!popup->isEmpty())
+ popup->addSeparator();
action = popup->addAction(QLineEdit::tr("Select All") + ACCEL_KEY(QKeySequence::SelectAll));
action->setEnabled(!d->control->text().isEmpty() && !d->control->allSelected());
diff --git a/src/gui/widgets/qlineedit_p.cpp b/src/gui/widgets/qlineedit_p.cpp
index 148da1b..d03c003 100644
--- a/src/gui/widgets/qlineedit_p.cpp
+++ b/src/gui/widgets/qlineedit_p.cpp
@@ -131,12 +131,12 @@ void QLineEditPrivate::init(const QString& txt)
Q_Q(QLineEdit);
control = new QLineControl(txt);
control->setFont(q->font());
- QObject::connect(control, SIGNAL(textChanged(const QString &)),
- q, SIGNAL(textChanged(const QString &)));
- QObject::connect(control, SIGNAL(textEdited(const QString &)),
- q, SLOT(_q_textEdited(const QString &)));
- QObject::connect(control, SIGNAL(cursorPositionChanged(int, int)),
- q, SLOT(_q_cursorPositionChanged(int, int)));
+ QObject::connect(control, SIGNAL(textChanged(QString)),
+ q, SIGNAL(textChanged(QString)));
+ QObject::connect(control, SIGNAL(textEdited(QString)),
+ q, SLOT(_q_textEdited(QString)));
+ QObject::connect(control, SIGNAL(cursorPositionChanged(int,int)),
+ q, SLOT(_q_cursorPositionChanged(int,int)));
QObject::connect(control, SIGNAL(selectionChanged()),
q, SIGNAL(selectionChanged()));
QObject::connect(control, SIGNAL(accepted()),
@@ -147,17 +147,17 @@ void QLineEditPrivate::init(const QString& txt)
QObject::connect(control, SIGNAL(editFocusChange(bool)),
q, SLOT(_q_editFocusChange(bool)));
#endif
- QObject::connect(control, SIGNAL(cursorPositionChanged(int, int)),
+ QObject::connect(control, SIGNAL(cursorPositionChanged(int,int)),
q, SLOT(updateMicroFocus()));
// for now, going completely overboard with updates.
QObject::connect(control, SIGNAL(selectionChanged()),
q, SLOT(update()));
- QObject::connect(control, SIGNAL(displayTextChanged(const QString &)),
+ QObject::connect(control, SIGNAL(displayTextChanged(QString)),
q, SLOT(update()));
- QObject::connect(control, SIGNAL(updateNeeded(const QRect &)),
+ QObject::connect(control, SIGNAL(updateNeeded(QRect)),
q, SLOT(update()));
QStyleOptionFrameV2 opt;
diff --git a/src/gui/widgets/qmdiarea.cpp b/src/gui/widgets/qmdiarea.cpp
index 60c5d7b..b3288c3 100644
--- a/src/gui/widgets/qmdiarea.cpp
+++ b/src/gui/widgets/qmdiarea.cpp
@@ -841,8 +841,8 @@ void QMdiAreaPrivate::appendChild(QMdiSubWindow *child)
child->installEventFilter(q);
QObject::connect(child, SIGNAL(aboutToActivate()), q, SLOT(_q_deactivateAllWindows()));
- QObject::connect(child, SIGNAL(windowStateChanged(Qt::WindowStates, Qt::WindowStates)),
- q, SLOT(_q_processWindowStateChanged(Qt::WindowStates, Qt::WindowStates)));
+ QObject::connect(child, SIGNAL(windowStateChanged(Qt::WindowStates,Qt::WindowStates)),
+ q, SLOT(_q_processWindowStateChanged(Qt::WindowStates,Qt::WindowStates)));
}
/*!
diff --git a/src/gui/widgets/qmdisubwindow.cpp b/src/gui/widgets/qmdisubwindow.cpp
index b5e28da..350f8579 100644
--- a/src/gui/widgets/qmdisubwindow.cpp
+++ b/src/gui/widgets/qmdisubwindow.cpp
@@ -2268,8 +2268,8 @@ QMdiSubWindow::QMdiSubWindow(QWidget *parent, Qt::WindowFlags flags)
else
d->menuIcon = windowIcon();
#endif
- connect(qApp, SIGNAL(focusChanged(QWidget *, QWidget *)),
- this, SLOT(_q_processFocusChanged(QWidget *, QWidget *)));
+ connect(qApp, SIGNAL(focusChanged(QWidget*,QWidget*)),
+ this, SLOT(_q_processFocusChanged(QWidget*,QWidget*)));
}
/*!
diff --git a/src/gui/widgets/qmenu.cpp b/src/gui/widgets/qmenu.cpp
index fc88d06..761a060 100644
--- a/src/gui/widgets/qmenu.cpp
+++ b/src/gui/widgets/qmenu.cpp
@@ -654,6 +654,24 @@ void QMenuPrivate::_q_overrideMenuActionDestroyed()
menuAction=defaultMenuAction;
}
+
+void QMenuPrivate::updateLayoutDirection()
+{
+ Q_Q(QMenu);
+ //we need to mimic the cause of the popup's layout direction
+ //to allow setting it on a mainwindow for example
+ //we call setLayoutDirection_helper to not overwrite a user-defined value
+ if (!q->testAttribute(Qt::WA_SetLayoutDirection)) {
+ if (QWidget *w = causedPopup.widget)
+ setLayoutDirection_helper(w->layoutDirection());
+ else if (QWidget *w = q->parentWidget())
+ setLayoutDirection_helper(w->layoutDirection());
+ else
+ setLayoutDirection_helper(QApplication::layoutDirection());
+ }
+}
+
+
/*!
Returns the action associated with this menu.
*/
@@ -1797,6 +1815,7 @@ void QMenu::popup(const QPoint &p, QAction *atAction)
d->tearoffHighlighted = 0;
d->motions = 0;
d->doChildEffects = true;
+ d->updateLayoutDirection();
#ifndef QT_NO_MENUBAR
// if this menu is part of a chain attached to a QMenuBar, set the
@@ -2347,6 +2366,9 @@ QMenu::event(QEvent *e)
{
Q_D(QMenu);
switch (e->type()) {
+ case QEvent::Polish:
+ d->updateLayoutDirection();
+ break;
case QEvent::ShortcutOverride: {
QKeyEvent *kev = static_cast<QKeyEvent*>(e);
if (kev->key() == Qt::Key_Up || kev->key() == Qt::Key_Down
diff --git a/src/gui/widgets/qmenu_p.h b/src/gui/widgets/qmenu_p.h
index c021063..5757885 100644
--- a/src/gui/widgets/qmenu_p.h
+++ b/src/gui/widgets/qmenu_p.h
@@ -292,6 +292,9 @@ public:
bool hasMouseMoved(const QPoint &globalPos);
+ void updateLayoutDirection();
+
+
//menu fading/scrolling effects
bool doChildEffects;
diff --git a/src/gui/widgets/qmenubar.cpp b/src/gui/widgets/qmenubar.cpp
index b1ff662..e50de02 100644
--- a/src/gui/widgets/qmenubar.cpp
+++ b/src/gui/widgets/qmenubar.cpp
@@ -1934,7 +1934,7 @@ void QMenuBar::setDefaultAction(QAction *act)
if (qt_wince_is_mobile())
if (d->defaultAction) {
disconnect(d->defaultAction, SIGNAL(changed()), this, SLOT(_q_updateDefaultAction()));
- disconnect(d->defaultAction, SIGNAL(destroyed ()), this, SLOT(_q_updateDefaultAction()));
+ disconnect(d->defaultAction, SIGNAL(destroyed()), this, SLOT(_q_updateDefaultAction()));
}
#endif
d->defaultAction = act;
diff --git a/src/gui/widgets/qsizegrip.cpp b/src/gui/widgets/qsizegrip.cpp
index cf193dc..6575dbb 100644
--- a/src/gui/widgets/qsizegrip.cpp
+++ b/src/gui/widgets/qsizegrip.cpp
@@ -99,6 +99,7 @@ public:
int dyMax;
Qt::Corner m_corner;
bool gotMousePress;
+ QWidget *tlw;
#ifdef Q_WS_MAC
void updateMacSizer(bool hide) const;
#endif
@@ -113,6 +114,19 @@ public:
return m_corner == Qt::BottomLeftCorner || m_corner == Qt::TopLeftCorner;
}
+ void updateTopLevelWidget()
+ {
+ Q_Q(QSizeGrip);
+ QWidget *w = qt_sizegrip_topLevelWidget(q);
+ if (tlw == w)
+ return;
+ if (tlw)
+ tlw->removeEventFilter(q);
+ tlw = w;
+ if (tlw)
+ tlw->installEventFilter(q);
+ }
+
// This slot is invoked by QLayout when the size grip is added to
// a layout or reparented after the tlw is shown. This re-implementation is basically
// the same as QWidgetPrivate::_q_showIfNotHidden except that it checks
@@ -121,7 +135,7 @@ public:
{
Q_Q(QSizeGrip);
bool showSizeGrip = !(q->isHidden() && q->testAttribute(Qt::WA_WState_ExplicitShowHide));
- QWidget *tlw = qt_sizegrip_topLevelWidget(q);
+ updateTopLevelWidget();
if (tlw && showSizeGrip) {
Qt::WindowStates sizeGripNotVisibleState = Qt::WindowFullScreen;
#ifndef Q_WS_MAC
@@ -232,6 +246,7 @@ void QSizeGripPrivate::init()
Q_Q(QSizeGrip);
dxMax = 0;
dyMax = 0;
+ tlw = 0;
m_corner = q->isLeftToRight() ? Qt::BottomRightCorner : Qt::BottomLeftCorner;
gotMousePress = false;
@@ -240,8 +255,7 @@ void QSizeGripPrivate::init()
? Qt::SizeFDiagCursor : Qt::SizeBDiagCursor);
#endif
q->setSizePolicy(QSizePolicy(QSizePolicy::Minimum, QSizePolicy::Fixed));
- QWidget *tlw = qt_sizegrip_topLevelWidget(q);
- tlw->installEventFilter(q);
+ updateTopLevelWidget();
}
@@ -524,19 +538,18 @@ void QSizeGrip::setVisible(bool visible)
/*! \reimp */
bool QSizeGrip::eventFilter(QObject *o, QEvent *e)
{
+ Q_D(QSizeGrip);
if ((isHidden() && testAttribute(Qt::WA_WState_ExplicitShowHide))
- || e->type() != QEvent::WindowStateChange) {
+ || e->type() != QEvent::WindowStateChange
+ || o != d->tlw) {
return QWidget::eventFilter(o, e);
}
- QWidget *tlw = qt_sizegrip_topLevelWidget(this);
- if (o != tlw)
- return QWidget::eventFilter(o, e);
Qt::WindowStates sizeGripNotVisibleState = Qt::WindowFullScreen;
#ifndef Q_WS_MAC
sizeGripNotVisibleState |= Qt::WindowMaximized;
#endif
// Don't show the size grip if the tlw is maximized or in full screen mode.
- setVisible(!(tlw->windowState() & sizeGripNotVisibleState));
+ setVisible(!(d->tlw->windowState() & sizeGripNotVisibleState));
setAttribute(Qt::WA_WState_ExplicitShowHide, false);
return QWidget::eventFilter(o, e);
}
diff --git a/src/gui/widgets/qtabwidget.cpp b/src/gui/widgets/qtabwidget.cpp
index d22bd54..49651a3 100644
--- a/src/gui/widgets/qtabwidget.cpp
+++ b/src/gui/widgets/qtabwidget.cpp
@@ -699,8 +699,8 @@ void QTabWidget::setTabBar(QTabBar* tb)
setFocusProxy(d->tabs);
connect(d->tabs, SIGNAL(currentChanged(int)),
this, SLOT(_q_showTab(int)));
- connect(d->tabs, SIGNAL(tabMoved(int, int)),
- this, SLOT(_q_tabMoved(int, int)));
+ connect(d->tabs, SIGNAL(tabMoved(int,int)),
+ this, SLOT(_q_tabMoved(int,int)));
if (d->tabs->tabsClosable())
connect(d->tabs, SIGNAL(tabCloseRequested(int)),
this, SIGNAL(tabCloseRequested(int)));
diff --git a/src/network/access/qhttp.cpp b/src/network/access/qhttp.cpp
index f006fba..7365435 100644
--- a/src/network/access/qhttp.cpp
+++ b/src/network/access/qhttp.cpp
@@ -3115,14 +3115,14 @@ void QHttpPrivate::setSock(QTcpSocket *sock)
QObject::connect(socket, SIGNAL(bytesWritten(qint64)),
q, SLOT(_q_slotBytesWritten(qint64)));
#ifndef QT_NO_NETWORKPROXY
- QObject::connect(socket, SIGNAL(proxyAuthenticationRequired(const QNetworkProxy &, QAuthenticator *)),
- q, SIGNAL(proxyAuthenticationRequired(const QNetworkProxy &, QAuthenticator *)));
+ QObject::connect(socket, SIGNAL(proxyAuthenticationRequired(QNetworkProxy,QAuthenticator*)),
+ q, SIGNAL(proxyAuthenticationRequired(QNetworkProxy,QAuthenticator*)));
#endif
#ifndef QT_NO_OPENSSL
if (qobject_cast<QSslSocket *>(socket)) {
- QObject::connect(socket, SIGNAL(sslErrors(const QList<QSslError> &)),
- q, SIGNAL(sslErrors(const QList<QSslError> &)));
+ QObject::connect(socket, SIGNAL(sslErrors(QList<QSslError>)),
+ q, SIGNAL(sslErrors(QList<QSslError>)));
QObject::connect(socket, SIGNAL(encryptedBytesWritten(qint64)),
q, SLOT(_q_slotEncryptedBytesWritten(qint64)));
}
diff --git a/src/network/access/qhttpnetworkconnectionchannel.cpp b/src/network/access/qhttpnetworkconnectionchannel.cpp
index 6962ab3..fa89fcc 100644
--- a/src/network/access/qhttpnetworkconnectionchannel.cpp
+++ b/src/network/access/qhttpnetworkconnectionchannel.cpp
@@ -90,8 +90,8 @@ void QHttpNetworkConnectionChannel::init()
this, SLOT(_q_error(QAbstractSocket::SocketError)),
Qt::DirectConnection);
#ifndef QT_NO_NETWORKPROXY
- QObject::connect(socket, SIGNAL(proxyAuthenticationRequired(const QNetworkProxy&, QAuthenticator*)),
- this, SLOT(_q_proxyAuthenticationRequired(const QNetworkProxy&, QAuthenticator*)),
+ QObject::connect(socket, SIGNAL(proxyAuthenticationRequired(QNetworkProxy,QAuthenticator*)),
+ this, SLOT(_q_proxyAuthenticationRequired(QNetworkProxy,QAuthenticator*)),
Qt::DirectConnection);
#endif
@@ -102,8 +102,8 @@ void QHttpNetworkConnectionChannel::init()
QObject::connect(sslSocket, SIGNAL(encrypted()),
this, SLOT(_q_encrypted()),
Qt::DirectConnection);
- QObject::connect(sslSocket, SIGNAL(sslErrors(const QList<QSslError>&)),
- this, SLOT(_q_sslErrors(const QList<QSslError>&)),
+ QObject::connect(sslSocket, SIGNAL(sslErrors(QList<QSslError>)),
+ this, SLOT(_q_sslErrors(QList<QSslError>)),
Qt::DirectConnection);
QObject::connect(sslSocket, SIGNAL(encryptedBytesWritten(qint64)),
this, SLOT(_q_encryptedBytesWritten(qint64)),
@@ -774,6 +774,8 @@ void QHttpNetworkConnectionChannel::_q_connected()
{
// improve performance since we get the request sent by the kernel ASAP
socket->setSocketOption(QAbstractSocket::LowDelayOption, 1);
+ // not sure yet if it helps, but it makes sense
+ socket->setSocketOption(QAbstractSocket::KeepAliveOption, 1);
pipeliningSupported = QHttpNetworkConnectionChannel::PipeliningSupportUnknown;
diff --git a/src/network/socket/qnativesocketengine.cpp b/src/network/socket/qnativesocketengine.cpp
index ecf5ad9..5d17022 100644
--- a/src/network/socket/qnativesocketengine.cpp
+++ b/src/network/socket/qnativesocketengine.cpp
@@ -876,7 +876,7 @@ bool QNativeSocketEngine::waitForRead(int msecs, bool *timedOut)
*/
bool QNativeSocketEngine::waitForWrite(int msecs, bool *timedOut)
{
- Q_D(const QNativeSocketEngine);
+ Q_D(QNativeSocketEngine);
Q_CHECK_VALID_SOCKETLAYER(QNativeSocketEngine::waitForWrite(), false);
Q_CHECK_NOT_STATE(QNativeSocketEngine::waitForWrite(),
QAbstractSocket::UnconnectedState, false);
@@ -893,6 +893,24 @@ bool QNativeSocketEngine::waitForWrite(int msecs, bool *timedOut)
setState(QAbstractSocket::ConnectedState);
d_func()->fetchConnectionParameters();
return true;
+ } else {
+ int value = 0;
+ int valueSize = sizeof(value);
+ if (::getsockopt(d->socketDescriptor, SOL_SOCKET, SO_ERROR, (char *) &value, &valueSize) == 0) {
+ if (value == WSAECONNREFUSED) {
+ d->setError(QAbstractSocket::ConnectionRefusedError, QNativeSocketEnginePrivate::ConnectionRefusedErrorString);
+ d->socketState = QAbstractSocket::UnconnectedState;
+ return false;
+ } else if (value == WSAETIMEDOUT) {
+ d->setError(QAbstractSocket::NetworkError, QNativeSocketEnginePrivate::ConnectionTimeOutErrorString);
+ d->socketState = QAbstractSocket::UnconnectedState;
+ return false;
+ } else if (value == WSAEHOSTUNREACH) {
+ d->setError(QAbstractSocket::NetworkError, QNativeSocketEnginePrivate::HostUnreachableErrorString);
+ d->socketState = QAbstractSocket::UnconnectedState;
+ return false;
+ }
+ }
}
#endif
@@ -913,7 +931,7 @@ bool QNativeSocketEngine::waitForReadOrWrite(bool *readyToRead, bool *readyToWri
bool checkRead, bool checkWrite,
int msecs, bool *timedOut)
{
- Q_D(const QNativeSocketEngine);
+ Q_D(QNativeSocketEngine);
Q_CHECK_VALID_SOCKETLAYER(QNativeSocketEngine::waitForWrite(), false);
Q_CHECK_NOT_STATE(QNativeSocketEngine::waitForReadOrWrite(),
QAbstractSocket::UnconnectedState, false);
@@ -927,6 +945,24 @@ bool QNativeSocketEngine::waitForReadOrWrite(bool *readyToRead, bool *readyToWri
setState(QAbstractSocket::ConnectedState);
d_func()->fetchConnectionParameters();
return true;
+ } else {
+ int value = 0;
+ int valueSize = sizeof(value);
+ if (::getsockopt(d->socketDescriptor, SOL_SOCKET, SO_ERROR, (char *) &value, &valueSize) == 0) {
+ if (value == WSAECONNREFUSED) {
+ d->setError(QAbstractSocket::ConnectionRefusedError, QNativeSocketEnginePrivate::ConnectionRefusedErrorString);
+ d->socketState = QAbstractSocket::UnconnectedState;
+ return false;
+ } else if (value == WSAETIMEDOUT) {
+ d->setError(QAbstractSocket::NetworkError, QNativeSocketEnginePrivate::ConnectionTimeOutErrorString);
+ d->socketState = QAbstractSocket::UnconnectedState;
+ return false;
+ } else if (value == WSAEHOSTUNREACH) {
+ d->setError(QAbstractSocket::NetworkError, QNativeSocketEnginePrivate::HostUnreachableErrorString);
+ d->socketState = QAbstractSocket::UnconnectedState;
+ return false;
+ }
+ }
}
#endif
if (ret == 0) {
diff --git a/src/network/socket/qnativesocketengine_win.cpp b/src/network/socket/qnativesocketengine_win.cpp
index 63fe78e..91f930a 100644
--- a/src/network/socket/qnativesocketengine_win.cpp
+++ b/src/network/socket/qnativesocketengine_win.cpp
@@ -1107,10 +1107,22 @@ int QNativeSocketEnginePrivate::nativeSelect(int timeout, bool selectForRead) co
tv.tv_sec = timeout / 1000;
tv.tv_usec = (timeout % 1000) * 1000;
- if (selectForRead)
+ if (selectForRead) {
ret = select(0, &fds, 0, 0, timeout < 0 ? 0 : &tv);
- else
- ret = select(0, 0, &fds, 0, timeout < 0 ? 0 : &tv);
+ } else {
+ // select for write
+
+ // Windows needs this to report errors when connecting a socket ...
+ fd_set fdexception;
+ FD_ZERO(&fdexception);
+ FD_SET(socketDescriptor, &fdexception);
+
+ ret = select(0, 0, &fds, &fdexception, timeout < 0 ? 0 : &tv);
+
+ // ... but if it is actually set, pretend it did not happen
+ if (ret > 0 && FD_ISSET(socketDescriptor, &fdexception))
+ ret--;
+ }
if (readEnabled)
readNotifier->setEnabled(true);
@@ -1125,9 +1137,10 @@ int QNativeSocketEnginePrivate::nativeSelect(int timeout,
bool readEnabled = checkRead && readNotifier && readNotifier->isEnabled();
if (readEnabled)
readNotifier->setEnabled(false);
-
+
fd_set fdread;
fd_set fdwrite;
+ fd_set fdexception;
int ret = 0;
@@ -1137,9 +1150,13 @@ int QNativeSocketEnginePrivate::nativeSelect(int timeout,
fdread.fd_array[0] = socketDescriptor;
}
memset(&fdwrite, 0, sizeof(fd_set));
+ FD_ZERO(&fdexception);
if (checkWrite) {
fdwrite.fd_count = 1;
fdwrite.fd_array[0] = socketDescriptor;
+
+ // Windows needs this to report errors when connecting a socket
+ FD_SET(socketDescriptor, &fdexception);
}
struct timeval tv;
@@ -1147,10 +1164,15 @@ int QNativeSocketEnginePrivate::nativeSelect(int timeout,
tv.tv_usec = (timeout % 1000) * 1000;
#if !defined(Q_OS_WINCE)
- ret = select(socketDescriptor + 1, &fdread, &fdwrite, 0, timeout < 0 ? 0 : &tv);
+ ret = select(socketDescriptor + 1, &fdread, &fdwrite, &fdexception, timeout < 0 ? 0 : &tv);
#else
- ret = select(1, &fdread, &fdwrite, 0, timeout < 0 ? 0 : &tv);
+ ret = select(1, &fdread, &fdwrite, &fdexception, timeout < 0 ? 0 : &tv);
#endif
+
+ //... but if it is actually set, pretend it did not happen
+ if (ret > 0 && FD_ISSET(socketDescriptor, &fdexception))
+ ret--;
+
if (readEnabled)
readNotifier->setEnabled(true);
diff --git a/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp b/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp
index 8c5bf0e..823f919 100644
--- a/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp
+++ b/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp
@@ -158,8 +158,8 @@ QGLTextureGlyphCache::QGLTextureGlyphCache(QGLContext *context, QFontEngineGlyph
, m_height(0)
{
glGenFramebuffers(1, &m_fbo);
- connect(QGLSignalProxy::instance(), SIGNAL(aboutToDestroyContext(const QGLContext *)),
- SLOT(contextDestroyed(const QGLContext *)));
+ connect(QGLSignalProxy::instance(), SIGNAL(aboutToDestroyContext(const QGLContext*)),
+ SLOT(contextDestroyed(const QGLContext*)));
}
QGLTextureGlyphCache::~QGLTextureGlyphCache()
diff --git a/src/opengl/qpaintengine_opengl.cpp b/src/opengl/qpaintengine_opengl.cpp
index aa6b6c9..8ab17a0 100644
--- a/src/opengl/qpaintengine_opengl.cpp
+++ b/src/opengl/qpaintengine_opengl.cpp
@@ -248,8 +248,8 @@ public:
bound(false)
{
connect(QGLSignalProxy::instance(),
- SIGNAL(aboutToDestroyContext(const QGLContext *)),
- SLOT(cleanupGLContextRefs(const QGLContext *)));
+ SIGNAL(aboutToDestroyContext(const QGLContext*)),
+ SLOT(cleanupGLContextRefs(const QGLContext*)));
}
inline void setDevice(QPaintDevice *pdev);
@@ -525,8 +525,8 @@ public:
QGLProgramCache() {
// we have to know when a context is deleted so we can free
// any program handles it holds
- connect(QGLSignalProxy::instance(), SIGNAL(aboutToDestroyContext(const QGLContext *)),
- SLOT(cleanupPrograms(const QGLContext *)));
+ connect(QGLSignalProxy::instance(), SIGNAL(aboutToDestroyContext(const QGLContext*)),
+ SLOT(cleanupPrograms(const QGLContext*)));
}
~QGLProgramCache() {
@@ -639,8 +639,8 @@ public:
: p(priv)
{
connect(QGLSignalProxy::instance(),
- SIGNAL(aboutToDestroyContext(const QGLContext *)),
- SLOT(cleanupGLContextRefs(const QGLContext *)));
+ SIGNAL(aboutToDestroyContext(const QGLContext*)),
+ SLOT(cleanupGLContextRefs(const QGLContext*)));
}
public Q_SLOTS:
@@ -1010,8 +1010,8 @@ public:
QGLGradientCache() : QObject(), buffer_ctx(0)
{
connect(QGLSignalProxy::instance(),
- SIGNAL(aboutToDestroyContext(const QGLContext *)),
- SLOT(cleanupGLContextRefs(const QGLContext *)));
+ SIGNAL(aboutToDestroyContext(const QGLContext*)),
+ SLOT(cleanupGLContextRefs(const QGLContext*)));
}
inline GLuint getBuffer(const QGradient &gradient, qreal opacity, QGLContext *ctx) {
@@ -4712,8 +4712,8 @@ void QGLGlyphCache::cacheGlyphs(QGLContext *context, const QTextItemInt &ti,
QWidget *widget = static_cast<QWidget *>(context->device());
connect(widget, SIGNAL(destroyed(QObject*)), SLOT(widgetDestroyed(QObject*)));
connect(QGLSignalProxy::instance(),
- SIGNAL(aboutToDestroyContext(const QGLContext *)),
- SLOT(cleanupContext(const QGLContext *)));
+ SIGNAL(aboutToDestroyContext(const QGLContext*)),
+ SLOT(cleanupContext(const QGLContext*)));
}
} else {
font_cache = dev_it.value();
diff --git a/src/opengl/qwindowsurface_gl.cpp b/src/opengl/qwindowsurface_gl.cpp
index f1f5976..e353f5d 100644
--- a/src/opengl/qwindowsurface_gl.cpp
+++ b/src/opengl/qwindowsurface_gl.cpp
@@ -374,7 +374,7 @@ void QGLWindowSurface::hijackWindow(QWidget *widget)
union { QGLContext **ctxPtr; void **voidPtr; };
- connect(widget, SIGNAL(destroyed(QObject *)), this, SLOT(deleted(QObject *)));
+ connect(widget, SIGNAL(destroyed(QObject*)), this, SLOT(deleted(QObject*)));
voidPtr = &widgetPrivate->extraData()->glContext;
d_ptr->contexts << ctxPtr;
diff --git a/src/openvg/qpixmapdata_vg.cpp b/src/openvg/qpixmapdata_vg.cpp
index 3254aa3..19c90ed 100644
--- a/src/openvg/qpixmapdata_vg.cpp
+++ b/src/openvg/qpixmapdata_vg.cpp
@@ -92,7 +92,6 @@ QVGPixmapData::~QVGPixmapData()
vgDestroyImage(vgImage);
if (vgImageOpacity != VG_INVALID_HANDLE)
vgDestroyImage(vgImageOpacity);
- } else {
#endif
}
#if !defined(QT_NO_EGL)
@@ -202,6 +201,14 @@ QPaintEngine* QVGPixmapData::paintEngine() const
return source.paintEngine();
}
+// This function works around QImage::bits() making a deep copy if the
+// QImage is not const. We force it to be const and then get the bits.
+// XXX: Should add a QImage::constBits() in the future to replace this.
+static inline const uchar *qt_vg_imageBits(const QImage& image)
+{
+ return image.bits();
+}
+
VGImage QVGPixmapData::toVGImage()
{
if (!isValid())
@@ -213,7 +220,7 @@ VGImage QVGPixmapData::toVGImage()
context = qt_vg_create_context(0);
#endif
- if (recreate) {
+ if (recreate && prevSize != QSize(w, h)) {
if (vgImage != VG_INVALID_HANDLE) {
vgDestroyImage(vgImage);
vgImage = VG_INVALID_HANDLE;
@@ -222,6 +229,8 @@ VGImage QVGPixmapData::toVGImage()
vgDestroyImage(vgImageOpacity);
vgImageOpacity = VG_INVALID_HANDLE;
}
+ } else if (recreate) {
+ cachedOpacity = -1.0f; // Force opacity image to be refreshed later.
}
if (vgImage == VG_INVALID_HANDLE) {
@@ -232,11 +241,12 @@ VGImage QVGPixmapData::toVGImage()
if (!source.isNull() && recreate) {
vgImageSubData
(vgImage,
- source.bits(), source.bytesPerLine(),
+ qt_vg_imageBits(source), source.bytesPerLine(),
VG_sARGB_8888_PRE, 0, 0, w, h);
}
recreate = false;
+ prevSize = QSize(w, h);
return vgImage;
}
@@ -244,43 +254,14 @@ VGImage QVGPixmapData::toVGImage()
VGImage QVGPixmapData::toVGImage(qreal opacity)
{
#if !defined(QT_SHIVAVG)
- if (!isValid())
+ // Force the primary VG image to be recreated if necessary.
+ if (toVGImage() == VG_INVALID_HANDLE)
return VG_INVALID_HANDLE;
-#if !defined(QT_NO_EGL)
- // Increase the reference count on the shared context.
- if (!context)
- context = qt_vg_create_context(0);
-#endif
-
- if (recreate) {
- if (vgImage != VG_INVALID_HANDLE) {
- vgDestroyImage(vgImage);
- vgImage = VG_INVALID_HANDLE;
- }
- if (vgImageOpacity != VG_INVALID_HANDLE) {
- vgDestroyImage(vgImageOpacity);
- vgImageOpacity = VG_INVALID_HANDLE;
- }
- }
-
- if (vgImage == VG_INVALID_HANDLE) {
- vgImage = vgCreateImage
- (VG_sARGB_8888_PRE, w, h, VG_IMAGE_QUALITY_FASTER);
- }
-
- if (!source.isNull() && recreate) {
- vgImageSubData
- (vgImage,
- source.bits(), source.bytesPerLine(),
- VG_sARGB_8888_PRE, 0, 0, w, h);
- }
-
- recreate = false;
-
if (opacity == 1.0f)
return vgImage;
+ // Create an alternative image for the selected opacity.
if (vgImageOpacity == VG_INVALID_HANDLE || cachedOpacity != opacity) {
if (vgImageOpacity == VG_INVALID_HANDLE) {
vgImageOpacity = vgCreateImage
@@ -405,6 +386,7 @@ void QVGPixmapData::fromNativeType(void* pixmap, NativeType type)
vgDestroyImage(vgImageOpacity);
vgImageOpacity = VG_INVALID_HANDLE;
}
+ prevSize = QSize();
TInt err = 0;
@@ -465,6 +447,7 @@ void QVGPixmapData::fromNativeType(void* pixmap, NativeType type)
is_null = (w <= 0 || h <= 0);
source = QImage();
recreate = false;
+ prevSize = QSize(w, h);
setSerialNumber(++qt_vg_pixmap_serial);
// release stuff
eglDestroyImageKHR(context->display(), eglImage);
diff --git a/src/openvg/qpixmapdata_vg_p.h b/src/openvg/qpixmapdata_vg_p.h
index f6fac88..fe19f35 100644
--- a/src/openvg/qpixmapdata_vg_p.h
+++ b/src/openvg/qpixmapdata_vg_p.h
@@ -109,6 +109,7 @@ protected:
#endif
protected:
+ QSize prevSize;
VGImage vgImage;
VGImage vgImageOpacity;
qreal cachedOpacity;
diff --git a/src/plugins/gfxdrivers/directfb/qdirectfbscreen.cpp b/src/plugins/gfxdrivers/directfb/qdirectfbscreen.cpp
index eb771ba..4cb0184 100644
--- a/src/plugins/gfxdrivers/directfb/qdirectfbscreen.cpp
+++ b/src/plugins/gfxdrivers/directfb/qdirectfbscreen.cpp
@@ -131,8 +131,8 @@ QDirectFBScreenPrivate::QDirectFBScreenPrivate(QDirectFBScreen *qptr)
QWSSignalHandler::instance()->addObject(this);
#endif
#ifdef QT_DIRECTFB_WM
- connect(QWSServer::instance(), SIGNAL(windowEvent(QWSWindow*, QWSServer::WindowEvent)),
- this, SLOT(onWindowEvent(QWSWindow*, QWSServer::WindowEvent)));
+ connect(QWSServer::instance(), SIGNAL(windowEvent(QWSWindow*,QWSServer::WindowEvent)),
+ this, SLOT(onWindowEvent(QWSWindow*,QWSServer::WindowEvent)));
#endif
}
diff --git a/src/plugins/phonon/mmf/mmf.pro b/src/plugins/phonon/mmf/mmf.pro
index c070605..854f893 100644
--- a/src/plugins/phonon/mmf/mmf.pro
+++ b/src/plugins/phonon/mmf/mmf.pro
@@ -39,7 +39,7 @@ HEADERS += \
$$PHONON_MMF_DIR/mmf_medianode.h \
$$PHONON_MMF_DIR/mmf_videoplayer.h \
$$PHONON_MMF_DIR/objectdump.h \
- $$PHONON_MMF_DIR/objectdump_global.h \
+ $$PHONON_MMF_DIR/objectdump_symbian.h \
$$PHONON_MMF_DIR/objecttree.h \
$$PHONON_MMF_DIR/utils.h \
$$PHONON_MMF_DIR/videooutput.h \
@@ -61,14 +61,12 @@ SOURCES += \
$$PHONON_MMF_DIR/mmf_medianode.cpp \
$$PHONON_MMF_DIR/mmf_videoplayer.cpp \
$$PHONON_MMF_DIR/objectdump.cpp \
+ $$PHONON_MMF_DIR/objectdump_symbian.cpp \
$$PHONON_MMF_DIR/objecttree.cpp \
$$PHONON_MMF_DIR/utils.cpp \
$$PHONON_MMF_DIR/videooutput.cpp \
$$PHONON_MMF_DIR/videowidget.cpp
-HEADERS += $$PHONON_MMF_DIR/objectdump_symbian.h
-SOURCES += $$PHONON_MMF_DIR/objectdump_symbian.cpp
-
LIBS += -lcone
LIBS += -lws32
diff --git a/src/qt3support/dialogs/q3filedialog.cpp b/src/qt3support/dialogs/q3filedialog.cpp
index c14ff5c..22bec63 100644
--- a/src/qt3support/dialogs/q3filedialog.cpp
+++ b/src/qt3support/dialogs/q3filedialog.cpp
@@ -116,8 +116,6 @@
QT_BEGIN_NAMESPACE
-#ifndef QT_MAC_USE_COCOA
-
/* XPM */
static const char * const start_xpm[]={
"16 15 8 1",
@@ -6053,8 +6051,7 @@ Q3FilePreview::Q3FilePreview()
function to provide file previewing.
*/
-#endif // QT_MAC_USE_COCOA
-
+
QT_END_NAMESPACE
#include "moc_q3filedialog.cpp"
diff --git a/src/qt3support/dialogs/q3filedialog.h b/src/qt3support/dialogs/q3filedialog.h
index 8644b4c..f6a7950 100644
--- a/src/qt3support/dialogs/q3filedialog.h
+++ b/src/qt3support/dialogs/q3filedialog.h
@@ -69,8 +69,6 @@ class QUrlInfo;
#ifndef QT_NO_FILEDIALOG
-#ifndef QT_MAC_USE_COCOA
-
class Q_COMPAT_EXPORT Q3FileIconProvider : public QObject
{
Q_OBJECT
@@ -339,8 +337,6 @@ private:
#endif
};
-#endif // QT_MAC_USE_COCOA
-
#endif // QT_NO_FILEDIALOG
QT_END_NAMESPACE
diff --git a/src/qt3support/dialogs/q3filedialog_mac.cpp b/src/qt3support/dialogs/q3filedialog_mac.cpp
index 585fa8f..6c5675b 100644
--- a/src/qt3support/dialogs/q3filedialog_mac.cpp
+++ b/src/qt3support/dialogs/q3filedialog_mac.cpp
@@ -56,11 +56,32 @@
#include "qstringlist.h"
#include "qtextcodec.h"
#include "qdesktopwidget.h"
+#include "qfiledialog.h"
#include <stdlib.h>
QT_BEGIN_NAMESPACE
-#ifndef QT_MAC_USE_COCOA
+#ifdef QT_MAC_USE_COCOA
+
+QStringList Q3FileDialog::macGetOpenFileNames(const QString &filter, QString *pwd,
+ QWidget *parent, const char* /*name*/,
+ const QString& caption, QString *selectedFilter,
+ bool /*multi*/, bool /*directory*/)
+{
+ return QFileDialog::getOpenFileNames(filter, *pwd, parent, 0,
+ caption);
+}
+
+
+QString Q3FileDialog::macGetSaveFileName(const QString &start, const QString &filter,
+ QString *, QWidget *parent, const char* /*name*/,
+ const QString& caption, QString *selectedFilter)
+{
+ return QFileDialog::getSaveFileName(start, filter, parent, 0,
+ caption, selectedFilter);
+}
+
+#else
/*****************************************************************************
Externals
diff --git a/src/s60installs/bwins/QtCoreu.def b/src/s60installs/bwins/QtCoreu.def
index 1218b75..49c4361 100644
--- a/src/s60installs/bwins/QtCoreu.def
+++ b/src/s60installs/bwins/QtCoreu.def
@@ -4387,4 +4387,15 @@ EXPORTS
?QBasicAtomicPointer_isFetchAndAddNative@@YA_NXZ @ 4386 NONAME ; bool QBasicAtomicPointer_isFetchAndAddNative(void)
?QBasicAtomicPointer_isFetchAndStoreNative@@YA_NXZ @ 4387 NONAME ; bool QBasicAtomicPointer_isFetchAndStoreNative(void)
?QBasicAtomicPointer_isTestAndSetNative@@YA_NXZ @ 4388 NONAME ; bool QBasicAtomicPointer_isTestAndSetNative(void)
+ ??0SignalEvent@QStateMachine@@QAE@PAVQObject@@HABV?$QList@VQVariant@@@@@Z @ 4389 NONAME ; QStateMachine::SignalEvent::SignalEvent(class QObject *, int, class QList<class QVariant> const &)
+ ??0WrappedEvent@QStateMachine@@QAE@PAVQObject@@PAVQEvent@@@Z @ 4390 NONAME ; QStateMachine::WrappedEvent::WrappedEvent(class QObject *, class QEvent *)
+ ??1SignalEvent@QStateMachine@@UAE@XZ @ 4391 NONAME ; QStateMachine::SignalEvent::~SignalEvent(void)
+ ??1WrappedEvent@QStateMachine@@UAE@XZ @ 4392 NONAME ; QStateMachine::WrappedEvent::~WrappedEvent(void)
+ ??_ESignalEvent@QStateMachine@@UAE@I@Z @ 4393 NONAME ; QStateMachine::SignalEvent::~SignalEvent(unsigned int)
+ ??_EWrappedEvent@QStateMachine@@UAE@I@Z @ 4394 NONAME ; QStateMachine::WrappedEvent::~WrappedEvent(unsigned int)
+ ?arguments@SignalEvent@QStateMachine@@QBE?AV?$QList@VQVariant@@@@XZ @ 4395 NONAME ; class QList<class QVariant> QStateMachine::SignalEvent::arguments(void) const
+ ?event@WrappedEvent@QStateMachine@@QBEPAVQEvent@@XZ @ 4396 NONAME ; class QEvent * QStateMachine::WrappedEvent::event(void) const
+ ?object@WrappedEvent@QStateMachine@@QBEPAVQObject@@XZ @ 4397 NONAME ; class QObject * QStateMachine::WrappedEvent::object(void) const
+ ?sender@SignalEvent@QStateMachine@@QBEPAVQObject@@XZ @ 4398 NONAME ; class QObject * QStateMachine::SignalEvent::sender(void) const
+ ?signalIndex@SignalEvent@QStateMachine@@QBEHXZ @ 4399 NONAME ; int QStateMachine::SignalEvent::signalIndex(void) const
diff --git a/src/s60installs/bwins/QtGuiu.def b/src/s60installs/bwins/QtGuiu.def
index 8a43f21..166b6fe 100644
--- a/src/s60installs/bwins/QtGuiu.def
+++ b/src/s60installs/bwins/QtGuiu.def
@@ -12514,4 +12514,7 @@ EXPORTS
?app_compile_version@QApplicationPrivate@@2HA @ 12513 NONAME ; int QApplicationPrivate::app_compile_version
?spacerItemFactoryMethod@QLayoutPrivate@@2P6APAVQSpacerItem@@PBVQLayout@@HHW4Policy@QSizePolicy@@1@ZA @ 12514 NONAME ; class QSpacerItem * (*QLayoutPrivate::spacerItemFactoryMethod)(class QLayout const *, int, int, enum QSizePolicy::Policy, enum QSizePolicy::Policy)
?allWidgets@QWidgetPrivate@@2PAV?$QSet@PAVQWidget@@@@A @ 12515 NONAME ; class QSet<class QWidget *> * QWidgetPrivate::allWidgets
+ ?effectiveFocusWidget@QWidgetPrivate@@QAEPAVQWidget@@XZ @ 12516 NONAME ; class QWidget * QWidgetPrivate::effectiveFocusWidget(void)
+ ?ignoreUnusedNavigationEvents@QTextControl@@QBE_NXZ @ 12517 NONAME ; bool QTextControl::ignoreUnusedNavigationEvents(void) const
+ ?setIgnoreUnusedNavigationEvents@QTextControl@@QAEX_N@Z @ 12518 NONAME ; void QTextControl::setIgnoreUnusedNavigationEvents(bool)
diff --git a/src/s60installs/bwins/QtWebKitu.def b/src/s60installs/bwins/QtWebKitu.def
index c14abe2..e5631f8 100644
--- a/src/s60installs/bwins/QtWebKitu.def
+++ b/src/s60installs/bwins/QtWebKitu.def
@@ -361,8 +361,8 @@ EXPORTS
?previousSibling@QWebElement@@QBE?AV1@XZ @ 360 NONAME ; class QWebElement QWebElement::previousSibling(void) const
?print@QWebView@@QBEXPAVQPrinter@@@Z @ 361 NONAME ; void QWebView::print(class QPrinter *) const
?printRequested@QWebPage@@IAEXPAVQWebFrame@@@Z @ 362 NONAME ; void QWebPage::printRequested(class QWebFrame *)
- ?printingMaximumShrinkFactor@QWebSettings@@QBEMXZ @ 363 NONAME ; float QWebSettings::printingMaximumShrinkFactor(void) const
- ?printingMinimumShrinkFactor@QWebSettings@@QBEMXZ @ 364 NONAME ; float QWebSettings::printingMinimumShrinkFactor(void) const
+ ?printingMaximumShrinkFactor@QWebSettings@@QBEMXZ @ 363 NONAME ABSENT ; float QWebSettings::printingMaximumShrinkFactor(void) const
+ ?printingMinimumShrinkFactor@QWebSettings@@QBEMXZ @ 364 NONAME ABSENT ; float QWebSettings::printingMinimumShrinkFactor(void) const
?provisionalLoad@QWebFrame@@IAEXXZ @ 365 NONAME ; void QWebFrame::provisionalLoad(void)
?qWebKitMajorVersion@@YAHXZ @ 366 NONAME ; int qWebKitMajorVersion(void)
?qWebKitMinorVersion@@YAHXZ @ 367 NONAME ; int qWebKitMinorVersion(void)
@@ -488,8 +488,8 @@ EXPORTS
?setPluginFactory@QWebPage@@QAEXPAVQWebPluginFactory@@@Z @ 487 NONAME ; void QWebPage::setPluginFactory(class QWebPluginFactory *)
?setPreferredContentsSize@QWebPage@@QBEXABVQSize@@@Z @ 488 NONAME ; void QWebPage::setPreferredContentsSize(class QSize const &) const
?setPreferredPluginForMimeType@QWebPluginDatabase@@QAEXABVQString@@ABVQWebPluginInfo@@@Z @ 489 NONAME ; void QWebPluginDatabase::setPreferredPluginForMimeType(class QString const &, class QWebPluginInfo const &)
- ?setPrintingMaximumShrinkFactor@QWebSettings@@QAEXM@Z @ 490 NONAME ; void QWebSettings::setPrintingMaximumShrinkFactor(float)
- ?setPrintingMinimumShrinkFactor@QWebSettings@@QAEXM@Z @ 491 NONAME ; void QWebSettings::setPrintingMinimumShrinkFactor(float)
+ ?setPrintingMaximumShrinkFactor@QWebSettings@@QAEXM@Z @ 490 NONAME ABSENT ; void QWebSettings::setPrintingMaximumShrinkFactor(float)
+ ?setPrintingMinimumShrinkFactor@QWebSettings@@QAEXM@Z @ 491 NONAME ABSENT ; void QWebSettings::setPrintingMinimumShrinkFactor(float)
?setRenderHint@QWebView@@QAEXW4RenderHint@QPainter@@_N@Z @ 492 NONAME ; void QWebView::setRenderHint(enum QPainter::RenderHint, bool)
?setRenderHints@QWebView@@QAEXV?$QFlags@W4RenderHint@QPainter@@@@@Z @ 493 NONAME ; void QWebView::setRenderHints(class QFlags<enum QPainter::RenderHint>)
?setScrollBarPolicy@QWebFrame@@QAEXW4Orientation@Qt@@W4ScrollBarPolicy@3@@Z @ 494 NONAME ; void QWebFrame::setScrollBarPolicy(enum Qt::Orientation, enum Qt::ScrollBarPolicy)
@@ -619,4 +619,5 @@ EXPORTS
?staticMetaObject@QGraphicsWebView@@2UQMetaObject@@B @ 618 NONAME ; struct QMetaObject const QGraphicsWebView::staticMetaObject
?staticMetaObject@QWebPage@@2UQMetaObject@@B @ 619 NONAME ; struct QMetaObject const QWebPage::staticMetaObject
?staticMetaObject@QWebView@@2UQMetaObject@@B @ 620 NONAME ; struct QMetaObject const QWebView::staticMetaObject
+ ?attributeNames@QWebElement@@QBE?AVQStringList@@ABVQString@@@Z @ 621 NONAME ; class QStringList QWebElement::attributeNames(class QString const &) const
diff --git a/src/s60installs/eabi/QtCoreu.def b/src/s60installs/eabi/QtCoreu.def
index 99be68e..6a4cdbd 100644
--- a/src/s60installs/eabi/QtCoreu.def
+++ b/src/s60installs/eabi/QtCoreu.def
@@ -3619,4 +3619,18 @@ EXPORTS
_ZN15QBasicAtomicInt19isFetchAndAddNativeEv @ 3618 NONAME
_ZN15QBasicAtomicInt21isFetchAndStoreNativeEv @ 3619 NONAME
_ZN15QBasicAtomicInt25isReferenceCountingNativeEv @ 3620 NONAME
+ _ZN13QStateMachine11SignalEventC1EP7QObjectiRK5QListI8QVariantE @ 3621 NONAME
+ _ZN13QStateMachine11SignalEventC2EP7QObjectiRK5QListI8QVariantE @ 3622 NONAME
+ _ZN13QStateMachine11SignalEventD0Ev @ 3623 NONAME
+ _ZN13QStateMachine11SignalEventD1Ev @ 3624 NONAME
+ _ZN13QStateMachine11SignalEventD2Ev @ 3625 NONAME
+ _ZN13QStateMachine12WrappedEventC1EP7QObjectP6QEvent @ 3626 NONAME
+ _ZN13QStateMachine12WrappedEventC2EP7QObjectP6QEvent @ 3627 NONAME
+ _ZN13QStateMachine12WrappedEventD0Ev @ 3628 NONAME
+ _ZN13QStateMachine12WrappedEventD1Ev @ 3629 NONAME
+ _ZN13QStateMachine12WrappedEventD2Ev @ 3630 NONAME
+ _ZTIN13QStateMachine11SignalEventE @ 3631 NONAME
+ _ZTIN13QStateMachine12WrappedEventE @ 3632 NONAME
+ _ZTVN13QStateMachine11SignalEventE @ 3633 NONAME
+ _ZTVN13QStateMachine12WrappedEventE @ 3634 NONAME
diff --git a/src/s60installs/eabi/QtGuiu.def b/src/s60installs/eabi/QtGuiu.def
index 43e291c..6c45a6e 100644
--- a/src/s60installs/eabi/QtGuiu.def
+++ b/src/s60installs/eabi/QtGuiu.def
@@ -11735,4 +11735,6 @@ EXPORTS
_Zls6QDebugP15QGraphicsObject @ 11734 NONAME
_Zls6QDebugRK12QStyleOption @ 11735 NONAME
_Zls6QDebugRKN12QStyleOption10OptionTypeE @ 11736 NONAME
+ _ZN12QTextControl31setIgnoreUnusedNavigationEventsEb @ 11737 NONAME
+ _ZNK12QTextControl28ignoreUnusedNavigationEventsEv @ 11738 NONAME
diff --git a/src/s60installs/eabi/QtWebKitu.def b/src/s60installs/eabi/QtWebKitu.def
index 88343c1..4aad884 100644
--- a/src/s60installs/eabi/QtWebKitu.def
+++ b/src/s60installs/eabi/QtWebKitu.def
@@ -654,8 +654,8 @@ EXPORTS
_Z34qt_drt_resetOriginAccessWhiteListsv @ 653 NONAME
_ZN11QWebElement17removeAllChildrenEv @ 654 NONAME
_ZN11QWebElement6renderEP8QPainter @ 655 NONAME
- _ZN12QWebSettings30setPrintingMaximumShrinkFactorEf @ 656 NONAME
- _ZN12QWebSettings30setPrintingMinimumShrinkFactorEf @ 657 NONAME
+ _ZN12QWebSettings30setPrintingMaximumShrinkFactorEf @ 656 NONAME ABSENT
+ _ZN12QWebSettings30setPrintingMinimumShrinkFactorEf @ 657 NONAME ABSENT
_ZN16QGraphicsWebView10itemChangeEN13QGraphicsItem18GraphicsItemChangeERK8QVariant @ 658 NONAME
_ZN16QGraphicsWebView11linkClickedERK4QUrl @ 659 NONAME
_ZN16QGraphicsWebView12loadFinishedEb @ 660 NONAME
@@ -674,8 +674,8 @@ EXPORTS
_ZN21QWebElementCollectionD2Ev @ 673 NONAME
_ZN21QWebElementCollectionaSERKS_ @ 674 NONAME
_ZN9QWebFrame6renderEP8QPainterNS_11RenderLayerERK7QRegion @ 675 NONAME
- _ZNK12QWebSettings27printingMaximumShrinkFactorEv @ 676 NONAME
- _ZNK12QWebSettings27printingMinimumShrinkFactorEv @ 677 NONAME
+ _ZNK12QWebSettings27printingMaximumShrinkFactorEv @ 676 NONAME ABSENT
+ _ZNK12QWebSettings27printingMinimumShrinkFactorEv @ 677 NONAME ABSENT
_ZNK16QGraphicsWebView10isModifiedEv @ 678 NONAME
_ZNK16QGraphicsWebView10pageActionEN8QWebPage9WebActionE @ 679 NONAME
_ZNK16QGraphicsWebView16inputMethodQueryEN2Qt16InputMethodQueryE @ 680 NONAME
@@ -689,4 +689,5 @@ EXPORTS
_ZThn16_NK16QGraphicsWebView8sizeHintEN2Qt8SizeHintERK6QSizeF @ 688 NONAME
_ZThn8_N16QGraphicsWebView10itemChangeEN13QGraphicsItem18GraphicsItemChangeERK8QVariant @ 689 NONAME
_ZThn8_NK16QGraphicsWebView16inputMethodQueryEN2Qt16InputMethodQueryE @ 690 NONAME
+ _ZNK11QWebElement14attributeNamesERK7QString @ 691 NONAME
diff --git a/src/script/api/qscriptengine.cpp b/src/script/api/qscriptengine.cpp
index d519102..dc0e0d0 100644
--- a/src/script/api/qscriptengine.cpp
+++ b/src/script/api/qscriptengine.cpp
@@ -776,7 +776,11 @@ QScriptEnginePrivate::QScriptEnginePrivate()
qMetaTypeId<QObjectList>();
#endif
- JSC::initializeThreading(); // ### hmmm
+ if (!QCoreApplication::instance()) {
+ qFatal("QScriptEngine: Must construct a Q(Core)Application before a QScriptEngine");
+ return;
+ }
+ JSC::initializeThreading();
globalData = JSC::JSGlobalData::create().releaseRef();
globalData->clientData = new QScript::GlobalClientData(this);
@@ -1302,7 +1306,7 @@ QScript::QObjectData *QScriptEnginePrivate::qobjectData(QObject *object)
QScript::QObjectData *data = new QScript::QObjectData(this);
m_qobjectData.insert(object, data);
QObject::connect(object, SIGNAL(destroyed(QObject*)),
- q_func(), SLOT(_q_objectDestroyed(QObject *)));
+ q_func(), SLOT(_q_objectDestroyed(QObject*)));
return data;
}
diff --git a/src/scripttools/debugging/qscriptdebuggercodefinderwidget.cpp b/src/scripttools/debugging/qscriptdebuggercodefinderwidget.cpp
index 8ed0aaa..e25bb04 100644
--- a/src/scripttools/debugging/qscriptdebuggercodefinderwidget.cpp
+++ b/src/scripttools/debugging/qscriptdebuggercodefinderwidget.cpp
@@ -143,7 +143,7 @@ QScriptDebuggerCodeFinderWidget::QScriptDebuggerCodeFinderWidget(QWidget *parent
d->editFind = new QLineEdit(this);
d->editFind->setMinimumSize(QSize(150, 0));
- connect(d->editFind, SIGNAL(textChanged(const QString&)),
+ connect(d->editFind, SIGNAL(textChanged(QString)),
this, SLOT(_q_updateButtons()));
connect(d->editFind, SIGNAL(returnPressed()),
this, SLOT(_q_next()));
diff --git a/src/scripttools/debugging/qscriptedit.cpp b/src/scripttools/debugging/qscriptedit.cpp
index 7f0a5e0..67d82a3 100644
--- a/src/scripttools/debugging/qscriptedit.cpp
+++ b/src/scripttools/debugging/qscriptedit.cpp
@@ -110,8 +110,8 @@ QScriptEdit::QScriptEdit(QWidget *parent)
QObject::connect(this, SIGNAL(blockCountChanged(int)),
this, SLOT(updateExtraAreaWidth()));
- QObject::connect(this, SIGNAL(updateRequest(const QRect &, int)),
- this, SLOT(updateExtraArea(const QRect &, int)));
+ QObject::connect(this, SIGNAL(updateRequest(QRect,int)),
+ this, SLOT(updateExtraArea(QRect,int)));
QObject::connect(this, SIGNAL(cursorPositionChanged()),
this, SLOT(highlightCurrentLine()));
diff --git a/src/tools/uic/cpp/cppwriteinitialization.cpp b/src/tools/uic/cpp/cppwriteinitialization.cpp
index b2e8f4f..88dfa98 100644
--- a/src/tools/uic/cpp/cppwriteinitialization.cpp
+++ b/src/tools/uic/cpp/cppwriteinitialization.cpp
@@ -2709,11 +2709,11 @@ void WriteInitialization::acceptConnection(DomConnection *connection)
m_output << m_indent << "QObject::connect("
<< sender
<< ", "
- << "SIGNAL(" << connection->elementSignal() << ')'
+ << "SIGNAL("<<connection->elementSignal()<<')'
<< ", "
<< receiver
<< ", "
- << "SLOT(" << connection->elementSlot() << ')'
+ << "SLOT("<<connection->elementSlot()<<')'
<< ");\n";
}