diff options
93 files changed, 1994 insertions, 1130 deletions
diff --git a/dist/changes-4.4.0 b/dist/changes-4.4.0 index a33b510..3e7d14d 100644 --- a/dist/changes-4.4.0 +++ b/dist/changes-4.4.0 @@ -1999,7 +1999,7 @@ Qt for Embedded Linux * Made the SL5000, USB, VR41xx and Yopy drivers available as plugins. - Decoration drivers - * Made the Styled, Windows and Default decorations avaiable as plugins + * Made the Styled, Windows and Default decorations available as plugins - Demo applications * Added embeddedsvgviewer, styledemo & fluidlauncher applications to diff --git a/dist/changes-4.7.0 b/dist/changes-4.7.0 index b9aa64d..d5b4672 100644 --- a/dist/changes-4.7.0 +++ b/dist/changes-4.7.0 @@ -8,11 +8,11 @@ The Qt version 4.7 series is binary compatible with the 4.6.x series. Applications compiled for 4.6 will continue to run with 4.7. Some of the changes listed in this file include issue tracking numbers -corresponding to tasks in the Task Tracker: +corresponding to tasks in the Qt Bug Tracker: - http://qt.nokia.com/developer/task-tracker + http://bugreports.qt.nokia.com/ -Each of these identifiers can be entered in the task tracker to obtain more +Each of these identifiers can be entered in the bug tracker to obtain more information about a particular change. **************************************************************************** diff --git a/doc/src/examples/plugandpaint.qdoc b/doc/src/examples/plugandpaint.qdoc index a502e18..0e2bfd0 100644 --- a/doc/src/examples/plugandpaint.qdoc +++ b/doc/src/examples/plugandpaint.qdoc @@ -513,7 +513,7 @@ Since the approach is identical to \l{tools/plugandpaintplugins/basictools}{Basic Tools}, we won't - review the code here. The only part of interes is the + review the code here. The only part of interest is the \c .pro file, since Extra Filters is a dynamic plugin (\l{tools/plugandpaintplugins/basictools}{Basic Tools} is linked statically into the Plug & Paint executable). diff --git a/doc/src/snippets/code/src_qdbus_qdbusmetatype.cpp b/doc/src/snippets/code/src_qdbus_qdbusmetatype.cpp index d97d61a..800a332 100644 --- a/doc/src/snippets/code/src_qdbus_qdbusmetatype.cpp +++ b/doc/src/snippets/code/src_qdbus_qdbusmetatype.cpp @@ -40,5 +40,6 @@ ****************************************************************************/ //! [0] +#include <QDBusMetaType> qDBusRegisterMetaType<MyClass>(); //! [0] diff --git a/src/3rdparty/clucene/src/CLucene/util/bufferedstream.h b/src/3rdparty/clucene/src/CLucene/util/bufferedstream.h index b73ad98..d905955 100644 --- a/src/3rdparty/clucene/src/CLucene/util/bufferedstream.h +++ b/src/3rdparty/clucene/src/CLucene/util/bufferedstream.h @@ -46,7 +46,7 @@ protected: /** * This function must be implemented by the subclasses. * It should write a maximum of @p space characters at the buffer - * position pointed to by @p start. If no more data is avaiable due to + * position pointed to by @p start. If no more data is available due to * end of file, -1 should be returned. If an error occurs, the status * should be set to Error, an error message should be set and the function * must return -1. diff --git a/src/3rdparty/javascriptcore/JavaScriptCore/ChangeLog b/src/3rdparty/javascriptcore/JavaScriptCore/ChangeLog index 4f6e565..11572b0 100644 --- a/src/3rdparty/javascriptcore/JavaScriptCore/ChangeLog +++ b/src/3rdparty/javascriptcore/JavaScriptCore/ChangeLog @@ -1,3 +1,29 @@ +2010-04-14 Kent Hansen <kent.hansen@nokia.com> + + Reviewed by Maciej Stachowiak. + + Mac OS X: Use deployment target to determine whether memory tagging should be enabled + https://bugs.webkit.org/show_bug.cgi?id=34888 + + When building on (Snow) Leopard but targeting Tiger + (TARGETING_TIGER defined, BUILDING_ON_TIGER not defined), + WebKit would crash on Tiger because the tags passed to mmap + caused those function calls to fail. + + Conversely, when building on Tiger but targeting Leopard + (BUILDING_ON_TIGER defined, TARGETING_LEOPARD defined), WebKit + would crash on Leopard because the tags passed to vm_map and + vm_allocate caused those function calls to fail. + + Solution: Use TARGETING_TIGER rather than BUILDING_ON_TIGER to + govern the tag definitions. Use the same tags for vm_map and + vm_allocate regardless of target, since they work on + both. Fall back to the mmap tags that work on Tiger (that is, + "no tags") if targeting Tiger, since those tags also work on + Leopard. + + * wtf/VMTags.h: + 2010-03-29 Patrick Gansterer <paroga@paroga.com> Reviewed by Darin Adler. diff --git a/src/3rdparty/javascriptcore/JavaScriptCore/wtf/VMTags.h b/src/3rdparty/javascriptcore/JavaScriptCore/wtf/VMTags.h index 34e2494..75bec11 100644 --- a/src/3rdparty/javascriptcore/JavaScriptCore/wtf/VMTags.h +++ b/src/3rdparty/javascriptcore/JavaScriptCore/wtf/VMTags.h @@ -30,25 +30,48 @@ // On Mac OS X, the VM subsystem allows tagging memory requested from mmap and vm_map // in order to aid tools that inspect system memory use. -#if OS(DARWIN) && !defined(BUILDING_ON_TIGER) +#if OS(DARWIN) #include <mach/vm_statistics.h> +#if !defined(TARGETING_TIGER) + #if defined(VM_MEMORY_TCMALLOC) #define VM_TAG_FOR_TCMALLOC_MEMORY VM_MAKE_TAG(VM_MEMORY_TCMALLOC) #else #define VM_TAG_FOR_TCMALLOC_MEMORY VM_MAKE_TAG(53) #endif // defined(VM_MEMORY_TCMALLOC) -#if defined(VM_MEMORY_JAVASCRIPT_CORE) && defined(VM_MEMORY_JAVASCRIPT_JIT_REGISTER_FILE) && defined(VM_MEMORY_JAVASCRIPT_JIT_EXECUTABLE_ALLOCATOR) && defined(VM_MEMORY_JAVASCRIPT_JIT_EXECUTABLE_ALLOCATOR) -#define VM_TAG_FOR_COLLECTOR_MEMORY VM_MAKE_TAG(VM_MEMORY_JAVASCRIPT_CORE) -#define VM_TAG_FOR_REGISTERFILE_MEMORY VM_MAKE_TAG(VM_MEMORY_JAVASCRIPT_JIT_REGISTER_FILE) +#if defined(VM_MEMORY_JAVASCRIPT_JIT_EXECUTABLE_ALLOCATOR) #define VM_TAG_FOR_EXECUTABLEALLOCATOR_MEMORY VM_MAKE_TAG(VM_MEMORY_JAVASCRIPT_JIT_EXECUTABLE_ALLOCATOR) #else -#define VM_TAG_FOR_COLLECTOR_MEMORY VM_MAKE_TAG(63) #define VM_TAG_FOR_EXECUTABLEALLOCATOR_MEMORY VM_MAKE_TAG(64) +#endif // defined(VM_MEMORY_JAVASCRIPT_JIT_EXECUTABLE_ALLOCATOR) + +#if defined(VM_MEMORY_JAVASCRIPT_JIT_REGISTER_FILE) +#define VM_TAG_FOR_REGISTERFILE_MEMORY VM_MAKE_TAG(VM_MEMORY_JAVASCRIPT_JIT_REGISTER_FILE) +#else #define VM_TAG_FOR_REGISTERFILE_MEMORY VM_MAKE_TAG(65) -#endif // defined(VM_MEMORY_JAVASCRIPT_CORE) && defined(VM_MEMORY_JAVASCRIPT_JIT_REGISTER_FILE) && defined(VM_MEMORY_JAVASCRIPT_JIT_EXECUTABLE_ALLOCATOR) && defined(VM_MEMORY_JAVASCRIPT_JIT_EXECUTABLE_ALLOCATOR) +#endif // defined(VM_MEMORY_JAVASCRIPT_JIT_REGISTER_FILE) + +#else // !defined(TARGETING_TIGER) + +// mmap on Tiger fails with tags that work on Leopard, so fall +// back to Tiger-compatible tags (that also work on Leopard) +// when targeting Tiger. +#define VM_TAG_FOR_TCMALLOC_MEMORY -1 +#define VM_TAG_FOR_EXECUTABLEALLOCATOR_MEMORY -1 +#define VM_TAG_FOR_REGISTERFILE_MEMORY -1 + +#endif // !defined(TARGETING_TIGER) + +// Tags for vm_map and vm_allocate work on both Tiger and Leopard. + +#if defined(VM_MEMORY_JAVASCRIPT_CORE) +#define VM_TAG_FOR_COLLECTOR_MEMORY VM_MAKE_TAG(VM_MEMORY_JAVASCRIPT_CORE) +#else +#define VM_TAG_FOR_COLLECTOR_MEMORY VM_MAKE_TAG(63) +#endif // defined(VM_MEMORY_JAVASCRIPT_CORE) #if defined(VM_MEMORY_WEBCORE_PURGEABLE_BUFFERS) #define VM_TAG_FOR_WEBCORE_PURGEABLE_MEMORY VM_MAKE_TAG(VM_MEMORY_WEBCORE_PURGEABLE_BUFFERS) @@ -56,7 +79,7 @@ #define VM_TAG_FOR_WEBCORE_PURGEABLE_MEMORY VM_MAKE_TAG(69) #endif // defined(VM_MEMORY_WEBCORE_PURGEABLE_BUFFERS) -#else // OS(DARWIN) && !defined(BUILDING_ON_TIGER) +#else // OS(DARWIN) #define VM_TAG_FOR_TCMALLOC_MEMORY -1 #define VM_TAG_FOR_COLLECTOR_MEMORY -1 @@ -64,6 +87,6 @@ #define VM_TAG_FOR_REGISTERFILE_MEMORY -1 #define VM_TAG_FOR_WEBCORE_PURGEABLE_MEMORY -1 -#endif // OS(DARWIN) && !defined(BUILDING_ON_TIGER) +#endif // OS(DARWIN) #endif // VMTags_h diff --git a/src/3rdparty/javascriptcore/VERSION b/src/3rdparty/javascriptcore/VERSION index 2b885a7..9a02027 100644 --- a/src/3rdparty/javascriptcore/VERSION +++ b/src/3rdparty/javascriptcore/VERSION @@ -4,8 +4,8 @@ This is a snapshot of JavaScriptCore from The commit imported was from the - javascriptcore-snapshot-07042010 branch/tag + javascriptcore-snapshot-20042010 branch/tag and has the sha1 checksum - 475f8c67522d8b3f3163dc3a6b24d6083fd0ac19 + c589321ffdda5e93cf77e2cf2cf43afe3e996f6e diff --git a/src/corelib/io/qdatastream.cpp b/src/corelib/io/qdatastream.cpp index 2731ae1..3a9d284 100644 --- a/src/corelib/io/qdatastream.cpp +++ b/src/corelib/io/qdatastream.cpp @@ -1144,16 +1144,17 @@ QDataStream &QDataStream::operator<<(double f) CHECK_STREAM_PRECOND(*this) #ifndef Q_DOUBLE_FORMAT - if (!noswap) { + if (noswap) { + dev->write((char *)&f, sizeof(double)); + } else { union { double val1; quint64 val2; } x; x.val1 = f; x.val2 = qbswap(x.val2); - f = x.val1; + dev->write((char *)&x.val2, sizeof(double)); } - dev->write((char *)&f, sizeof(double)); #else union { double val1; diff --git a/src/corelib/io/qfsfileengine_win.cpp b/src/corelib/io/qfsfileengine_win.cpp index eeca07e..ec49f1a 100644 --- a/src/corelib/io/qfsfileengine_win.cpp +++ b/src/corelib/io/qfsfileengine_win.cpp @@ -542,11 +542,13 @@ qint64 QFSFileEnginePrivate::nativeSize() const if (errorCode == ERROR_ACCESS_DENIED || errorCode == ERROR_SHARING_VIOLATION) { QByteArray path = nativeFilePath; // path for the FindFirstFile should not end with a trailing slash - while (path.endsWith('\\')) - path.chop(1); + while (!path.isEmpty() && reinterpret_cast<const wchar_t *>( + path.constData() + path.length())[-1] == '\\') + path.chop(2); // FindFirstFile can not handle drives - if (!path.endsWith(':')) { + if (!path.isEmpty() && reinterpret_cast<const wchar_t *>( + path.constData() + path.length())[-1] != ':') { WIN32_FIND_DATA findData; HANDLE hFind = ::FindFirstFile((const wchar_t*)path.constData(), &findData); diff --git a/src/corelib/kernel/qeventdispatcher_win.cpp b/src/corelib/kernel/qeventdispatcher_win.cpp index 2633a7c..135ec303 100644 --- a/src/corelib/kernel/qeventdispatcher_win.cpp +++ b/src/corelib/kernel/qeventdispatcher_win.cpp @@ -595,7 +595,7 @@ void QEventDispatcherWin32Private::registerTimer(WinTimerInfo *t) } else { ok = t->fastTimerId = qtimeSetEvent(t->interval, 1, qt_fast_timer_proc, (DWORD_PTR)t, TIME_CALLBACK_FUNCTION | TIME_PERIODIC | TIME_KILL_SYNCHRONOUS); - if (ok == 0) { // fall back to normal timer if no more multimedia timers avaiable + if (ok == 0) { // fall back to normal timer if no more multimedia timers available ok = SetTimer(internalHwnd, t->timerId, (uint) t->interval, 0); } } diff --git a/src/declarative/QmlChanges.txt b/src/declarative/QmlChanges.txt index 55f7b21..9c46467 100644 --- a/src/declarative/QmlChanges.txt +++ b/src/declarative/QmlChanges.txt @@ -3,6 +3,11 @@ The changes below are pre Qt 4.7.0 RC Flickable: overShoot is replaced by boundsBehavior enumeration. +C++ API +------- +QDeclarativeExpression::value() has been renamed to +QDeclarativeExpression::evaluate() + ============================================================================= The changes below are pre Qt 4.7.0 beta @@ -62,22 +67,22 @@ automatically 'followed' anymore. If you want to follow an hypothetical rect1, you should do now: - Rectangle { - color: "green" - width: 60; height: 60; - x: rect1.x - 5; y: rect1.y - 5; - Behavior on x { SmoothedAnimation { velocity: 200 } } - Behavior on y { SmoothedAnimation { velocity: 200 } } - } + Rectangle { + color: "green" + width: 60; height: 60; + x: rect1.x - 5; y: rect1.y - 5; + Behavior on x { SmoothedAnimation { velocity: 200 } } + Behavior on y { SmoothedAnimation { velocity: 200 } } + } instead of the old automatic source changed tracking: - Rectangle { - color: "green" - width: 60; height: 60; - EaseFollow on x { source: rect1.x - 5; velocity: 200 } - EaseFollow on y { source: rect1.y - 5; velocity: 200 } - } + Rectangle { + color: "green" + width: 60; height: 60; + EaseFollow on x { source: rect1.x - 5; velocity: 200 } + EaseFollow on y { source: rect1.y - 5; velocity: 200 } + } This is a syntax and behavior change. diff --git a/src/declarative/graphicsitems/qdeclarativeitemsmodule.cpp b/src/declarative/graphicsitems/qdeclarativeitemsmodule.cpp index 4238c53..2945b6c 100644 --- a/src/declarative/graphicsitems/qdeclarativeitemsmodule.cpp +++ b/src/declarative/graphicsitems/qdeclarativeitemsmodule.cpp @@ -143,6 +143,7 @@ void QDeclarativeItemModule::defineModule() qmlRegisterType<QAction>(); qmlRegisterType<QDeclarativePen>(); qmlRegisterType<QDeclarativeFlickableVisibleArea>(); + qmlRegisterType<QGraphicsEffect>(); qmlRegisterUncreatableType<QDeclarativeKeyNavigationAttached>("Qt",4,7,"KeyNavigation",QDeclarativeKeyNavigationAttached::tr("KeyNavigation is only available via attached properties")); qmlRegisterUncreatableType<QDeclarativeKeysAttached>("Qt",4,7,"Keys",QDeclarativeKeysAttached::tr("Keys is only available via attached properties")); diff --git a/src/declarative/graphicsitems/qdeclarativerectangle.cpp b/src/declarative/graphicsitems/qdeclarativerectangle.cpp index 3daa83f..0328f91 100644 --- a/src/declarative/graphicsitems/qdeclarativerectangle.cpp +++ b/src/declarative/graphicsitems/qdeclarativerectangle.cpp @@ -357,9 +357,7 @@ void QDeclarativeRectangle::generateBorderedRect() Q_D(QDeclarativeRectangle); if (d->rectImage.isNull()) { const int pw = d->pen && d->pen->isValid() ? d->pen->width() : 0; - // Adding 5 here makes qDrawBorderPixmap() paint correctly with smooth: true - // Ideally qDrawBorderPixmap() would be fixed - QTBUG-7999 - d->rectImage = QPixmap(pw*2 + 5, pw*2 + 5); + d->rectImage = QPixmap(pw*2 + 3, pw*2 + 3); d->rectImage.fill(Qt::transparent); QPainter p(&(d->rectImage)); p.setRenderHint(QPainter::Antialiasing); diff --git a/src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp b/src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp index 7fa8cc4..e2d8bc7 100644 --- a/src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp +++ b/src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp @@ -198,7 +198,7 @@ QVariant QDeclarativeVisualItemModel::evaluate(int index, const QString &express QDeclarativeContext *ctxt = new QDeclarativeContext(ccontext); ctxt->setContextObject(d->children.at(index)); QDeclarativeExpression e(ctxt, expression, objectContext); - QVariant value = e.value(); + QVariant value = e.evaluate(); delete ctxt; return value; } @@ -1138,7 +1138,7 @@ QVariant QDeclarativeVisualDataModel::evaluate(int index, const QString &express QDeclarativeItem *item = qobject_cast<QDeclarativeItem *>(nobj); if (item) { QDeclarativeExpression e(qmlContext(item), expression, objectContext); - value = e.value(); + value = e.evaluate(); } } else { QDeclarativeContext *ccontext = d->m_context; @@ -1147,7 +1147,7 @@ QVariant QDeclarativeVisualDataModel::evaluate(int index, const QString &express QDeclarativeVisualDataModelData *data = new QDeclarativeVisualDataModelData(index, this); ctxt->setContextObject(data); QDeclarativeExpression e(ctxt, expression, objectContext); - value = e.value(); + value = e.evaluate(); delete data; delete ctxt; } diff --git a/src/declarative/qml/qdeclarativeboundsignal.cpp b/src/declarative/qml/qdeclarativeboundsignal.cpp index eb352a2..89f1256 100644 --- a/src/declarative/qml/qdeclarativeboundsignal.cpp +++ b/src/declarative/qml/qdeclarativeboundsignal.cpp @@ -97,8 +97,6 @@ QDeclarativeBoundSignal::QDeclarativeBoundSignal(QObject *scope, const QMetaMeth QObject *parent) : m_expression(0), m_signal(signal), m_paramsValid(false), m_isEvaluating(false), m_params(0) { - // A cached evaluation of the QDeclarativeExpression::value() slot index. - // // This is thread safe. Although it may be updated by two threads, they // will both set it to the same value - so the worst thing that can happen // is that they both do the work to figure it out. Boo hoo. @@ -113,8 +111,6 @@ QDeclarativeBoundSignal::QDeclarativeBoundSignal(QDeclarativeContext *ctxt, cons QObject *parent) : m_expression(0), m_signal(signal), m_paramsValid(false), m_isEvaluating(false), m_params(0) { - // A cached evaluation of the QDeclarativeExpression::value() slot index. - // // This is thread safe. Although it may be updated by two threads, they // will both set it to the same value - so the worst thing that can happen // is that they both do the work to figure it out. Boo hoo. diff --git a/src/declarative/qml/qdeclarativecomponent.cpp b/src/declarative/qml/qdeclarativecomponent.cpp index c86f089..3899e73 100644 --- a/src/declarative/qml/qdeclarativecomponent.cpp +++ b/src/declarative/qml/qdeclarativecomponent.cpp @@ -67,14 +67,14 @@ int statusId = qRegisterMetaType<QDeclarativeComponent::Status>("QDeclarativeCom /*! \class QDeclarativeComponent - \since 4.7 + \since 4.7 \brief The QDeclarativeComponent class encapsulates a QML component description. \mainclass */ /*! \qmlclass Component QDeclarativeComponent - \since 4.7 + \since 4.7 \brief The Component element encapsulates a QML component description. Components are reusable, encapsulated Qml element with a well-defined interface. @@ -86,26 +86,26 @@ int statusId = qRegisterMetaType<QDeclarativeComponent::Status>("QDeclarativeCom file containing it. \qml -Item { - Component { - id: redSquare - Rectangle { - color: "red" - width: 10 - height: 10 + Item { + Component { + id: redSquare + Rectangle { + color: "red" + width: 10 + height: 10 + } } + Loader { sourceComponent: redSquare } + Loader { sourceComponent: redSquare; x: 20 } } - Loader { sourceComponent: redSquare } - Loader { sourceComponent: redSquare; x: 20 } -} \endqml +*/ - \section1 Attached Properties - - \e onCompleted +/*! + \qmlattachedsignal Component::onCompleted() Emitted after component "startup" has completed. This can be used to - execute script code at startup, once the full QML environment has been + execute script code at startup, once the full QML environment has been established. The \c {Component::onCompleted} attached property can be applied to @@ -120,8 +120,10 @@ Item { } } \endqml +*/ - \e onDestruction +/*! + \qmlattachedsignal Component::onDestruction() Emitted as the component begins destruction. This can be used to undo work done in the onCompleted signal, or other imperative code in your @@ -129,7 +131,7 @@ Item { The \c {Component::onDestruction} attached property can be applied to any element. However, it applies to the destruction of the component as - a whole, and not the destruction of the specific object. The order of + a whole, and not the destruction of the specific object. The order of running the \c onDestruction scripts is undefined. \qml diff --git a/src/declarative/qml/qdeclarativecomponent.h b/src/declarative/qml/qdeclarativecomponent.h index 526a319..f3cfe3c 100644 --- a/src/declarative/qml/qdeclarativecomponent.h +++ b/src/declarative/qml/qdeclarativecomponent.h @@ -117,6 +117,7 @@ protected: private: QDeclarativeComponent(QDeclarativeEngine *, QDeclarativeCompiledData *, int, int, QObject *parent); + Q_DISABLE_COPY(QDeclarativeComponent) friend class QDeclarativeVME; friend class QDeclarativeCompositeTypeData; }; diff --git a/src/declarative/qml/qdeclarativecontext.h b/src/declarative/qml/qdeclarativecontext.h index 94c9f4a..548869c 100644 --- a/src/declarative/qml/qdeclarativecontext.h +++ b/src/declarative/qml/qdeclarativecontext.h @@ -103,6 +103,7 @@ private: friend class QDeclarativeContextData; QDeclarativeContext(QDeclarativeContextData *); QDeclarativeContext(QDeclarativeEngine *, bool); + Q_DISABLE_COPY(QDeclarativeContext) }; QT_END_NAMESPACE diff --git a/src/declarative/qml/qdeclarativeengine.h b/src/declarative/qml/qdeclarativeengine.h index e161cd9..01487f5 100644 --- a/src/declarative/qml/qdeclarativeengine.h +++ b/src/declarative/qml/qdeclarativeengine.h @@ -118,6 +118,7 @@ Q_SIGNALS: void warnings(const QList<QDeclarativeError> &warnings); private: + Q_DISABLE_COPY(QDeclarativeEngine) Q_DECLARE_PRIVATE(QDeclarativeEngine) }; diff --git a/src/declarative/qml/qdeclarativeenginedebug.cpp b/src/declarative/qml/qdeclarativeenginedebug.cpp index 264fd8d..69e42f8 100644 --- a/src/declarative/qml/qdeclarativeenginedebug.cpp +++ b/src/declarative/qml/qdeclarativeenginedebug.cpp @@ -416,7 +416,7 @@ void QDeclarativeEngineDebugServer::messageReceived(const QByteArray &message) if (object && context) { QDeclarativeExpression exprObj(context, expr, object); bool undefined = false; - QVariant value = exprObj.value(&undefined); + QVariant value = exprObj.evaluate(&undefined); if (undefined) result = QLatin1String("<undefined>"); else diff --git a/src/declarative/qml/qdeclarativeexpression.cpp b/src/declarative/qml/qdeclarativeexpression.cpp index 8b5a62f..f561a7e 100644 --- a/src/declarative/qml/qdeclarativeexpression.cpp +++ b/src/declarative/qml/qdeclarativeexpression.cpp @@ -479,18 +479,18 @@ QVariant QDeclarativeExpressionPrivate::value(QObject *secondaryScope, bool *isU } /*! - Returns the value of the expression, or an invalid QVariant if the - expression is invalid or has an error. + Evaulates the expression, returning the result of the evaluation, + or an invalid QVariant if the expression is invalid or has an error. - \a isUndefined is set to true if the expression resulted in an + \a valueIsUndefined is set to true if the expression resulted in an undefined value. \sa hasError(), error() */ -QVariant QDeclarativeExpression::value(bool *isUndefined) +QVariant QDeclarativeExpression::evaluate(bool *valueIsUndefined) { Q_D(QDeclarativeExpression); - return d->value(0, isUndefined); + return d->value(0, valueIsUndefined); } /*! @@ -569,7 +569,7 @@ QObject *QDeclarativeExpression::scopeObject() const } /*! - Returns true if the last call to value() resulted in an error, + Returns true if the last call to evaluate() resulted in an error, otherwise false. \sa error(), clearError() @@ -593,7 +593,7 @@ void QDeclarativeExpression::clearError() } /*! - Return any error from the last call to value(). If there was no error, + Return any error from the last call to evaluate(). If there was no error, this returns an invalid QDeclarativeError instance. \sa hasError(), clearError() @@ -606,10 +606,9 @@ QDeclarativeError QDeclarativeExpression::error() const } /*! \internal */ -void QDeclarativeExpression::__q_notify() +void QDeclarativeExpressionPrivate::_q_notify() { - Q_D(QDeclarativeExpression); - d->emitValueChanged(); + emitValueChanged(); } void QDeclarativeExpressionPrivate::clearGuards() @@ -625,7 +624,7 @@ void QDeclarativeExpressionPrivate::updateGuards(const QPODVector<QDeclarativeEn static int notifyIdx = -1; if (notifyIdx == -1) - notifyIdx = QDeclarativeExpression::staticMetaObject.indexOfMethod("__q_notify()"); + notifyIdx = QDeclarativeExpression::staticMetaObject.indexOfMethod("_q_notify()"); if (properties.count() != data->guardListLength) { QDeclarativeNotifierEndpoint *newGuardList = @@ -711,7 +710,7 @@ void QDeclarativeExpressionPrivate::updateGuards(const QPODVector<QDeclarativeEn Emitted each time the expression value changes from the last time it was evaluated. The expression must have been evaluated at least once (by - calling QDeclarativeExpression::value()) before this signal will be emitted. + calling QDeclarativeExpression::evaluate()) before this signal will be emitted. */ void QDeclarativeExpressionPrivate::emitValueChanged() @@ -771,3 +770,4 @@ bool QDeclarativeAbstractExpression::isValid() const QT_END_NAMESPACE +#include <moc_qdeclarativeexpression.cpp> diff --git a/src/declarative/qml/qdeclarativeexpression.h b/src/declarative/qml/qdeclarativeexpression.h index 35d6949..6c72e4d 100644 --- a/src/declarative/qml/qdeclarativeexpression.h +++ b/src/declarative/qml/qdeclarativeexpression.h @@ -86,7 +86,7 @@ public: void clearError(); QDeclarativeError error() const; - QVariant value(bool *isUndefined = 0); + QVariant evaluate(bool *valueIsUndefined = 0); Q_SIGNALS: void valueChanged(); @@ -97,13 +97,12 @@ protected: QDeclarativeExpression(QDeclarativeContextData *, void *, QDeclarativeRefCount *rc, QObject *me, const QString &, int, QDeclarativeExpressionPrivate &dd); -private Q_SLOTS: - void __q_notify(); - private: QDeclarativeExpression(QDeclarativeContextData *, const QString &, QObject *); + Q_DISABLE_COPY(QDeclarativeExpression) Q_DECLARE_PRIVATE(QDeclarativeExpression) + Q_PRIVATE_SLOT(d_func(), void _q_notify()) friend class QDeclarativeDebugger; friend class QDeclarativeContext; friend class QDeclarativeVME; diff --git a/src/declarative/qml/qdeclarativeexpression_p.h b/src/declarative/qml/qdeclarativeexpression_p.h index d39aa2c..4ff3162 100644 --- a/src/declarative/qml/qdeclarativeexpression_p.h +++ b/src/declarative/qml/qdeclarativeexpression_p.h @@ -164,6 +164,7 @@ public: return expr->q_func(); } + void _q_notify(); virtual void emitValueChanged(); static void exceptionToError(QScriptEngine *, QDeclarativeError &); diff --git a/src/declarative/qml/qdeclarativeextensionplugin.h b/src/declarative/qml/qdeclarativeextensionplugin.h index 8095ec7..8a9378a 100644 --- a/src/declarative/qml/qdeclarativeextensionplugin.h +++ b/src/declarative/qml/qdeclarativeextensionplugin.h @@ -64,6 +64,9 @@ public: virtual void registerTypes(const char *uri) = 0; virtual void initializeEngine(QDeclarativeEngine *engine, const char *uri); + +private: + Q_DISABLE_COPY(QDeclarativeExtensionPlugin) }; QT_END_NAMESPACE diff --git a/src/declarative/qml/qdeclarativewatcher.cpp b/src/declarative/qml/qdeclarativewatcher.cpp index 9ea84b8..842b3c4 100644 --- a/src/declarative/qml/qdeclarativewatcher.cpp +++ b/src/declarative/qml/qdeclarativewatcher.cpp @@ -110,7 +110,7 @@ void QDeclarativeWatchProxy::notifyValueChanged() { QVariant v; if (m_expr) - v = m_expr->value(); + v = m_expr->evaluate(); else v = m_property.read(m_object); diff --git a/src/declarative/util/qdeclarativeanimation.cpp b/src/declarative/util/qdeclarativeanimation.cpp index 4f7719b..3b0d264 100644 --- a/src/declarative/util/qdeclarativeanimation.cpp +++ b/src/declarative/util/qdeclarativeanimation.cpp @@ -780,7 +780,7 @@ void QDeclarativeScriptActionPrivate::execute() QDeclarativeData *ddata = QDeclarativeData::get(q); if (ddata && ddata->outerContext && !ddata->outerContext->url.isEmpty()) expr.setSourceLocation(ddata->outerContext->url.toString(), ddata->lineNumber); - expr.value(); + expr.evaluate(); if (expr.hasError()) qmlInfo(q) << expr.error(); } diff --git a/src/declarative/util/qdeclarativepropertychanges.cpp b/src/declarative/util/qdeclarativepropertychanges.cpp index 8a6937d..2641dcf 100644 --- a/src/declarative/util/qdeclarativepropertychanges.cpp +++ b/src/declarative/util/qdeclarativepropertychanges.cpp @@ -434,7 +434,7 @@ QDeclarativePropertyChanges::ActionList QDeclarativePropertyChanges::actions() a.specifiedProperty = QString::fromUtf8(property); if (d->isExplicit) { - a.toValue = d->expressions.at(ii).second->value(); + a.toValue = d->expressions.at(ii).second->evaluate(); } else { QDeclarativeBinding *newBinding = new QDeclarativeBinding(d->expressions.at(ii).second->expression(), object(), qmlContext(this)); diff --git a/src/declarative/util/qdeclarativestategroup.cpp b/src/declarative/util/qdeclarativestategroup.cpp index 81f4230..2349ce1 100644 --- a/src/declarative/util/qdeclarativestategroup.cpp +++ b/src/declarative/util/qdeclarativestategroup.cpp @@ -288,7 +288,7 @@ bool QDeclarativeStateGroupPrivate::updateAutoState() QDeclarativeState *state = states.at(ii); if (state->isWhenKnown()) { if (!state->name().isEmpty()) { - if (state->when() && state->when()->value().toBool()) { + if (state->when() && state->when()->evaluate().toBool()) { if (stateChangeDebug()) qWarning() << "Setting auto state due to:" << state->when()->expression(); diff --git a/src/declarative/util/qdeclarativestateoperations.cpp b/src/declarative/util/qdeclarativestateoperations.cpp index 0aad498..9049b83 100644 --- a/src/declarative/util/qdeclarativestateoperations.cpp +++ b/src/declarative/util/qdeclarativestateoperations.cpp @@ -579,7 +579,7 @@ void QDeclarativeStateChangeScript::execute(Reason) QDeclarativeData *ddata = QDeclarativeData::get(this); if (ddata && ddata->outerContext && !ddata->outerContext->url.isEmpty()) expr.setSourceLocation(ddata->outerContext->url.toString(), ddata->lineNumber); - expr.value(); + expr.evaluate(); if (expr.hasError()) qmlInfo(this, expr.error()); } diff --git a/src/declarative/util/qdeclarativeview.h b/src/declarative/util/qdeclarativeview.h index 1807758..3513c04 100644 --- a/src/declarative/util/qdeclarativeview.h +++ b/src/declarative/util/qdeclarativeview.h @@ -105,8 +105,10 @@ protected: virtual void setRootObject(QObject *obj); virtual bool eventFilter(QObject *watched, QEvent *e); +private: friend class QDeclarativeViewPrivate; QDeclarativeViewPrivate *d; + Q_DISABLE_COPY(QDeclarativeView) }; QT_END_NAMESPACE diff --git a/src/gui/kernel/qapplication_win.cpp b/src/gui/kernel/qapplication_win.cpp index 1d8eb4c..fb2837e 100644 --- a/src/gui/kernel/qapplication_win.cpp +++ b/src/gui/kernel/qapplication_win.cpp @@ -79,6 +79,7 @@ extern void qt_wince_hide_taskbar(HWND hwnd); //defined in qguifunctions_wince.c #include "qlayout.h" #include "qtooltip.h" #include "qt_windows.h" +#include "qscrollbar.h" #if defined(QT_NON_COMMERCIAL) #include "qnc_win.h" #endif @@ -701,6 +702,21 @@ void QApplicationPrivate::initializeWidgetPaletteHash() QApplication::setPalette(menu, "QMenuBar"); } +static void qt_set_windows_updateScrollBar(QWidget *widget) +{ + QList<QObject*> children = widget->children(); + for (int i = 0; i < children.size(); ++i) { + QObject *o = children.at(i); + if(!o->isWidgetType()) + continue; + if (QWidget *w = static_cast<QWidget *>(o)) + qt_set_windows_updateScrollBar(w); + } + if (qobject_cast<QScrollBar*>(widget)) + widget->updateGeometry(); +} + + /***************************************************************************** qt_init() - initializes Qt for Windows *****************************************************************************/ @@ -1930,6 +1946,15 @@ extern "C" LRESULT QT_WIN_CALLBACK QtWndProc(HWND hwnd, UINT message, WPARAM wPa } } } + else if (msg.wParam == SPI_SETNONCLIENTMETRICS) { + widget = (QETWidget*)QWidget::find(hwnd); + if (widget && !widget->parentWidget()) { + qt_set_windows_updateScrollBar(widget); + QEvent e(QEvent::LayoutRequest); + QApplication::sendEvent(widget, &e); + } + } + break; case WM_PAINT: // paint event diff --git a/src/gui/kernel/qcocoamenuloader_mac.mm b/src/gui/kernel/qcocoamenuloader_mac.mm index b58fd7c..8d65aa1 100644 --- a/src/gui/kernel/qcocoamenuloader_mac.mm +++ b/src/gui/kernel/qcocoamenuloader_mac.mm @@ -53,6 +53,12 @@ QT_FORWARD_DECLARE_CLASS(QCFString) QT_FORWARD_DECLARE_CLASS(QString) +#ifndef QT_NO_TRANSLATION + QT_BEGIN_NAMESPACE + extern QString qt_mac_applicationmenu_string(int type); + QT_END_NAMESPACE +#endif + QT_USE_NAMESPACE @implementation QT_MANGLE_NAMESPACE(QCocoaMenuLoader) @@ -226,7 +232,6 @@ QT_USE_NAMESPACE - (void)qtTranslateApplicationMenu { #ifndef QT_NO_TRANSLATION - extern QString qt_mac_applicationmenu_string(int type); [servicesItem setTitle: qt_mac_QStringToNSString(qt_mac_applicationmenu_string(0))]; [hideItem setTitle: qt_mac_QStringToNSString(qt_mac_applicationmenu_string(1).arg(qAppName()))]; [hideAllOthersItem setTitle: qt_mac_QStringToNSString(qt_mac_applicationmenu_string(2))]; diff --git a/src/gui/kernel/qcocoasharedwindowmethods_mac_p.h b/src/gui/kernel/qcocoasharedwindowmethods_mac_p.h index ec00915..e94d247 100644 --- a/src/gui/kernel/qcocoasharedwindowmethods_mac_p.h +++ b/src/gui/kernel/qcocoasharedwindowmethods_mac_p.h @@ -101,6 +101,17 @@ QT_END_NAMESPACE return !(isPopup || isToolTip || isTool); } +- (void)becomeMainWindow +{ + [super becomeMainWindow]; + // Cocoa sometimes tell a hidden window to become the + // main window (and as such, show it). This can e.g + // happend when the application gets activated. If + // this is the case, we tell it to hide again: + if (![self isVisible]) + [self orderOut:self]; +} + - (void)toggleToolbarShown:(id)sender { macSendToolbarChangeEvent([self QT_MANGLE_NAMESPACE(qt_qwidget)]); diff --git a/src/gui/styles/qmacstyle_mac.mm b/src/gui/styles/qmacstyle_mac.mm index 074dd89..f5b0b0c 100644 --- a/src/gui/styles/qmacstyle_mac.mm +++ b/src/gui/styles/qmacstyle_mac.mm @@ -2143,7 +2143,7 @@ int QMacStyle::pixelMetric(PixelMetric metric, const QStyleOption *opt, const QW if (qstyleoption_cast<const QStyleOptionComboBox *>(opt) != 0) ret = 0; else - ret = QWindowsStyle::pixelMetric(metric, opt, widget); + ret = 1; break; case PM_MaximumDragDistance: ret = -1; @@ -3099,14 +3099,16 @@ void QMacStyle::drawPrimitive(PrimitiveElement pe, const QStyleOption *opt, QPai HIRect hirect = qt_hirectForQRect(opt->rect); HIThemeDrawButton(&hirect, &bi, cg, kHIThemeOrientationNormal, 0); break; } + case PE_Frame: { QPen oldPen = p->pen(); - QPen newPen; - newPen.setBrush(opt->palette.dark()); - p->setPen(newPen); + p->setPen(opt->palette.base().color().darker(140)); p->drawRect(opt->rect.adjusted(0, 0, -1, -1)); + p->setPen(opt->palette.base().color().darker(180)); + p->drawLine(opt->rect.topLeft(), opt->rect.topRight()); p->setPen(oldPen); break; } + case PE_FrameLineEdit: if (const QStyleOptionFrame *frame = qstyleoption_cast<const QStyleOptionFrame *>(opt)) { if (frame->state & State_Sunken) { @@ -3279,10 +3281,14 @@ void QMacStyle::drawControl(ControlElement ce, const QStyleOption *opt, QPainter if (header->orientation == Qt::Horizontal){ switch (header->position) { case QStyleOptionHeader::Beginning: + ir.adjust(-1, -1, 0, 0); break; case QStyleOptionHeader::Middle: + ir.adjust(-1, -1, 0, 0); + break; + case QStyleOptionHeader::OnlyOneSection: case QStyleOptionHeader::End: - ir.adjust(-1, 0, 0, 0); + ir.adjust(-1, -1, 1, 0); break; default: break; diff --git a/src/gui/widgets/qabstractscrollarea.cpp b/src/gui/widgets/qabstractscrollarea.cpp index 73ec53e..8cffebd 100644 --- a/src/gui/widgets/qabstractscrollarea.cpp +++ b/src/gui/widgets/qabstractscrollarea.cpp @@ -983,6 +983,7 @@ bool QAbstractScrollArea::event(QEvent *e) case QEvent::StyleChange: case QEvent::LayoutDirectionChange: case QEvent::ApplicationLayoutDirectionChange: + case QEvent::LayoutRequest: d->layoutChildren(); // fall through default: diff --git a/src/gui/widgets/qmenu_mac.mm b/src/gui/widgets/qmenu_mac.mm index 6a0eb53..7645c23 100644 --- a/src/gui/widgets/qmenu_mac.mm +++ b/src/gui/widgets/qmenu_mac.mm @@ -665,6 +665,7 @@ void qt_mac_set_modal_state_helper_recursive(OSMenuRef menu, OSMenuRef merge, bo } } #else + bool modalWindowOnScreen = qApp->activeModalWidget() != 0; for (NSMenuItem *item in [menu itemArray]) { OSMenuRef submenu = [item submenu]; if (submenu != merge) { @@ -674,10 +675,20 @@ void qt_mac_set_modal_state_helper_recursive(OSMenuRef menu, OSMenuRef merge, bo // The item should follow what the QAction has. if ([item tag]) { QAction *action = reinterpret_cast<QAction *>([item tag]); - syncNSMenuItemEnabled(item, action->isEnabled()); - } else { - syncNSMenuItemEnabled(item, YES); - } + syncNSMenuItemEnabled(item, action->isEnabled()); + } else { + syncNSMenuItemEnabled(item, YES); + } + // We sneak in some extra code here to handle a menu problem: + // If there is no window on screen, we cannot set 'nil' as + // menu item target, because then cocoa will disable the item + // (guess it assumes that there will be no first responder to + // catch the trigger anyway?) OTOH, If we have a modal window, + // then setting the menu loader as target will make cocoa not + // deliver the trigger because the loader is then seen as modally + // shaddowed). So either way there are shortcomings. Instead, we + // decide the target as late as possible: + [item setTarget:modalWindowOnScreen ? nil : getMenuLoader()]; } else { syncNSMenuItemEnabled(item, NO); } diff --git a/src/network/bearer/qnetworkconfigmanager_p.cpp b/src/network/bearer/qnetworkconfigmanager_p.cpp index a651dd1..a7bd2d5 100644 --- a/src/network/bearer/qnetworkconfigmanager_p.cpp +++ b/src/network/bearer/qnetworkconfigmanager_p.cpp @@ -381,7 +381,7 @@ void QNetworkConfigurationManagerPrivate::updateConfigurations() connect(engine, SIGNAL(configurationChanged(QNetworkConfigurationPrivatePointer)), this, SLOT(configurationChanged(QNetworkConfigurationPrivatePointer))); - QMetaObject::invokeMethod(engine, "requestUpdate"); + QMetaObject::invokeMethod(engine, "initialize"); } } diff --git a/src/network/kernel/qhostinfo.cpp b/src/network/kernel/qhostinfo.cpp index baf69e7..7e006e0 100644 --- a/src/network/kernel/qhostinfo.cpp +++ b/src/network/kernel/qhostinfo.cpp @@ -488,9 +488,23 @@ QHostInfoLookupManager::~QHostInfoLookupManager() wasDeleted = true; // don't qDeleteAll currentLookups, the QThreadPool has ownership - qDeleteAll(postponedLookups); - qDeleteAll(scheduledLookups); - qDeleteAll(finishedLookups); + clear(); +} + +void QHostInfoLookupManager::clear() +{ + { + QMutexLocker locker(&mutex); + qDeleteAll(postponedLookups); + qDeleteAll(scheduledLookups); + qDeleteAll(finishedLookups); + postponedLookups.clear(); + scheduledLookups.clear(); + finishedLookups.clear(); + } + + threadPool.waitForDone(); + cache.clear(); } void QHostInfoLookupManager::work() @@ -636,7 +650,7 @@ void qt_qhostinfo_clear_cache() { QHostInfoLookupManager* manager = theHostInfoLookupManager(); if (manager) { - manager->cache.clear(); + manager->clear(); } } diff --git a/src/network/kernel/qhostinfo_p.h b/src/network/kernel/qhostinfo_p.h index 4fc74e9..e11766b 100644 --- a/src/network/kernel/qhostinfo_p.h +++ b/src/network/kernel/qhostinfo_p.h @@ -116,7 +116,7 @@ public: // These functions are outside of the QHostInfo class and strictly internal. // Do NOT use them outside of QAbstractSocket. QHostInfo Q_NETWORK_EXPORT qt_qhostinfo_lookup(const QString &name, QObject *receiver, const char *member, bool *valid, int *id); -void Q_NETWORK_EXPORT qt_qhostinfo_clear_cache(); +void Q_AUTOTEST_EXPORT qt_qhostinfo_clear_cache(); void Q_AUTOTEST_EXPORT qt_qhostinfo_enable_cache(bool e); class QHostInfoCache @@ -161,6 +161,7 @@ public: QHostInfoLookupManager(); ~QHostInfoLookupManager(); + void clear(); void work(); // called from QHostInfo diff --git a/src/plugins/bearer/corewlan/qcorewlanengine.h b/src/plugins/bearer/corewlan/qcorewlanengine.h index 5c69299..3c24c54 100644 --- a/src/plugins/bearer/corewlan/qcorewlanengine.h +++ b/src/plugins/bearer/corewlan/qcorewlanengine.h @@ -47,15 +47,18 @@ #include <QMap> #include <QTimer> #include <SystemConfiguration/SystemConfiguration.h> +#include <QThread> #ifndef QT_NO_BEARERMANAGEMENT QT_BEGIN_NAMESPACE class QNetworkConfigurationPrivate; +class QScanThread; class QCoreWlanEngine : public QBearerEngineImpl { + friend class QScanThread; Q_OBJECT public: @@ -70,6 +73,7 @@ public: void connectToId(const QString &id); void disconnectFromId(const QString &id); + Q_INVOKABLE void initialize(); Q_INVOKABLE void requestUpdate(); QNetworkSession::State sessionStateForId(const QString &id); @@ -84,27 +88,52 @@ public: private Q_SLOTS: void doRequestUpdate(); + void networksChanged(); private: bool isWifiReady(const QString &dev); - QMap<QString, QString> configurationInterface; - QStringList scanForSsids(const QString &interfaceName); - - bool isKnownSsid(const QString &ssid); QList<QNetworkConfigurationPrivate *> foundConfigurations; SCDynamicStoreRef storeSession; CFRunLoopSourceRef runloopSource; bool hasWifi; + bool scanning; + QScanThread *scanThread; protected: - QMap<QString, QMap<QString,QString> > userProfiles; - void startNetworkChangeLoop(); + +}; + +class QScanThread : public QThread +{ + Q_OBJECT + +public: + QScanThread(QObject *parent = 0); + ~QScanThread(); + + void quit(); + QList<QNetworkConfigurationPrivate *> getConfigurations(); + QString interfaceName; + QMap<QString, QString> configurationInterface; void getUserConfigurations(); QString getNetworkNameFromSsid(const QString &ssid); QString getSsidFromNetworkName(const QString &name); + bool isKnownSsid(const QString &ssid); + QMap<QString, QMap<QString,QString> > userProfiles; + +signals: + void networksChanged(); + +protected: + void run(); + +private: + QList<QNetworkConfigurationPrivate *> fetchedConfigurations; + QMutex mutex; QStringList foundNetwork(const QString &id, const QString &ssid, const QNetworkConfiguration::StateFlags state, const QString &interfaceName, const QNetworkConfiguration::Purpose purpose); + }; QT_END_NAMESPACE diff --git a/src/plugins/bearer/corewlan/qcorewlanengine.mm b/src/plugins/bearer/corewlan/qcorewlanengine.mm index 268126a..3206833 100644 --- a/src/plugins/bearer/corewlan/qcorewlanengine.mm +++ b/src/plugins/bearer/corewlan/qcorewlanengine.mm @@ -67,10 +67,6 @@ #include <private/qt_cocoa_helpers_mac_p.h> #include "private/qcore_mac_p.h" -#ifndef QT_NO_BEARERMANAGEMENT - -QT_BEGIN_NAMESPACE - @interface QNSListener : NSObject { NSNotificationCenter *center; @@ -96,7 +92,6 @@ QT_BEGIN_NAMESPACE QMacCocoaAutoReleasePool pool; center = [NSNotificationCenter defaultCenter]; currentInterface = [CWInterface interfaceWithName:nil]; -// [center addObserver:self selector:@selector(notificationHandler:) name:kCWLinkDidChangeNotification object:nil]; [center addObserver:self selector:@selector(notificationHandler:) name:kCWPowerDidChangeNotification object:nil]; [locker unlock]; return self; @@ -130,6 +125,8 @@ QT_BEGIN_NAMESPACE QNSListener *listener = 0; +QT_BEGIN_NAMESPACE + void networkChangeCallback(SCDynamicStoreRef/* store*/, CFArrayRef changedKeys, void *info) { for ( long i = 0; i < CFArrayGetCount(changedKeys); i++) { @@ -143,20 +140,279 @@ void networkChangeCallback(SCDynamicStoreRef/* store*/, CFArrayRef changedKeys, return; } -QCoreWlanEngine::QCoreWlanEngine(QObject *parent) -: QBearerEngineImpl(parent) + +QScanThread::QScanThread(QObject *parent) + :QThread(parent) { - startNetworkChangeLoop(); +} + +QScanThread::~QScanThread() +{ +} + +void QScanThread::quit() +{ + wait(); +} + +void QScanThread::run() +{ + NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; + QStringList found; + mutex.lock(); + CWInterface *currentInterface = [CWInterface interfaceWithName:qt_mac_QStringToNSString(interfaceName)]; + mutex.unlock(); + + if([currentInterface power]) { + NSError *err = nil; + NSDictionary *parametersDict = [NSDictionary dictionaryWithObjectsAndKeys: + [NSNumber numberWithBool:YES], kCWScanKeyMerge, + [NSNumber numberWithInteger:100], kCWScanKeyRestTime, nil]; + + NSArray* apArray = [currentInterface scanForNetworksWithParameters:parametersDict error:&err]; + CWNetwork *apNetwork; + + if (!err) { + + for(uint row=0; row < [apArray count]; row++ ) { + apNetwork = [apArray objectAtIndex:row]; + + const QString networkSsid = qt_mac_NSStringToQString([apNetwork ssid]); + const QString id = QString::number(qHash(QLatin1String("corewlan:") + networkSsid)); + found.append(id); + + QNetworkConfiguration::StateFlags state = QNetworkConfiguration::Undefined; + bool known = isKnownSsid(networkSsid); + if( [currentInterface.interfaceState intValue] == kCWInterfaceStateRunning) { + if( networkSsid == qt_mac_NSStringToQString( [currentInterface ssid])) { + state = QNetworkConfiguration::Active; + } + } + if(state == QNetworkConfiguration::Undefined) { + if(known) { + state = QNetworkConfiguration::Discovered; + } else { + state = QNetworkConfiguration::Undefined; + } + } + QNetworkConfiguration::Purpose purpose = QNetworkConfiguration::UnknownPurpose; + if([[apNetwork securityMode] intValue] == kCWSecurityModeOpen) { + purpose = QNetworkConfiguration::PublicPurpose; + } else { + purpose = QNetworkConfiguration::PrivatePurpose; + } + + found.append(foundNetwork(id, networkSsid, state, interfaceName, purpose)); + + } //end row +// [parametersDict release]; + + } //end error + } // endwifi power + // add known configurations that are not around. + QMapIterator<QString, QMap<QString,QString> > i(userProfiles); + while (i.hasNext()) { + i.next(); + + QString networkName = i.key(); + const QString id = QString::number(qHash(QLatin1String("corewlan:") + networkName)); + + if(!found.contains(id)) { + QString networkSsid = getSsidFromNetworkName(networkName); + const QString ssidId = QString::number(qHash(QLatin1String("corewlan:") + networkSsid)); + QNetworkConfiguration::StateFlags state = QNetworkConfiguration::Undefined; + QString interfaceName; + QMapIterator<QString, QString> ij(i.value()); + while (ij.hasNext()) { + ij.next(); + interfaceName = ij.value(); + } + + if( [currentInterface.interfaceState intValue] == kCWInterfaceStateRunning) { + if( networkSsid == qt_mac_NSStringToQString([currentInterface ssid])) { + state = QNetworkConfiguration::Active; + } + } + if(state == QNetworkConfiguration::Undefined) { + if( userProfiles.contains(networkName) + && found.contains(ssidId)) { + state = QNetworkConfiguration::Discovered; + } + } + + if(state == QNetworkConfiguration::Undefined) { + state = QNetworkConfiguration::Defined; + } + + found.append(foundNetwork(id, networkName, state, interfaceName, QNetworkConfiguration::UnknownPurpose)); + } + } + emit networksChanged(); + [pool release]; +} + +QStringList QScanThread::foundNetwork(const QString &id, const QString &name, const QNetworkConfiguration::StateFlags state, const QString &interfaceName, const QNetworkConfiguration::Purpose purpose) +{ + QStringList found; + QMutexLocker locker(&mutex); + QNetworkConfigurationPrivate *ptr = new QNetworkConfigurationPrivate; + + ptr->name = name; + ptr->isValid = true; + ptr->id = id; + ptr->state = state; + ptr->type = QNetworkConfiguration::InternetAccessPoint; + ptr->bearer = QLatin1String("WLAN"); + ptr->purpose = purpose; + + fetchedConfigurations.append( ptr); + configurationInterface.insert(ptr->id, interfaceName); + + locker.unlock(); + locker.relock(); + found.append(id); + return found; +} + +QList<QNetworkConfigurationPrivate *> QScanThread::getConfigurations() +{ + QMutexLocker locker(&mutex); + + QList<QNetworkConfigurationPrivate *> foundConfigurations = fetchedConfigurations; + fetchedConfigurations.clear(); + + return foundConfigurations; +} + +void QScanThread::getUserConfigurations() +{ + QMutexLocker locker(&mutex); QMacCocoaAutoReleasePool pool; - if([[CWInterface supportedInterfaces] count] > 0 && !listener) { - listener = [[QNSListener alloc] init]; - listener.engine = this; - hasWifi = true; - } else { - hasWifi = false; + userProfiles.clear(); + + NSArray *wifiInterfaces = [CWInterface supportedInterfaces]; + for(uint row=0; row < [wifiInterfaces count]; row++ ) { + + CWInterface *wifiInterface = [CWInterface interfaceWithName: [wifiInterfaces objectAtIndex:row]]; + NSString *nsInterfaceName = [wifiInterface name]; +// add user configured system networks + SCDynamicStoreRef dynRef = SCDynamicStoreCreate(kCFAllocatorSystemDefault, (CFStringRef)@"Qt corewlan", nil, nil); + NSDictionary * airportPlist = (NSDictionary *)SCDynamicStoreCopyValue(dynRef, (CFStringRef)[NSString stringWithFormat:@"Setup:/Network/Interface/%@/AirPort", nsInterfaceName]); + CFRelease(dynRef); + + NSDictionary *prefNetDict = [airportPlist objectForKey:@"PreferredNetworks"]; + + NSArray *thisSsidarray = [prefNetDict valueForKey:@"SSID_STR"]; + for(NSString *ssidkey in thisSsidarray) { + QString thisSsid = qt_mac_NSStringToQString(ssidkey); + if(!userProfiles.contains(thisSsid)) { + QMap <QString,QString> map; + map.insert(thisSsid, qt_mac_NSStringToQString(nsInterfaceName)); + userProfiles.insert(thisSsid, map); + } + } + CFRelease(airportPlist); + + // 802.1X user profiles + QString userProfilePath = QDir::homePath() + "/Library/Preferences/com.apple.eap.profiles.plist"; + NSDictionary* eapDict = [[[NSDictionary alloc] initWithContentsOfFile:qt_mac_QStringToNSString(userProfilePath)] autorelease]; + NSString *profileStr= @"Profiles"; + NSString *nameStr = @"UserDefinedName"; + NSString *networkSsidStr = @"Wireless Network"; + for (id profileKey in eapDict) { + if ([profileStr isEqualToString:profileKey]) { + NSDictionary *itemDict = [eapDict objectForKey:profileKey]; + for (id itemKey in itemDict) { + + NSInteger dictSize = [itemKey count]; + id objects[dictSize]; + id keys[dictSize]; + + [itemKey getObjects:objects andKeys:keys]; + QString networkName; + QString ssid; + for(int i = 0; i < dictSize; i++) { + if([nameStr isEqualToString:keys[i]]) { + networkName = qt_mac_NSStringToQString(objects[i]); + } + if([networkSsidStr isEqualToString:keys[i]]) { + ssid = qt_mac_NSStringToQString(objects[i]); + } + if(!userProfiles.contains(networkName) + && !ssid.isEmpty()) { + QMap<QString,QString> map; + map.insert(ssid, qt_mac_NSStringToQString(nsInterfaceName)); + userProfiles.insert(networkName, map); + } + } + } + } + } + } +} + +QString QScanThread::getSsidFromNetworkName(const QString &name) +{ + QMutexLocker locker(&mutex); + + QMapIterator<QString, QMap<QString,QString> > i(userProfiles); + while (i.hasNext()) { + i.next(); + QMap<QString,QString> map = i.value(); + QMapIterator<QString, QString> ij(i.value()); + while (ij.hasNext()) { + ij.next(); + const QString networkNameHash = QString::number(qHash(QLatin1String("corewlan:") +i.key())); + if(name == i.key() || name == networkNameHash) { + return ij.key(); + } + } + } + return QString(); +} + +QString QScanThread::getNetworkNameFromSsid(const QString &ssid) +{ + QMutexLocker locker(&mutex); + + QMapIterator<QString, QMap<QString,QString> > i(userProfiles); + while (i.hasNext()) { + i.next(); + QMap<QString,QString> map = i.value(); + QMapIterator<QString, QString> ij(i.value()); + while (ij.hasNext()) { + ij.next(); + if(ij.key() == ssid) { + return i.key(); + } + } } - QMetaObject::invokeMethod(this, "requestUpdate", Qt::QueuedConnection); + return QString(); +} + +bool QScanThread::isKnownSsid(const QString &ssid) +{ + QMutexLocker locker(&mutex); + + QMapIterator<QString, QMap<QString,QString> > i(userProfiles); + while (i.hasNext()) { + i.next(); + QMap<QString,QString> map = i.value(); + if(map.keys().contains(ssid)) { + return true; + } + } + return false; +} + + +QCoreWlanEngine::QCoreWlanEngine(QObject *parent) +: QBearerEngineImpl(parent), scanThread(0) +{ + scanThread = new QScanThread(this); + connect(scanThread, SIGNAL(networksChanged()), + this, SLOT(networksChanged())); } QCoreWlanEngine::~QCoreWlanEngine() @@ -167,18 +423,35 @@ QCoreWlanEngine::~QCoreWlanEngine() [listener release]; } +void QCoreWlanEngine::initialize() +{ + QMutexLocker locker(&mutex); + + if([[CWInterface supportedInterfaces] count] > 0 && !listener) { + listener = [[QNSListener alloc] init]; + listener.engine = this; + hasWifi = true; + } else { + hasWifi = false; + } + storeSession = NULL; + + startNetworkChangeLoop(); +} + + QString QCoreWlanEngine::getInterfaceFromId(const QString &id) { QMutexLocker locker(&mutex); - return configurationInterface.value(id); + return scanThread->configurationInterface.value(id); } bool QCoreWlanEngine::hasIdentifier(const QString &id) { QMutexLocker locker(&mutex); - return configurationInterface.contains(id); + return scanThread->configurationInterface.contains(id); } void QCoreWlanEngine::connectToId(const QString &id) @@ -195,13 +468,14 @@ void QCoreWlanEngine::connectToId(const QString &id) NSMutableDictionary *params = [NSMutableDictionary dictionaryWithCapacity:0]; QString wantedSsid; - bool using8021X = false; QNetworkConfigurationPrivatePointer ptr = accessPointConfigurations.value(id); - const QString idHash = QString::number(qHash(QLatin1String("corewlan:") + getNetworkNameFromSsid(ptr->name))); + const QString idHash = QString::number(qHash(QLatin1String("corewlan:") + ptr->name)); + const QString idHash2 = QString::number(qHash(QLatin1String("corewlan:") + scanThread->getNetworkNameFromSsid(ptr->name))); - if (idHash != id) { + bool using8021X = false; + if (idHash2 != id) { NSArray *array = [CW8021XProfile allUser8021XProfiles]; for (NSUInteger i = 0; i < [array count]; ++i) { @@ -210,7 +484,7 @@ void QCoreWlanEngine::connectToId(const QString &id) const QString ssidHash = QString::number(qHash(QLatin1String("corewlan:") + qt_mac_NSStringToQString([[array objectAtIndex:i] ssid]))); if (id == networkNameHashCheck || id == ssidHash) { - const QString thisName = getSsidFromNetworkName(id); + const QString thisName = scanThread->getSsidFromNetworkName(id); if (thisName.isEmpty()) wantedSsid = id; else @@ -225,24 +499,25 @@ void QCoreWlanEngine::connectToId(const QString &id) if (!using8021X) { QString wantedNetwork; - QMapIterator<QString, QMap<QString,QString> > i(userProfiles); + QMapIterator<QString, QMap<QString,QString> > i(scanThread->userProfiles); while (i.hasNext()) { i.next(); wantedNetwork = i.key(); const QString networkNameHash = QString::number(qHash(QLatin1String("corewlan:") + wantedNetwork)); if (id == networkNameHash) { - wantedSsid = getSsidFromNetworkName(wantedNetwork); + wantedSsid = scanThread->getSsidFromNetworkName(wantedNetwork); break; } } } NSDictionary *scanParameters = [NSDictionary dictionaryWithObjectsAndKeys: [NSNumber numberWithBool:YES], kCWScanKeyMerge, + [NSNumber numberWithInt:kCWScanTypeFast], kCWScanKeyScanType, [NSNumber numberWithInteger:100], kCWScanKeyRestTime, qt_mac_QStringToNSString(wantedSsid), kCWScanKeySSID, nil]; - NSArray *scanArray = [NSArray arrayWithArray:[wifiInterface scanForNetworksWithParameters:scanParameters error:&err]]; + NSArray *scanArray = [wifiInterface scanForNetworksWithParameters:scanParameters error:&err]; if(!err) { for(uint row=0; row < [scanArray count]; row++ ) { @@ -349,7 +624,7 @@ void QCoreWlanEngine::disconnectFromId(const QString &id) void QCoreWlanEngine::requestUpdate() { - getUserConfigurations(); + scanThread->getUserConfigurations(); doRequestUpdate(); } @@ -359,228 +634,12 @@ void QCoreWlanEngine::doRequestUpdate() QMacCocoaAutoReleasePool pool; - QStringList previous = accessPointConfigurations.keys(); - NSArray *wifiInterfaces = [CWInterface supportedInterfaces]; for (uint row = 0; row < [wifiInterfaces count]; ++row) { - foreach (const QString &interface, - scanForSsids(qt_mac_NSStringToQString([wifiInterfaces objectAtIndex:row]))) { - previous.removeAll(interface); - } + scanThread->interfaceName = qt_mac_NSStringToQString([wifiInterfaces objectAtIndex:row]); + scanThread->start(); } - - while (!previous.isEmpty()) { - QNetworkConfigurationPrivatePointer ptr = accessPointConfigurations.take(previous.takeFirst()); - - configurationInterface.remove(ptr->id); - - locker.unlock(); - emit configurationRemoved(ptr); - locker.relock(); - } - locker.unlock(); - emit updateCompleted(); -} - -QString QCoreWlanEngine::getSsidFromNetworkName(const QString &name) -{ - QMapIterator<QString, QMap<QString,QString> > i(userProfiles); - while (i.hasNext()) { - i.next(); - QMap<QString,QString> map = i.value(); - QMapIterator<QString, QString> ij(i.value()); - while (ij.hasNext()) { - ij.next(); - const QString networkNameHash = QString::number(qHash(QLatin1String("corewlan:") + i.key())); - if (name == i.key() || name == networkNameHash) { - return ij.key(); - } - } - } - return QString(); -} - -QString QCoreWlanEngine::getNetworkNameFromSsid(const QString &ssid) -{ - QMapIterator<QString, QMap<QString,QString> > i(userProfiles); - while (i.hasNext()) { - i.next(); - QMap<QString,QString> map = i.value(); - QMapIterator<QString, QString> ij(i.value()); - while (ij.hasNext()) { - ij.next(); - if(ij.key() == ssid) { - return i.key(); - } - } - } - return QString(); -} - -QStringList QCoreWlanEngine::scanForSsids(const QString &interfaceName) -{ - QMutexLocker locker(&mutex); - - QStringList found; - - if(!hasWifi) { - return found; - } - QMacCocoaAutoReleasePool pool; - - CWInterface *currentInterface = [CWInterface interfaceWithName:qt_mac_QStringToNSString(interfaceName)]; - QStringList addedConfigs; - - if([currentInterface power]) { - NSError *err = nil; - NSDictionary *parametersDict = [NSDictionary dictionaryWithObjectsAndKeys: - [NSNumber numberWithBool:YES], kCWScanKeyMerge, - [NSNumber numberWithInt:kCWScanTypeFast], kCWScanKeyScanType, // get the networks in the scan cache - [NSNumber numberWithInteger:100], kCWScanKeyRestTime, nil]; - NSArray* apArray = [currentInterface scanForNetworksWithParameters:parametersDict error:&err]; - CWNetwork *apNetwork; - if (!err) { - - for(uint row=0; row < [apArray count]; row++ ) { - apNetwork = [apArray objectAtIndex:row]; - - const QString networkSsid = qt_mac_NSStringToQString([apNetwork ssid]); - - const QString id = QString::number(qHash(QLatin1String("corewlan:") + networkSsid)); - found.append(id); - - QNetworkConfiguration::StateFlags state = QNetworkConfiguration::Undefined; - bool known = isKnownSsid(networkSsid); - if( [currentInterface.interfaceState intValue] == kCWInterfaceStateRunning) { - if( networkSsid == qt_mac_NSStringToQString( [currentInterface ssid])) { - state = QNetworkConfiguration::Active; - } - } - if(state == QNetworkConfiguration::Undefined) { - if(known) { - state = QNetworkConfiguration::Discovered; - } else { - state = QNetworkConfiguration::Undefined; - } - } - QNetworkConfiguration::Purpose purpose = QNetworkConfiguration::UnknownPurpose; - if([[apNetwork securityMode] intValue] == kCWSecurityModeOpen) { - purpose = QNetworkConfiguration::PublicPurpose; - } else { - purpose = QNetworkConfiguration::PrivatePurpose; - } - - found.append(foundNetwork(id, networkSsid, state, interfaceName, purpose)); - - } //end row - } //end error - } // endwifi power - - // add known configurations that are not around. - QMapIterator<QString, QMap<QString,QString> > i(userProfiles); - while (i.hasNext()) { - i.next(); - - QString networkName = i.key(); - const QString id = QString::number(qHash(QLatin1String("corewlan:") + networkName)); - - if(!found.contains(id)) { - QString networkSsid = getSsidFromNetworkName(networkName); - const QString ssidId = QString::number(qHash(QLatin1String("corewlan:") + networkSsid)); - QNetworkConfiguration::StateFlags state = QNetworkConfiguration::Undefined; - QString interfaceName; - QMapIterator<QString, QString> ij(i.value()); - while (ij.hasNext()) { - ij.next(); - interfaceName = ij.value(); - } - - if( [currentInterface.interfaceState intValue] == kCWInterfaceStateRunning) { - if( networkSsid == qt_mac_NSStringToQString([currentInterface ssid])) { - state = QNetworkConfiguration::Active; - } - } - if(state == QNetworkConfiguration::Undefined) { - if( userProfiles.contains(networkName) - && found.contains(ssidId)) { - state = QNetworkConfiguration::Discovered; - } - } - - if(state == QNetworkConfiguration::Undefined) { - state = QNetworkConfiguration::Defined; - } - - found.append(foundNetwork(id, networkName, state, interfaceName, QNetworkConfiguration::UnknownPurpose)); - } - } - return found; -} - -QStringList QCoreWlanEngine::foundNetwork(const QString &id, const QString &name, const QNetworkConfiguration::StateFlags state, const QString &interfaceName, const QNetworkConfiguration::Purpose purpose) -{ - QStringList found; - QMutexLocker locker(&mutex); - if (accessPointConfigurations.contains(id)) { - QNetworkConfigurationPrivatePointer ptr = accessPointConfigurations.value(id); - - bool changed = false; - - ptr->mutex.lock(); - - if (!ptr->isValid) { - ptr->isValid = true; - changed = true; - } - - if (ptr->name != name) { - ptr->name = name; - changed = true; - } - - if (ptr->id != id) { - ptr->id = id; - changed = true; - } - - if (ptr->state != state) { - ptr->state = state; - changed = true; - } - - if (ptr->purpose != purpose) { - ptr->purpose = purpose; - changed = true; - } - ptr->mutex.unlock(); - - if (changed) { - locker.unlock(); - emit configurationChanged(ptr); - locker.relock(); - } - found.append(id); - } else { - QNetworkConfigurationPrivatePointer ptr(new QNetworkConfigurationPrivate); - - ptr->name = name; - ptr->isValid = true; - ptr->id = id; - ptr->state = state; - ptr->type = QNetworkConfiguration::InternetAccessPoint; - ptr->bearer = QLatin1String("WLAN"); - ptr->purpose = purpose; - - accessPointConfigurations.insert(ptr->id, ptr); - configurationInterface.insert(ptr->id, interfaceName); - - locker.unlock(); - emit configurationAdded(ptr); - locker.relock(); - found.append(id); - } - return found; } bool QCoreWlanEngine::isWifiReady(const QString &wifiDeviceName) @@ -596,20 +655,6 @@ bool QCoreWlanEngine::isWifiReady(const QString &wifiDeviceName) return false; } -bool QCoreWlanEngine::isKnownSsid(const QString &ssid) -{ - QMutexLocker locker(&mutex); - - QMapIterator<QString, QMap<QString,QString> > i(userProfiles); - while (i.hasNext()) { - i.next(); - QMap<QString,QString> map = i.value(); - if(map.keys().contains(ssid)) { - return true; - } - } - return false; -} QNetworkSession::State QCoreWlanEngine::sessionStateForId(const QString &id) { @@ -644,7 +689,6 @@ QNetworkConfigurationManager::Capabilities QCoreWlanEngine::capabilities() const void QCoreWlanEngine::startNetworkChangeLoop() { - storeSession = NULL; SCDynamicStoreContext dynStoreContext = { 0, this/*(void *)storeSession*/, NULL, NULL, NULL }; storeSession = SCDynamicStoreCreate(NULL, @@ -711,74 +755,73 @@ bool QCoreWlanEngine::requiresPolling() const return true; } -void QCoreWlanEngine::getUserConfigurations() +void QCoreWlanEngine::networksChanged() { - QMacCocoaAutoReleasePool pool; - userProfiles.clear(); + QMutexLocker locker(&mutex); - NSArray *wifiInterfaces = [CWInterface supportedInterfaces]; - for(uint row=0; row < [wifiInterfaces count]; row++ ) { + QStringList previous = accessPointConfigurations.keys(); - CWInterface *wifiInterface = [CWInterface interfaceWithName: [wifiInterfaces objectAtIndex:row]]; - NSString *nsInterfaceName = [wifiInterface name]; -// add user configured system networks - SCDynamicStoreRef dynRef = SCDynamicStoreCreate(kCFAllocatorSystemDefault, (CFStringRef)@"Qt corewlan", nil, nil); - NSDictionary *airportPlist = (NSDictionary *)SCDynamicStoreCopyValue(dynRef, (CFStringRef)[[NSString stringWithFormat:@"Setup:/Network/Interface/%@/AirPort", nsInterfaceName] autorelease]); - CFRelease(dynRef); + QList<QNetworkConfigurationPrivate *> foundConfigurations = scanThread->getConfigurations(); + while (!foundConfigurations.isEmpty()) { + QNetworkConfigurationPrivate *cpPriv = foundConfigurations.takeFirst(); - NSDictionary *prefNetDict = [airportPlist objectForKey:@"PreferredNetworks"]; + previous.removeAll(cpPriv->id); - NSArray *thisSsidarray = [prefNetDict valueForKey:@"SSID_STR"]; - for(NSString *ssidkey in thisSsidarray) { - QString thisSsid = qt_mac_NSStringToQString(ssidkey); - if(!userProfiles.contains(thisSsid)) { - QMap <QString,QString> map; - map.insert(thisSsid, qt_mac_NSStringToQString(nsInterfaceName)); - userProfiles.insert(thisSsid, map); + if (accessPointConfigurations.contains(cpPriv->id)) { + QNetworkConfigurationPrivatePointer ptr = accessPointConfigurations.value(cpPriv->id); + + bool changed = false; + + ptr->mutex.lock(); + + if (ptr->isValid != cpPriv->isValid) { + ptr->isValid = cpPriv->isValid; + changed = true; } - } - CFRelease(airportPlist); - // 802.1X user profiles - QString userProfilePath = QDir::homePath() + "/Library/Preferences/com.apple.eap.profiles.plist"; - NSDictionary* eapDict = [[NSDictionary alloc] initWithContentsOfFile:qt_mac_QStringToNSString(userProfilePath)]; - NSString *profileStr= @"Profiles"; - NSString *nameStr = @"UserDefinedName"; - NSString *networkSsidStr = @"Wireless Network"; - for (id profileKey in eapDict) { - if ([profileStr isEqualToString:profileKey]) { - NSDictionary *itemDict = [eapDict objectForKey:profileKey]; - for (id itemKey in itemDict) { + if (ptr->name != cpPriv->name) { + ptr->name = cpPriv->name; + changed = true; + } - NSInteger dictSize = [itemKey count]; - id objects[dictSize]; - id keys[dictSize]; + if (ptr->state != cpPriv->state) { + ptr->state = cpPriv->state; + changed = true; + } - [itemKey getObjects:objects andKeys:keys]; - QString networkName; - QString ssid; - for(int i = 0; i < dictSize; i++) { - if([nameStr isEqualToString:keys[i]]) { - networkName = qt_mac_NSStringToQString(objects[i]); - } - if([networkSsidStr isEqualToString:keys[i]]) { - ssid = qt_mac_NSStringToQString(objects[i]); - } - if(!userProfiles.contains(networkName) - && !ssid.isEmpty()) { - QMap<QString,QString> map; - map.insert(ssid, qt_mac_NSStringToQString(nsInterfaceName)); - userProfiles.insert(networkName, map); - } - } - } - [itemDict release]; + ptr->mutex.unlock(); + + if (changed) { + locker.unlock(); + emit configurationChanged(ptr); + locker.relock(); } + + delete cpPriv; + } else { + QNetworkConfigurationPrivatePointer ptr(cpPriv); + + accessPointConfigurations.insert(ptr->id, ptr); + + locker.unlock(); + emit configurationAdded(ptr); + locker.relock(); } - [eapDict release]; } + + while (!previous.isEmpty()) { + QNetworkConfigurationPrivatePointer ptr = + accessPointConfigurations.take(previous.takeFirst()); + + locker.unlock(); + emit configurationRemoved(ptr); + locker.relock(); + } + + locker.unlock(); + emit updateCompleted(); + } -QT_END_NAMESPACE -#endif // QT_NO_BEARERMANAGEMENT +QT_END_NAMESPACE diff --git a/src/plugins/bearer/generic/qgenericengine.cpp b/src/plugins/bearer/generic/qgenericengine.cpp index 41ff3e0..652fe4a 100644 --- a/src/plugins/bearer/generic/qgenericengine.cpp +++ b/src/plugins/bearer/generic/qgenericengine.cpp @@ -177,6 +177,11 @@ void QGenericEngine::disconnectFromId(const QString &id) emit connectionError(id, OperationNotSupported); } +void QGenericEngine::initialize() +{ + doRequestUpdate(); +} + void QGenericEngine::requestUpdate() { doRequestUpdate(); diff --git a/src/plugins/bearer/generic/qgenericengine.h b/src/plugins/bearer/generic/qgenericengine.h index 82d22af..cdbbc9d 100644 --- a/src/plugins/bearer/generic/qgenericengine.h +++ b/src/plugins/bearer/generic/qgenericengine.h @@ -70,6 +70,7 @@ public: void connectToId(const QString &id); void disconnectFromId(const QString &id); + Q_INVOKABLE void initialize(); Q_INVOKABLE void requestUpdate(); QNetworkSession::State sessionStateForId(const QString &id); diff --git a/src/plugins/bearer/icd/qicdengine.cpp b/src/plugins/bearer/icd/qicdengine.cpp index fc9b469..9d1bfab 100644 --- a/src/plugins/bearer/icd/qicdengine.cpp +++ b/src/plugins/bearer/icd/qicdengine.cpp @@ -225,8 +225,6 @@ QIcdEngine::QIcdEngine(QObject *parent) : QBearerEngine(parent), iapMonitor(new IapMonitor), m_dbusInterface(0), firstUpdate(true), m_scanGoingOn(false) { - QMetaObject::invokeMethod(this, "doRequestUpdate", Qt::QueuedConnection); - init(); } QIcdEngine::~QIcdEngine() @@ -243,8 +241,10 @@ QNetworkConfigurationManager::Capabilities QIcdEngine::capabilities() const QNetworkConfigurationManager::NetworkSessionRequired; } -void QIcdEngine::init() +void QIcdEngine::initialize() { + QMutexLocker locker(&mutex); + // Setup DBus Interface for ICD m_dbusInterface = new QDBusInterface(ICD_DBUS_API_INTERFACE, ICD_DBUS_API_PATH, @@ -272,6 +272,8 @@ void QIcdEngine::init() QNetworkConfigurationPrivatePointer ptr(cpPriv); userChoiceConfigurations.insert(cpPriv->id, ptr); + + doRequestUpdate(); } static inline QString network_attrs_to_security(uint network_attrs) diff --git a/src/plugins/bearer/icd/qicdengine.h b/src/plugins/bearer/icd/qicdengine.h index 841874f..2f9f8ed 100644 --- a/src/plugins/bearer/icd/qicdengine.h +++ b/src/plugins/bearer/icd/qicdengine.h @@ -91,6 +91,7 @@ public: bool hasIdentifier(const QString &id); + Q_INVOKABLE void initialize(); Q_INVOKABLE void requestUpdate(); QNetworkConfigurationManager::Capabilities capabilities() const; @@ -123,7 +124,6 @@ public: emit configurationChanged(ptr); } - void init(); void cleanup(); void addConfiguration(QString &iap_id); diff --git a/src/plugins/bearer/nativewifi/qnativewifiengine.cpp b/src/plugins/bearer/nativewifi/qnativewifiengine.cpp index e796df3..9b6ffa0 100644 --- a/src/plugins/bearer/nativewifi/qnativewifiengine.cpp +++ b/src/plugins/bearer/nativewifi/qnativewifiengine.cpp @@ -100,8 +100,6 @@ QNativeWifiEngine::QNativeWifiEngine(QObject *parent) if (result != ERROR_SUCCESS) qDebug("%s: WlanRegisterNotification failed with error %ld\n", __FUNCTION__, result); #endif - - scanComplete(); } QNativeWifiEngine::~QNativeWifiEngine() @@ -472,6 +470,11 @@ void QNativeWifiEngine::disconnectFromId(const QString &id) } } +void QNativeWifiEngine::initialize() +{ + scanComplete(); +} + void QNativeWifiEngine::requestUpdate() { QMutexLocker locker(&mutex); diff --git a/src/plugins/bearer/nativewifi/qnativewifiengine.h b/src/plugins/bearer/nativewifi/qnativewifiengine.h index 77764e4..3b21985 100644 --- a/src/plugins/bearer/nativewifi/qnativewifiengine.h +++ b/src/plugins/bearer/nativewifi/qnativewifiengine.h @@ -80,6 +80,7 @@ public: void connectToId(const QString &id); void disconnectFromId(const QString &id); + Q_INVOKABLE void initialize(); Q_INVOKABLE void requestUpdate(); QNetworkSession::State sessionStateForId(const QString &id); diff --git a/src/plugins/bearer/networkmanager/qnetworkmanagerengine.cpp b/src/plugins/bearer/networkmanager/qnetworkmanagerengine.cpp index 13b2252..3ebc356 100644 --- a/src/plugins/bearer/networkmanager/qnetworkmanagerengine.cpp +++ b/src/plugins/bearer/networkmanager/qnetworkmanagerengine.cpp @@ -93,16 +93,16 @@ QNetworkManagerEngine::QNetworkManagerEngine(QObject *parent) userSettings->setConnections(); connect(userSettings, SIGNAL(newConnection(QDBusObjectPath)), this, SLOT(newConnection(QDBusObjectPath))); - - QMetaObject::invokeMethod(this, "init", Qt::QueuedConnection); } QNetworkManagerEngine::~QNetworkManagerEngine() { } -void QNetworkManagerEngine::init() +void QNetworkManagerEngine::initialize() { + QMutexLocker locker(&mutex); + // Get current list of access points. foreach (const QDBusObjectPath &devicePath, interface->getDevices()) deviceAdded(devicePath); diff --git a/src/plugins/bearer/networkmanager/qnetworkmanagerengine.h b/src/plugins/bearer/networkmanager/qnetworkmanagerengine.h index 7f8badb..8e95a2c 100644 --- a/src/plugins/bearer/networkmanager/qnetworkmanagerengine.h +++ b/src/plugins/bearer/networkmanager/qnetworkmanagerengine.h @@ -73,8 +73,6 @@ public: QNetworkManagerEngine(QObject *parent = 0); ~QNetworkManagerEngine(); - Q_INVOKABLE void init(); - bool networkManagerAvailable() const; QString getInterfaceFromId(const QString &id); @@ -85,6 +83,7 @@ public: void connectToId(const QString &id); void disconnectFromId(const QString &id); + Q_INVOKABLE void initialize(); Q_INVOKABLE void requestUpdate(); QNetworkSession::State sessionStateForId(const QString &id); diff --git a/src/plugins/bearer/symbian/symbianengine.cpp b/src/plugins/bearer/symbian/symbianengine.cpp index c629d02..8e9675e 100644 --- a/src/plugins/bearer/symbian/symbianengine.cpp +++ b/src/plugins/bearer/symbian/symbianengine.cpp @@ -137,7 +137,12 @@ SymbianEngine::SymbianEngine(QObject *parent) return; } #endif - +} + +void SymbianEngine::initialize() +{ + QMutexLocker locker(&mutex); + SymbianNetworkConfigurationPrivate *cpPriv = new SymbianNetworkConfigurationPrivate; cpPriv->name = "UserChoice"; cpPriv->bearer = SymbianNetworkConfigurationPrivate::BearerUnknown; diff --git a/src/plugins/bearer/symbian/symbianengine.h b/src/plugins/bearer/symbian/symbianengine.h index dfd12bd..afb37de 100644 --- a/src/plugins/bearer/symbian/symbianengine.h +++ b/src/plugins/bearer/symbian/symbianengine.h @@ -110,6 +110,7 @@ public: bool hasIdentifier(const QString &id); + Q_INVOKABLE void initialize(); Q_INVOKABLE void requestUpdate(); QNetworkConfigurationManager::Capabilities capabilities() const; diff --git a/src/script/api/qscriptengine.cpp b/src/script/api/qscriptengine.cpp index 0b8a2e4..03d535c 100644 --- a/src/script/api/qscriptengine.cpp +++ b/src/script/api/qscriptengine.cpp @@ -796,7 +796,7 @@ JSC::JSValue JSC_HOST_CALL functionQsTr(JSC::ExecState *exec, JSC::JSObject*, JS JSC::UString context; // The first non-empty source URL in the call stack determines the translation context. { - JSC::ExecState *frame = exec->removeHostCallFrameFlag(); + JSC::ExecState *frame = exec->callerFrame()->removeHostCallFrameFlag(); while (frame) { if (frame->codeBlock() && frame->codeBlock()->source() && !frame->codeBlock()->source()->url().isEmpty()) { @@ -3404,7 +3404,7 @@ void QScriptEngine::installTranslatorFunctions(const QScriptValue &object) // unsigned attribs = JSC::DontEnum; JSC::asObject(jscObject)->putDirectFunction(exec, new (exec)JSC::NativeFunctionWrapper(exec, glob->prototypeFunctionStructure(), 5, JSC::Identifier(exec, "qsTranslate"), QScript::functionQsTranslate)); JSC::asObject(jscObject)->putDirectFunction(exec, new (exec)JSC::NativeFunctionWrapper(exec, glob->prototypeFunctionStructure(), 2, JSC::Identifier(exec, "QT_TRANSLATE_NOOP"), QScript::functionQsTranslateNoOp)); - JSC::asObject(jscObject)->putDirectFunction(exec, new (exec)JSC::PrototypeFunction(exec, glob->prototypeFunctionStructure(), 3, JSC::Identifier(exec, "qsTr"), QScript::functionQsTr)); + JSC::asObject(jscObject)->putDirectFunction(exec, new (exec)JSC::NativeFunctionWrapper(exec, glob->prototypeFunctionStructure(), 3, JSC::Identifier(exec, "qsTr"), QScript::functionQsTr)); JSC::asObject(jscObject)->putDirectFunction(exec, new (exec)JSC::NativeFunctionWrapper(exec, glob->prototypeFunctionStructure(), 1, JSC::Identifier(exec, "QT_TR_NOOP"), QScript::functionQsTrNoOp)); glob->stringPrototype()->putDirectFunction(exec, new (exec)JSC::NativeFunctionWrapper(exec, glob->prototypeFunctionStructure(), 1, JSC::Identifier(exec, "arg"), QScript::stringProtoFuncArg)); diff --git a/src/script/bridge/qscriptqobject.cpp b/src/script/bridge/qscriptqobject.cpp index 0477454..5e4f097 100644 --- a/src/script/bridge/qscriptqobject.cpp +++ b/src/script/bridge/qscriptqobject.cpp @@ -35,6 +35,7 @@ #include "Error.h" #include "PrototypeFunction.h" +#include "NativeFunctionWrapper.h" #include "PropertyNameArray.h" #include "JSFunction.h" #include "JSString.h" @@ -1753,9 +1754,9 @@ QObjectPrototype::QObjectPrototype(JSC::ExecState* exec, WTF::PassRefPtr<JSC::St | QScriptEngine::ExcludeSuperClassProperties | QScriptEngine::ExcludeChildObjects)); - putDirectFunction(exec, new (exec) JSC::PrototypeFunction(exec, prototypeFunctionStructure, /*length=*/0, exec->propertyNames().toString, qobjectProtoFuncToString), JSC::DontEnum); - putDirectFunction(exec, new (exec) JSC::PrototypeFunction(exec, prototypeFunctionStructure, /*length=*/1, JSC::Identifier(exec, "findChild"), qobjectProtoFuncFindChild), JSC::DontEnum); - putDirectFunction(exec, new (exec) JSC::PrototypeFunction(exec, prototypeFunctionStructure, /*length=*/1, JSC::Identifier(exec, "findChildren"), qobjectProtoFuncFindChildren), JSC::DontEnum); + putDirectFunction(exec, new (exec) JSC::NativeFunctionWrapper(exec, prototypeFunctionStructure, /*length=*/0, exec->propertyNames().toString, qobjectProtoFuncToString), JSC::DontEnum); + putDirectFunction(exec, new (exec) JSC::NativeFunctionWrapper(exec, prototypeFunctionStructure, /*length=*/1, JSC::Identifier(exec, "findChild"), qobjectProtoFuncFindChild), JSC::DontEnum); + putDirectFunction(exec, new (exec) JSC::NativeFunctionWrapper(exec, prototypeFunctionStructure, /*length=*/1, JSC::Identifier(exec, "findChildren"), qobjectProtoFuncFindChildren), JSC::DontEnum); this->structure()->setHasGetterSetterProperties(true); } @@ -2015,7 +2016,7 @@ QMetaObjectPrototype::QMetaObjectPrototype( JSC::Structure* prototypeFunctionStructure) : QMetaObjectWrapperObject(exec, StaticQtMetaObject::get(), /*ctor=*/JSC::JSValue(), structure) { - putDirectFunction(exec, new (exec) JSC::PrototypeFunction(exec, prototypeFunctionStructure, /*length=*/0, JSC::Identifier(exec, "className"), qmetaobjectProtoFuncClassName), JSC::DontEnum); + putDirectFunction(exec, new (exec) JSC::NativeFunctionWrapper(exec, prototypeFunctionStructure, /*length=*/0, JSC::Identifier(exec, "className"), qmetaobjectProtoFuncClassName), JSC::DontEnum); } static const uint qt_meta_data_QObjectConnectionManager[] = { diff --git a/src/script/bridge/qscriptvariant.cpp b/src/script/bridge/qscriptvariant.cpp index b2dd3b0..93459a8 100644 --- a/src/script/bridge/qscriptvariant.cpp +++ b/src/script/bridge/qscriptvariant.cpp @@ -29,6 +29,8 @@ #include "Error.h" #include "PrototypeFunction.h" +#include "JSFunction.h" +#include "NativeFunctionWrapper.h" #include "JSString.h" namespace JSC @@ -139,8 +141,8 @@ QVariantPrototype::QVariantPrototype(JSC::ExecState* exec, WTF::PassRefPtr<JSC:: { setDelegate(new QVariantDelegate(QVariant())); - putDirectFunction(exec, new (exec) JSC::PrototypeFunction(exec, prototypeFunctionStructure, 0, exec->propertyNames().toString, variantProtoFuncToString), JSC::DontEnum); - putDirectFunction(exec, new (exec) JSC::PrototypeFunction(exec, prototypeFunctionStructure, 0, exec->propertyNames().valueOf, variantProtoFuncValueOf), JSC::DontEnum); + putDirectFunction(exec, new (exec) JSC::NativeFunctionWrapper(exec, prototypeFunctionStructure, 0, exec->propertyNames().toString, variantProtoFuncToString), JSC::DontEnum); + putDirectFunction(exec, new (exec) JSC::NativeFunctionWrapper(exec, prototypeFunctionStructure, 0, exec->propertyNames().valueOf, variantProtoFuncValueOf), JSC::DontEnum); } diff --git a/tests/auto/declarative/qdeclarativeecmascript/tst_qdeclarativeecmascript.cpp b/tests/auto/declarative/qdeclarativeecmascript/tst_qdeclarativeecmascript.cpp index 6939290..97fced4 100644 --- a/tests/auto/declarative/qdeclarativeecmascript/tst_qdeclarativeecmascript.cpp +++ b/tests/auto/declarative/qdeclarativeecmascript/tst_qdeclarativeecmascript.cpp @@ -381,7 +381,7 @@ void tst_qdeclarativeecmascript::basicExpressions() nestedContext.setContextProperty("millipedeLegs", QVariant(100)); MyExpression expr(nest?&nestedContext:&context, expression); - QCOMPARE(expr.value(), result); + QCOMPARE(expr.evaluate(), result); } void tst_qdeclarativeecmascript::arrayExpressions() @@ -396,7 +396,7 @@ void tst_qdeclarativeecmascript::arrayExpressions() context.setContextProperty("c", &obj3); MyExpression expr(&context, "[a, b, c, 10]"); - QVariant result = expr.value(); + QVariant result = expr.evaluate(); QCOMPARE(result.userType(), qMetaTypeId<QList<QObject *> >()); QList<QObject *> list = qvariant_cast<QList<QObject *> >(result); QCOMPARE(list.count(), 4); @@ -424,47 +424,47 @@ void tst_qdeclarativeecmascript::contextPropertiesTriggerReeval() { MyExpression expr(&context, "testProp + 1"); QCOMPARE(expr.changed, false); - QCOMPARE(expr.value(), QVariant(2)); + QCOMPARE(expr.evaluate(), QVariant(2)); context.setContextProperty("testProp", QVariant(2)); QCOMPARE(expr.changed, true); - QCOMPARE(expr.value(), QVariant(3)); + QCOMPARE(expr.evaluate(), QVariant(3)); } { MyExpression expr(&context, "testProp + testProp + testProp"); QCOMPARE(expr.changed, false); - QCOMPARE(expr.value(), QVariant(6)); + QCOMPARE(expr.evaluate(), QVariant(6)); context.setContextProperty("testProp", QVariant(4)); QCOMPARE(expr.changed, true); - QCOMPARE(expr.value(), QVariant(12)); + QCOMPARE(expr.evaluate(), QVariant(12)); } { MyExpression expr(&context, "testObj.stringProperty"); QCOMPARE(expr.changed, false); - QCOMPARE(expr.value(), QVariant("Hello")); + QCOMPARE(expr.evaluate(), QVariant("Hello")); context.setContextProperty("testObj", &object2); QCOMPARE(expr.changed, true); - QCOMPARE(expr.value(), QVariant("World")); + QCOMPARE(expr.evaluate(), QVariant("World")); } { MyExpression expr(&context, "testObj.stringProperty /**/"); QCOMPARE(expr.changed, false); - QCOMPARE(expr.value(), QVariant("World")); + QCOMPARE(expr.evaluate(), QVariant("World")); context.setContextProperty("testObj", &object1); QCOMPARE(expr.changed, true); - QCOMPARE(expr.value(), QVariant("Hello")); + QCOMPARE(expr.evaluate(), QVariant("Hello")); } { MyExpression expr(&context, "testObj2"); QCOMPARE(expr.changed, false); - QCOMPARE(expr.value(), QVariant::fromValue((QObject *)object3)); + QCOMPARE(expr.evaluate(), QVariant::fromValue((QObject *)object3)); } } @@ -484,42 +484,42 @@ void tst_qdeclarativeecmascript::objectPropertiesTriggerReeval() { MyExpression expr(&context, "testObj.stringProperty"); QCOMPARE(expr.changed, false); - QCOMPARE(expr.value(), QVariant("Hello")); + QCOMPARE(expr.evaluate(), QVariant("Hello")); object1.setStringProperty(QLatin1String("World")); QCOMPARE(expr.changed, true); - QCOMPARE(expr.value(), QVariant("World")); + QCOMPARE(expr.evaluate(), QVariant("World")); } { MyExpression expr(&context, "testObj.objectProperty.stringProperty"); QCOMPARE(expr.changed, false); - QCOMPARE(expr.value(), QVariant()); + QCOMPARE(expr.evaluate(), QVariant()); object1.setObjectProperty(&object2); QCOMPARE(expr.changed, true); expr.changed = false; - QCOMPARE(expr.value(), QVariant("Dog")); + QCOMPARE(expr.evaluate(), QVariant("Dog")); object1.setObjectProperty(&object3); QCOMPARE(expr.changed, true); expr.changed = false; - QCOMPARE(expr.value(), QVariant("Cat")); + QCOMPARE(expr.evaluate(), QVariant("Cat")); object1.setObjectProperty(0); QCOMPARE(expr.changed, true); expr.changed = false; - QCOMPARE(expr.value(), QVariant()); + QCOMPARE(expr.evaluate(), QVariant()); object1.setObjectProperty(&object3); QCOMPARE(expr.changed, true); expr.changed = false; - QCOMPARE(expr.value(), QVariant("Cat")); + QCOMPARE(expr.evaluate(), QVariant("Cat")); object3.setStringProperty("Donkey"); QCOMPARE(expr.changed, true); expr.changed = false; - QCOMPARE(expr.value(), QVariant("Donkey")); + QCOMPARE(expr.evaluate(), QVariant("Donkey")); } } diff --git a/tests/auto/declarative/qdeclarativeimage/tst_qdeclarativeimage.cpp b/tests/auto/declarative/qdeclarativeimage/tst_qdeclarativeimage.cpp index 73aefaf..e0143a6 100644 --- a/tests/auto/declarative/qdeclarativeimage/tst_qdeclarativeimage.cpp +++ b/tests/auto/declarative/qdeclarativeimage/tst_qdeclarativeimage.cpp @@ -401,7 +401,7 @@ T *tst_qdeclarativeimage::findItem(QGraphicsObject *parent, const QString &objec if (mo.cast(item) && (objectName.isEmpty() || item->objectName() == objectName)) { if (index != -1) { QDeclarativeExpression e(qmlContext(item), "index", item); - if (e.value().toInt() == index) + if (e.evaluate().toInt() == index) return static_cast<T*>(item); } else { return static_cast<T*>(item); diff --git a/tests/auto/declarative/qdeclarativelistmodel/tst_qdeclarativelistmodel.cpp b/tests/auto/declarative/qdeclarativelistmodel/tst_qdeclarativelistmodel.cpp index e4c296f..ec97461 100644 --- a/tests/auto/declarative/qdeclarativelistmodel/tst_qdeclarativelistmodel.cpp +++ b/tests/auto/declarative/qdeclarativelistmodel/tst_qdeclarativelistmodel.cpp @@ -279,7 +279,7 @@ void tst_qdeclarativelistmodel::dynamic() if (!warning.isEmpty()) QTest::ignoreMessage(QtWarningMsg, warning.toLatin1()); - int actual = e.value().toInt(); + int actual = e.evaluate().toInt(); if (e.hasError()) qDebug() << e.error(); // errors not expected QVERIFY(!e.hasError()); @@ -338,9 +338,9 @@ void tst_qdeclarativelistmodel::dynamic_worker() QDeclarativeExpression e(eng.rootContext(), operations.last().toString(), &model); if (QByteArray(QTest::currentDataTag()).startsWith("nested")) - QVERIFY(e.value().toInt() != result); + QVERIFY(e.evaluate().toInt() != result); else - QCOMPARE(e.value().toInt(), result); + QCOMPARE(e.evaluate().toInt(), result); } delete item; diff --git a/tests/auto/declarative/qdeclarativelistview/tst_qdeclarativelistview.cpp b/tests/auto/declarative/qdeclarativelistview/tst_qdeclarativelistview.cpp index 6b7a361..cab4d52 100644 --- a/tests/auto/declarative/qdeclarativelistview/tst_qdeclarativelistview.cpp +++ b/tests/auto/declarative/qdeclarativelistview/tst_qdeclarativelistview.cpp @@ -1551,7 +1551,7 @@ T *tst_QDeclarativeListView::findItem(QGraphicsObject *parent, const QString &ob if (mo.cast(item) && (objectName.isEmpty() || item->objectName() == objectName)) { if (index != -1) { QDeclarativeExpression e(qmlContext(item), "index", item); - if (e.value().toInt() == index) + if (e.evaluate().toInt() == index) return static_cast<T*>(item); } else { return static_cast<T*>(item); diff --git a/tests/auto/declarative/qdeclarativepathview/tst_qdeclarativepathview.cpp b/tests/auto/declarative/qdeclarativepathview/tst_qdeclarativepathview.cpp index df7c511..0e3a74d 100644 --- a/tests/auto/declarative/qdeclarativepathview/tst_qdeclarativepathview.cpp +++ b/tests/auto/declarative/qdeclarativepathview/tst_qdeclarativepathview.cpp @@ -697,7 +697,7 @@ T *tst_QDeclarativePathView::findItem(QGraphicsObject *parent, const QString &ob if (mo.cast(item) && (objectName.isEmpty() || item->objectName() == objectName)) { if (index != -1) { QDeclarativeExpression e(qmlContext(item), "index", item); - if (e.value().toInt() == index) + if (e.evaluate().toInt() == index) return static_cast<T*>(item); } else { return static_cast<T*>(item); diff --git a/tests/auto/declarative/qmlvisual/qdeclarativeborderimage/data/borders.0.png b/tests/auto/declarative/qmlvisual/qdeclarativeborderimage/data/borders.0.png Binary files differindex 80cbd26..bb9dfbb 100644 --- a/tests/auto/declarative/qmlvisual/qdeclarativeborderimage/data/borders.0.png +++ b/tests/auto/declarative/qmlvisual/qdeclarativeborderimage/data/borders.0.png diff --git a/tests/auto/declarative/qmlvisual/qdeclarativepositioners/data/usingRepeater.qml b/tests/auto/declarative/qmlvisual/qdeclarativepositioners/data/usingRepeater.qml index a4036fe..b293d70 100644 --- a/tests/auto/declarative/qmlvisual/qdeclarativepositioners/data/usingRepeater.qml +++ b/tests/auto/declarative/qmlvisual/qdeclarativepositioners/data/usingRepeater.qml @@ -6,334 +6,334 @@ VisualTest { } Frame { msec: 16 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 32 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 48 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 64 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 80 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 96 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 112 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 128 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 144 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 160 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 176 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 192 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 208 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 224 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 240 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 256 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 272 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 288 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 304 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 320 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 336 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 352 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 368 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 384 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 400 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 416 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 432 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 448 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 464 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 480 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 496 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 512 - hash: "0273c293855f2b2bdbf579fc5cdce63f" + hash: "b72bfb206ae52e0e4fb8927b82d64b64" } Frame { msec: 528 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 544 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 560 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 576 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 592 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 608 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 624 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 640 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 656 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 672 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 688 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 704 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 720 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 736 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 752 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 768 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 784 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 800 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 816 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 832 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 848 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 864 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 880 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 896 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 912 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 928 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 944 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 960 - image: "repeater.0.png" + image: "usingRepeater.0.png" } Frame { msec: 976 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 992 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1008 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1024 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1040 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1056 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1072 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1088 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1104 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1120 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1136 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1152 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1168 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1184 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1200 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1216 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1232 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1248 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1264 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1280 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1296 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1312 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } Frame { msec: 1328 - hash: "53a01771047c8ec806a335a1a3d6af71" + hash: "f2de1f70c5f242604beb4ee0251c8032" } } diff --git a/tests/auto/qdiriterator/tst_qdiriterator.cpp b/tests/auto/qdiriterator/tst_qdiriterator.cpp index c1db8f2..1a873b8 100644 --- a/tests/auto/qdiriterator/tst_qdiriterator.cpp +++ b/tests/auto/qdiriterator/tst_qdiriterator.cpp @@ -85,11 +85,13 @@ private: // convenience functions return false; } - bool createFile(const QString &fileName) + enum Cleanup { DoDelete, DontDelete }; + bool createFile(const QString &fileName, Cleanup cleanup = DoDelete) { QFile file(fileName); if (file.open(QIODevice::WriteOnly)) { - createdFiles << fileName; + if (cleanup == DoDelete) + createdFiles << fileName; return true; } return false; @@ -131,9 +133,9 @@ tst_QDirIterator::tst_QDirIterator() createDirectory("entrylist"); createDirectory("entrylist/directory"); - createFile("entrylist/file"); + createFile("entrylist/file", DontDelete); createFile("entrylist/writable"); - createFile("entrylist/directory/dummy"); + createFile("entrylist/directory/dummy", DontDelete); createDirectory("recursiveDirs"); createDirectory("recursiveDirs/dir1"); diff --git a/tests/auto/qhostinfo/tst_qhostinfo.cpp b/tests/auto/qhostinfo/tst_qhostinfo.cpp index 4282062..c336746 100644 --- a/tests/auto/qhostinfo/tst_qhostinfo.cpp +++ b/tests/auto/qhostinfo/tst_qhostinfo.cpp @@ -128,6 +128,7 @@ private slots: void threadSafety(); void multipleSameLookups(); + void multipleDifferentLookups_data(); void multipleDifferentLookups(); void cache(); @@ -441,36 +442,46 @@ void tst_QHostInfo::multipleSameLookups() for (int i = 0; i < COUNT; i++) QHostInfo::lookupHost("localhost", this, SLOT(resultsReady(const QHostInfo))); - QTRY_VERIFY(lookupsDoneCounter == COUNT); - - // spin two seconds more to see if it is not more :) - QTestEventLoop::instance().enterLoop(2); - QTRY_VERIFY(lookupsDoneCounter == COUNT); + QElapsedTimer timer; + timer.start(); + while (timer.elapsed() < 10000 && lookupsDoneCounter < COUNT) { + QTestEventLoop::instance().enterLoop(2); + } + QCOMPARE(lookupsDoneCounter, COUNT); } // this test is for the multi-threaded QHostInfo rewrite. It is about getting results at all, // not about getting correct IPs +void tst_QHostInfo::multipleDifferentLookups_data() +{ + QTest::addColumn<int>("repeats"); + QTest::newRow("1") << 1; + QTest::newRow("2") << 2; + QTest::newRow("5") << 5; + QTest::newRow("10") << 10; +} + void tst_QHostInfo::multipleDifferentLookups() { QStringList hostnameList; hostnameList << "www.ovi.com" << "www.nokia.com" << "qt.nokia.com" << "www.trolltech.com" << "troll.no" - << "www.qtcentre.org" << "forum.nokia.com" << "www.forum.nokia.com" << "wiki.forum.nokia.com" - << "www.nokia.no" << "nokia.de" << "127.0.0.1" << "----"; + << "www.qtcentre.org" << "forum.nokia.com" << "www.nokia.com" << "wiki.forum.nokia.com" + << "www.nokia.com" << "nokia.de" << "127.0.0.1" << "----"; + QFETCH(int, repeats); const int COUNT = hostnameList.size(); lookupsDoneCounter = 0; for (int i = 0; i < hostnameList.size(); i++) - QHostInfo::lookupHost(hostnameList.at(i), this, SLOT(resultsReady(const QHostInfo))); - - // give some time - QTestEventLoop::instance().enterLoop(5); - // try_verify gives some more time - QTRY_VERIFY(lookupsDoneCounter == COUNT); + for (int j = 0; j < repeats; ++j) + QHostInfo::lookupHost(hostnameList.at(i), this, SLOT(resultsReady(const QHostInfo))); - // spin two seconds more to see if it is not more than expected - QTestEventLoop::instance().enterLoop(2); - QTRY_VERIFY(lookupsDoneCounter == COUNT); + QElapsedTimer timer; + timer.start(); + while (timer.elapsed() < 10000 && lookupsDoneCounter < repeats*COUNT) { + QTestEventLoop::instance().enterLoop(2); + } + QCOMPARE(lookupsDoneCounter, repeats*COUNT); } void tst_QHostInfo::cache() @@ -517,7 +528,7 @@ void tst_QHostInfo::resultsReady(const QHostInfo &hi) lookupDone = true; lookupResults = hi; lookupsDoneCounter++; - QTestEventLoop::instance().exitLoop(); + QMetaObject::invokeMethod(&QTestEventLoop::instance(), "exitLoop", Qt::QueuedConnection); } QTEST_MAIN(tst_QHostInfo) diff --git a/tests/auto/qitemmodel/tst_qitemmodel.cpp b/tests/auto/qitemmodel/tst_qitemmodel.cpp index f466045..d36df9c 100644 --- a/tests/auto/qitemmodel/tst_qitemmodel.cpp +++ b/tests/auto/qitemmodel/tst_qitemmodel.cpp @@ -452,7 +452,7 @@ void checkChildren(QAbstractItemModel *currentModel, const QModelIndex &parent, QCOMPARE(index.column(), c); QCOMPARE(currentModel->data(index, Qt::DisplayRole).isValid(), true); - // If the next test fails here is some somewhat usefull debug you play with. + // If the next test fails here is some somewhat useful debug you play with. /* if (currentModel->parent(index) != parent) { qDebug() << r << c << currentDepth << currentModel->data(index).toString() diff --git a/tests/auto/qthread/tst_qthread.cpp b/tests/auto/qthread/tst_qthread.cpp index 9a4397e..7a5b053 100644 --- a/tests/auto/qthread/tst_qthread.cpp +++ b/tests/auto/qthread/tst_qthread.cpp @@ -442,9 +442,9 @@ void tst_QThread::exit() thread2.object = 0; thread2.code = 53; thread2.result = 0; + QMutexLocker locker2(&thread2.mutex); thread2.start(); thread2.exit(thread2.code); - QMutexLocker locker2(&thread2.mutex); thread2.cond.wait(locker2.mutex()); QVERIFY(thread2.wait(five_minutes)); QCOMPARE(thread2.result, thread2.code); @@ -514,9 +514,9 @@ void tst_QThread::quit() Quit_Thread thread2; thread2.object = 0; thread2.result = -1; + QMutexLocker locker2(&thread2.mutex); thread2.start(); thread2.quit(); - QMutexLocker locker2(&thread2.mutex); thread2.cond.wait(locker2.mutex()); QVERIFY(thread2.wait(five_minutes)); QCOMPARE(thread2.result, 0); diff --git a/tools/assistant/tools/assistant/helpviewer.cpp b/tools/assistant/tools/assistant/helpviewer.cpp index 0c51a02..22b3f30 100644 --- a/tools/assistant/tools/assistant/helpviewer.cpp +++ b/tools/assistant/tools/assistant/helpviewer.cpp @@ -52,6 +52,10 @@ QT_BEGIN_NAMESPACE +QString AbstractHelpViewer::DocPath = QString::fromLatin1("qthelp://com." + "trolltech.qt.%1/").arg(QString(QLatin1String(QT_VERSION_STR)) + .replace(QLatin1String("."), QLatin1String(""))); + QString AbstractHelpViewer::AboutBlank = QCoreApplication::translate("HelpViewer", "<title>about:blank</title>"); @@ -128,11 +132,12 @@ bool AbstractHelpViewer::canOpenPage(const QString &url) return !mimeFromUrl(url).isEmpty(); } -QString AbstractHelpViewer::mimeFromUrl(const QString &url) +QString AbstractHelpViewer::mimeFromUrl(const QUrl &url) { TRACE_OBJ - const int index = url.lastIndexOf(QLatin1Char('.')); - const QByteArray &ext = url.mid(index).toUtf8().toLower(); + const QString &path = url.path(); + const int index = path.lastIndexOf(QLatin1Char('.')); + const QByteArray &ext = path.mid(index).toUtf8().toLower(); const ExtensionMap *e = extensionMap; while (e->extension) { diff --git a/tools/assistant/tools/assistant/helpviewer.h b/tools/assistant/tools/assistant/helpviewer.h index 6f1f48d..80a6f87 100644 --- a/tools/assistant/tools/assistant/helpviewer.h +++ b/tools/assistant/tools/assistant/helpviewer.h @@ -67,13 +67,14 @@ public: virtual bool handleForwardBackwardMouseButtons(QMouseEvent *e) = 0; + static QString DocPath; static QString AboutBlank; static QString LocalHelpFile; static QString PageNotFoundMessage; static bool isLocalUrl(const QUrl &url); static bool canOpenPage(const QString &url); - static QString mimeFromUrl(const QString &url); + static QString mimeFromUrl(const QUrl &url); static bool launchWithExternalApp(const QUrl &url); }; diff --git a/tools/assistant/tools/assistant/helpviewer_qwv.cpp b/tools/assistant/tools/assistant/helpviewer_qwv.cpp index db1cd58..a19b29a 100644 --- a/tools/assistant/tools/assistant/helpviewer_qwv.cpp +++ b/tools/assistant/tools/assistant/helpviewer_qwv.cpp @@ -129,13 +129,27 @@ QNetworkReply *HelpNetworkAccessManager::createRequest(Operation /*op*/, const QNetworkRequest &request, QIODevice* /*outgoingData*/) { TRACE_OBJ - const QUrl &url = request.url(); - const QString &mimeType = AbstractHelpViewer::mimeFromUrl(url.toString()); - + QString url = request.url().toString(); HelpEngineWrapper &helpEngine = HelpEngineWrapper::instance(); + + // TODO: For some reason the url to load is already wrong (passed from webkit) + // though the css file and the references inside should work that way. One + // possible problem might be that the css is loaded at the same level as the + // html, thus a path inside the css like (../images/foo.png) might cd out of + // the virtual folder + if (!helpEngine.findFile(url).isValid()) { + if (url.startsWith(AbstractHelpViewer::DocPath)) { + if (!url.startsWith(AbstractHelpViewer::DocPath + QLatin1String("qdoc/"))) { + url = url.replace(AbstractHelpViewer::DocPath, + AbstractHelpViewer::DocPath + QLatin1String("qdoc/")); + } + } + } + + const QString &mimeType = AbstractHelpViewer::mimeFromUrl(url); const QByteArray &data = helpEngine.findFile(url).isValid() ? helpEngine.fileData(url) - : AbstractHelpViewer::PageNotFoundMessage.arg(url.toString()).toUtf8(); + : AbstractHelpViewer::PageNotFoundMessage.arg(url).toUtf8(); return new HelpNetworkReply(request, data, mimeType.isEmpty() ? QLatin1String("application/octet-stream") : mimeType); } diff --git a/tools/designer/src/components/propertyeditor/propertyeditor.cpp b/tools/designer/src/components/propertyeditor/propertyeditor.cpp index 86d7bdf..a8ca8ad 100644 --- a/tools/designer/src/components/propertyeditor/propertyeditor.cpp +++ b/tools/designer/src/components/propertyeditor/propertyeditor.cpp @@ -135,7 +135,7 @@ QSize ElidingLabel::sizeHint() const return size; } -void ElidingLabel::paintEvent(QPaintEvent *e) { +void ElidingLabel::paintEvent(QPaintEvent *) { QPainter painter(this); painter.setPen(QColor(0, 0, 0, 60)); painter.setBrush(QColor(255, 255, 255, 40)); diff --git a/tools/designer/src/lib/shared/filterwidget.cpp b/tools/designer/src/lib/shared/filterwidget.cpp index f485346..07af901 100644 --- a/tools/designer/src/lib/shared/filterwidget.cpp +++ b/tools/designer/src/lib/shared/filterwidget.cpp @@ -80,8 +80,11 @@ void IconButton::paintEvent(QPaintEvent *) QPainter painter(this); // Note isDown should really use the active state but in most styles // this has no proper feedback - QPixmap iconpixmap = icon().pixmap(ICONBUTTON_SIZE, ICONBUTTON_SIZE, isDown() ? - QIcon::Selected : QIcon::Normal); + QIcon::Mode state = QIcon::Disabled; + if (isEnabled()) + state = isDown() ? QIcon::Selected : QIcon::Normal; + QPixmap iconpixmap = icon().pixmap(QSize(ICONBUTTON_SIZE, ICONBUTTON_SIZE), + state, QIcon::Off); QRect pixmapRect = QRect(0, 0, iconpixmap.width(), iconpixmap.height()); pixmapRect.moveCenter(rect().center()); painter.setOpacity(m_fader); @@ -204,9 +207,12 @@ QString FilterWidget::text() const return m_editor->text(); } -void FilterWidget::checkButton(const QString &) +void FilterWidget::checkButton(const QString &text) { - m_button->animateShow(!m_editor->text().isEmpty()); + static QString oldtext; + if (oldtext.isEmpty() || text.isEmpty()) + m_button->animateShow(!m_editor->text().isEmpty()); + oldtext = text; } void FilterWidget::reset() diff --git a/tools/pixeltool/qpixeltool.cpp b/tools/pixeltool/qpixeltool.cpp index c684688..f64dfba 100644 --- a/tools/pixeltool/qpixeltool.cpp +++ b/tools/pixeltool/qpixeltool.cpp @@ -356,7 +356,7 @@ void QPixelTool::contextMenuEvent(QContextMenuEvent *e) freeze.setCheckable(true); freeze.setChecked(tmpFreeze); freeze.setShortcut(QKeySequence(Qt::Key_Space)); - QAction autoUpdate(QLatin1String("Continous update"), &menu); + QAction autoUpdate(QLatin1String("Continuous update"), &menu); autoUpdate.setCheckable(true); autoUpdate.setChecked(m_autoUpdate); autoUpdate.setShortcut(QKeySequence(Qt::Key_A)); diff --git a/tools/qdoc3/config.h b/tools/qdoc3/config.h index 980d1fb..c29becc 100644 --- a/tools/qdoc3/config.h +++ b/tools/qdoc3/config.h @@ -142,6 +142,7 @@ class Config #define CONFIG_MACRO "macro" #define CONFIG_NATURALLANGUAGE "naturallanguage" #define CONFIG_OBSOLETELINKS "obsoletelinks" +#define CONFIG_ONLINE "online" #define CONFIG_OUTPUTDIR "outputdir" #define CONFIG_OUTPUTENCODING "outputencoding" #define CONFIG_OUTPUTLANGUAGE "outputlanguage" diff --git a/tools/qdoc3/doc.cpp b/tools/qdoc3/doc.cpp index ad4cdde..5716626 100644 --- a/tools/qdoc3/doc.cpp +++ b/tools/qdoc3/doc.cpp @@ -3036,7 +3036,7 @@ QString Doc::canonicalTitle(const QString &title) QString result; result.reserve(title.size()); - bool slurping = false; + bool dashAppended = false; bool begun = false; int lastAlnum = 0; for (int i = 0; i != title.size(); ++i) { @@ -3047,18 +3047,21 @@ QString Doc::canonicalTitle(const QString &title) if (alnum) { result += QLatin1Char(c); begun = true; - slurping = false; + dashAppended = false; lastAlnum = result.size(); } - else if (!slurping) { + else if (!dashAppended) { if (begun) result += QLatin1Char('-'); - slurping = true; + dashAppended = true; } +#if 0 + // This was screwing things up. else { result += title[i]; lastAlnum = result.size(); } +#endif } result.truncate(lastAlnum); return result; diff --git a/tools/qdoc3/htmlgenerator.cpp b/tools/qdoc3/htmlgenerator.cpp index 23a3ef1..9a5ffca 100644 --- a/tools/qdoc3/htmlgenerator.cpp +++ b/tools/qdoc3/htmlgenerator.cpp @@ -204,10 +204,18 @@ static void addLink(const QString &linkTarget, HtmlGenerator::HtmlGenerator() - : helpProjectWriter(0), inLink(false), inContents(false), - inSectionHeading(false), inTableHeader(false), numTableRows(0), - threeColumnEnumValueTable(true), funcLeftParen("\\S(\\()"), - myTree(0), slow(false), obsoleteLinks(false) + : helpProjectWriter(0), + inLink(false), + inContents(false), + inSectionHeading(false), + inTableHeader(false), + numTableRows(0), + threeColumnEnumValueTable(true), + offlineDocs(true), + funcLeftParen("\\S(\\()"), + myTree(0), + slow(false), + obsoleteLinks(false) { } @@ -262,7 +270,7 @@ void HtmlGenerator::initializeGenerator(const Config &config) HTMLGENERATOR_GENERATEMACREFS); project = config.getString(CONFIG_PROJECT); - + offlineDocs = !config.getBool(CONFIG_ONLINE); projectDescription = config.getString(CONFIG_DESCRIPTION); if (projectDescription.isEmpty() && !project.isEmpty()) projectDescription = project + " Reference Documentation"; @@ -406,9 +414,7 @@ void HtmlGenerator::generateTree(const Tree *tree, CodeMarker *marker) generateIndex(fileBase, projectUrl, projectDescription); generatePageIndex(outputDir() + "/" + fileBase + ".pageindex", marker); - //qDebug() << "start helpProjectWriter->generate(myTree)"; helpProjectWriter->generate(myTree); - //qDebug() << "end helpProjectWriter->generate(myTree)"; } void HtmlGenerator::startText(const Node * /* relative */, @@ -506,14 +512,14 @@ int HtmlGenerator::generateAtom(const Atom *atom, out() << formattingRightMap()[ATOM_FORMATTING_TELETYPE]; break; case Atom::Code: - out() << "<pre>" + out() << "<pre class=\"highlightedCode\">" << trimmedTrailing(highlightedCode(indent(codeIndent,atom->string()), marker,relative)) << "</pre>\n"; break; #ifdef QDOC_QML case Atom::Qml: - out() << "<pre>" + out() << "<pre class=\"highlightedCode\">" << trimmedTrailing(highlightedCode(indent(codeIndent,atom->string()), marker,relative)) << "</pre>\n"; @@ -521,7 +527,7 @@ int HtmlGenerator::generateAtom(const Atom *atom, #endif case Atom::CodeNew: out() << "<p>you can rewrite it as</p>\n" - << "<pre>" + << "<pre class=\"highlightedCode\">" << trimmedTrailing(highlightedCode(indent(codeIndent,atom->string()), marker,relative)) << "</pre>\n"; @@ -530,9 +536,9 @@ int HtmlGenerator::generateAtom(const Atom *atom, out() << "<p>For example, if you have code like</p>\n"; // fallthrough case Atom::CodeBad: - out() << "<pre><font color=\"#404040\">" + out() << "<pre class=\"highlightedCode\">" << trimmedTrailing(protectEnc(plainCode(indent(codeIndent,atom->string())))) - << "</font></pre>\n"; + << "</pre>\n"; break; case Atom::FootnoteLeft: // ### For now @@ -841,7 +847,7 @@ int HtmlGenerator::generateAtom(const Atom *atom, if (atom->next() != 0) text = atom->next()->string(); if (atom->type() == Atom::Image) - out() << "<p align=\"center\">"; + out() << "<p class=\"centerAlign\">"; if (fileName.isEmpty()) { out() << "<font color=\"red\">[Missing image " << protectEnc(atom->string()) << "]</font>"; @@ -860,7 +866,7 @@ int HtmlGenerator::generateAtom(const Atom *atom, case Atom::ImageText: break; case Atom::LegaleseLeft: - out() << "<div style=\"padding: 0.5em; background: #e0e0e0; color: black\">"; + out() << "<div class=\"LegaleseLeft\">"; break; case Atom::LegaleseRight: out() << "</div>"; @@ -902,13 +908,13 @@ int HtmlGenerator::generateAtom(const Atom *atom, else if (atom->string() == ATOM_LIST_VALUE) { threeColumnEnumValueTable = isThreeColumnEnumValueTable(atom); if (threeColumnEnumValueTable) { - out() << "<p><table class=\"valuelist\">" + out() << "<table class=\"valuelist\">" << "<tr><th>Constant</th>" << "<th>Value</th>" << "<th>Description</th></tr>\n"; } else { - out() << "<p><table class=\"valuelist\">" + out() << "<table class=\"valuelist\">" << "<tr><th>Constant</th><th>Value</th></tr>\n"; } } @@ -943,10 +949,10 @@ int HtmlGenerator::generateAtom(const Atom *atom, else { // (atom->string() == ATOM_LIST_VALUE) // ### Trenton - out() << "<tr><td valign=\"top\"><tt>" + out() << "<tr><td class=\"topAlign\"><tt>" << protectEnc(plainCode(marker->markedUpEnumValue(atom->next()->string(), relative))) - << "</tt></td><td align=\"center\" valign=\"top\">"; + << "</tt></td><td class=\"centerAlign topAlign\">"; QString itemValue; if (relative->type() == Node::Enum) { @@ -972,7 +978,7 @@ int HtmlGenerator::generateAtom(const Atom *atom, } else if (atom->string() == ATOM_LIST_VALUE) { if (threeColumnEnumValueTable) { - out() << "</td><td valign=\"top\">"; + out() << "</td><td class=\"topAlign\">"; if (matchAhead(atom, Atom::ListItemRight)) out() << " "; } @@ -1002,7 +1008,7 @@ int HtmlGenerator::generateAtom(const Atom *atom, out() << "</dl>\n"; } else if (atom->string() == ATOM_LIST_VALUE) { - out() << "</table></p>\n"; + out() << "</table>\n"; } else { out() << "</ol>\n"; @@ -1083,29 +1089,28 @@ int HtmlGenerator::generateAtom(const Atom *atom, } if (!atom->string().isEmpty()) { if (atom->string().contains("%")) - out() << "<p><table class=\"generic\" width=\"" << atom->string() << "\" " - << "align=\"center\">\n"; + out() << "<table class=\"generic centerAlign\" width=\"" << atom->string() << "\">\n "; else { - out() << "<p><table class=\"generic\" align=\"center\">\n"; + out() << "<table class=\"generic centerAlign\">\n"; } } else { - out() << "<p><table class=\"generic\" align=\"center\">\n"; + out() << "<table class=\"generic centerAlign\">\n"; } numTableRows = 0; break; case Atom::TableRight: - out() << "</table></p>\n"; + out() << "</table>\n"; break; case Atom::TableHeaderLeft: - out() << "<thead><tr valign=\"top\" class=\"qt-style\">"; + out() << "<thead><tr class=\"qt-style topAlign\">"; inTableHeader = true; break; case Atom::TableHeaderRight: out() << "</tr>"; if (matchAhead(atom, Atom::TableHeaderLeft)) { skipAhead = 1; - out() << "\n<tr valign=\"top\" class=\"qt-style\">"; + out() << "\n<tr class=\"qt-style topAlign\">"; } else { out() << "</thead>\n"; @@ -1114,9 +1119,9 @@ int HtmlGenerator::generateAtom(const Atom *atom, break; case Atom::TableRowLeft: if (++numTableRows % 2 == 1) - out() << "<tr valign=\"top\" class=\"odd\">"; + out() << "<tr class=\"odd topAlign\">"; else - out() << "<tr valign=\"top\" class=\"even\">"; + out() << "<tr class=\"even topAlign\">"; break; case Atom::TableRowRight: out() << "</tr>\n"; @@ -1181,11 +1186,11 @@ int HtmlGenerator::generateAtom(const Atom *atom, out() << "<a name=\"" << Doc::canonicalTitle(atom->string()) << "\"></a>"; break; case Atom::UnhandledFormat: - out() << "<font color=\"red\"><b><Missing HTML></b></font>"; + out() << "<b class=\"redFont\"><Missing HTML></b>"; break; case Atom::UnknownCommand: - out() << "<font color=\"red\"><b><code>\\" << protectEnc(atom->string()) - << "</code></b></font>"; + out() << "<b class=\"redFont\"><code>\\" << protectEnc(atom->string()) + << "</code></b>"; break; #ifdef QDOC_QML case Atom::QmlText: @@ -1737,146 +1742,17 @@ void HtmlGenerator::generateHeader(const QString& title, out() << " <script src=\"scripts/jquery.js\" type=\"text/javascript\"></script>\n"; out() << " <script src=\"scripts/functions.js\" type=\"text/javascript\"></script>\n"; out() << "</head>\n"; - -#if 0 - out() << "<!DOCTYPE html\n" - " PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\" \"DTD/xhtml1-strict.dtd\">\n"; - out() << QString("<html xmlns=\"http://www.w3.org/1999/xhtml\" xml:lang=\"%1\" lang=\"%1\">\n").arg(naturalLanguage); - - QString shortVersion; - if ((project != "Qtopia") && (project != "Qt Extended")) { - shortVersion = project + " " + shortVersion + ": "; - if (node && !node->doc().location().isEmpty()) - out() << "<!-- " << node->doc().location().fileName() << " -->\n"; - - shortVersion = myTree->version(); - if (shortVersion.count(QChar('.')) == 2) - shortVersion.truncate(shortVersion.lastIndexOf(QChar('.'))); - if (!shortVersion.isEmpty()) { - if (project == "QSA") - shortVersion = "QSA " + shortVersion + ": "; - else - shortVersion = "Qt " + shortVersion + ": "; - } - } - - out() << "<head>\n" - " <title>" << shortVersion << protectEnc(title) << "</title>\n"; - out() << QString("<meta http-equiv=\"Content-type\" content=\"text/html; charset=%1\" />").arg(outputEncoding); - - if (!style.isEmpty()) - out() << " <style type=\"text/css\">" << style << "</style>\n"; - - const QMap<QString, QString> &metaMap = node->doc().metaTagMap(); - if (!metaMap.isEmpty()) { - QMapIterator<QString, QString> i(metaMap); - while (i.hasNext()) { - i.next(); - out() << " <meta name=\"" << protectEnc(i.key()) << "\" contents=\"" - << protectEnc(i.value()) << "\" />\n"; - } - } - - navigationLinks.clear(); - - if (node && !node->links().empty()) { - QPair<QString,QString> linkPair; - QPair<QString,QString> anchorPair; - const Node *linkNode; - - if (node->links().contains(Node::PreviousLink)) { - linkPair = node->links()[Node::PreviousLink]; - linkNode = findNodeForTarget(linkPair.first, node, marker); - if (!linkNode || linkNode == node) - anchorPair = linkPair; - else - anchorPair = anchorForNode(linkNode); - - out() << " <link rel=\"prev\" href=\"" - << anchorPair.first << "\" />\n"; - - navigationLinks += "[Previous: <a href=\"" + anchorPair.first + "\">"; - if (linkPair.first == linkPair.second && !anchorPair.second.isEmpty()) - navigationLinks += protectEnc(anchorPair.second); - else - navigationLinks += protectEnc(linkPair.second); - navigationLinks += "</a>]\n"; - } - if (node->links().contains(Node::ContentsLink)) { - linkPair = node->links()[Node::ContentsLink]; - linkNode = findNodeForTarget(linkPair.first, node, marker); - if (!linkNode || linkNode == node) - anchorPair = linkPair; - else - anchorPair = anchorForNode(linkNode); - - out() << " <link rel=\"contents\" href=\"" - << anchorPair.first << "\" />\n"; - navigationLinks += "[<a href=\"" + anchorPair.first + "\">"; - if (linkPair.first == linkPair.second && !anchorPair.second.isEmpty()) - navigationLinks += protectEnc(anchorPair.second); - else - navigationLinks += protectEnc(linkPair.second); - navigationLinks += "</a>]\n"; - } - if (node->links().contains(Node::NextLink)) { - linkPair = node->links()[Node::NextLink]; - linkNode = findNodeForTarget(linkPair.first, node, marker); - if (!linkNode || linkNode == node) - anchorPair = linkPair; - else - anchorPair = anchorForNode(linkNode); - - out() << " <link rel=\"next\" href=\"" - << anchorPair.first << "\" />\n"; - - navigationLinks += "[Next: <a href=\"" + anchorPair.first + "\">"; - if (linkPair.first == linkPair.second && !anchorPair.second.isEmpty()) - navigationLinks += protectEnc(anchorPair.second); - else - navigationLinks += protectEnc(linkPair.second); - navigationLinks += "</a>]\n"; - } - if (node->links().contains(Node::IndexLink)) { - linkPair = node->links()[Node::IndexLink]; - linkNode = findNodeForTarget(linkPair.first, node, marker); - if (!linkNode || linkNode == node) - anchorPair = linkPair; - else - anchorPair = anchorForNode(linkNode); - out() << " <link rel=\"index\" href=\"" - << anchorPair.first << "\" />\n"; - } - if (node->links().contains(Node::StartLink)) { - linkPair = node->links()[Node::StartLink]; - linkNode = findNodeForTarget(linkPair.first, node, marker); - if (!linkNode || linkNode == node) - anchorPair = linkPair; - else - anchorPair = anchorForNode(linkNode); - out() << " <link rel=\"start\" href=\"" - << anchorPair.first << "\" />\n"; - } - } - - foreach (const QString &stylesheet, stylesheets) { - out() << " <link href=\"" << stylesheet << "\" rel=\"stylesheet\" " - << "type=\"text/css\" />\n"; - } - - foreach (const QString &customHeadElement, customHeadElements) { - out() << " " << customHeadElement << "\n"; - } - - out() << "</head>\n" - #endif + if (offlineDocs) + out() << "<body class=\"offline\">\n"; + else out() << "<body class=\"\">\n"; + if (mainPage) generateMacRef(node, marker); out() << QString(postHeader).replace("\\" + COMMAND_VERSION, myTree->version()); -#if 0 +#if 0 // Removed for new docf format. MWS if (node && !node->links().empty()) out() << "<p>\n" << navigationLinks << "</p>\n"; #endif @@ -1932,7 +1808,7 @@ void HtmlGenerator::generateBrief(const Node *node, CodeMarker *marker, void HtmlGenerator::generateIncludes(const InnerNode *inner, CodeMarker *marker) { if (!inner->includes().isEmpty()) { - out() << "<pre>" + out() << "<pre clas=\"highlightedCode\">" << trimmedTrailing(highlightedCode(indent(codeIndent, marker->markedUpIncludes(inner->includes())), marker,inner)) @@ -1966,8 +1842,8 @@ void HtmlGenerator::generateTableOfContents(const Node *node, QString tdTag; if (numColumns > 1) { - tdTag = "<td width=\"" + QString::number((100 + numColumns - 1) / numColumns) + "%\">"; - out() << "<p><table class=\"toc\" width=\"100%\">\n<tr valign=\"top\">" + tdTag = "<td>"; /* width=\"" + QString::number((100 + numColumns - 1) / numColumns) + "%\">";*/ + out() << "<table class=\"toc\">\n<tr class=\"topAlign\">" << tdTag << "\n"; } @@ -2019,7 +1895,7 @@ void HtmlGenerator::generateTableOfContents(const Node *node, } if (numColumns > 1) - out() << "</td></tr></table></p>\n"; + out() << "</td></tr></table>\n"; inContents = false; inLink = false; @@ -2104,10 +1980,12 @@ void HtmlGenerator::generateTableOfContents(const Node *node, } int numAtoms; Text headingText = Text::sectionHeading(atom); + QString s = headingText.toString(); out() << "<li>"; out() << "<a href=\"" << "#" - << Doc::canonicalTitle(headingText.toString()) + //<< registerRef(s) + << Doc::canonicalTitle(s) << "\">"; generateAtomList(headingText.firstAtom(), node, marker, true, numAtoms); out() << "</a></li>\n"; @@ -2128,7 +2006,7 @@ void HtmlGenerator::generateNavigationBar(const NavigationBar& bar, { if (bar.prev.begin() != 0 || bar.current.begin() != 0 || bar.next.begin() != 0) { - out() << "<p align=\"right\">"; + out() << "<p class=\"rightAlign\">"; if (bar.prev.begin() != 0) { #if 0 out() << "[<a href=\"" << section.previousBaseName() @@ -2304,7 +2182,7 @@ void HtmlGenerator::generateAnnotatedList(const Node *relative, CodeMarker *marker, const NodeMap &nodeMap) { - out() << "<p><table class=\"annotated\">\n"; + out() << "<table class=\"annotated\">\n"; int row = 0; foreach (const QString &name, nodeMap.keys()) { @@ -2314,9 +2192,9 @@ void HtmlGenerator::generateAnnotatedList(const Node *relative, continue; if (++row % 2 == 1) - out() << "<tr valign=\"top\" class=\"odd\">"; + out() << "<tr class=\"odd topAlign\">"; else - out() << "<tr valign=\"top\" class=\"even\">"; + out() << "<tr class=\"even topAlign\">"; out() << "<th>"; generateFullName(node, relative, marker); out() << "</th>"; @@ -2336,7 +2214,7 @@ void HtmlGenerator::generateAnnotatedList(const Node *relative, } out() << "</tr>\n"; } - out() << "</table></p>\n"; + out() << "</table>\n"; } /*! @@ -2489,7 +2367,7 @@ void HtmlGenerator::generateCompactList(const Node *relative, } firstOffset[NumColumns] = classMap.count(); - out() << "<p><table class=\"generic\">\n"; + out() << "<table class=\"generic\">\n"; for (k = 0; k < numRows; k++) { out() << "<tr>\n"; for (i = 0; i < NumColumns; i++) { @@ -2510,7 +2388,7 @@ void HtmlGenerator::generateCompactList(const Node *relative, currentParagraphNo[i] = NumParagraphs - 1; } #endif - out() << "<td align=\"right\">"; + out() << "<td class=\"rightAlign\">"; if (currentOffsetInParagraph[i] == 0) { // start a new paragraph out() << "<b>" @@ -2553,18 +2431,18 @@ void HtmlGenerator::generateCompactList(const Node *relative, } out() << "</tr>\n"; } - out() << "</table></p>\n"; + out() << "</table>\n"; } void HtmlGenerator::generateFunctionIndex(const Node *relative, CodeMarker *marker) { - out() << "<p align=\"center\"><font size=\"+1\"><b>"; + out() << "<p class=\"centerAlign functionIndex\"><b>"; for (int i = 0; i < 26; i++) { QChar ch('a' + i); out() << QString("<a href=\"#%1\">%2</a> ").arg(ch).arg(ch.toUpper()); } - out() << "</b></font></p>\n"; + out() << "</b></p>\n"; char nextLetter = 'a'; char currentLetter; @@ -2832,8 +2710,8 @@ void HtmlGenerator::generateSection(const NodeList& nl, } else { if (twoColumn) - out() << "<p><table class=\"propsummary\">\n" - << "<tr><td valign=\"top\">"; + out() << "<table class=\"propsummary\">\n" + << "<tr><td class=\"topAlign\">"; out() << "<ul>\n"; } @@ -2846,12 +2724,11 @@ void HtmlGenerator::generateSection(const NodeList& nl, } if (name_alignment) { - out() << "<tr><td class=\"memItemLeft\" " - << "align=\"right\" valign=\"top\">"; + out() << "<tr><td class=\"memItemLeft rightAlign topAlign\"> "; } else { if (twoColumn && i == (int) (nl.count() + 1) / 2) - out() << "</ul></td><td valign=\"top\"><ul>\n"; + out() << "</ul></td><td class=\"topAlign\"><ul>\n"; out() << "<li><div class=\"fn\">"; } @@ -2868,7 +2745,7 @@ void HtmlGenerator::generateSection(const NodeList& nl, else { out() << "</ul>\n"; if (twoColumn) - out() << "</td></tr>\n</table></p>\n"; + out() << "</td></tr>\n</table>\n"; } } } @@ -2894,8 +2771,8 @@ void HtmlGenerator::generateSectionList(const Section& section, } else { if (twoColumn) - out() << "<p><table class=\"propsummary\">\n" - << "<tr><td valign=\"top\">"; + out() << "<table class=\"propsummary\">\n" + << "<tr><td class=\"topAlign\">"; out() << "<ul>\n"; } @@ -2908,12 +2785,11 @@ void HtmlGenerator::generateSectionList(const Section& section, } if (name_alignment) { - out() << "<tr><td class=\"memItemLeft\" " - << "align=\"right\" valign=\"top\">"; + out() << "<tr><td class=\"memItemLeft topAlign rightAlign\"> "; } else { if (twoColumn && i == (int) (section.members.count() + 1) / 2) - out() << "</ul></td><td valign=\"top\"><ul>\n"; + out() << "</ul></td><td class=\"topAlign\"><ul>\n"; out() << "<li><div class=\"fn\">"; } @@ -2930,7 +2806,7 @@ void HtmlGenerator::generateSectionList(const Section& section, else { out() << "</ul>\n"; if (twoColumn) - out() << "</td></tr>\n</table></p>\n"; + out() << "</td></tr>\n</table>\n"; } } @@ -3027,7 +2903,7 @@ QString HtmlGenerator::highlightedCode(const QString& markedCode, for (int i = 0, n = src.size(); i < n;) { if (src.at(i) == charLangle && src.at(i + 1).unicode() == '@') { if (nameAlignment && !done) {// && (i != 0)) Why was this here? - html += "</td><td class=\"memItemRight\" valign=\"bottom\">"; + html += "</td><td class=\"memItemRight bottomAlign\">"; done = true; } i += 2; @@ -3192,8 +3068,8 @@ void HtmlGenerator::generateSectionList(const Section& section, twoColumn = (section.members.count() >= 5); } if (twoColumn) - out() << "<p><table class=\"generic\">\n" - << "<tr><td valign=\"top\">"; + out() << "<table class=\"generic\">\n" + << "<tr><td class=\"topAlign\">"; out() << "<ul>\n"; int i = 0; @@ -3205,7 +3081,7 @@ void HtmlGenerator::generateSectionList(const Section& section, } if (twoColumn && i == (int) (section.members.count() + 1) / 2) - out() << "</ul></td><td valign=\"top\"><ul>\n"; + out() << "</ul></td><td class=\"topAlign\"><ul>\n"; out() << "<li><div class=\"fn\"></div>"; if (style == CodeMarker::Accessors) @@ -3219,7 +3095,7 @@ void HtmlGenerator::generateSectionList(const Section& section, } out() << "</ul>\n"; if (twoColumn) - out() << "</td></tr>\n</table></p>\n"; + out() << "</td></tr>\n</table>\n"; } if (style == CodeMarker::Summary && !section.inherited.isEmpty()) { @@ -4371,8 +4247,6 @@ void HtmlGenerator::endLink() inObsoleteLink = false; } -QT_END_NAMESPACE - #ifdef QDOC_QML /*! @@ -4393,15 +4267,15 @@ void HtmlGenerator::generateQmlSummary(const Section& section, twoColumn = (count >= 5); } if (twoColumn) - out() << "<p><table class=\"qmlsummary\">\n" - << "<tr><td valign=\"top\">"; + out() << "<table class=\"qmlsummary\">\n" + << "<tr><td class=\"topAlign\">"; out() << "<ul>\n"; int row = 0; m = section.members.begin(); while (m != section.members.end()) { if (twoColumn && row == (int) (count + 1) / 2) - out() << "</ul></td><td valign=\"top\"><ul>\n"; + out() << "</ul></td><td class=\"topAlign\"><ul>\n"; out() << "<li><div class=\"fn\"></div>"; generateQmlItem(*m,relative,marker,true); out() << "</li>\n"; @@ -4410,7 +4284,7 @@ void HtmlGenerator::generateQmlSummary(const Section& section, } out() << "</ul>\n"; if (twoColumn) - out() << "</td></tr>\n</table></p>\n"; + out() << "</td></tr>\n</table>\n"; } } @@ -4504,7 +4378,7 @@ void HtmlGenerator::generateQmlInherits(const QmlClassNode* cn, const Node* n = myTree->findNode(strList,Node::Fake); if (n && n->subType() == Node::QmlClass) { const QmlClassNode* qcn = static_cast<const QmlClassNode*>(n); - out() << "<p style=\"text-align: center\">"; + out() << "<p class=\"centerAlign\">"; Text text; text << "[Inherits "; text << Atom(Atom::LinkNode,CodeMarker::stringForNode(qcn)); @@ -4551,7 +4425,7 @@ void HtmlGenerator::generateQmlInstantiates(const QmlClassNode* qcn, { const ClassNode* cn = qcn->classNode(); if (cn && (cn->status() != Node::Internal)) { - out() << "<p style=\"text-align: center\">"; + out() << "<p class=\"centerAlign\">"; Text text; text << "["; text << Atom(Atom::LinkNode,CodeMarker::stringForNode(qcn)); @@ -4582,7 +4456,7 @@ void HtmlGenerator::generateInstantiatedBy(const ClassNode* cn, if (cn && cn->status() != Node::Internal && !cn->qmlElement().isEmpty()) { const Node* n = myTree->root()->findNode(cn->qmlElement(),Node::Fake); if (n && n->subType() == Node::QmlClass) { - out() << "<p style=\"text-align: center\">"; + out() << "<p class=\"centerAlign\">"; Text text; text << "["; text << Atom(Atom::LinkNode,CodeMarker::stringForNode(cn)); @@ -4726,3 +4600,139 @@ void HtmlGenerator::generatePageIndex(const QString& fileName, CodeMarker* marke } #endif + +#if 0 // fossil removed for new doc format MWS 19/04/2010 + out() << "<!DOCTYPE html\n" + " PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\" \"DTD/xhtml1-strict.dtd\">\n"; + out() << QString("<html xmlns=\"http://www.w3.org/1999/xhtml\" xml:lang=\"%1\" lang=\"%1\">\n").arg(naturalLanguage); + + QString shortVersion; + if ((project != "Qtopia") && (project != "Qt Extended")) { + shortVersion = project + " " + shortVersion + ": "; + if (node && !node->doc().location().isEmpty()) + out() << "<!-- " << node->doc().location().fileName() << " -->\n"; + + shortVersion = myTree->version(); + if (shortVersion.count(QChar('.')) == 2) + shortVersion.truncate(shortVersion.lastIndexOf(QChar('.'))); + if (!shortVersion.isEmpty()) { + if (project == "QSA") + shortVersion = "QSA " + shortVersion + ": "; + else + shortVersion = "Qt " + shortVersion + ": "; + } + } + + out() << "<head>\n" + " <title>" << shortVersion << protectEnc(title) << "</title>\n"; + out() << QString("<meta http-equiv=\"Content-type\" content=\"text/html; charset=%1\" />").arg(outputEncoding); + + if (!style.isEmpty()) + out() << " <style type=\"text/css\">" << style << "</style>\n"; + + const QMap<QString, QString> &metaMap = node->doc().metaTagMap(); + if (!metaMap.isEmpty()) { + QMapIterator<QString, QString> i(metaMap); + while (i.hasNext()) { + i.next(); + out() << " <meta name=\"" << protectEnc(i.key()) << "\" contents=\"" + << protectEnc(i.value()) << "\" />\n"; + } + } + + navigationLinks.clear(); + + if (node && !node->links().empty()) { + QPair<QString,QString> linkPair; + QPair<QString,QString> anchorPair; + const Node *linkNode; + + if (node->links().contains(Node::PreviousLink)) { + linkPair = node->links()[Node::PreviousLink]; + linkNode = findNodeForTarget(linkPair.first, node, marker); + if (!linkNode || linkNode == node) + anchorPair = linkPair; + else + anchorPair = anchorForNode(linkNode); + + out() << " <link rel=\"prev\" href=\"" + << anchorPair.first << "\" />\n"; + + navigationLinks += "[Previous: <a href=\"" + anchorPair.first + "\">"; + if (linkPair.first == linkPair.second && !anchorPair.second.isEmpty()) + navigationLinks += protectEnc(anchorPair.second); + else + navigationLinks += protectEnc(linkPair.second); + navigationLinks += "</a>]\n"; + } + if (node->links().contains(Node::ContentsLink)) { + linkPair = node->links()[Node::ContentsLink]; + linkNode = findNodeForTarget(linkPair.first, node, marker); + if (!linkNode || linkNode == node) + anchorPair = linkPair; + else + anchorPair = anchorForNode(linkNode); + + out() << " <link rel=\"contents\" href=\"" + << anchorPair.first << "\" />\n"; + + navigationLinks += "[<a href=\"" + anchorPair.first + "\">"; + if (linkPair.first == linkPair.second && !anchorPair.second.isEmpty()) + navigationLinks += protectEnc(anchorPair.second); + else + navigationLinks += protectEnc(linkPair.second); + navigationLinks += "</a>]\n"; + } + if (node->links().contains(Node::NextLink)) { + linkPair = node->links()[Node::NextLink]; + linkNode = findNodeForTarget(linkPair.first, node, marker); + if (!linkNode || linkNode == node) + anchorPair = linkPair; + else + anchorPair = anchorForNode(linkNode); + + out() << " <link rel=\"next\" href=\"" + << anchorPair.first << "\" />\n"; + + navigationLinks += "[Next: <a href=\"" + anchorPair.first + "\">"; + if (linkPair.first == linkPair.second && !anchorPair.second.isEmpty()) + navigationLinks += protectEnc(anchorPair.second); + else + navigationLinks += protectEnc(linkPair.second); + navigationLinks += "</a>]\n"; + } + if (node->links().contains(Node::IndexLink)) { + linkPair = node->links()[Node::IndexLink]; + linkNode = findNodeForTarget(linkPair.first, node, marker); + if (!linkNode || linkNode == node) + anchorPair = linkPair; + else + anchorPair = anchorForNode(linkNode); + out() << " <link rel=\"index\" href=\"" + << anchorPair.first << "\" />\n"; + } + if (node->links().contains(Node::StartLink)) { + linkPair = node->links()[Node::StartLink]; + linkNode = findNodeForTarget(linkPair.first, node, marker); + if (!linkNode || linkNode == node) + anchorPair = linkPair; + else + anchorPair = anchorForNode(linkNode); + out() << " <link rel=\"start\" href=\"" + << anchorPair.first << "\" />\n"; + } + } + + foreach (const QString &stylesheet, stylesheets) { + out() << " <link href=\"" << stylesheet << "\" rel=\"stylesheet\" " + << "type=\"text/css\" />\n"; + } + + foreach (const QString &customHeadElement, customHeadElements) { + out() << " " << customHeadElement << "\n"; + } + + out() << "</head>\n" + #endif + + QT_END_NAMESPACE diff --git a/tools/qdoc3/htmlgenerator.h b/tools/qdoc3/htmlgenerator.h index 559c968..2a365e9 100644 --- a/tools/qdoc3/htmlgenerator.h +++ b/tools/qdoc3/htmlgenerator.h @@ -297,6 +297,7 @@ class HtmlGenerator : public PageGenerator bool inTableHeader; int numTableRows; bool threeColumnEnumValueTable; + bool offlineDocs; QString link; QStringList sectionNumber; QRegExp funcLeftParen; diff --git a/tools/qdoc3/test/assistant.qdocconf b/tools/qdoc3/test/assistant.qdocconf index 5308afd..1deefce 100644 --- a/tools/qdoc3/test/assistant.qdocconf +++ b/tools/qdoc3/test/assistant.qdocconf @@ -16,7 +16,45 @@ qhp.Assistant.file = assistant.qhp qhp.Assistant.namespace = com.trolltech.assistant.470 qhp.Assistant.virtualFolder = qdoc qhp.Assistant.indexTitle = Qt Assistant Manual -qhp.Assistant.extraFiles = classic.css images/qt-logo.png images/trolltech-logo.png +qhp.Assistant.extraFiles = images/api_examples.png \ + images/api_lookup.png \ + images/api_topics.png \ + images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ + images/bg_l.png \ + images/bg_lr.png \ + images/bg_r.png \ + images/bg_ul_blank.png \ + images/bg_ul.png \ + images/bg_ur_blank.png \ + images/bg_ur.png \ + images/box_bg.png \ + images/breadcrumb.png \ + images/bullet_dn.png \ + images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ + images/feedbackground.png \ + images/form_bg.png \ + images/horBar.png \ + images/page_bg.png \ + images/print.png \ + images/qt_guide.png \ + images/qt_icon.png \ + images/qt-logo.png \ + images/qt_ref_doc.png \ + images/qt_tools.png \ + images/sep.png \ + images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ + images/taskmenuextension-example.png \ + scripts/functions.js \ + scripts/jquery.js \ + style/style.css qhp.Assistant.filterAttributes = qt 4.7.0 tools assistant qhp.Assistant.customFilters.Assistant.name = Qt Assistant Manual qhp.Assistant.customFilters.Assistant.filterAttributes = qt tools assistant diff --git a/tools/qdoc3/test/designer.qdocconf b/tools/qdoc3/test/designer.qdocconf index 2eb3d96..513801a 100644 --- a/tools/qdoc3/test/designer.qdocconf +++ b/tools/qdoc3/test/designer.qdocconf @@ -16,7 +16,45 @@ qhp.Designer.file = designer.qhp qhp.Designer.namespace = com.trolltech.designer.470 qhp.Designer.virtualFolder = qdoc qhp.Designer.indexTitle = Qt Designer Manual -qhp.Designer.extraFiles = classic.css images/qt-logo.png images/trolltech-logo.png +qhp.Designer.extraFiles = images/api_examples.png \ + images/api_lookup.png \ + images/api_topics.png \ + images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ + images/bg_l.png \ + images/bg_lr.png \ + images/bg_r.png \ + images/bg_ul_blank.png \ + images/bg_ul.png \ + images/bg_ur_blank.png \ + images/bg_ur.png \ + images/box_bg.png \ + images/breadcrumb.png \ + images/bullet_dn.png \ + images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ + images/feedbackground.png \ + images/form_bg.png \ + images/horBar.png \ + images/page_bg.png \ + images/print.png \ + images/qt_guide.png \ + images/qt_icon.png \ + images/qt-logo.png \ + images/qt_ref_doc.png \ + images/qt_tools.png \ + images/sep.png \ + images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ + images/taskmenuextension-example.png \ + scripts/functions.js \ + scripts/jquery.js \ + style/style.css qhp.Designer.filterAttributes = qt 4.7.0 tools designer qhp.Designer.customFilters.Designer.name = Qt Designer Manual qhp.Designer.customFilters.Designer.filterAttributes = qt tools designer diff --git a/tools/qdoc3/test/linguist.qdocconf b/tools/qdoc3/test/linguist.qdocconf index ac536be..a3f4f00 100644 --- a/tools/qdoc3/test/linguist.qdocconf +++ b/tools/qdoc3/test/linguist.qdocconf @@ -16,7 +16,45 @@ qhp.Linguist.file = linguist.qhp qhp.Linguist.namespace = com.trolltech.linguist.470 qhp.Linguist.virtualFolder = qdoc qhp.Linguist.indexTitle = Qt Linguist Manual -qhp.Linguist.extraFiles = classic.css images/qt-logo.png images/trolltech-logo.png +qhp.Linguist.extraFiles = images/api_examples.png \ + images/api_lookup.png \ + images/api_topics.png \ + images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ + images/bg_l.png \ + images/bg_lr.png \ + images/bg_r.png \ + images/bg_ul_blank.png \ + images/bg_ul.png \ + images/bg_ur_blank.png \ + images/bg_ur.png \ + images/box_bg.png \ + images/breadcrumb.png \ + images/bullet_dn.png \ + images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ + images/feedbackground.png \ + images/form_bg.png \ + images/horBar.png \ + images/page_bg.png \ + images/print.png \ + images/qt_guide.png \ + images/qt_icon.png \ + images/qt-logo.png \ + images/qt_ref_doc.png \ + images/qt_tools.png \ + images/sep.png \ + images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ + images/taskmenuextension-example.png \ + scripts/functions.js \ + scripts/jquery.js \ + style/style.css qhp.Linguist.filterAttributes = qt 4.7.0 tools linguist qhp.Linguist.customFilters.Linguist.name = Qt Linguist Manual qhp.Linguist.customFilters.Linguist.filterAttributes = qt tools linguist diff --git a/tools/qdoc3/test/qdeclarative.qdocconf b/tools/qdoc3/test/qdeclarative.qdocconf index 03514c1..125a410 100644 --- a/tools/qdoc3/test/qdeclarative.qdocconf +++ b/tools/qdoc3/test/qdeclarative.qdocconf @@ -27,8 +27,45 @@ qhp.Qml.indexTitle = Qml Reference # Files not referenced in any qdoc file # See also extraimages.HTML -qhp.Qml.extraFiles = classic.css \ - images/qt-logo.png +qhp.Qml.extraFiles = images/api_examples.png \ + images/api_lookup.png \ + images/api_topics.png \ + images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ + images/bg_l.png \ + images/bg_lr.png \ + images/bg_r.png \ + images/bg_ul_blank.png \ + images/bg_ul.png \ + images/bg_ur_blank.png \ + images/bg_ur.png \ + images/box_bg.png \ + images/breadcrumb.png \ + images/bullet_dn.png \ + images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ + images/feedbackground.png \ + images/form_bg.png \ + images/horBar.png \ + images/page_bg.png \ + images/print.png \ + images/qt_guide.png \ + images/qt_icon.png \ + images/qt-logo.png \ + images/qt_ref_doc.png \ + images/qt_tools.png \ + images/sep.png \ + images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ + images/taskmenuextension-example.png \ + scripts/functions.js \ + scripts/jquery.js \ + style/style.css qhp.Qml.filterAttributes = qt 4.6.0 qtrefdoc qhp.Qml.customFilters.Qt.name = Qt 4.6.0 diff --git a/tools/qdoc3/test/qmake.qdocconf b/tools/qdoc3/test/qmake.qdocconf index bd47028..f38a2a4 100644 --- a/tools/qdoc3/test/qmake.qdocconf +++ b/tools/qdoc3/test/qmake.qdocconf @@ -16,7 +16,45 @@ qhp.qmake.file = qmake.qhp qhp.qmake.namespace = com.trolltech.qmake.470 qhp.qmake.virtualFolder = qdoc qhp.qmake.indexTitle = QMake Manual -qhp.qmake.extraFiles = classic.css images/qt-logo.png images/trolltech-logo.png +qhp.qmake.extraFiles = images/api_examples.png \ + images/api_lookup.png \ + images/api_topics.png \ + images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ + images/bg_l.png \ + images/bg_lr.png \ + images/bg_r.png \ + images/bg_ul_blank.png \ + images/bg_ul.png \ + images/bg_ur_blank.png \ + images/bg_ur.png \ + images/box_bg.png \ + images/breadcrumb.png \ + images/bullet_dn.png \ + images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ + images/feedbackground.png \ + images/form_bg.png \ + images/horBar.png \ + images/page_bg.png \ + images/print.png \ + images/qt_guide.png \ + images/qt_icon.png \ + images/qt-logo.png \ + images/qt_ref_doc.png \ + images/qt_tools.png \ + images/sep.png \ + images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ + images/taskmenuextension-example.png \ + scripts/functions.js \ + scripts/jquery.js \ + style/style.css qhp.qmake.filterAttributes = qt 4.7.0 tools qmake qhp.qmake.customFilters.qmake.name = qmake Manual qhp.qmake.customFilters.qmake.filterAttributes = qt tools qmake diff --git a/tools/qdoc3/test/qt-build-docs.qdocconf b/tools/qdoc3/test/qt-build-docs.qdocconf index dbff4e2..0694748 100644 --- a/tools/qdoc3/test/qt-build-docs.qdocconf +++ b/tools/qdoc3/test/qt-build-docs.qdocconf @@ -22,14 +22,12 @@ qhp.Qt.indexTitle = Qt Reference Documentation # Files not referenced in any qdoc file (last four are needed by qtdemo) # See also extraimages.HTML qhp.Qt.extraFiles = index.html \ - style/style.css \ - scripts/functions.js \ - scripts/jquery.js \ images/api_examples.png \ images/api_lookup.png \ images/api_topics.png \ - images/bg_ll.png \ images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ images/bg_l.png \ images/bg_lr.png \ images/bg_r.png \ @@ -37,24 +35,33 @@ qhp.Qt.extraFiles = index.html \ images/bg_ul.png \ images/bg_ur_blank.png \ images/bg_ur.png \ + images/box_bg.png \ images/breadcrumb.png \ images/bullet_dn.png \ images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ images/feedbackground.png \ images/form_bg.png \ images/horBar.png \ images/page_bg.png \ images/print.png \ images/qt_guide.png \ + images/qt_icon.png \ images/qt-logo.png \ images/qt_ref_doc.png \ images/qt_tools.png \ images/sep.png \ images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ images/taskmenuextension-example.png \ - images/coloreditorfactoryimage.png \ - images/dynamiclayouts-example.png \ - images/stylesheet-coffee-plastique.png + scripts/functions.js \ + scripts/jquery.js \ + style/style.css + qhp.Qt.filterAttributes = qt 4.7.0 qtrefdoc diff --git a/tools/qdoc3/test/qt-build-docs_zh_CN.qdocconf b/tools/qdoc3/test/qt-build-docs_zh_CN.qdocconf index 461c069..5a3d726 100644 --- a/tools/qdoc3/test/qt-build-docs_zh_CN.qdocconf +++ b/tools/qdoc3/test/qt-build-docs_zh_CN.qdocconf @@ -30,14 +30,12 @@ qhp.Qt.customFilters.Qt.filterAttributes = qt 4.7.0 # Files not referenced in any qdoc file (last four are needed by qtdemo) # See also extraimages.HTML qhp.Qt.extraFiles = index.html \ - style/style.css \ - scripts/functions.js \ - scripts/jquery.js \ images/api_examples.png \ images/api_lookup.png \ images/api_topics.png \ - images/bg_ll.png \ images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ images/bg_l.png \ images/bg_lr.png \ images/bg_r.png \ @@ -45,24 +43,32 @@ qhp.Qt.extraFiles = index.html \ images/bg_ul.png \ images/bg_ur_blank.png \ images/bg_ur.png \ + images/box_bg.png \ images/breadcrumb.png \ images/bullet_dn.png \ images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ images/feedbackground.png \ images/form_bg.png \ images/horBar.png \ images/page_bg.png \ images/print.png \ images/qt_guide.png \ + images/qt_icon.png \ images/qt-logo.png \ images/qt_ref_doc.png \ images/qt_tools.png \ images/sep.png \ images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ images/taskmenuextension-example.png \ - images/coloreditorfactoryimage.png \ - images/dynamiclayouts-example.png \ - images/stylesheet-coffee-plastique.png + scripts/functions.js \ + scripts/jquery.js \ + style/style.css language = Cpp diff --git a/tools/qdoc3/test/qt-html-templates.qdocconf b/tools/qdoc3/test/qt-html-templates.qdocconf index 67a25f3..158aef3 100644 --- a/tools/qdoc3/test/qt-html-templates.qdocconf +++ b/tools/qdoc3/test/qt-html-templates.qdocconf @@ -2,7 +2,7 @@ HTML.stylesheets = style/style.css HTML.postheader = " <div class=\"header\" id=\"qtdocheader\">\n" \ " <div id=\"nav-logo\">\n" \ " <a href=\"index.html\">Home</a></div>\n" \ - " <a href=\"#\" class=\"qtref\"><span>Qt Reference Documentation</span></a>\n" \ + " <a href=\"index.html\" class=\"qtref\"><span>Qt Reference Documentation</span></a>\n" \ " <div id=\"nav-topright\">\n" \ " <ul>\n" \ " <li class=\"nav-topright-home\"><a href=\"http://qt.nokia.com/\">Qt HOME</a></li>\n" \ @@ -16,8 +16,8 @@ HTML.postheader = " <div class=\"header\" id=\"qtdocheader\">\n" \ " </div>\n" \ " <div id=\"shortCut\">\n" \ " <ul>\n" \ - " <li class=\"shortCut-topleft-inactive\"><span><a href=\"index.html\">VERSION 4.7</a></span></li>\n" \ - " <li class=\"shortCut-topleft-active\"><a href=\"http://qt.nokia.com/doc/\">ALL QT VERSIONS" \ + " <li class=\"shortCut-topleft-inactive\"><span><a href=\"index.html\">Qt 4.7</a></span></li>\n" \ + " <li class=\"shortCut-topleft-active\"><a href=\"http://qt.nokia.com/doc/\">ALL Qt VERSIONS" \ " </a></li>\n" \ " </ul>\n" \ " </div>\n" \ @@ -73,9 +73,9 @@ HTML.postheader = " <div class=\"header\" id=\"qtdocheader\">\n" \ " <ul>\n" \ " <li><a href=\"examples.html\">All examples</a></li>\n" \ " <li><a href=\"tutorials.html\">All tutorials</a></li>\n" \ - " <li><a href=\"#\">Qt Quick examples</a></li>\n" \ - " <li><a href=\"#\">Desktop examples</a></li>\n" \ - " <li><a href=\"#\">Device examples</a></li>\n" \ + " <li><a href=\"examples.html\">Qt Quick examples</a></li>\n" \ + " <li><a href=\"examples.html\">Desktop examples</a></li>\n" \ + " <li><a href=\"examples.html\">Device examples</a></li>\n" \ " </ul>\n" \ " </div>\n" \ " <div class=\"live\">\n" \ @@ -96,7 +96,7 @@ HTML.postheader = " <div class=\"header\" id=\"qtdocheader\">\n" \ " <li id=\"medA\" class=\"t_button active\">A</li>\n" \ " <li id=\"bigA\" class=\"t_button\">A</li>\n" \ " <li id=\"print\" class=\"t_button\"><a href=\"javascript:this.print();\">\n" \ - " <img src=\"images/sep.png\" /><img id=\"printIcon\" src=\"images/print.png\" alt=\"Print this page\" /></a></li>\n" \ + " <img src=\"images/sep.png\" alt=\"\" /><img id=\"printIcon\" src=\"images/print.png\" alt=\"Print this page\" /></a></li>\n" \ " </ul>\n" \ " </div>\n" \ " </div>\n" \ @@ -110,7 +110,6 @@ HTML.footer = " </div>\n" \ " <div class=\"ft\">\n" \ " <span></span>\n" \ " </div>\n" \ - " </div>\n" \ " <div class=\"footer\">\n" \ " <p>\n" \ " <acronym title=\"Copyright\">©</acronym> 2008-2010 Nokia Corporation and/or its\n" \ @@ -121,10 +120,10 @@ HTML.footer = " </div>\n" \ " href=\"http://qt.nokia.com/about/privacy-policy\">Privacy Policy</a></p>\n" \ " </div>\n" \ " <div id=\"feedbackBox\">\n" \ - " <form action=\"#\">\n" \ " <div id=\"feedcloseX\">\n" \ " <a href=\"#\" onclick=\"\$(\'#feedbackBox\').hide();\$(\'#blurpage\').hide()\">X</a>\n" \ " </div>\n" \ + " <form action=\"#\">\n" \ " <textarea id=\"feedbox\" rows=\"5\" cols=\"40\">Please submit you feedback...</textarea>\n" \ " <input id=\"feedsubmit\" type=\"submit\" onclick=\"\$(\'#feedbackBox\').hide();\$(\'#blurpage\').hide()\"\n" \ " name=\"feedback\" />\n" \ @@ -132,7 +131,6 @@ HTML.footer = " </div>\n" \ " </div>\n" \ " <div id=\"blurpage\">\n" \ " </div>\n" \ - " <script src=\"scripts/functions.js\" type=\"text/javascript\"></script>\n" \ "<script type=\"text/javascript\">\n" \ " var _gaq = _gaq || [];\n" \ " _gaq.push([\'_setAccount\', \'UA-4457116-5\']);\n" \ diff --git a/tools/qdoc3/test/qt.qdocconf b/tools/qdoc3/test/qt.qdocconf index cc3e436..69ab4e1 100644 --- a/tools/qdoc3/test/qt.qdocconf +++ b/tools/qdoc3/test/qt.qdocconf @@ -9,6 +9,7 @@ versionsym = version = %VERSION% description = Qt Reference Documentation url = http://qt.nokia.com/doc/4.7 +online = true sourceencoding = UTF-8 outputencoding = UTF-8 @@ -25,14 +26,12 @@ qhp.Qt.indexRoot = # Files not referenced in any qdoc file (last four are needed by qtdemo) # See also extraimages.HTML qhp.Qt.extraFiles = index.html \ - style/style.css \ - scripts/functions.js \ - scripts/jquery.js \ images/api_examples.png \ images/api_lookup.png \ images/api_topics.png \ - images/bg_ll.png \ images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ images/bg_l.png \ images/bg_lr.png \ images/bg_r.png \ @@ -40,24 +39,32 @@ qhp.Qt.extraFiles = index.html \ images/bg_ul.png \ images/bg_ur_blank.png \ images/bg_ur.png \ + images/box_bg.png \ images/breadcrumb.png \ images/bullet_dn.png \ images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ images/feedbackground.png \ images/form_bg.png \ images/horBar.png \ images/page_bg.png \ images/print.png \ images/qt_guide.png \ + images/qt_icon.png \ images/qt-logo.png \ images/qt_ref_doc.png \ images/qt_tools.png \ images/sep.png \ images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ images/taskmenuextension-example.png \ - images/coloreditorfactoryimage.png \ - images/dynamiclayouts-example.png \ - images/stylesheet-coffee-plastique.png + scripts/functions.js \ + scripts/jquery.js \ + style/style.css qhp.Qt.filterAttributes = qt 4.7.0 qtrefdoc qhp.Qt.customFilters.Qt.name = Qt 4.7.0 diff --git a/tools/qdoc3/test/qt_zh_CN.qdocconf b/tools/qdoc3/test/qt_zh_CN.qdocconf index c5d2c88..a5a65d8 100644 --- a/tools/qdoc3/test/qt_zh_CN.qdocconf +++ b/tools/qdoc3/test/qt_zh_CN.qdocconf @@ -32,14 +32,12 @@ qhp.Qt.customFilters.Qt.filterAttributes = qt 4.7.0 # Files not referenced in any qdoc file (last four are needed by qtdemo) # See also extraimages.HTML qhp.Qt.extraFiles = index.html \ - style/style.css \ - scripts/functions.js \ - scripts/jquery.js \ images/api_examples.png \ images/api_lookup.png \ images/api_topics.png \ - images/bg_ll.png \ images/bg_l_blank.png \ + images/bg_ll_blank.png \ + images/bg_ll.png \ images/bg_l.png \ images/bg_lr.png \ images/bg_r.png \ @@ -47,24 +45,32 @@ qhp.Qt.extraFiles = index.html \ images/bg_ul.png \ images/bg_ur_blank.png \ images/bg_ur.png \ + images/box_bg.png \ images/breadcrumb.png \ images/bullet_dn.png \ images/bullet_gt.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/coloreditorfactoryimage.png \ + images/content_bg.png \ + images/dynamiclayouts-example.png \ images/feedbackground.png \ images/form_bg.png \ images/horBar.png \ images/page_bg.png \ images/print.png \ images/qt_guide.png \ + images/qt_icon.png \ images/qt-logo.png \ images/qt_ref_doc.png \ images/qt_tools.png \ images/sep.png \ images/sprites-combined.png \ + images/stylesheet-coffee-plastique.png \ images/taskmenuextension-example.png \ - images/coloreditorfactoryimage.png \ - images/dynamiclayouts-example.png \ - images/stylesheet-coffee-plastique.png + scripts/functions.js \ + scripts/jquery.js \ + style/style.css language = Cpp diff --git a/tools/qtconfig/mainwindow.cpp b/tools/qtconfig/mainwindow.cpp index 0de4b43..9675f99 100644 --- a/tools/qtconfig/mainwindow.cpp +++ b/tools/qtconfig/mainwindow.cpp @@ -432,7 +432,7 @@ MainWindow::MainWindow() #endif #ifndef QT_NO_OPENGL videomodeCombo->addItem(tr("OpenGL"), QLatin1String("OpenGL")); - videomodeCombo->setItemData(videomodeCombo->findText(tr("OpenGL")), tr("Use OpenGL if avaiable"), Qt::ToolTipRole); + videomodeCombo->setItemData(videomodeCombo->findText(tr("OpenGL")), tr("Use OpenGL if available"), Qt::ToolTipRole); #endif videomodeCombo->addItem(tr("Software"), QLatin1String("Software")); videomodeCombo->setItemData(videomodeCombo->findText(tr("Software")), tr("Use simple software rendering"), Qt::ToolTipRole); diff --git a/tools/qtestlib/wince/cetest/main.cpp b/tools/qtestlib/wince/cetest/main.cpp index 9fe5f02..4272a83 100644 --- a/tools/qtestlib/wince/cetest/main.cpp +++ b/tools/qtestlib/wince/cetest/main.cpp @@ -285,10 +285,14 @@ int main(int argc, char **argv) } // Check wether the project is still in debug/release mode after reading // If .pro specifies to be one mode only, we need to accept this - if (project.isActiveConfig("debug")) + if (project.isActiveConfig("debug") && !project.isActiveConfig("release")) { TestConfiguration::testDebug = true; - else + debugOutput("ActiveConfig: debug only in .pro.", 1); + } + if (!project.isActiveConfig("debug") && project.isActiveConfig("release")) { TestConfiguration::testDebug = false; + debugOutput("ActiveConfig: release only in .pro.", 1); + } // determine what is the real mkspec to use if the default mkspec is being used if (Option::mkfile::qmakespec.endsWith("/default")) diff --git a/translations/assistant_de.ts b/translations/assistant_de.ts index 0a0d37f..bfafc71 100644 --- a/translations/assistant_de.ts +++ b/translations/assistant_de.ts @@ -147,7 +147,7 @@ Grund: <translation>Lesezeichen verwalten...</translation> </message> <message> - <location line="+2"/> + <location line="+3"/> <source>Add Bookmark...</source> <translation>Lesezeichen hinzufügen ...</translation> </message> @@ -190,7 +190,7 @@ Grund: <context> <name>CentralWidget</name> <message> - <location filename="../tools/assistant/tools/assistant/centralwidget.cpp" line="+117"/> + <location filename="../tools/assistant/tools/assistant/centralwidget.cpp" line="+121"/> <source>Add new page</source> <translation>Neue Seite hinzufügen</translation> </message> @@ -488,19 +488,19 @@ Grund: <name>MainWindow</name> <message> <location filename="../tools/assistant/tools/assistant/mainwindow.cpp" line="+123"/> - <location line="+366"/> + <location line="+369"/> <source>Index</source> <translation>Index</translation> </message> <message> - <location line="-360"/> - <location line="+358"/> + <location line="-363"/> + <location line="+361"/> <source>Contents</source> <translation>Inhalt</translation> </message> <message> - <location line="-351"/> - <location line="+355"/> + <location line="-354"/> + <location line="+358"/> <source>Bookmarks</source> <translation>Lesezeichen</translation> </message> @@ -510,14 +510,14 @@ Grund: <translation>Suchen</translation> </message> <message> - <location line="-335"/> - <location line="+672"/> + <location line="-338"/> + <location line="+680"/> <location line="+284"/> <source>Qt Assistant</source> <translation>Qt Assistant</translation> </message> <message> - <location line="-702"/> + <location line="-705"/> <source>Page Set&up...</source> <translation>S&eite einrichten ...</translation> </message> @@ -532,17 +532,17 @@ Grund: <translation>&Drucken ...</translation> </message> <message> - <location line="+7"/> + <location line="-10"/> <source>New &Tab</source> <translation>Neuer &Reiter</translation> </message> <message> - <location line="+3"/> + <location line="+17"/> <source>&Close Tab</source> <translation>Reiter &schließen</translation> </message> <message> - <location line="+4"/> + <location line="+5"/> <source>&Quit</source> <translation>&Beenden</translation> </message> @@ -662,17 +662,17 @@ Grund: <translation>Ctrl+Alt+Left</translation> </message> <message> - <location line="+591"/> + <location line="+596"/> <source>Could not register file '%1': %2</source> <translation>Die Datei '%1' konnte nicht registriert werden: %2</translation> </message> <message> - <location line="-584"/> + <location line="-589"/> <source>About...</source> <translation>Über ...</translation> </message> <message> - <location line="+16"/> + <location line="+21"/> <source>Navigation Toolbar</source> <translation>Navigationsleiste</translation> </message> @@ -717,12 +717,12 @@ Grund: <translation>Suchindex wird aufgebaut</translation> </message> <message> - <location line="-661"/> + <location line="-669"/> <source>Looking for Qt Documentation...</source> <translation>Suche nach Qt-Dokumentation ...</translation> </message> <message> - <location line="+219"/> + <location line="+227"/> <source>&Window</source> <translation>&Fenster</translation> </message> @@ -742,12 +742,12 @@ Grund: <translation>Zoom</translation> </message> <message> - <location line="-161"/> + <location line="-169"/> <source>&File</source> <translation>&Datei</translation> </message> <message> - <location line="+29"/> + <location line="+32"/> <source>&Edit</source> <translation>&Bearbeiten</translation> </message> diff --git a/translations/designer_de.ts b/translations/designer_de.ts index 475a5d5..b508b7f 100644 --- a/translations/designer_de.ts +++ b/translations/designer_de.ts @@ -180,12 +180,12 @@ <context> <name>BrushPropertyManager</name> <message> - <location filename="../tools/designer/src/components/propertyeditor/brushpropertymanager.cpp" line="+149"/> + <location filename="../tools/designer/src/components/propertyeditor/brushpropertymanager.cpp" line="+159"/> <source>Style</source> <translation>Stil</translation> </message> <message> - <location line="-97"/> + <location line="-107"/> <source>No brush</source> <translation>Kein Muster</translation> </message> @@ -260,7 +260,7 @@ <translation>Kreuzende Diagonalen</translation> </message> <message> - <location line="+94"/> + <location line="+104"/> <source>Color</source> <translation>Farbe</translation> </message> @@ -741,7 +741,7 @@ <context> <name>Designer</name> <message> - <location filename="../tools/designer/src/components/formeditor/qdesigner_resource.cpp" line="+449"/> + <location filename="../tools/designer/src/components/formeditor/qdesigner_resource.cpp" line="+446"/> <source>Qt Designer</source> <translation>Qt Designer</translation> </message> @@ -1202,7 +1202,7 @@ <context> <name>MainWindowBase</name> <message> - <location filename="../tools/designer/src/designer/mainwindow.cpp" line="+119"/> + <location filename="../tools/designer/src/designer/mainwindow.cpp" line="+121"/> <source>Main</source> <extracomment>Not currently used (main tool bar)</extracomment> <translation>Haupt-Werkzeugleiste</translation> @@ -1579,7 +1579,7 @@ Script: %3</source> <context> <name>QDesignerActions</name> <message> - <location filename="../tools/designer/src/designer/qdesigner_actions.cpp" line="+178"/> + <location filename="../tools/designer/src/designer/qdesigner_actions.cpp" line="+180"/> <source>Edit Widgets</source> <translation>Widgets bearbeiten</translation> </message> @@ -1604,17 +1604,17 @@ Script: %3</source> <translation>Einstellungen...</translation> </message> <message> - <location line="+298"/> + <location line="+321"/> <source>Clear &Menu</source> <translation>Menü &löschen</translation> </message> <message> - <location line="-233"/> + <location line="-246"/> <source>CTRL+SHIFT+S</source> <translation>CTRL+SHIFT+S</translation> </message> <message> - <location line="+113"/> + <location line="+126"/> <source>CTRL+R</source> <translation>CTRL+R</translation> </message> @@ -1668,7 +1668,7 @@ Script: %3</source> <translation>Designer-UI-Dateien (*.%1);;Alle Dateien (*)</translation> </message> <message> - <location line="-620"/> + <location line="-643"/> <source>%1 already exists. Do you want to replace it?</source> <translation>Die Datei %1 existiert bereits. @@ -1680,7 +1680,7 @@ Möchten Sie sie überschreiben?</translation> <translation>Das Formular %1 wurde gespeichert...</translation> </message> <message> - <location line="+371"/> + <location line="+394"/> <source>&Recent Forms</source> <translation>&Zuletzt bearbeitete Formulare</translation> </message> @@ -1764,7 +1764,7 @@ Möchten Sie einen anderen Namen eingeben oder ein neues Formular erzeugen?</tra <translation>Vorschau &schließen</translation> </message> <message> - <location line="-898"/> + <location line="-921"/> <source>Save &Image...</source> <translation>&Vorschaubild speichern...</translation> </message> @@ -1779,7 +1779,7 @@ Möchten Sie einen anderen Namen eingeben oder ein neues Formular erzeugen?</tra <translation>&Zusätzliche Schriftarten...</translation> </message> <message> - <location line="+651"/> + <location line="+674"/> <source>The file %1 could not be opened. Reason: %2 Would you like to retry or select a different file?</source> @@ -1813,7 +1813,7 @@ Möchten Sie es noch einmal versuchen?</translation> <translation>Die Datei %1 konnte nicht geschrieben werden.</translation> </message> <message> - <location line="-1163"/> + <location line="-1186"/> <source>&New...</source> <translation>&Neu...</translation> </message> @@ -1844,17 +1844,17 @@ Möchten Sie es noch einmal versuchen?</translation> </message> <message> <location line="+1"/> - <location line="+901"/> + <location line="+924"/> <source>&Close</source> <translation>&Schließen</translation> </message> <message> - <location line="-896"/> + <location line="-919"/> <source>View &Code...</source> <translation>&Code anzeigen...</translation> </message> <message> - <location line="+424"/> + <location line="+447"/> <location line="+248"/> <source>Save Form As</source> <translation>Formular unter einem anderen Namen speichern</translation> @@ -1886,7 +1886,7 @@ Möchten Sie es noch einmal versuchen?</translation> <translation>%1 wurde gedruckt.</translation> </message> <message> - <location line="-1149"/> + <location line="-1162"/> <source>ALT+CTRL+S</source> <translation>ALT+CTRL+S</translation> </message> @@ -2085,7 +2085,7 @@ Möchten Sie es noch einmal versuchen?</translation> <context> <name>QDesignerPropertySheet</name> <message> - <location filename="../tools/designer/src/lib/shared/qdesigner_propertysheet.cpp" line="+755"/> + <location filename="../tools/designer/src/lib/shared/qdesigner_propertysheet.cpp" line="+758"/> <source>Dynamic Properties</source> <translation>Dynamische Eigenschaften</translation> </message> @@ -2098,14 +2098,14 @@ Möchten Sie es noch einmal versuchen?</translation> <translation>Der Layout-Typ '%1' wird nicht unterstützt; es wurde ein Grid-Layout erzeugt.</translation> </message> <message> - <location line="+243"/> + <location line="+239"/> <source>The container extension of the widget '%1' (%2) returned a widget not managed by Designer '%3' (%4) when queried for page #%5. Container pages should only be added by specifying them in XML returned by the domXml() method of the custom widget.</source> <translation>Die Container-Extension des Widgets '%1' (%2) gab für Seite %5 ein Widget '%3' (%4) zurück, was nicht von Designer verwaltet wird. Container-Seiten sollten ausschließlich im XML der domXML()-Methode spezifiziert werden.</translation> </message> <message> - <location line="+599"/> + <location line="+545"/> <source>Unexpected element <%1></source> <extracomment>Parsing clipboard contents</extracomment> <translation>Ungültiges Element <%1></translation> @@ -2207,12 +2207,12 @@ Container-Seiten sollten ausschließlich im XML der domXML()-Methode spezifizier <translation>Werkzeugleisten</translation> </message> <message> - <location line="+465"/> + <location line="+466"/> <source>Save Forms?</source> <translation>Formulare speichern?</translation> </message> <message> - <location line="-494"/> + <location line="-495"/> <source>&View</source> <translation>&Ansicht</translation> </message> @@ -2227,7 +2227,7 @@ Container-Seiten sollten ausschließlich im XML der domXML()-Methode spezifizier <translation>Widgetbox</translation> </message> <message> - <location line="+292"/> + <location line="+293"/> <source>If you do not review your documents, all your changes will be lost.</source> <translation>Die Änderungen gehen verloren, wenn Sie sich die Formulare nicht noch einmal ansehen.</translation> </message> @@ -3497,7 +3497,7 @@ Dies kann zum Beispiel eine Sprachkennung wie "_de" sein.</translation <context> <name>QtResourceView</name> <message> - <location filename="../tools/designer/src/lib/shared/qtresourceview.cpp" line="+566"/> + <location filename="../tools/designer/src/lib/shared/qtresourceview.cpp" line="+567"/> <source>Size: %1 x %2 %3</source> <translation>Größe: %1 x %2 @@ -3908,6 +3908,26 @@ Möchten Sie sie überschreiben?</translation> </message> <message> <location line="+6"/> + <source>File</source> + <translation>Datei</translation> + </message> + <message> + <location line="+4"/> + <source>Edit</source> + <translation>Bearbeiten</translation> + </message> + <message> + <location line="+4"/> + <source>Tools</source> + <translation>Werkzeuge</translation> + </message> + <message> + <location line="+4"/> + <source>Form</source> + <translation>Formular</translation> + </message> + <message> + <location line="+4"/> <source>Toolbars</source> <translation>Werkzeugleisten</translation> </message> @@ -4698,9 +4718,14 @@ Möchten Sie sie überschreiben?</translation> <context> <name>qdesigner_internal::FilterWidget</name> <message> - <location filename="../tools/designer/src/lib/shared/filterwidget.cpp" line="+185"/> - <source><Filter></source> - <translation><Filter></translation> + <location filename="../tools/designer/src/lib/shared/filterwidget.cpp" line="+160"/> + <source>Filter</source> + <translation>Filter</translation> + </message> + <message> + <location line="+36"/> + <source>Clear text</source> + <translation>Text löschen</translation> </message> </context> <context> @@ -4827,7 +4852,7 @@ Möchten Sie sie überschreiben?</translation> <context> <name>qdesigner_internal::FormWindowBase</name> <message> - <location filename="../tools/designer/src/lib/shared/formwindowbase.cpp" line="+393"/> + <location filename="../tools/designer/src/lib/shared/formwindowbase.cpp" line="+404"/> <source>Delete</source> <translation>Löschen</translation> </message> @@ -4997,7 +5022,7 @@ Möchten Sie sie überschreiben?</translation> <translation>Formular&einstellungen...</translation> </message> <message> - <location line="+92"/> + <location line="+94"/> <source>Break Layout</source> <translation>Layout auflösen</translation> </message> @@ -5018,7 +5043,7 @@ Möchten Sie sie überschreiben?</translation> <translation>Formulareinstellungen - %1</translation> </message> <message> - <location line="-525"/> + <location line="-527"/> <source>Removes empty columns and rows</source> <translation>Entfernt unbesetzte Zeilen und Spalten</translation> </message> @@ -5975,7 +6000,7 @@ ate the goose who was loose.</source> <context> <name>qdesigner_internal::PropertyEditor</name> <message> - <location filename="../tools/designer/src/components/propertyeditor/propertyeditor.cpp" line="+183"/> + <location filename="../tools/designer/src/components/propertyeditor/propertyeditor.cpp" line="+231"/> <source>Add Dynamic Property...</source> <translation>Dynamische Eigenschaft hinzufügen...</translation> </message> @@ -5995,14 +6020,14 @@ ate the goose who was loose.</source> <translation>Detailansicht</translation> </message> <message> - <location line="+597"/> + <location line="+598"/> <source>Object: %1 Class: %2</source> <translation>Objekt: %1 Klasse: %2</translation> </message> <message> - <location line="-600"/> + <location line="-601"/> <source>Sorting</source> <translation>Sortiert</translation> </message> @@ -6012,7 +6037,7 @@ Klasse: %2</translation> <translation>Farbige Hervorhebung</translation> </message> <message> - <location line="+66"/> + <location line="+61"/> <source>Configure Property Editor</source> <translation>Anzeige der Eigenschaften konfigurieren</translation> </message> diff --git a/translations/linguist_de.ts b/translations/linguist_de.ts index 14095ba..5597458 100644 --- a/translations/linguist_de.ts +++ b/translations/linguist_de.ts @@ -453,7 +453,7 @@ Es wird mit einer einfachen Universalform gearbeitet.</translation> <translation>Ctrl+Q</translation> </message> <message> - <location filename="../tools/linguist/linguist/mainwindow.cpp" line="+646"/> + <location filename="../tools/linguist/linguist/mainwindow.cpp" line="+668"/> <location line="+15"/> <source>&Save</source> <translation>&Speichern</translation> @@ -909,7 +909,7 @@ Es wird mit einer einfachen Universalform gearbeitet.</translation> <translation>Freigeben unter ...</translation> </message> <message> - <location filename="../tools/linguist/linguist/mainwindow.cpp" line="-2013"/> + <location filename="../tools/linguist/linguist/mainwindow.cpp" line="-2035"/> <source></source> <comment>This is the application's main window.</comment> <translation></translation> @@ -1023,12 +1023,12 @@ Soll die erstgenannte Datei übersprungen werden?</translation> <message> <location filename="../tools/linguist/linguist/mainwindow.ui"/> <location filename="../tools/linguist/linguist/mainwindow.cpp" line="+15"/> - <location line="+1165"/> + <location line="+1187"/> <source>Release</source> <translation>Freigeben</translation> </message> <message> - <location filename="../tools/linguist/linguist/mainwindow.cpp" line="-1164"/> + <location filename="../tools/linguist/linguist/mainwindow.cpp" line="-1186"/> <source>Qt message files for released applications (*.qm) All files (*)</source> <translation>Qt-Nachrichtendateien (*.qm) @@ -1095,7 +1095,7 @@ Alle Dateien (*)</translation> <location line="+34"/> <location line="+24"/> <location line="+22"/> - <location line="+516"/> + <location line="+538"/> <location line="+1"/> <location line="+274"/> <location line="+40"/> @@ -1104,7 +1104,7 @@ Alle Dateien (*)</translation> <translation>Qt Linguist</translation> </message> <message> - <location line="-1198"/> + <location line="-1220"/> <location line="+102"/> <source>Cannot find the string '%1'.</source> <translation>Kann Zeichenkette '%1' nicht finden.</translation> @@ -1233,7 +1233,7 @@ Alle Dateien (*)</translation> <translation>Es wurden alle Übersetzungseinheiten abgearbeitet.</translation> </message> <message> - <location line="+176"/> + <location line="+198"/> <source>&Window</source> <translation>&Fenster</translation> </message> @@ -1493,7 +1493,7 @@ Alle Dateien (*)</translation> <message> <location/> <source>Display information about the Qt toolkit by Nokia.</source> - <translation type="unfinished"></translation> + <translation>Zeigt Informationen über das Qt-Toolkit von Nokia an.</translation> </message> </context> <context> @@ -1797,7 +1797,7 @@ Zeile: %2</translation> <translation>Kompilierte Qt-Übersetzungen</translation> </message> <message> - <location filename="../tools/linguist/linguist/mainwindow.cpp" line="-1280"/> + <location filename="../tools/linguist/linguist/mainwindow.cpp" line="-1302"/> <source>Translation files (%1);;</source> <translation>Übersetzungsdateien (%1);;</translation> </message> @@ -1818,11 +1818,16 @@ Zeile: %2</translation> <translation>Qt Linguist</translation> </message> <message> - <location filename="../tools/linguist/shared/po.cpp" line="+658"/> + <location filename="../tools/linguist/shared/po.cpp" line="+817"/> <source>GNU Gettext localization files</source> <translation>GNU-Gettext-Übersetzungsdateien</translation> </message> <message> + <location line="+7"/> + <source>GNU Gettext localization template files</source> + <translation>Vorlagen für GNU-Gettext-Übersetzungsdateien</translation> + </message> + <message> <location filename="../tools/linguist/shared/ts.cpp" line="+752"/> <source>Qt translation sources (format 1.1)</source> <translation>Qt-Übersetzungsdateien (Formatversion 1.1)</translation> @@ -1838,7 +1843,7 @@ Zeile: %2</translation> <translation>Qt-Übersetzungsdateien (aktuelles Format)</translation> </message> <message> - <location filename="../tools/linguist/shared/xliff.cpp" line="+827"/> + <location filename="../tools/linguist/shared/xliff.cpp" line="+829"/> <source>XLIFF localization files</source> <translation>XLIFF-Übersetzungsdateien</translation> </message> diff --git a/translations/qt_de.ts b/translations/qt_de.ts index ec7e786..86d5edb 100644 --- a/translations/qt_de.ts +++ b/translations/qt_de.ts @@ -12,7 +12,7 @@ <context> <name>FakeReply</name> <message> - <location filename="../src/3rdparty/webkit/WebKit/qt/tests/qwebframe/tst_qwebframe.cpp" line="+2200"/> + <location filename="../src/3rdparty/webkit/WebKit/qt/tests/qwebframe/tst_qwebframe.cpp" line="+2217"/> <source>Fake error !</source> <translation>Fake error !</translation> </message> @@ -25,7 +25,7 @@ <context> <name>MAC_APPLICATION_MENU</name> <message> - <location filename="../src/gui/kernel/qapplication.cpp" line="+2314"/> + <location filename="../src/gui/kernel/qapplication.cpp" line="+2316"/> <source>Services</source> <translation>Dienste</translation> </message> @@ -44,6 +44,21 @@ <source>Show All</source> <translation>Alle anzeigen</translation> </message> + <message> + <location line="+1"/> + <source>Preferences...</source> + <translation>Einstellungen...</translation> + </message> + <message> + <location line="+1"/> + <source>Quit %1</source> + <translation>%1 beenden</translation> + </message> + <message> + <location line="+1"/> + <source>About %1</source> + <translation>Über %1</translation> + </message> </context> <context> <name>Phonon::</name> @@ -81,25 +96,32 @@ <context> <name>Phonon::AudioOutput</name> <message> - <location filename="../src/3rdparty/phonon/phonon/audiooutput.cpp" line="+385"/> + <location filename="../src/3rdparty/phonon/phonon/audiooutput.cpp" line="+444"/> + <location line="+34"/> <source><html>The audio playback device <b>%1</b> does not work.<br/>Falling back to <b>%2</b>.</html></source> <translation><html>Das Audiogerät <b>%1</b> funktioniert nicht.<br/>Es wird stattdessen <b>%2</b> verwendet.</html></translation> </message> <message> - <location line="+13"/> + <location line="-21"/> <source><html>Switching to the audio playback device <b>%1</b><br/>which just became available and has higher preference.</html></source> <translation><html>Das Audiogerät <b>%1</b> wurde aktiviert,<br/>da es gerade verfügbar und höher priorisiert ist.</html></translation> </message> <message> <location line="+3"/> + <location line="+14"/> <source>Revert back to device '%1'</source> <translation>Zurückschalten zum Gerät '%1'</translation> </message> + <message> + <location line="-3"/> + <source><html>Switching to the audio playback device <b>%1</b><br/>which has higher preference or is specifically configured for this stream.</html></source> + <translation><html>Es wird zum Audiogerät <b>%1</b> geschaltet, <br/>da es höher priorisiert ist oder spezifisch für diesen Stream konfiguriert wurde.</html></translation> + </message> </context> <context> <name>Phonon::Gstreamer::Backend</name> <message> - <location filename="../src/3rdparty/phonon/gstreamer/backend.cpp" line="+182"/> + <location filename="../src/3rdparty/phonon/gstreamer/backend.cpp" line="+188"/> <source>Warning: You do not seem to have the package gstreamer0.10-plugins-good installed. Some video features have been disabled.</source> <translation>Achtung: Das Paket gstreamer0.10-plugins-good ist nicht installiert. @@ -116,7 +138,7 @@ Die Audio- und Video-Unterstützung steht nicht zur Verfügung.</translation> <context> <name>Phonon::Gstreamer::MediaObject</name> <message> - <location filename="../src/3rdparty/phonon/gstreamer/mediaobject.cpp" line="+90"/> + <location filename="../src/3rdparty/phonon/gstreamer/mediaobject.cpp" line="+93"/> <source>Cannot start playback. Check your GStreamer installation and make sure you @@ -126,29 +148,39 @@ have libgstreamer-plugins-base installed.</source> Bitte überprüfen Sie Ihre GStreamer-Installation und stellen Sie sicher, dass das Paket libgstreamer-plugins-base installiert ist.</translation> </message> <message> - <location line="+113"/> + <location line="+129"/> + <source>Missing codec helper script assistant.</source> + <translation>Der Skript-Hilfsassistent des Codecs fehlt.</translation> + </message> + <message> + <location line="+2"/> + <source>Plugin codec installation failed for codec: %0</source> + <translation>Die Installation des Codec-Plugins schlug fehl für: %0</translation> + </message> + <message> + <location line="+11"/> <source>A required codec is missing. You need to install the following codec(s) to play this content: %0</source> <translation>Es sind nicht alle erforderlichen Codecs installiert. Um diesen Inhalt abzuspielen, muss der folgende Codec installiert werden: %0</translation> </message> <message> - <location line="+702"/> - <location line="+8"/> - <location line="+15"/> - <location line="+26"/> + <location line="+730"/> <location line="+6"/> - <location line="+19"/> - <location line="+339"/> + <location line="+13"/> + <location line="+24"/> + <location line="+6"/> + <location line="+18"/> + <location line="+434"/> <location line="+24"/> <source>Could not open media source.</source> <translation>Die Medienquelle konnte nicht geöffnet werden.</translation> </message> <message> - <location line="-424"/> + <location line="-514"/> <source>Invalid source type.</source> <translation>Ungültiger Typ der Medienquelle.</translation> </message> <message> - <location line="+398"/> + <location line="+488"/> <source>Could not locate media source.</source> <translation>Die Medienquelle konnte nicht gefunden werden.</translation> </message> @@ -350,12 +382,40 @@ Bitte überprüfen Sie Ihre GStreamer-Installation und stellen Sie sicher, dass <translation>Die Lautstärke konnte nicht eingestellt werden</translation> </message> <message> - <location line="+50"/> + <location line="+45"/> + <source>Loading clip failed</source> + <translation>Das Laden des Clips schlug fehl</translation> + </message> + <message> + <location line="+24"/> <source>Playback complete</source> <translation>Abspielen beendet</translation> </message> </context> <context> + <name>Phonon::MMF::AbstractVideoPlayer</name> + <message> + <location filename="../src/3rdparty/phonon/mmf/abstractvideoplayer.cpp" line="+108"/> + <source>Pause failed</source> + <translation>Fehler bei Pause-Funktion</translation> + </message> + <message> + <location line="+16"/> + <source>Seek failed</source> + <translation>Suchoperation fehlgeschlagen</translation> + </message> + <message> + <location line="+54"/> + <source>Getting position failed</source> + <translation>Die Position konnte nicht bestimmt werden</translation> + </message> + <message> + <location line="+66"/> + <source>Opening clip failed</source> + <translation>Der Clip konnte nicht geöffnet werden</translation> + </message> +</context> +<context> <name>Phonon::MMF::AudioEqualizer</name> <message> <location filename="../src/3rdparty/phonon/mmf/audioequalizer.cpp" line="+92"/> @@ -370,10 +430,17 @@ Bitte überprüfen Sie Ihre GStreamer-Installation und stellen Sie sicher, dass <source>Getting position failed</source> <translation>Die Position konnte nicht bestimmt werden</translation> </message> +</context> +<context> + <name>Phonon::MMF::DsaVideoPlayer</name> <message> - <location line="+36"/> - <source>Opening clip failed</source> - <translation>Der Clip konnte nicht geöffnet werden</translation> + <location filename="../src/3rdparty/phonon/mmf/videoplayer_dsa.cpp" line="+238"/> + <location line="+15"/> + <location line="+8"/> + <location line="+22"/> + <location line="+22"/> + <source>Video display error</source> + <translation>Fehler bei der Video-Anzeige</translation> </message> </context> <context> @@ -450,7 +517,7 @@ Bitte überprüfen Sie Ihre GStreamer-Installation und stellen Sie sicher, dass <context> <name>Phonon::MMF::MediaObject</name> <message> - <location filename="../src/3rdparty/phonon/mmf/mediaobject.cpp" line="+270"/> + <location filename="../src/3rdparty/phonon/mmf/mediaobject.cpp" line="+276"/> <source>Error opening source: type not supported</source> <translation>Die Quelle konnte nicht geöffnet werden: Dieser Typ wird nicht unterstützt</translation> </message> @@ -469,38 +536,10 @@ Bitte überprüfen Sie Ihre GStreamer-Installation und stellen Sie sicher, dass </message> </context> <context> - <name>Phonon::MMF::VideoPlayer</name> - <message> - <location filename="../src/3rdparty/phonon/mmf/mmf_videoplayer.cpp" line="+125"/> - <source>Pause failed</source> - <translation>Fehler bei Pause-Funktion</translation> - </message> + <name>Phonon::MMF::SurfaceVideoPlayer</name> <message> + <location filename="../src/3rdparty/phonon/mmf/videoplayer_surface.cpp" line="+126"/> <location line="+16"/> - <source>Seek failed</source> - <translation>Suchoperation fehlgeschlagen</translation> - </message> - <message> - <location line="+54"/> - <source>Getting position failed</source> - <translation>Die Position konnte nicht bestimmt werden</translation> - </message> - <message> - <location line="+26"/> - <source>Opening clip failed</source> - <translation>Der Clip konnte nicht geöffnet werden</translation> - </message> - <message> - <location line="+26"/> - <source>Buffering clip failed</source> - <translation>Fehler beim Puffern des Clips</translation> - </message> - <message> - <location line="+174"/> - <location line="+12"/> - <location line="+176"/> - <location line="+15"/> - <location line="+6"/> <source>Video display error</source> <translation>Fehler bei der Video-Anzeige</translation> </message> @@ -1236,7 +1275,7 @@ nach <translation>Diese Socket-Operation wird nicht unterstützt</translation> </message> <message> - <location filename="../src/network/access/qhttpnetworkconnection.cpp" line="+598"/> + <location filename="../src/network/access/qhttpnetworkconnection.cpp" line="+614"/> <location filename="../src/network/socket/qabstractsocket.cpp" line="+203"/> <source>Socket operation timed out</source> <translation>Das Zeitlimit für die Operation wurde überschritten</translation> @@ -1281,7 +1320,7 @@ nach <context> <name>QApplication</name> <message> - <location filename="../src/gui/kernel/qapplication.cpp" line="-10"/> + <location filename="../src/gui/kernel/qapplication.cpp" line="-13"/> <source>QT_LAYOUT_DIRECTION</source> <comment>Translate this string to the string 'LTR' in left-to-right languages or to 'RTL' in right-to-left languages (such as Hebrew and Arabic) to get proper widget layout.</comment> <translation>LTR</translation> @@ -1409,7 +1448,7 @@ nach <context> <name>QComboBox</name> <message> - <location filename="../src/plugins/accessible/widgets/complexwidgets.cpp" line="+1771"/> + <location filename="../src/plugins/accessible/widgets/complexwidgets.cpp" line="+1772"/> <location line="+65"/> <source>Open</source> <translation>Öffnen</translation> @@ -1558,7 +1597,7 @@ nach <context> <name>QDeclarativeAbstractAnimation</name> <message> - <location filename="../src/declarative/util/qdeclarativeanimation.cpp" line="+164"/> + <location filename="../src/declarative/util/qdeclarativeanimation.cpp" line="+165"/> <source>Cannot animate non-existent property "%1"</source> <translation>Die Eigenschaft '%1" existiert nicht und kann daher nicht animiert werden</translation> </message> @@ -1571,19 +1610,19 @@ nach <context> <name>QDeclarativeAnchors</name> <message> - <location filename="../src/declarative/graphicsitems/qdeclarativeanchors.cpp" line="+176"/> + <location filename="../src/declarative/graphicsitems/qdeclarativeanchors.cpp" line="+181"/> <source>Possible anchor loop detected on fill.</source> <translation>Bei der Fülloperation wurde eine potentielle Endlosschleife der Anker festgestellt.</translation> </message> <message> - <location line="+28"/> + <location line="+29"/> <source>Possible anchor loop detected on centerIn.</source> <translation>Bei der Operation 'centerIn' wurde eine potentielle Endlosschleife der Anker festgestellt.</translation> </message> <message> - <location line="+170"/> + <location line="+201"/> <location line="+34"/> - <location line="+607"/> + <location line="+610"/> <location line="+37"/> <source>Cannot anchor to an item that isn't a parent or sibling.</source> <translation>Das Ziel eines Anker muss ein Elternelement oder Element der gleichen Ebene sein.</translation> @@ -1639,7 +1678,7 @@ nach <context> <name>QDeclarativeBehavior</name> <message> - <location filename="../src/declarative/util/qdeclarativebehavior.cpp" line="+124"/> + <location filename="../src/declarative/util/qdeclarativebehavior.cpp" line="+122"/> <source>Cannot change the animation assigned to a Behavior.</source> <translation>Die zu einem Behavior-Element gehörende Animation kann nicht geändert werden.</translation> </message> @@ -1647,7 +1686,15 @@ nach <context> <name>QDeclarativeBinding</name> <message> - <location filename="../src/declarative/qml/qdeclarativebinding.cpp" line="+195"/> + <location filename="../src/declarative/qml/qdeclarativebinding.cpp" line="+222"/> + <source>Binding loop detected for property "%1"</source> + <translation>Bei der für die Eigenschaft "%1" angegebenen Bindung wurde eine Endlosschleife festgestellt</translation> + </message> +</context> +<context> + <name>QDeclarativeCompiledBindings</name> + <message> + <location filename="../src/declarative/qml/qdeclarativecompiledbindings.cpp" line="+305"/> <source>Binding loop detected for property "%1"</source> <translation>Bei der für die Eigenschaft "%1" angegebenen Bindung wurde eine Endlosschleife festgestellt</translation> </message> @@ -1655,16 +1702,17 @@ nach <context> <name>QDeclarativeCompiler</name> <message> - <location filename="../src/declarative/qml/qdeclarativecompiler.cpp" line="+188"/> - <location line="+1807"/> + <location filename="../src/declarative/qml/qdeclarativecompiler.cpp" line="+186"/> + <location line="+1654"/> + <location line="+187"/> <location line="+82"/> <location line="+75"/> - <location line="+459"/> + <location line="+488"/> <source>Invalid property assignment: "%1" is a read-only property</source> <translation>Ungültige Zuweisung bei Eigenschaft: "%1" ist schreibgeschützt</translation> </message> <message> - <location line="-2414"/> + <location line="-2477"/> <source>Invalid property assignment: unknown enumeration</source> <translation>Ungültige Zuweisung bei Eigenschaft: Ungültiger Aufzählungswert</translation> </message> @@ -1749,12 +1797,12 @@ nach <translation>Ungültige Zuweisung bei Eigenschaft: Der Typ "%1" ist nicht unterstützt</translation> </message> <message> - <location line="+259"/> + <location line="+269"/> <source>Element is not creatable.</source> <translation>Das Element kann nicht erzeugt werden.</translation> </message> <message> - <location line="+548"/> + <location line="+603"/> <source>Component elements may not contain properties other than id</source> <translation>Komponenten dürfen außer id keine weiteren Eigenschaften enthalten.</translation> </message> @@ -1770,12 +1818,12 @@ nach </message> <message> <location line="+6"/> - <location line="+594"/> + <location line="+558"/> <source>id is not unique</source> <translation>ID-Wert nicht eindeutig</translation> </message> <message> - <location line="-584"/> + <location line="-548"/> <source>Invalid component body specification</source> <translation>Inhalt der Komponente ungültig</translation> </message> @@ -1785,7 +1833,7 @@ nach <translation>Es kann keine leere Komponentenangabe erzeugt werden</translation> </message> <message> - <location line="+17"/> + <location line="+19"/> <source>Invalid Script block. Specify either the source property or inline script</source> <translation>Ungültiges Skript. Es muss die Eigenschaft oder ein eingebettetes Skript angegeben werden</translation> </message> @@ -1795,7 +1843,7 @@ nach <translation>Ungültige Angabe für Skript</translation> </message> <message> - <location line="+24"/> + <location line="+25"/> <source>Properties cannot be set on Script block</source> <translation>Für ein Skript können keine Eigenschaften angegeben werden</translation> </message> @@ -1805,12 +1853,7 @@ nach <translation>Ungültiges Skript</translation> </message> <message> - <location line="+144"/> - <source>Incorrectly specified signal</source> - <translation>Ungültige Signalspezifikation</translation> - </message> - <message> - <location line="+13"/> + <location line="+128"/> <source>Empty signal assignment</source> <translation>Leere Signalzuweisung</translation> </message> @@ -1843,12 +1886,12 @@ nach </message> <message> <location line="+2"/> - <location line="+361"/> + <location line="+355"/> <source>Cannot assign to non-existent property "%1"</source> <translation>Es kann keine Zuweisung erfolgen, da keine Eigenschaft des Namens '%1" existiert</translation> </message> <message> - <location line="-330"/> + <location line="-324"/> <source>Invalid use of namespace</source> <translation>Ungültige Verwendung eines Namensraums</translation> </message> @@ -1863,23 +1906,18 @@ nach <translation>Ungültige Verwendung einer Eigenschaft des Typs 'Id'</translation> </message> <message> - <location line="+13"/> - <source>id conflicts with type name</source> - <translation>Der Wert der Id ist ungültig, da er bereits als Typnamen vergeben ist</translation> - </message> - <message> - <location line="+2"/> - <source>id conflicts with namespace prefix</source> - <translation>Der Wert der Id ist ungültig, da er bereits als Namensraum vergeben ist</translation> + <location line="-356"/> + <source>Incorrectly specified signal assignment</source> + <translation></translation> </message> <message> - <location line="+84"/> + <location line="+445"/> <location line="+2"/> <source>Property has already been assigned a value</source> <translation>Der Eigenschaft wurde bereits ein Wert zugewiesen</translation> </message> <message> - <location line="+8"/> + <location line="+12"/> <location line="+8"/> <source>Invalid grouped property access</source> <translation>Falsche Gruppierung bei Zugriff auf Eigenschaft</translation> @@ -1895,7 +1933,7 @@ nach <translation>Ungültige Verwendung von Eigenschaften</translation> </message> <message> - <location line="+12"/> + <location line="+13"/> <source>Property assignment expected</source> <translation>Zuweisung an Eigenschaft erwartet</translation> </message> @@ -1945,7 +1983,7 @@ nach <translation>"%1" kann nicht auf "%2" angewandt werden</translation> </message> <message> - <location line="+96"/> + <location line="+117"/> <source>Duplicate default property</source> <translation>Mehrfaches Auftreten der Vorgabe-Eigenschaft</translation> </message> @@ -2000,7 +2038,7 @@ nach <translation>Ungültiger Typ der Eigenschaft</translation> </message> <message> - <location line="+151"/> + <location line="+159"/> <source>Invalid empty ID</source> <translation>Ungültiger (leerer) Id-Wert</translation> </message> @@ -2050,7 +2088,7 @@ nach <context> <name>QDeclarativeComponent</name> <message> - <location filename="../src/declarative/qml/qdeclarativecomponent.cpp" line="+442"/> + <location filename="../src/declarative/qml/qdeclarativecomponent.cpp" line="+452"/> <source>Invalid empty URL</source> <translation>Ungültige (leere) URL</translation> </message> @@ -2058,18 +2096,13 @@ nach <context> <name>QDeclarativeCompositeTypeManager</name> <message> - <location filename="../src/declarative/qml/qdeclarativecompositetypemanager.cpp" line="+415"/> - <location line="+220"/> + <location filename="../src/declarative/qml/qdeclarativecompositetypemanager.cpp" line="+483"/> + <location line="+268"/> <source>Resource %1 unavailable</source> <translation>Auf die Ressource %1 konnte nicht zugegriffen werden</translation> </message> <message> - <location line="-141"/> - <source>Import %1 unavailable</source> - <translation>Import %1 nicht verfügbar</translation> - </message> - <message> - <location line="+30"/> + <location line="-119"/> <source>Namespace %1 cannot be used as a type</source> <translation>Der Namensraum %1 kann nicht als Typangabe verwendet werden</translation> </message> @@ -2079,7 +2112,7 @@ nach <translation>%1 ist keine Typangabe</translation> </message> <message> - <location line="+42"/> + <location line="+46"/> <source>Type %1 unavailable</source> <translation>Der Typ %1 ist nicht verfügbar</translation> </message> @@ -2142,11 +2175,48 @@ nach <source>SQL: database version mismatch</source> <translation>SQL: Die Version der Datenbank entspricht nicht der erwarteten Version</translation> </message> + <message> + <location filename="../src/declarative/qml/qdeclarativeengine.cpp" line="+1515"/> + <source>module "%1" definition "%2" not readable</source> + <translation>Modul "%1" Definition "%2" kann nicht gelesen werden</translation> + </message> + <message> + <location line="+23"/> + <source>plugin cannot be loaded for module "%1": %2</source> + <translation>Das Plugin des Moduls "%1" konnte nicht geladen werden: %2</translation> + </message> + <message> + <location line="+5"/> + <source>module "%1" plugin "%2" not found</source> + <translation>Modul "%1" Plugin "%2" konnte nicht gefunden werden</translation> + </message> + <message> + <location line="+82"/> + <location line="+55"/> + <source>module "%1" version %2.%3 is not installed</source> + <translation>Modul "%1" Version %2.%3 ist nicht installiert</translation> + </message> + <message> + <location line="-53"/> + <source>module "%1" is not installed</source> + <translation>Modul "%1" ist nicht installiert</translation> + </message> + <message> + <location line="+14"/> + <location line="+19"/> + <source>"%1": no such directory</source> + <translation>Das Verzeichnis "%1" existiert nicht</translation> + </message> + <message> + <location line="-2"/> + <source>import "%1" has no qmldir and no namespace</source> + <translation>"qmldir" und Namensraum fehlt bei Import "%1"</translation> + </message> </context> <context> <name>QDeclarativeFlipable</name> <message> - <location filename="../src/declarative/graphicsitems/qdeclarativeflipable.cpp" line="+124"/> + <location filename="../src/declarative/graphicsitems/qdeclarativeflipable.cpp" line="+125"/> <source>front is a write-once property</source> <translation>'front' kann nur einmal zugewiesen werden</translation> </message> @@ -2159,7 +2229,7 @@ nach <context> <name>QDeclarativeInfo</name> <message> - <location filename="../src/declarative/qml/qdeclarativeinfo.cpp" line="+112"/> + <location filename="../src/declarative/qml/qdeclarativeinfo.cpp" line="+113"/> <location line="+3"/> <source>unknown location</source> <translation>Unbekannter Ort</translation> @@ -2168,50 +2238,51 @@ nach <context> <name>QDeclarativeListModel</name> <message> - <location filename="../src/declarative/util/qdeclarativelistmodel.cpp" line="+483"/> + <location filename="../src/declarative/util/qdeclarativelistmodel.cpp" line="+399"/> <source>remove: index %1 out of range</source> <translation>remove: Der Index %1 ist außerhalb des gültigen Bereichs</translation> </message> <message> - <location line="+30"/> + <location line="+33"/> <source>insert: value is not an object</source> <translation>insert: Der Wert ist kein Objekt</translation> </message> <message> - <location line="+9"/> + <location line="+5"/> <source>insert: index %1 out of range</source> <translation>insert: Der Index %1 ist außerhalb des gültigen Bereichs</translation> </message> <message> - <location line="+29"/> + <location line="+30"/> <source>move: out of range</source> <translation>move: Außerhalb des gültigen Bereichs</translation> </message> <message> - <location line="+49"/> + <location line="+40"/> <source>append: value is not an object</source> <translation>append: Der Wert ist kein Objekt</translation> </message> <message> - <location line="+39"/> + <location line="+34"/> <source>get: index %1 out of range</source> <translation>get: Der Index %1 ist außerhalb des gültigen Bereichs</translation> </message> <message> - <location line="+33"/> + <location line="+25"/> <source>set: value is not an object</source> <translation>set: Der Wert ist kein Objekt</translation> </message> <message> <location line="+4"/> - <location line="+39"/> + <location line="+34"/> <source>set: index %1 out of range</source> <translation>set: Der Index %1 ist außerhalb des gültigen Bereichs</translation> </message> <message> - <location line="+38"/> - <source>ListElement: cannot use default property</source> - <translation>ListElement: Die Vorgabe-Eigenschaft kann nicht verwendet werden</translation> + <location line="+39"/> + <location line="+15"/> + <source>ListElement: cannot contain nested elements</source> + <translation>ListElement kann keine geschachtelten Elemente enthalten</translation> </message> <message> <location line="+4"/> @@ -2219,20 +2290,28 @@ nach <translation>ListElement: Die "id"-Eigenschaft kann nicht verwendet werden</translation> </message> <message> - <location line="+46"/> + <location line="+49"/> <source>ListElement: cannot use script for property value</source> <translation>ListElement: Es kann kein Skript für den Wert der Eigenschaft verwendet werden</translation> </message> <message> - <location line="+25"/> + <location line="+29"/> <source>ListModel: undefined property '%1'</source> <translation>ListModel: Die Eigenschaft '%1' ist nicht definiert</translation> </message> </context> <context> + <name>QDeclarativeLoader</name> + <message> + <location filename="../src/declarative/graphicsitems/qdeclarativeloader.cpp" line="+309"/> + <source>Loader does not support loading non-visual elements.</source> + <translation>Das Laden nicht-visueller Elemente ist nicht unterstützt.</translation> + </message> +</context> +<context> <name>QDeclarativeParentAnimation</name> <message> - <location filename="../src/declarative/util/qdeclarativeanimation.cpp" line="+2486"/> + <location filename="../src/declarative/util/qdeclarativeanimation.cpp" line="+2370"/> <source>Unable to preserve appearance under complex transform</source> <translation>Das Erscheinungsbild kann bei einer komplexen Transformation nicht beibehalten werden</translation> </message> @@ -2251,7 +2330,7 @@ nach <context> <name>QDeclarativeParentChange</name> <message> - <location filename="../src/declarative/util/qdeclarativestateoperations.cpp" line="+93"/> + <location filename="../src/declarative/util/qdeclarativestateoperations.cpp" line="+94"/> <source>Unable to preserve appearance under complex transform</source> <translation>Das Erscheinungsbild kann bei einer komplexen Transformation nicht beibehalten werden</translation> </message> @@ -2270,7 +2349,7 @@ nach <context> <name>QDeclarativeParser</name> <message> - <location filename="../src/declarative/qml/parser/qdeclarativejslexer.cpp" line="+556"/> + <location filename="../src/declarative/qml/parser/qdeclarativejslexer.cpp" line="+558"/> <source>Illegal character</source> <translation>Ungültiges Zeichen</translation> </message> @@ -2315,7 +2394,7 @@ nach <translation>Ungültiger Modifikator '%0' bei regulärem Ausdruck</translation> </message> <message> - <location filename="../src/declarative/qml/parser/qdeclarativejsparser.cpp" line="+1781"/> + <location filename="../src/declarative/qml/parser/qdeclarativejsparser.cpp" line="+1828"/> <location line="+67"/> <source>Syntax error</source> <translation>Syntaxfehler</translation> @@ -2332,14 +2411,14 @@ nach <translation>Es wird das Element '%1' erwartet</translation> </message> <message> - <location filename="../src/declarative/qml/qdeclarativescriptparser.cpp" line="+266"/> - <location line="+434"/> + <location filename="../src/declarative/qml/qdeclarativescriptparser.cpp" line="+264"/> + <location line="+481"/> <location line="+59"/> <source>Property value set multiple times</source> <translation>Mehrfache Zuweisung eines Wertes an eine Eigenschaft</translation> </message> <message> - <location line="-482"/> + <location line="-529"/> <source>Expected type name</source> <translation>Es wird ein Typname erwartet</translation> </message> @@ -2349,17 +2428,27 @@ nach <translation>Ungültige Verwendung von Skript-Blöcken</translation> </message> <message> - <location line="+154"/> + <location line="+161"/> <source>Invalid import qualifier ID</source> <translation>Ungültige Id-Angabe bei Import</translation> </message> <message> + <location line="+15"/> + <source>Script import qualifiers must be unique.</source> + <translation>Der für den Skript-Import angegebene Qualifizierer muss eindeutig sein.</translation> + </message> + <message> + <location line="+10"/> + <source>Script import requires a qualifier</source> + <translation>Der Skript-Import erfordert die Angabe eines Qualifizierers.</translation> + </message> + <message> <location line="+11"/> <source>Library import requires a version</source> <translation>Der Import einer Bibliothek erfordert eine Versionsangabe</translation> </message> <message> - <location line="+53"/> + <location line="+60"/> <source>Expected parameter type</source> <translation>Es wird eine Typangabe für den Parameter erwartet</translation> </message> @@ -2384,7 +2473,7 @@ nach <translation>'read-only' wird an dieser Stelle noch nicht unterstützt</translation> </message> <message> - <location line="+213"/> + <location line="+222"/> <source>JavaScript declaration outside Script element</source> <translation>Eine JavaScript-Deklaration ist außerhalb eines Skriptelementes nicht zulässig</translation> </message> @@ -2397,15 +2486,39 @@ nach <context> <name>QDeclarativePauseAnimation</name> <message> - <location filename="../src/declarative/util/qdeclarativeanimation.cpp" line="-2103"/> + <location filename="../src/declarative/util/qdeclarativeanimation.cpp" line="-1972"/> <source>Cannot set a duration of < 0</source> <translation>Es kann keine Zeitdauer <0 gesetzt werden</translation> </message> </context> <context> + <name>QDeclarativePixmapCache</name> + <message> + <location filename="../src/declarative/util/qdeclarativepixmapcache.cpp" line="+197"/> + <source>Error decoding: %1: %2</source> + <translation>Fehler beim Decodieren: %1: %2</translation> + </message> + <message> + <location line="+70"/> + <source>Failed to get image from provider: %1</source> + <translation>Bilddaten konnten nicht erhalten werden: %1</translation> + </message> + <message> + <location line="+19"/> + <location line="+342"/> + <source>Cannot open: %1</source> + <translation>Fehlschlag beim Öffnen: %1</translation> + </message> + <message> + <location line="+37"/> + <source>Unknown Error loading %1</source> + <translation>Unbekannter Fehler beim Laden von %1</translation> + </message> +</context> +<context> <name>QDeclarativePropertyAnimation</name> <message> - <location line="+1252"/> + <location filename="../src/declarative/util/qdeclarativeanimation.cpp" line="+1100"/> <source>Cannot set a duration of < 0</source> <translation>Es kann keine Zeitdauer <0 gesetzt werden</translation> </message> @@ -2413,7 +2526,12 @@ nach <context> <name>QDeclarativePropertyChanges</name> <message> - <location filename="../src/declarative/util/qdeclarativepropertychanges.cpp" line="+380"/> + <location filename="../src/declarative/util/qdeclarativepropertychanges.cpp" line="+231"/> + <source>PropertyChanges does not support creating state-specific objects.</source> + <translation>Die Erzeugung von Objekten, die einem Zustand zugeordnet sind, wird von PropertyChanges nicht unterstützt.</translation> + </message> + <message> + <location line="+151"/> <source>Cannot assign to non-existent property "%1"</source> <translation>Es kann keine Zuweisung erfolgen, da keine Eigenschaft des Namens '%1" existiert</translation> </message> @@ -2426,7 +2544,7 @@ nach <context> <name>QDeclarativeTextInput</name> <message> - <location filename="../src/declarative/graphicsitems/qdeclarativetextinput.cpp" line="+594"/> + <location filename="../src/declarative/graphicsitems/qdeclarativetextinput.cpp" line="+783"/> <location line="+9"/> <source>Could not load cursor delegate</source> <translation>Cursor-Delegate konnte nicht geladen werden</translation> @@ -2440,12 +2558,12 @@ nach <context> <name>QDeclarativeVME</name> <message> - <location filename="../src/declarative/qml/qdeclarativevme.cpp" line="+195"/> + <location filename="../src/declarative/qml/qdeclarativevme.cpp" line="+194"/> <source>Unable to create object of type %1</source> <translation>Es konnte kein Objekt des Typs %1 erzeugt werden</translation> </message> <message> - <location line="+306"/> + <location line="+380"/> <source>Cannot assign value %1 to property %2</source> <translation>Der Wert '%1' kann nicht der Eigenschaft %2 zugewiesen werden</translation> </message> @@ -2465,7 +2583,7 @@ nach <translation>Der Signal-Eigenschaft %1 kann kein Objekt zugewiesen werden</translation> </message> <message> - <location line="+147"/> + <location line="+153"/> <source>Cannot assign object to list</source> <translation>Zuweisung eines Objekts an eine Liste nicht zulässig</translation> </message> @@ -2488,7 +2606,7 @@ nach <context> <name>QDeclarativeVisualDataModel</name> <message> - <location filename="../src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp" line="+1022"/> + <location filename="../src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp" line="+1032"/> <source>Delegate component must be Item type.</source> <translation>Delegate-Komponente muss vom Typ 'Item' sein</translation> </message> @@ -2496,7 +2614,7 @@ nach <context> <name>QDeclarativeXmlListModelRole</name> <message> - <location filename="../src/declarative/util/qdeclarativexmllistmodel_p.h" line="+158"/> + <location filename="../src/declarative/util/qdeclarativexmllistmodel_p.h" line="+168"/> <source>An XmlRole query must not start with '/'</source> <translation>Eine XmlRole-Abfrage darf nicht mit '/' beginnen</translation> </message> @@ -2504,7 +2622,7 @@ nach <context> <name>QDeclarativeXmlRoleList</name> <message> - <location filename="../src/declarative/util/qdeclarativexmllistmodel.cpp" line="+623"/> + <location filename="../src/declarative/util/qdeclarativexmllistmodel.cpp" line="+638"/> <source>An XmlListModel query must start with '/' or "//"</source> <translation>Eine XmlListModel-Abfrage muss mit '/' oder "//" beginnen</translation> </message> @@ -2530,12 +2648,12 @@ nach <context> <name>QDialog</name> <message> - <location filename="../src/gui/dialogs/qdialog.cpp" line="+659"/> + <location filename="../src/gui/dialogs/qdialog.cpp" line="+645"/> <source>What's This?</source> <translation>Direkthilfe</translation> </message> <message> - <location line="-135"/> + <location line="-122"/> <source>Done</source> <translation>Fertig</translation> </message> @@ -2543,9 +2661,9 @@ nach <context> <name>QDialogButtonBox</name> <message> - <location filename="../src/gui/dialogs/qmessagebox.cpp" line="+1906"/> + <location filename="../src/gui/dialogs/qmessagebox.cpp" line="+1920"/> <location line="+464"/> - <location filename="../src/gui/widgets/qdialogbuttonbox.cpp" line="+648"/> + <location filename="../src/gui/widgets/qdialogbuttonbox.cpp" line="+649"/> <source>OK</source> <translation>OK</translation> </message> @@ -2757,7 +2875,7 @@ nach <context> <name>QFile</name> <message> - <location filename="../src/corelib/io/qfile.cpp" line="+698"/> + <location filename="../src/corelib/io/qfile.cpp" line="+703"/> <location line="+155"/> <source>Destination file exists</source> <translation>Die Zieldatei existiert bereits</translation> @@ -2797,7 +2915,7 @@ nach <name>QFileDialog</name> <message> <location filename="../src/gui/dialogs/qfiledialog.cpp" line="+558"/> - <location line="+471"/> + <location line="+481"/> <source>All Files (*)</source> <translation>Alle Dateien (*)</translation> </message> @@ -2820,13 +2938,13 @@ nach <translation>Details</translation> </message> <message> - <location filename="../src/gui/itemviews/qfileiconprovider.cpp" line="+465"/> + <location filename="../src/gui/itemviews/qfileiconprovider.cpp" line="+467"/> <location line="+1"/> <source>File</source> <translation>Datei</translation> </message> <message> - <location filename="../src/gui/dialogs/qfiledialog.cpp" line="-488"/> + <location filename="../src/gui/dialogs/qfiledialog.cpp" line="-498"/> <source>Open</source> <translation>Öffnen</translation> </message> @@ -2836,7 +2954,7 @@ nach <translation>Speichern unter</translation> </message> <message> - <location line="+699"/> + <location line="+709"/> <location line="+55"/> <location line="+1532"/> <source>&Open</source> @@ -2854,7 +2972,7 @@ nach <translation>Zuletzt besucht</translation> </message> <message> - <location line="-2530"/> + <location line="-2540"/> <source>&Rename</source> <translation>&Umbenennen</translation> </message> @@ -2869,17 +2987,17 @@ nach <translation>&Versteckte Dateien anzeigen</translation> </message> <message> - <location line="+1976"/> + <location line="+1986"/> <source>New Folder</source> <translation>Neues Verzeichnis</translation> </message> <message> - <location line="-2011"/> + <location line="-2021"/> <source>Find Directory</source> <translation>Verzeichnis suchen</translation> </message> <message> - <location line="+706"/> + <location line="+716"/> <source>Directories</source> <translation>Verzeichnisse</translation> </message> @@ -2889,8 +3007,8 @@ nach <translation>Alle Dateien (*.*)</translation> </message> <message> - <location filename="../src/gui/dialogs/qfiledialog.cpp" line="-665"/> - <location line="+669"/> + <location filename="../src/gui/dialogs/qfiledialog.cpp" line="-675"/> + <location line="+679"/> <source>Directory:</source> <translation>Verzeichnis:</translation> </message> @@ -2989,7 +3107,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> <translation>Unbekannt</translation> </message> <message> - <location filename="../src/gui/dialogs/qfiledialog.cpp" line="-2130"/> + <location filename="../src/gui/dialogs/qfiledialog.cpp" line="-2140"/> <source>Show </source> <translation>Anzeigen </translation> </message> @@ -3005,7 +3123,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> <translation>&Neues Verzeichnis</translation> </message> <message> - <location line="+677"/> + <location line="+687"/> <location line="+43"/> <source>&Choose</source> <translation>&Auswählen</translation> @@ -3016,8 +3134,8 @@ Möchten Sie die Datei trotzdem löschen?</translation> <translation>Löschen</translation> </message> <message> - <location filename="../src/gui/dialogs/qfiledialog.cpp" line="-713"/> - <location line="+673"/> + <location filename="../src/gui/dialogs/qfiledialog.cpp" line="-723"/> + <location line="+683"/> <source>File &name:</source> <translation>Datei&name:</translation> </message> @@ -3033,12 +3151,42 @@ Möchten Sie die Datei trotzdem löschen?</translation> <source>Create New Folder</source> <translation>Neuen Ordner erstellen</translation> </message> + <message> + <location/> + <source>Go back</source> + <translation>Zurück</translation> + </message> + <message> + <location/> + <source>Go forward</source> + <translation>Vor</translation> + </message> + <message> + <location/> + <source>Go to the parent directory</source> + <translation>Gehe zum übergeordneten Verzeichnis</translation> + </message> + <message> + <location/> + <source>Create a New Folder</source> + <translation>Neuen Ordner erstellen</translation> + </message> + <message> + <location/> + <source>Change to list view mode</source> + <translation>Wechsle zu Listenansicht</translation> + </message> + <message> + <location/> + <source>Change to detail view mode</source> + <translation>Wechsle zu Detailansicht</translation> + </message> </context> <context> <name>QFileSystemModel</name> <message> <location filename="../src/gui/dialogs/qfilesystemmodel.cpp" line="+740"/> - <location filename="../src/gui/itemviews/qdirmodel.cpp" line="+476"/> + <location filename="../src/gui/itemviews/qdirmodel.cpp" line="+482"/> <source>%1 TB</source> <translation>%1 TB</translation> </message> @@ -3418,14 +3566,14 @@ Möchten Sie die Datei trotzdem löschen?</translation> <translation>Verbindung mit %1 beendet</translation> </message> <message> - <location filename="../src/network/access/qftp.cpp" line="+1377"/> + <location filename="../src/network/access/qftp.cpp" line="+1383"/> <location filename="../src/qt3support/network/q3ftp.cpp" line="-243"/> <location line="+250"/> <source>Connection closed</source> <translation>Verbindung beendet</translation> </message> <message> - <location line="-1489"/> + <location line="-1495"/> <location filename="../src/qt3support/network/q3ftp.cpp" line="-1566"/> <source>Host %1 not found</source> <translation>Rechner %1 konnte nicht gefunden werden</translation> @@ -3450,7 +3598,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> <translation>Unbekannter Fehler</translation> </message> <message> - <location line="+891"/> + <location line="+897"/> <location filename="../src/qt3support/network/q3ftp.cpp" line="+77"/> <source>Connecting to host failed: %1</source> @@ -3522,7 +3670,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> %1</translation> </message> <message> - <location line="-1529"/> + <location line="-1535"/> <location filename="../src/qt3support/network/q3ftp.cpp" line="-1356"/> <source>Not connected</source> <translation>Keine Verbindung</translation> @@ -3912,7 +4060,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> <context> <name>QIODevice</name> <message> - <location filename="../src/corelib/global/qglobal.cpp" line="+2094"/> + <location filename="../src/corelib/global/qglobal.cpp" line="+2099"/> <source>Permission denied</source> <translation>Zugriff verweigert</translation> </message> @@ -3932,7 +4080,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> <translation>Kein freier Speicherplatz auf dem Gerät vorhanden</translation> </message> <message> - <location filename="../src/corelib/io/qiodevice.cpp" line="+1564"/> + <location filename="../src/corelib/io/qiodevice.cpp" line="+1596"/> <source>Unknown error</source> <translation>Unbekannter Fehler</translation> </message> @@ -3940,7 +4088,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> <context> <name>QInputContext</name> <message> - <location filename="../src/gui/inputmethod/qinputcontextfactory.cpp" line="+256"/> + <location filename="../src/gui/inputmethod/qinputcontextfactory.cpp" line="+301"/> <source>XIM</source> <translation>XIM</translation> </message> @@ -3996,7 +4144,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> <translation>Operation unmap fehlgeschlagen für '%1': %2</translation> </message> <message> - <location line="+361"/> + <location line="+375"/> <source>The plugin '%1' uses incompatible Qt library. (%2.%3.%4) [%5]</source> <translation>Das Plugin '%1' verwendet eine inkompatible Qt-Bibliothek. (%2.%3.%4) [%5]</translation> </message> @@ -4011,7 +4159,8 @@ Möchten Sie die Datei trotzdem löschen?</translation> <translation>Unbekannter Fehler</translation> </message> <message> - <location line="-402"/> + <location line="-540"/> + <location line="+138"/> <location filename="../src/corelib/plugin/qpluginloader.cpp" line="+343"/> <source>The shared library was not found.</source> <translation>Die dynamische Bibliothek konnte nicht gefunden werden.</translation> @@ -4048,7 +4197,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> <context> <name>QLineEdit</name> <message> - <location filename="../src/gui/widgets/qlineedit.cpp" line="+2107"/> + <location filename="../src/gui/widgets/qlineedit.cpp" line="+2110"/> <source>Select All</source> <translation>Alles auswählen</translation> </message> @@ -4124,7 +4273,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> <message> <location line="+3"/> <location filename="../src/network/socket/qlocalsocket_unix.cpp" line="+3"/> - <location filename="../src/network/socket/qlocalsocket_win.cpp" line="+80"/> + <location filename="../src/network/socket/qlocalsocket_win.cpp" line="+79"/> <location line="+59"/> <source>%1: Invalid name</source> <translation>%1: Ungültiger Name</translation> @@ -4371,7 +4520,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> <context> <name>QMediaPlayer</name> <message> - <location filename="../src/multimedia/playback/qmediaplayer.cpp" line="+494"/> + <location filename="../src/multimedia/playback/qmediaplayer.cpp" line="+496"/> <source>The QMediaPlayer object does not have a valid service</source> <translation>Das QMediaPlayer-Objekt verfügt über keinen gültigen Dienst</translation> </message> @@ -4462,7 +4611,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> <translation>Hilfe</translation> </message> <message> - <location line="-1119"/> + <location line="-1129"/> <source>Show Details...</source> <translation>Details einblenden...</translation> </message> @@ -4735,7 +4884,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> <context> <name>QNetworkAccessManager</name> <message> - <location filename="../src/network/access/qnetworkreplyimpl.cpp" line="+885"/> + <location filename="../src/network/access/qnetworkreplyimpl.cpp" line="+910"/> <source>Network access is disabled.</source> <translation>Der Zugriff auf das Netzwerk ist nicht gestattet.</translation> </message> @@ -4748,17 +4897,17 @@ Möchten Sie die Datei trotzdem löschen?</translation> <translation>Beim Herunterladen von %1 trat ein Fehler auf - Die Antwort des Servers ist: %2</translation> </message> <message> - <location filename="../src/network/access/qnetworkreplyimpl.cpp" line="-801"/> + <location filename="../src/network/access/qnetworkreplyimpl.cpp" line="-828"/> <source>Protocol "%1" is unknown</source> <translation>Das Protokoll "%1" ist unbekannt</translation> </message> <message> - <location line="+177"/> + <location line="+192"/> <source>Network session error.</source> <translation>Fehler bei Netzwerkverbindung.</translation> </message> <message> - <location line="+323"/> + <location line="+329"/> <source>Temporary network failure.</source> <translation>Das Netzwerk ist zur Zeit ausgefallen.</translation> </message> @@ -4766,7 +4915,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> <context> <name>QNetworkReplyImpl</name> <message> - <location line="+110"/> + <location line="+111"/> <location line="+28"/> <source>Operation canceled</source> <translation>Operation abgebrochen</translation> @@ -4775,7 +4924,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> <context> <name>QNetworkSession</name> <message> - <location filename="../src/network/bearer/qnetworksession.cpp" line="+441"/> + <location filename="../src/network/bearer/qnetworksession.cpp" line="+449"/> <source>Invalid configuration.</source> <translation>Ungültige Konfiguration.</translation> </message> @@ -4783,8 +4932,8 @@ Möchten Sie die Datei trotzdem löschen?</translation> <context> <name>QNetworkSessionPrivateImpl</name> <message> - <location filename="../src/plugins/bearer/qnetworksession_impl.cpp" line="+270"/> - <location filename="../src/plugins/bearer/symbian/qnetworksession_impl.cpp" line="+215"/> + <location filename="../src/plugins/bearer/qnetworksession_impl.cpp" line="+272"/> + <location filename="../src/plugins/bearer/symbian/qnetworksession_impl.cpp" line="+227"/> <source>Unknown session error.</source> <translation>Unbekannter Fehler bei Netzwerkverbindung.</translation> </message> @@ -4813,7 +4962,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> <translation>Das Roaming wurde abgebrochen oder ist hier nicht möglich.</translation> </message> <message> - <location filename="../src/plugins/bearer/icd/qnetworksession_impl.cpp" line="+1159"/> + <location filename="../src/plugins/bearer/icd/qnetworksession_impl.cpp" line="+1005"/> <source>Roaming error</source> <translation>Fehler beim Roaming</translation> </message> @@ -4905,12 +5054,12 @@ Möchten Sie die Datei trotzdem löschen?</translation> <context> <name>QODBCDriver</name> <message> - <location filename="../src/sql/drivers/odbc/qsql_odbc.cpp" line="+1842"/> + <location filename="../src/sql/drivers/odbc/qsql_odbc.cpp" line="+1888"/> <source>Unable to connect</source> <translation>Es kann keine Verbindung aufgebaut werden</translation> </message> <message> - <location line="+234"/> + <location line="+269"/> <source>Unable to disable autocommit</source> <translation>'autocommit' konnte nicht deaktiviert werden</translation> </message> @@ -4930,7 +5079,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> <translation>'autocommit' konnte nicht aktiviert werden</translation> </message> <message> - <location line="-277"/> + <location line="-312"/> <source>Unable to connect - Driver doesn't support all functionality required</source> <translation>Es kann keine Verbindung aufgebaut werden weil der Treiber die benötigte Funktionalität nicht vollständig unterstützt</translation> </message> @@ -4938,7 +5087,7 @@ Möchten Sie die Datei trotzdem löschen?</translation> <context> <name>QODBCResult</name> <message> - <location line="-940"/> + <location line="-941"/> <location line="+351"/> <source>QODBCResult::reset: Unable to set 'SQL_CURSOR_STATIC' as statement attribute. Please check your ODBC driver configuration</source> <translation>QODBCResult::reset: 'SQL_CURSOR_STATIC' konnte nicht als Attribut des Befehls gesetzt werden. Bitte prüfen Sie die Konfiguration Ihres ODBC-Treibers</translation> @@ -4990,10 +5139,16 @@ Möchten Sie die Datei trotzdem löschen?</translation> <context> <name>QObject</name> <message> - <location filename="../src/declarative/util/qdeclarativexmllistmodel.cpp" line="-193"/> + <location filename="../src/declarative/util/qdeclarativexmllistmodel.cpp" line="-194"/> <source>"%1" duplicates a previous role name and will be disabled.</source> <translation>"%1" ist bereits als Name einer Rolle vergeben und wird daher deaktiviert.</translation> </message> + <message> + <location filename="../src/3rdparty/phonon/phonon/pulsesupport.cpp" line="+162"/> + <location line="+11"/> + <source>PulseAudio Sound Server</source> + <translation>PulseAudio Sound Server</translation> + </message> </context> <context> <name>QPPDOptionsModel</name> @@ -5915,7 +6070,7 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> <translation>Zeitüberschreitung</translation> </message> <message> - <location filename="../src/corelib/io/qprocess.cpp" line="+856"/> + <location filename="../src/corelib/io/qprocess.cpp" line="+866"/> <location line="+52"/> <location filename="../src/corelib/io/qprocess_win.cpp" line="-211"/> <location line="+50"/> @@ -7535,7 +7690,157 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> <translation>Umdrehen</translation> </message> <message> - <location line="+603"/> + <location line="+4"/> + <source>Kanji</source> + <translation>Kanji</translation> + </message> + <message> + <location line="+1"/> + <source>Muhenkan</source> + <translation>Muhenkan</translation> + </message> + <message> + <location line="+1"/> + <source>Henkan</source> + <translation>Henkan</translation> + </message> + <message> + <location line="+1"/> + <source>Romaji</source> + <translation>Romaji</translation> + </message> + <message> + <location line="+1"/> + <source>Hiragana</source> + <translation>Hiragana</translation> + </message> + <message> + <location line="+1"/> + <source>Katakana</source> + <translation>Katakana</translation> + </message> + <message> + <location line="+1"/> + <source>Hiragana Katakana</source> + <translation>Hiragana Katakana</translation> + </message> + <message> + <location line="+1"/> + <source>Zenkaku</source> + <translation>Zenkaku</translation> + </message> + <message> + <location line="+1"/> + <source>Hankaku</source> + <translation>Hankaku</translation> + </message> + <message> + <location line="+1"/> + <source>Zenkaku Hankaku</source> + <translation>Zenkaku Hankaku</translation> + </message> + <message> + <location line="+1"/> + <source>Touroku</source> + <translation>Touroku</translation> + </message> + <message> + <location line="+1"/> + <source>Massyo</source> + <translation>Massyo</translation> + </message> + <message> + <location line="+1"/> + <source>Kana Lock</source> + <translation>Kana Lock</translation> + </message> + <message> + <location line="+1"/> + <source>Kana Shift</source> + <translation>Kana Shift</translation> + </message> + <message> + <location line="+1"/> + <source>Eisu Shift</source> + <translation>Eisu Shift</translation> + </message> + <message> + <location line="+1"/> + <source>Eisu toggle</source> + <translation>Eisu toggle</translation> + </message> + <message> + <location line="+1"/> + <source>Code input</source> + <translation>Code-Eingabe</translation> + </message> + <message> + <location line="+1"/> + <source>Multiple Candidate</source> + <translation>Mehrere Vorschläge</translation> + </message> + <message> + <location line="+1"/> + <source>Previous Candidate</source> + <translation>Vorangegangener Vorschlag</translation> + </message> + <message> + <location line="+4"/> + <source>Hangul</source> + <translation>Hangul</translation> + </message> + <message> + <location line="+1"/> + <source>Hangul Start</source> + <translation>Hangul Anfang</translation> + </message> + <message> + <location line="+1"/> + <source>Hangul End</source> + <translation>Hangul Ende</translation> + </message> + <message> + <location line="+1"/> + <source>Hangul Hanja</source> + <translation>Hangul Hanja</translation> + </message> + <message> + <location line="+1"/> + <source>Hangul Jamo</source> + <translation>Hangul Jamo</translation> + </message> + <message> + <location line="+1"/> + <source>Hangul Romaja</source> + <translation>Hangul Romaja</translation> + </message> + <message> + <location line="+1"/> + <source>Hangul Jeonja</source> + <translation>Hangul Jeonja</translation> + </message> + <message> + <location line="+1"/> + <source>Hangul Banja</source> + <translation>Hangul Banja</translation> + </message> + <message> + <location line="+1"/> + <source>Hangul PreHanja</source> + <translation>Hangul PreHanja</translation> + </message> + <message> + <location line="+1"/> + <source>Hangul PostHanja</source> + <translation>Hangul PostHanja</translation> + </message> + <message> + <location line="+1"/> + <source>Hangul Special</source> + <translation>Hangul Special</translation> + </message> + <message> + <location line="+602"/> <location line="+135"/> <source>Ctrl</source> <translation>Strg</translation> @@ -7569,7 +7874,7 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> <translation>F%1</translation> </message> <message> - <location line="-899"/> + <location line="-934"/> <source>Home Page</source> <translation>Startseite</translation> </message> @@ -7703,7 +8008,7 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> <translation>Abbrechen</translation> </message> <message> - <location filename="../src/gui/kernel/qsoftkeymanager_s60.cpp" line="+331"/> + <location filename="../src/gui/kernel/qsoftkeymanager_s60.cpp" line="+319"/> <source>Exit</source> <translation>Beenden</translation> </message> @@ -8039,7 +8344,7 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> <context> <name>QTcpServer</name> <message> - <location filename="../src/network/socket/qtcpserver.cpp" line="+282"/> + <location filename="../src/network/socket/qtcpserver.cpp" line="+292"/> <source>Operation on socket is not supported</source> <translation>Diese Socket-Operation wird nicht unterstützt</translation> </message> @@ -8047,7 +8352,7 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> <context> <name>QTextControl</name> <message> - <location filename="../src/gui/text/qtextcontrol.cpp" line="+2034"/> + <location filename="../src/gui/text/qtextcontrol.cpp" line="+2036"/> <source>&Undo</source> <translation>&Rückgängig</translation> </message> @@ -8105,7 +8410,7 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> <context> <name>QUdpSocket</name> <message> - <location filename="../src/network/socket/qudpsocket.cpp" line="+179"/> + <location filename="../src/network/socket/qudpsocket.cpp" line="+189"/> <source>This platform does not support IPv6</source> <translation>Diese Plattform unterstützt kein IPv6</translation> </message> @@ -8205,7 +8510,7 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> <context> <name>QWebFrame</name> <message> - <location filename="../src/3rdparty/webkit/WebKit/qt/WebCoreSupport/FrameLoaderClientQt.cpp" line="+712"/> + <location filename="../src/3rdparty/webkit/WebKit/qt/WebCoreSupport/FrameLoaderClientQt.cpp" line="+753"/> <source>Request cancelled</source> <translation>Anfrage wurde abgebrochen</translation> </message> @@ -8238,7 +8543,7 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> <context> <name>QWebPage</name> <message> - <location filename="../src/3rdparty/webkit/WebCore/platform/qt/Localizations.cpp" line="+42"/> + <location filename="../src/3rdparty/webkit/WebCore/platform/qt/Localizations.cpp" line="+44"/> <source>Submit</source> <comment>default label for Submit buttons in forms on web pages</comment> <translation>Senden</translation> @@ -8490,7 +8795,13 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> <translation>Von rechts nach links</translation> </message> <message> - <location line="+105"/> + <location line="+100"/> + <source>Missing Plug-in</source> + <comment>Label text to be used when a plug-in is missing</comment> + <translation>Fehlendes Plugin</translation> + </message> + <message> + <location line="+20"/> <source>Loading...</source> <comment>Media controller status message when the media is loading</comment> <translation>Lädt...</translation> @@ -8724,7 +9035,7 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> <translation>%1 Sekunden</translation> </message> <message> - <location line="-210"/> + <location line="-225"/> <source>Inspect</source> <comment>Inspect Element context menu item</comment> <translation>Prüfen</translation> @@ -8748,13 +9059,13 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> <translation>Gespeicherte Suchanfragen löschen</translation> </message> <message> - <location line="+75"/> + <location line="+90"/> <source>Unknown</source> <comment>Unknown filesize FTP directory listing item</comment> <translation>Unbekannt</translation> </message> <message> - <location filename="../src/3rdparty/webkit/WebKit/qt/WebCoreSupport/InspectorClientQt.cpp" line="+167"/> + <location filename="../src/3rdparty/webkit/WebKit/qt/WebCoreSupport/InspectorClientQt.cpp" line="+236"/> <source>Web Inspector - %2</source> <translation>Web Inspector - %2</translation> </message> @@ -8765,12 +9076,12 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> <translation>%1 (%2x%3 Pixel)</translation> </message> <message> - <location filename="../src/3rdparty/webkit/WebCore/platform/network/qt/QNetworkReplyHandler.cpp" line="+416"/> + <location filename="../src/3rdparty/webkit/WebCore/platform/network/qt/QNetworkReplyHandler.cpp" line="+456"/> <source>Bad HTTP request</source> <translation>Ungültige HTTP-Anforderung</translation> </message> <message> - <location filename="../src/3rdparty/webkit/WebCore/platform/qt/Localizations.cpp" line="-291"/> + <location filename="../src/3rdparty/webkit/WebCore/platform/qt/Localizations.cpp" line="-306"/> <source>This is a searchable index. Enter search keywords: </source> <comment>text that appears at the start of nearly-obsolete web pages in the form of a 'searchable index'</comment> <translation>Dieser Index verfügt über eine Suchfunktion. Geben Sie einen Suchbegriff ein:</translation> @@ -8850,22 +9161,22 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> </translation> </message> <message> - <location filename="../src/3rdparty/webkit/WebKit/qt/Api/qwebpage.cpp" line="+1833"/> + <location filename="../src/3rdparty/webkit/WebKit/qt/Api/qwebpage.cpp" line="+1959"/> <source>JavaScript Alert - %1</source> <translation>JavaScript-Hinweis - %1</translation> </message> <message> - <location line="+16"/> + <location line="+17"/> <source>JavaScript Confirm - %1</source> <translation>JavaScript-Bestätigung - %1</translation> </message> <message> - <location line="+19"/> + <location line="+20"/> <source>JavaScript Prompt - %1</source> <translation>JavaScript-Eingabeaufforderung - %1</translation> </message> <message> - <location line="+25"/> + <location line="+26"/> <source>JavaScript Problem - %1</source> <translation>JavaScript-Problem - %1</translation> </message> @@ -8875,7 +9186,7 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> <translation>Das Skript dieser Webseite ist fehlerhaft. Möchten Sie es anhalten?</translation> </message> <message> - <location line="+381"/> + <location line="+374"/> <source>Move the cursor to the next character</source> <translation>Positionsmarke auf folgendes Zeichen setzen</translation> </message> @@ -9096,7 +9407,7 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> <context> <name>QWidget</name> <message> - <location filename="../src/gui/kernel/qwidget.cpp" line="+5805"/> + <location filename="../src/gui/kernel/qwidget.cpp" line="+5809"/> <source>*</source> <translation>*</translation> </message> @@ -9104,7 +9415,7 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> <context> <name>QWizard</name> <message> - <location filename="../src/gui/dialogs/qwizard.cpp" line="+661"/> + <location filename="../src/gui/dialogs/qwizard.cpp" line="+701"/> <source>Cancel</source> <translation>Abbrechen</translation> </message> @@ -11927,4 +12238,27 @@ Bitte wählen Sie einen anderen Dateinamen.</translation> <translation>Das Attribut '%1' enthält einen ungültigen qualifizierten Namen: %2.</translation> </message> </context> +<context> + <name>Widget</name> + <message> + <location filename="../src/3rdparty/webkit/WebKit/qt/tests/hybridPixmap/widget.ui"/> + <source>Widget</source> + <translation>Widget</translation> + </message> + <message> + <location/> + <source>about:blank</source> + <translation>about:blank</translation> + </message> + <message> + <location/> + <source>Image from Qt to HTML</source> + <translation>Bild von Qt zu HTML</translation> + </message> + <message> + <location/> + <source>Pixmap from Qt to HTML</source> + <translation>Pixmap von Qt zu HTML</translation> + </message> +</context> </TS> diff --git a/translations/qt_help_de.ts b/translations/qt_help_de.ts index 40d1158..c7a8103 100644 --- a/translations/qt_help_de.ts +++ b/translations/qt_help_de.ts @@ -43,7 +43,7 @@ </message> <message> <location line="+11"/> - <location line="+49"/> + <location line="+52"/> <source>Cannot open collection file: %1</source> <translation>Katalogdatei kann nicht geöffnet werden: %1</translation> </message> @@ -58,7 +58,7 @@ <translation>Die Katalogdatei '%1' existiert bereits.</translation> </message> <message> - <location line="+148"/> + <location line="+151"/> <source>Unknown filter '%1'!</source> <translation>Unbekannter Filter '%1'.</translation> </message> @@ -78,12 +78,12 @@ <translation>Die Datenbank '%1' kann nicht zur Optimierung geöffnet werden.</translation> </message> <message> - <location line="-436"/> + <location line="-439"/> <source>Cannot create directory: %1</source> <translation>Das Verzeichnis kann nicht angelegt werden: %1</translation> </message> <message> - <location line="+23"/> + <location line="+26"/> <source>Cannot copy collection file: %1</source> <translation>Die Katalogdatei kann nicht kopiert werden: %1</translation> </message> @@ -158,7 +158,7 @@ <translation>Die Datenbank-Datei %1 kann nicht geöffnet werden.</translation> </message> <message> - <location line="+11"/> + <location line="+14"/> <source>Cannot register namespace %1!</source> <translation>Der Namensraum %1 kann nicht registriert werden.</translation> </message> @@ -266,7 +266,7 @@ <context> <name>QHelpProject</name> <message> - <location filename="../tools/assistant/lib/qhelpprojectdata.cpp" line="+86"/> + <location filename="../tools/assistant/lib/qhelpprojectdata.cpp" line="+88"/> <source>Unknown token.</source> <translation>Unbekanntes Token.</translation> </message> @@ -282,16 +282,16 @@ </message> <message> <location line="+14"/> - <source>A virtual folder must not contain a '/' character!</source> - <translation>Ein virtuelles Verzeichnis darf kein '/'-Zeichen enthalten.</translation> + <source>Virtual folder has invalid syntax.</source> + <translation>Ungültige Syntax bei Angabe des virtuellen Verzeichnisses.</translation> </message> <message> - <location line="+6"/> - <source>A namespace must not contain a '/' character!</source> - <translation>Ein Namensraum darf kein '/'-Zeichen enthalten.</translation> + <location line="+5"/> + <source>Namespace has invalid syntax.</source> + <translation>Ungültige Syntax der Namensraum-Angabe.</translation> </message> <message> - <location line="+20"/> + <location line="+19"/> <source>Missing namespace in QtHelpProject.</source> <translation>Fehlender Namensraum in QtHelpProject.</translation> </message> @@ -306,7 +306,7 @@ <translation>Fehlendes Attribut in Schlagwort in Zeile %1.</translation> </message> <message> - <location line="+125"/> + <location line="+141"/> <source>The input file %1 could not be opened!</source> <translation>Die Eingabe-Datei %1 kann nicht geöffnet werden.</translation> </message> |