summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarkku Luukkainen <markku.luukkainen@digia.com>2009-06-15 12:42:50 (GMT)
committerMarkku Luukkainen <markku.luukkainen@digia.com>2009-06-15 12:42:50 (GMT)
commitaef056f9bae16c3c152dfdd50c72cb505870b152 (patch)
tree370fe0d3c8471e23cd5096b89c5efd04938c2c3a
parent2b630bd12b9e944707d8e52c1135e88750323ed0 (diff)
parent607cb959290b828fcf8f5ec88f72fb168ec08dae (diff)
downloadQt-aef056f9bae16c3c152dfdd50c72cb505870b152.zip
Qt-aef056f9bae16c3c152dfdd50c72cb505870b152.tar.gz
Qt-aef056f9bae16c3c152dfdd50c72cb505870b152.tar.bz2
Merge branch 'master' of git@scm.dev.nokia.troll.no:qt/qt-s60-public
-rw-r--r--dist/changes-4.5.2-tower210
-rw-r--r--doc/src/platform-notes.qdoc2
-rw-r--r--doc/src/symbian-exceptionsafety.qdoc17
-rw-r--r--doc/src/topics.qdoc11
-rw-r--r--src/corelib/global/qglobal.cpp48
-rw-r--r--src/corelib/global/qglobal.h12
-rw-r--r--src/corelib/tools/qscopedpointer.cpp15
-rw-r--r--src/gui/painting/qpainterpath.cpp18
-rw-r--r--src/gui/painting/qpainterpath.h6
9 files changed, 271 insertions, 68 deletions
diff --git a/dist/changes-4.5.2-tower b/dist/changes-4.5.2-tower
index 1a039ba..19e8d3c 100644
--- a/dist/changes-4.5.2-tower
+++ b/dist/changes-4.5.2-tower
@@ -28,7 +28,8 @@ New modules
-----------
- QtSql
- * todo
+ * Implemented QtSql module with sqlite3 backend. For now backend is
+ provided only in binary format.
- QtWebkit
* todo
- Phonon
@@ -44,58 +45,239 @@ New classes
Ported classes
--------------
-- todo
- * todo
+- QSound
+ * Implemented CMdaAudioPlayerUtility based Symbian backend for QSound.
+- QLocalSocket and QLocalServer
+ * Added support for QLocalSocket and QLocalServer on Symbian
Features
--------
+- QApplication
+ * Implemented QApplication::beep() for Symbian
+- QSslSocket
+ * Added support for -openssl option i.e. runtime resolving of OpenSSL
+ symbols
- todo
* todo
Optimizations
-------------
-- todo
- * todo
+- qdrawhelper
+ * Optimized drawing operations for RVCT builds, particulary for ARMV6.
+
+- qwidget_s60.cpp
+ * Avoid unnecessary calls to FocusChanged in Symbian
+
+****************************************************************************
+* Code clean-up *
+****************************************************************************
+
+- Cleanup qeventdispatcher_unix.cpp
+ * 247268: All qeventdispatcher_unix.cpp changes were reverted since,
+ this file is not anymore used in Symbian OS branch.
+- Cleanup QtNetwork workarounds implemented earlier due to Open C bugs.
+ * 247287: Removed getaddrinfo workaround
+ * 247288: Removed waitForConnected workaround
+ * 247289: Removed qt_socket_accept workaround
+ * 247290: Removed qt_socket_connect workaround
+ * 247290: Removed E32IONREAD workaround
+ * 247293: Removed nativeHasPendingDatagrams workaround
+ * 247295: Removed QNativeSocketEnginePrivate::nativeRead EPIPE
+ workaround
+- Other code clean-ups
+ * 247278: Removed unnecessary includes from qbackingstore.cpp.
+ * Fixed Q_OS_SYMBIAN ifdef usage in qfiledialog_p.h
+ * 247272: Removed qtestnetworkservers.h dependency, used
+ network-settings.h
+ * Revert "Work around compiler bug on Nokia Metrowerks compiler."
+ * Remove UI highlights being inverted colors based on highlight text colors.
+
****************************************************************************
* Build issues *
****************************************************************************
-- todo
+- QTest
+ * Fixed testlib export macros for RVCT builds.
****************************************************************************
* Changes to existing classes *
****************************************************************************
-- todo
- * todo
+- QDesktopServices
+ * Fixed forwardslash/backslash usage as an path separator
+
+- QPluginLoader
+ * QPluginLoader will look for plugin stubs from the same folder on other
+ drives if it can't find them from the indicated drive.
+
+- QEventDispatcher
+ * Lowered the timeout for reprioritizing the process to 100ms
+
+- QNetworkInterface
+ * Fixed R-handle leak in Symbian version of qnetworkinterface_unix.cpp
+ * Introduced a new qnetworkinterface_symbian.cpp, because there wasn't
+ really anything common to UNIX equivalent
+
+- QHostInfo
+ * Added support for host lookups with multiple ipv4 addresses.
+
+- QUdpSocket
+ * Updated BindFlag documentation to reflect behaviour on Symbian OS
+
+- QLocale
+ * Removed workaround for missing tzname symbol, fixes QLocal timeZone
+ implementation for Symbian.
+
+- QTemporaryFile
+ * Fixed temporary file rename in Symbian OS.
+
+- QThread
+ * Fix for thread termination in Symbian OS.
+
+- QIoDevice
+ * Fixed compilation error when QIODEVICE_DEBUG is defined.
+
+- QS60Style
+ * Added subElementRect implementation for SE_ItemViewItemCheckIndicator.
+ * Added support for E90 layouts.
+ * Added support for QScrollArea, QTextEditor, QGroupBox, QTreeView, QToolBar and QDial styling.
+ * Better support for theme and layout changes.
+ * Better support for themed palettes and themed text colors.
+ * Better support for multiselection in item views.
+ * Better theming for QTable and QPanel.
+ * Better support of highlight graphics and texts for QLists, QTreeViews, QCalendarWidgets and QComboBoxes.
+ * Support polishing fonts. Fonts are no longer changed within the drawing code.
+ * Draw spinbox arrowbuttons side-by-side, instead one on top of the other.
+ * Harmonize widget drawing so that widgets are of similar height.
+ * Support check states for QLists and QPushButtons.
+ * Support flat QPushButtons.
+ * Support busy indicator.
+ * Support QScrollBar pressed state.
+ * Support QPushButton disabled theme graphics.
+ * Separate theme background for QDialogs.
+ * Clarify QToolButton pressed state.
+ * Removed linedrawing of panels and groupboxes.
+ * Fix palette-polution for a style that is activated from an application after S60Style has been in use.
+ * Fix for frame masks with color depth other than EGrey2.
+ * Fix for squeezed QTabBars.
+ * Fix memory leak when color skinning graphics.
+
+- QDesktopServices
+ * Switched QDesktopServices mail-to URL handling to RSendAs in Symbian,
+ due to the fact that CSendUi requires extensive capabilities to work
+ correctly. Currently e-mail sending with qdesktopservices::openUrl
+ works in Symbian only if e-mail account already exists.
+
+- QCoeFepInputContext (non-public)
+ * Fixes FEP crash when changing the focused Qt widget to NULL.
+
+- QApplication
+ * 252798: Fixed layout when orientation changed via
+ AknAppUi::SetOrientationL.
+
+- QUdpSocket
+ * Wrote hack for QUdpSocket::writeDatagram return value in Symbian OS.
+
+- QNativeSocketEnginePrivate (non-public)
+ * Changed select to listen also expectfds in Symbain OS for given
+ sockets (Workaround to Open C bug).
+ * Fix to Open C bug: Socket connect failure is indicated exception set.
+
+- QEventDispatcherSymbian (non-public)
+ * Fixed ASSERT panic in Symbian event dispatcher
+ * 246600: Fix problem in eventdispatcher destructor / AO canceling
+ * Fixed active scheduler removal when calling QThread::terminate
+ * Fix to Open C bug: select sometimes returns -1 and errno is
+ ECONNREFUSED
****************************************************************************
* Examples and demos *
****************************************************************************
+- Drilldown
+ * Added to demonstrate QtSql usage in Symbian OS
+
+- Deform, Pathstroke, and Wiggly
+ * Removed Symbian specific animation timer fixes since more generic
+ fix was made to event dispatcher.
+
+- Ftp
+ * Enabled default iap setting for FTP example
+
+- DesktopServices
+ * Implemented content filters for desktopservices example.
+ * Added error handling to qdesktopservices example when openUrl fails.
+
+- SecureSocketClient
+ * Fixed build issue caused by lack of cursor.
+
+- Fluidlauncher
+ * Removed ugly workaround to make emulator deployment work correctly,
+ since the issue has been fixed in qmake.
+ * Included drilldown to demonstrate QtSql usage
+ * Updated screenshots to S60 style
-- todo
- * todo
****************************************************************************
* Tools *
****************************************************************************
-- todo
- * todo
+- qmake
+ * Support for generating Symbian "test" targets: CONFIG += symbian_test.
+ * Support for Symbian Build System, version 2 (aka Raptor) via
+ symbian-sbsv2 mkspec.
+ * PAGED keyword is added to all MMP files by default, except in S60 3.1
+ builds.
+ * Read-only flag is no longer preserved when deploying files into
+ emulator environment.
+ * Changed the timestamp to ISO format in all files generated
+ by qmake for symbian-* mkspecs.
+ * Qt's VERSION variable will now generate VERSION keyword in mmp files.
+ * Made Open C include paths handling bit more robust.
+
+- configure
+ * -cetest is no longer a supported switch for configure.
+ * -stl option is enabled by default for Symbian OS
+ * -openssl option is enabled by default for Symbian OS.
+
+- Release package creation
+ * Removed the obsolete script to create release package.
+
+- Createpackage script
+ * Now creates packages with .sis suffix.
+
+- Patch_capabilities script
+ * Will now patch also vendor id.
+
+****************************************************************************
+* Documnetation *
+****************************************************************************
+- qmake-manual
+ * 250370: Added documentation for ICON keyword
****************************************************************************
* Plugins *
****************************************************************************
-- todo
- * todo
+- S60 version specific plugins
+ * Isolated S60 version dependent functionality to S60 version specific
+ plugins (qts60plugin_x_y.dll) to make it possible for single build to
+ run on any supported device, even if with reduced functionality on
+ some.
+
****************************************************************************
* Important Behavior Changes *
****************************************************************************
+- Qt libs
+ * Qt libs are now built with "All -Tcb" capabilities always. It is now
+ always necessary to run patch_capabilities.pl script if self-signing
+ of Qt libs is desired.
+ * QtCore and QtSql made UNPAGED as workaround for an obscure crash
+ when they are paged.
+
- todo
* todo
diff --git a/doc/src/platform-notes.qdoc b/doc/src/platform-notes.qdoc
index 63b721a..53db855 100644
--- a/doc/src/platform-notes.qdoc
+++ b/doc/src/platform-notes.qdoc
@@ -521,7 +521,7 @@
supported by Qt can be found on the \l{Supported Platforms} page.
For information about mixing exceptions with symbian leaves,
- see \l QSymbianLeaveException.
+ see \l{Exception Safety with Symbian}
*/
/*!
diff --git a/doc/src/symbian-exceptionsafety.qdoc b/doc/src/symbian-exceptionsafety.qdoc
index 212f707..e42ecd1 100644
--- a/doc/src/symbian-exceptionsafety.qdoc
+++ b/doc/src/symbian-exceptionsafety.qdoc
@@ -80,11 +80,11 @@
Symbian leaves to standard C++ exceptions. The following help is provided:
\list
- \o \l qt_translateSymbianErrorToException(int error) takes a Symbian
+ \o \l qt_translateSymbianErrorToException() takes a Symbian
error code and throws an appropriate exception to represent it.
This will do nothing if the error code is not in fact an error. The
function is equivalent to Symbian's \c User::LeaveIfError.
- \o \l QT_TRANSLATE_SYMBIAN_LEAVE_TO_EXCEPTION(f) takes a Symbian leaving
+ \o \l QT_TRANSLATE_SYMBIAN_LEAVE_TO_EXCEPTION() takes a Symbian leaving
code fragment f and runs it under a trap harness converting any resulting
error into an exception.
\o \c TRAP and \c TRAPD from the Symbian libraries can be used to convert
@@ -113,18 +113,18 @@
provided:
\list
- \o \l qt_translateExceptionToSymbianError(const std::exception& ex) -
+ \o \l qt_translateExceptionToSymbianError() -
this takes a standard exception and gives an appropriate Symbian
error code. If no mapping is known for the exception type,
\c KErrGeneral is returned.
- \o \l qt_translateExceptionToSymbianErrorL(const std::exception& ex) -
+ \o \l qt_translateExceptionToSymbianErrorL() -
this takes a standard exception and generates an appropriate Symbian
leave.
- \o \l QT_TRANSLATE_EXCEPTION_TO_SYMBIAN_ERROR(err, f) - this macro
+ \o \l QT_TRANSLATE_EXCEPTION_TO_SYMBIAN_ERROR() - this macro
takes the standard C++ code fragment \c f, catches any std::exceptions
thrown from it, and sets err to the corresponding Symbian error code.
err is set to \c KErrNone otherwise.
- \o \l QT_TRANSLATE_EXCEPTION_TO_SYMBIAN_LEAVE(f) - this macro takes the
+ \o \l QT_TRANSLATE_EXCEPTION_TO_SYMBIAN_LEAVE() - this macro takes the
standard C++ code fragment \c f, catches any std::exceptions thrown from
it, and throws a corresponding Symbian leave.
\endlist
@@ -164,9 +164,8 @@
it's dealing with strings it probably does, again bad.
Line 4 is tricky, it calls a leaving function which is ok within a \c TRAP,
- but it also uses \l qt_QString2TPtrC. You might think this is safe, but
- there is a potential realloc call in there, so this can cause an unwelcome
- exception.
+ but it also uses a helper function to convert string types. In this case
+ the helper function may cause an unwelcome exception.
We could rewrite this with nested exception translations, but it's much
easier to refactor it.
diff --git a/doc/src/topics.qdoc b/doc/src/topics.qdoc
index 6ef3a89..09a86bd 100644
--- a/doc/src/topics.qdoc
+++ b/doc/src/topics.qdoc
@@ -300,3 +300,14 @@ including ARM, Intel x86, MIPS and SH-4.
\endlist
\endtable
*/
+
+/*!
+\group qts60
+\title Qt for S60
+\ingroup topics
+\brief Documents related to Qt for S60
+
+\list
+ \o \l {Exception Safety with Symbian}
+\endlist
+*/
diff --git a/src/corelib/global/qglobal.cpp b/src/corelib/global/qglobal.cpp
index 6590ea6..e53fd2d 100644
--- a/src/corelib/global/qglobal.cpp
+++ b/src/corelib/global/qglobal.cpp
@@ -3215,7 +3215,8 @@ bool QInternal::callFunction(InternalFunction func, void **args)
#include <typeinfo>
/*! \macro QT_TRANSLATE_SYMBIAN_LEAVE_TO_EXCEPTION(function)
- \relates QSymbianLeaveException
+ \relates <QtGlobal>
+ \ingroup qts60
TRAP leaves from Symbian \a function and throws an appropriate
standard C++ exception instead.
@@ -3241,7 +3242,7 @@ bool QInternal::callFunction(InternalFunction func, void **args)
*/
/*! \macro QT_TRANSLATE_EXCEPTION_TO_SYMBIAN_ERROR(error, function)
- \relates QSymbianLeaveException
+ \relates <QtGlobal>
\ingroup qts60
Catch standard C++ exceptions from a \a function and convert them to a Symbian OS
@@ -3272,7 +3273,7 @@ bool QInternal::callFunction(InternalFunction func, void **args)
*/
/*! \macro QT_TRANSLATE_EXCEPTION_TO_SYMBIAN_LEAVE(function)
- \relates QSymbianLeaveException
+ \relates <QtGlobal>
\ingroup qts60
Catch standard C++ exceptions from \a function and convert them to Symbian OS
@@ -3298,37 +3299,22 @@ bool QInternal::callFunction(InternalFunction func, void **args)
\sa QT_TRANSLATE_SYMBIAN_LEAVE_TO_EXCEPTION(), QT_TRANSLATE_EXCEPTION_TO_SYMBIAN_ERROR()
*/
-/*! \class QSymbianLeaveException
- \ingroup qts60
- \brief The QSymbianLeaveException class represents a block of Symbian leave code.
-
- \warning This class is only available on Symbian.
-*/
-
-/*! \fn QSymbianLeaveException::QSymbianLeaveException(int error)
+#include <stdexcept>
- Constructs a QSymbianLeaveException object that stores the given
- Symbian \a error code.
-*/
-
-/*! \fn const char *QSymbianLeaveException::what() const
-
- Returns a C-style character string describing the general
- cause of the current error.
-
- The string is not localized.
-*/
-const char *QSymbianLeaveException::what() const throw()
+class QSymbianLeaveException : public std::exception
{
- static char msg[36];
- snprintf(msg, sizeof(msg), "Symbian leave exception %d", error);
- return msg;
-}
+public:
+ inline QSymbianLeaveException(int err) : error(err) {}
+ inline const char* what() const throw() { return "Symbian leave exception"; }
+
+public:
+ int error;
+};
-/*! \relates QSymbianLeaveException
+/*! \relates <QtGlobal>
\ingroup qts60
- Throws a QSymbianLeaveException if the \a error parameter is a symbian error code.
+ Throws an exception if the \a error parameter is a symbian error code.
This is the exception throwing equivalent of Symbian's User::LeaveIfError.
\warning This function is only available on Symbian.
@@ -3347,7 +3333,7 @@ void qt_translateSymbianErrorToException(int error)
}
}
-/*! \relates QSymbianLeaveException
+/*! \relates <QtGlobal>
\ingroup qts60
Convert a caught standard C++ exception \a aThrow to a Symbian leave
@@ -3361,7 +3347,7 @@ void qt_translateExceptionToSymbianErrorL(const std::exception& aThrow)
User::Leave(qt_translateExceptionToSymbianError(aThrow));
}
-/*! \relates QSymbianLeaveException
+/*! \relates <QtGlobal>
\ingroup qts60
Convert a caught standard C++ exception \a aThrow to a Symbian error code
diff --git a/src/corelib/global/qglobal.h b/src/corelib/global/qglobal.h
index 450fd86..825b7e8 100644
--- a/src/corelib/global/qglobal.h
+++ b/src/corelib/global/qglobal.h
@@ -2312,16 +2312,8 @@ QT3_SUPPORT Q_CORE_EXPORT const char *qInstallPathSysconf();
#if defined(Q_OS_SYMBIAN)
-#include <stdexcept>
-
-class QSymbianLeaveException : public std::exception
-{
-public:
- inline QSymbianLeaveException(int err) : error(err) {}
- const char* what() const throw();
-public:
- int error;
-};
+// forward declare std::exception
+namespace std { class exception; }
Q_CORE_EXPORT void qt_translateSymbianErrorToException(int error);
Q_CORE_EXPORT void qt_translateExceptionToSymbianErrorL(const std::exception& ex);
diff --git a/src/corelib/tools/qscopedpointer.cpp b/src/corelib/tools/qscopedpointer.cpp
index 0239575..6a1ffb6 100644
--- a/src/corelib/tools/qscopedpointer.cpp
+++ b/src/corelib/tools/qscopedpointer.cpp
@@ -134,6 +134,21 @@
*/
/*!
+ \fn bool QScopedPointer::operator==(const QScopedPointer<T> &other) const
+
+ Equality operator. Returns true if the scoped pointer \a other
+ is pointing to the same object as this pointer, otherwise returns false.
+*/
+
+
+/*!
+ \fn bool QScopedPointer::operator!=(const QScopedPointer<T> *other) const
+
+ Inequality operator. Returns true if the scoped pointer \a other
+ is not pointing to the same object as this pointer, otherwise returns false.
+*/
+
+/*!
\fn bool QScopedPointer::isNull() const
Returns \c true if this object is holding a pointer that is \c null.
diff --git a/src/gui/painting/qpainterpath.cpp b/src/gui/painting/qpainterpath.cpp
index 12dbc62..635218e 100644
--- a/src/gui/painting/qpainterpath.cpp
+++ b/src/gui/painting/qpainterpath.cpp
@@ -73,6 +73,24 @@
QT_BEGIN_NAMESPACE
+struct QPainterPathPrivateHandler
+{
+ static inline void cleanup(QPainterPathPrivate *d)
+ {
+ // note - we must up-cast to QPainterPathData since QPainterPathPrivate
+ // has a non-virtual destructor!
+ if (d && !d->ref.deref())
+ delete static_cast<QPainterPathData *>(d);
+ }
+
+ static inline void reset(QPainterPathPrivate *&d, QPainterPathPrivate *other)
+ {
+ QPainterPathPrivate *oldD = d;
+ d = other;
+ cleanup(oldD);
+ }
+};
+
// This value is used to determine the length of control point vectors
// when approximating arc segments as curves. The factor is multiplied
// with the radius of the circle.
diff --git a/src/gui/painting/qpainterpath.h b/src/gui/painting/qpainterpath.h
index 0513593..e12194e 100644
--- a/src/gui/painting/qpainterpath.h
+++ b/src/gui/painting/qpainterpath.h
@@ -57,6 +57,7 @@ QT_MODULE(Gui)
class QFont;
class QPainterPathPrivate;
+struct QPainterPathPrivateHandler;
class QPainterPathData;
class QPainterPathStrokerPrivate;
class QPolygonF;
@@ -196,7 +197,7 @@ public:
QPainterPath &operator-=(const QPainterPath &other);
private:
- QScopedSharedPointer<QPainterPathPrivate> d_ptr;
+ QScopedCustomPointer<QPainterPathPrivate, QPainterPathPrivateHandler> d_ptr;
inline void ensureData() { if (!d_ptr) ensureData_helper(); }
void ensureData_helper();
@@ -230,8 +231,7 @@ public:
friend class QPainterPathStrokerPrivate;
friend class QMatrix;
friend class QTransform;
- friend class QScopedSharedPointer<QPainterPathPrivate>;
- friend class QScopedSharedPointerHandler<QPainterPathPrivate>;
+ friend struct QPainterPathPrivateHandler;
#ifndef QT_NO_DATASTREAM
friend Q_GUI_EXPORT QDataStream &operator<<(QDataStream &, const QPainterPath &);
friend Q_GUI_EXPORT QDataStream &operator>>(QDataStream &, QPainterPath &);