From 47c12e2a4cf135faf5ac58d54d8fe87068b35d3d Mon Sep 17 00:00:00 2001 From: Jani Hautakangas Date: Thu, 28 Oct 2010 11:27:02 +0300 Subject: Fallback to vgWritePixels in drawPixmap. Use vgWritePixels, if possible, in case where VGImage for QPixmap can't be allocated due to low GPU memory situation. This patch also renames some VG paint engine internal functions to clarify their purpose. Task-number: QT-3589 Reviewed-by: Jason Barron --- src/openvg/qpaintengine_vg.cpp | 86 +++++++++++++++++++++++++++++++++++++----- src/openvg/qpaintengine_vg_p.h | 1 + src/openvg/qpixmapdata_vg.cpp | 45 ++++++++++++++-------- src/openvg/qpixmapdata_vg_p.h | 6 ++- src/openvg/qvg_symbian.cpp | 3 +- 5 files changed, 113 insertions(+), 28 deletions(-) diff --git a/src/openvg/qpaintengine_vg.cpp b/src/openvg/qpaintengine_vg.cpp index ce9d11a..9df32d9 100644 --- a/src/openvg/qpaintengine_vg.cpp +++ b/src/openvg/qpaintengine_vg.cpp @@ -55,6 +55,8 @@ #include #include #include +#include +#include #include #include #include @@ -3060,6 +3062,21 @@ void qt_vg_drawVGImageStencil vgDrawImage(vgImg); } +bool QVGPaintEngine::canVgWritePixels(const QImage &image) const +{ + Q_D(const QVGPaintEngine); + // vgWritePixels ignores masking, blending and xforms so we can only use it if + // ALL of the following conditions are true: + // - It is a simple translate, or a scale of -1 on the y-axis (inverted) + // - The opacity is totally opaque + // - The composition mode is "source" OR "source over" provided the image is opaque + return ( d->imageTransform.type() <= QTransform::TxScale + && d->imageTransform.m11() == 1.0 && qAbs(d->imageTransform.m22()) == 1.0) + && d->opacity == 1.0f + && (d->blendMode == VG_BLEND_SRC || (d->blendMode == VG_BLEND_SRC_OVER && + !image.hasAlphaChannel())); +} + void QVGPaintEngine::drawPixmap(const QRectF &r, const QPixmap &pm, const QRectF &sr) { QPixmapData *pd = pm.pixmapData(); @@ -3074,9 +3091,18 @@ void QVGPaintEngine::drawPixmap(const QRectF &r, const QPixmap &pm, const QRectF drawVGImage(d, r, vgpd->toVGImage(), vgpd->size(), sr); else drawVGImage(d, r, vgpd->toVGImage(d->opacity), vgpd->size(), sr); - } else { - drawImage(r, *(pd->buffer()), sr, Qt::AutoColor); + + if(!vgpd->failedToAlloc) + return; + + // try to reallocate next time if reasonable small pixmap + QSize screenSize = QApplication::desktop()->screenGeometry().size(); + if (pm.size().width() <= screenSize.width() + && pm.size().height() <= screenSize.height()) + vgpd->failedToAlloc = false; } + + drawImage(r, *(pd->buffer()), sr, Qt::AutoColor); } void QVGPaintEngine::drawPixmap(const QPointF &pos, const QPixmap &pm) @@ -3093,9 +3119,18 @@ void QVGPaintEngine::drawPixmap(const QPointF &pos, const QPixmap &pm) drawVGImage(d, pos, vgpd->toVGImage()); else drawVGImage(d, pos, vgpd->toVGImage(d->opacity)); - } else { - drawImage(pos, *(pd->buffer())); + + if (!vgpd->failedToAlloc) + return; + + // try to reallocate next time if reasonable small pixmap + QSize screenSize = QApplication::desktop()->screenGeometry().size(); + if (pm.size().width() <= screenSize.width() + && pm.size().height() <= screenSize.height()) + vgpd->failedToAlloc = false; } + + drawImage(pos, *(pd->buffer())); } void QVGPaintEngine::drawImage @@ -3116,9 +3151,31 @@ void QVGPaintEngine::drawImage QRectF(QPointF(0, 0), sr.size())); } } else { - // Monochrome images need to use the vgChildImage() path. - vgImg = toVGImage(image, flags); - drawVGImage(d, r, vgImg, image.size(), sr); + if (canVgWritePixels(image) && (r.size() == sr.size()) && !flags) { + // Optimization for straight blits, no blending + int x = sr.x(); + int y = sr.y(); + int bpp = image.depth() >> 3; // bytes + int offset = 0; + int bpl = image.bytesPerLine(); + if (d->imageTransform.m22() < 0) { + // inverted + offset = ((y + sr.height()) * bpl) - ((image.width() - x) * bpp); + bpl = -bpl; + } else { + offset = (y * bpl) + (x * bpp); + } + const uchar *bits = image.constBits() + offset; + + QPointF mapped = d->imageTransform.map(r.topLeft()); + vgWritePixels(bits, bpl, qt_vg_image_to_vg_format(image.format()), + mapped.x(), mapped.y() - sr.height(), r.width(), r.height()); + return; + } else { + // Monochrome images need to use the vgChildImage() path. + vgImg = toVGImage(image, flags); + drawVGImage(d, r, vgImg, image.size(), sr); + } } vgDestroyImage(vgImg); } @@ -3127,10 +3184,21 @@ void QVGPaintEngine::drawImage(const QPointF &pos, const QImage &image) { Q_D(QVGPaintEngine); VGImage vgImg; - if (d->simpleTransform || d->opacity == 1.0f) + if (canVgWritePixels(image)) { + // Optimization for straight blits, no blending + bool inverted = (d->imageTransform.m22() < 0); + const uchar *bits = inverted ? image.constBits() + image.byteCount() : image.constBits(); + int bpl = inverted ? -image.bytesPerLine() : image.bytesPerLine(); + + QPointF mapped = d->imageTransform.map(pos); + vgWritePixels(bits, bpl, qt_vg_image_to_vg_format(image.format()), + mapped.x(), mapped.y() - image.height(), image.width(), image.height()); + return; + } else if (d->simpleTransform || d->opacity == 1.0f) { vgImg = toVGImage(image); - else + } else { vgImg = toVGImageWithOpacity(image, d->opacity); + } drawVGImage(d, pos, vgImg); vgDestroyImage(vgImg); } diff --git a/src/openvg/qpaintengine_vg_p.h b/src/openvg/qpaintengine_vg_p.h index 75cf053..dc98137 100644 --- a/src/openvg/qpaintengine_vg_p.h +++ b/src/openvg/qpaintengine_vg_p.h @@ -170,6 +170,7 @@ private: bool isDefaultClipRegion(const QRegion& region); bool isDefaultClipRect(const QRect& rect); bool clearRect(const QRectF &rect, const QColor &color); + bool canVgWritePixels(const QImage &image) const; }; QT_END_NAMESPACE diff --git a/src/openvg/qpixmapdata_vg.cpp b/src/openvg/qpixmapdata_vg.cpp index e8ec333..724d06d 100644 --- a/src/openvg/qpixmapdata_vg.cpp +++ b/src/openvg/qpixmapdata_vg.cpp @@ -65,6 +65,7 @@ QVGPixmapData::QVGPixmapData(PixelType type) recreate = true; inImagePool = false; inLRU = false; + failedToAlloc = false; #if !defined(QT_NO_EGL) context = 0; qt_vg_register_pixmap(this); @@ -74,13 +75,13 @@ QVGPixmapData::QVGPixmapData(PixelType type) QVGPixmapData::~QVGPixmapData() { - destroyImageAndContext(); + destroyVGImageAndVGContext(); #if !defined(QT_NO_EGL) qt_vg_unregister_pixmap(this); #endif } -void QVGPixmapData::destroyImages() +void QVGPixmapData::destroyVGImages() { if (inImagePool) { QVGImagePool *pool = QVGImagePool::instance(); @@ -99,23 +100,23 @@ void QVGPixmapData::destroyImages() inImagePool = false; } -void QVGPixmapData::destroyImageAndContext() +void QVGPixmapData::destroyVGImageAndVGContext() { if (vgImage != VG_INVALID_HANDLE) { // We need to have a context current to destroy the image. #if !defined(QT_NO_EGL) if (context->isCurrent()) { - destroyImages(); + destroyVGImages(); } else { // We don't currently have a widget surface active, but we // need a surface to make the context current. So use the // shared pbuffer surface instead. context->makeCurrent(qt_vg_shared_surface()); - destroyImages(); + destroyVGImages(); context->lazyDoneCurrent(); } #else - destroyImages(); + destroyVGImages(); #endif } #if !defined(QT_NO_EGL) @@ -155,6 +156,9 @@ void QVGPixmapData::resize(int wid, int ht) void QVGPixmapData::fromImage (const QImage &image, Qt::ImageConversionFlags flags) { + if(image.isNull()) + return; + QImage img = image; createPixmapForImage(img, flags, false); } @@ -203,10 +207,19 @@ void QVGPixmapData::createPixmapForImage(QImage &image, Qt::ImageConversionFlags else resize(image.width(), image.height()); - if (inPlace && image.data_ptr()->convertInPlace(sourceFormat(), flags)) + QImage::Format format = sourceFormat(); + int d = image.depth(); + if (d == 1 || d == 16 || d == 24 || (d == 32 && !image.hasAlphaChannel())) + format = QImage::Format_RGB32; + else if (!(flags & Qt::NoOpaqueDetection) && const_cast(image).data_ptr()->checkForAlphaPixels()) + format = sourceFormat(); + else + format = QImage::Format_RGB32; + + if (inPlace && image.data_ptr()->convertInPlace(format, flags)) source = image; else - source = image.convertToFormat(sourceFormat()); + source = image.convertToFormat(format); recreate = true; } @@ -278,7 +291,7 @@ QPaintEngine* QVGPixmapData::paintEngine() const VGImage QVGPixmapData::toVGImage() { - if (!isValid()) + if (!isValid() || failedToAlloc) return VG_INVALID_HANDLE; #if !defined(QT_NO_EGL) @@ -288,17 +301,19 @@ VGImage QVGPixmapData::toVGImage() #endif if (recreate && prevSize != QSize(w, h)) - destroyImages(); + destroyVGImages(); else if (recreate) cachedOpacity = -1.0f; // Force opacity image to be refreshed later. if (vgImage == VG_INVALID_HANDLE) { vgImage = QVGImagePool::instance()->createImageForPixmap - (VG_sARGB_8888_PRE, w, h, VG_IMAGE_QUALITY_FASTER, this); + (qt_vg_image_to_vg_format(source.format()), w, h, VG_IMAGE_QUALITY_FASTER, this); // Bail out if we run out of GPU memory - try again next time. - if (vgImage == VG_INVALID_HANDLE) + if (vgImage == VG_INVALID_HANDLE) { + failedToAlloc = true; return VG_INVALID_HANDLE; + } inImagePool = true; } else if (inImagePool) { @@ -309,7 +324,7 @@ VGImage QVGPixmapData::toVGImage() vgImageSubData (vgImage, source.constBits(), source.bytesPerLine(), - VG_sARGB_8888_PRE, 0, 0, w, h); + qt_vg_image_to_vg_format(source.format()), 0, 0, w, h); } recreate = false; @@ -378,7 +393,7 @@ void QVGPixmapData::hibernate() return; forceToImage(); - destroyImageAndContext(); + destroyVGImageAndVGContext(); } void QVGPixmapData::reclaimImages() @@ -386,7 +401,7 @@ void QVGPixmapData::reclaimImages() if (!inImagePool) return; forceToImage(); - destroyImages(); + destroyVGImages(); } Q_DECL_IMPORT extern int qt_defaultDpiX(); diff --git a/src/openvg/qpixmapdata_vg_p.h b/src/openvg/qpixmapdata_vg_p.h index 114d545..b8f01eb 100644 --- a/src/openvg/qpixmapdata_vg_p.h +++ b/src/openvg/qpixmapdata_vg_p.h @@ -143,7 +143,9 @@ private: QVGPixmapData *nextLRU; QVGPixmapData *prevLRU; bool inLRU; + bool failedToAlloc; friend class QVGImagePool; + friend class QVGPaintEngine; #if !defined(QT_NO_EGL) QVGPixmapData *next; @@ -169,8 +171,8 @@ protected: void forceToImage(); QImage::Format sourceFormat() const; - void destroyImageAndContext(); - void destroyImages(); + void destroyVGImageAndVGContext(); + void destroyVGImages(); }; QT_END_NAMESPACE diff --git a/src/openvg/qvg_symbian.cpp b/src/openvg/qvg_symbian.cpp index 41b35fc..b6bf858 100644 --- a/src/openvg/qvg_symbian.cpp +++ b/src/openvg/qvg_symbian.cpp @@ -144,7 +144,7 @@ void QVGPixmapData::fromNativeType(void* pixmap, NativeType type) if (type == QPixmapData::SgImage && pixmap) { #if defined(QT_SYMBIAN_SUPPORTS_SGIMAGE) && !defined(QT_NO_EGL) RSgImage *sgImage = reinterpret_cast(pixmap); - destroyImages(); + destroyVGImages(); prevSize = QSize(); VGImage vgImage = sgImageToVGImage(context, *sgImage); @@ -164,7 +164,6 @@ void QVGPixmapData::fromNativeType(void* pixmap, NativeType type) CFbsBitmap *bitmap = reinterpret_cast(pixmap); bool deleteSourceBitmap = false; - #ifdef Q_SYMBIAN_HAS_EXTENDED_BITMAP_TYPE // Rasterize extended bitmaps -- cgit v0.12 From 55497edc83121317078d62083a835f2b794b37e4 Mon Sep 17 00:00:00 2001 From: Titta Heikkala Date: Thu, 28 Oct 2010 10:31:41 +0300 Subject: Fixed crash with QClipboard in Symbian^3 QClipboard now returns copied data outside TRAP to prevent TRAP levels to get crossed. Task-number: QTBUG-14790 Reviewed-by: Janne Koskinen Merge-request: 897 Reviewed-by: Janne Koskinen --- src/gui/kernel/qclipboard_s60.cpp | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/src/gui/kernel/qclipboard_s60.cpp b/src/gui/kernel/qclipboard_s60.cpp index c9b1d23..73280b2 100644 --- a/src/gui/kernel/qclipboard_s60.cpp +++ b/src/gui/kernel/qclipboard_s60.cpp @@ -257,18 +257,14 @@ const QMimeData* QClipboard::mimeData(Mode mode) const } } CleanupStack::PopAndDestroy(cb); - if (dataExists) { - return d->source(); - } - else { - return 0; - } - }); if (err != KErrNone){ qDebug()<< "clipboard is empty/err: " << err; } + if (dataExists) { + return d->source(); + } } return 0; } -- cgit v0.12 From 8d2fcb26e23d498e3e2efd600ad60a20fdba14c7 Mon Sep 17 00:00:00 2001 From: Alessandro Portale Date: Thu, 28 Oct 2010 19:48:22 +0200 Subject: Temporarily remove .def file entries for a little stunt --- src/s60installs/bwins/QtGuiu.def | 2 -- src/s60installs/eabi/QtGuiu.def | 2 -- 2 files changed, 4 deletions(-) diff --git a/src/s60installs/bwins/QtGuiu.def b/src/s60installs/bwins/QtGuiu.def index 7cc2752..aacc03a 100644 --- a/src/s60installs/bwins/QtGuiu.def +++ b/src/s60installs/bwins/QtGuiu.def @@ -12894,6 +12894,4 @@ EXPORTS ?effectiveBoundingRect@QGraphicsItemPrivate@@QBE?AVQRectF@@PAVQGraphicsItem@@@Z @ 12893 NONAME ; class QRectF QGraphicsItemPrivate::effectiveBoundingRect(class QGraphicsItem *) const ?maxTextureHeight@QTextureGlyphCache@@UBEHXZ @ 12894 NONAME ; int QTextureGlyphCache::maxTextureHeight(void) const ?maxTextureWidth@QTextureGlyphCache@@UBEHXZ @ 12895 NONAME ; int QTextureGlyphCache::maxTextureWidth(void) const - ?convertToPostscriptFontFamilyName@QFontEngine@@SA?AVQByteArray@@ABV2@@Z @ 12896 NONAME ; class QByteArray QFontEngine::convertToPostscriptFontFamilyName(class QByteArray const &) - ?lastResortFont@QFont@@QBE?AVQString@@XZ @ 12897 NONAME ; class QString QFont::lastResortFont(void) const diff --git a/src/s60installs/eabi/QtGuiu.def b/src/s60installs/eabi/QtGuiu.def index 4e867a3..4442d33 100644 --- a/src/s60installs/eabi/QtGuiu.def +++ b/src/s60installs/eabi/QtGuiu.def @@ -12097,6 +12097,4 @@ EXPORTS _ZN19QApplicationPrivate19qmljsDebugArgumentsE @ 12096 NONAME DATA 4 _ZN20QGraphicsItemPrivate26childrenBoundingRectHelperEP10QTransformP6QRectFP13QGraphicsItem @ 12097 NONAME _ZNK20QGraphicsItemPrivate21effectiveBoundingRectEP13QGraphicsItem @ 12098 NONAME - _ZNK5QFont14lastResortFontEv @ 12099 NONAME - _ZN11QFontEngine33convertToPostscriptFontFamilyNameERK10QByteArray @ 12100 NONAME -- cgit v0.12 From 2362d8b1e9fa86da1d3cc5dbb7d4467ec12311e1 Mon Sep 17 00:00:00 2001 From: Alessandro Portale Date: Thu, 28 Oct 2010 19:49:55 +0200 Subject: Do not crash on Symbian The qml debugging enabler in QtDeclarative made any Qt app crash which used QDeclarative. Reason was that QtDeclarative.dll tried to directly access (private) writable static data from QtGui.dll. This patch adds an accessor function for the data to QtGui, and the crash is gone. Done-by: Kai Koehne Reviewed-by: Kai Koehne Conflicts: src/declarative/debugger/qdeclarativedebugservice.cpp --- src/declarative/debugger/qdeclarativedebugservice.cpp | 12 ++++++------ src/gui/kernel/qapplication.cpp | 9 +++++++-- src/gui/kernel/qapplication_p.h | 3 ++- src/s60installs/bwins/QtGuiu.def | 4 +++- src/s60installs/eabi/QtGuiu.def | 4 +++- 5 files changed, 21 insertions(+), 11 deletions(-) diff --git a/src/declarative/debugger/qdeclarativedebugservice.cpp b/src/declarative/debugger/qdeclarativedebugservice.cpp index b98cd5d..c39da3d 100644 --- a/src/declarative/debugger/qdeclarativedebugservice.cpp +++ b/src/declarative/debugger/qdeclarativedebugservice.cpp @@ -204,13 +204,13 @@ QDeclarativeDebugServer *QDeclarativeDebugServer::instance() bool ok = false; // format: qmljsdebugger=port:3768[,block] - if (!appD->qmljsDebugArguments.isEmpty()) { + if (!appD->qmljsDebugArgumentsString().isEmpty()) { - if (appD->qmljsDebugArguments.indexOf(QLatin1String("port:")) == 0) { - int separatorIndex = appD->qmljsDebugArguments.indexOf(QLatin1Char(',')); - port = appD->qmljsDebugArguments.mid(5, separatorIndex - 5).toInt(&ok); + if (appD->qmljsDebugArgumentsString().indexOf(QLatin1String("port:")) == 0) { + int separatorIndex = appD->qmljsDebugArgumentsString().indexOf(QLatin1Char(',')); + port = appD->qmljsDebugArgumentsString().mid(5, separatorIndex - 5).toInt(&ok); } - block = appD->qmljsDebugArguments.contains(QLatin1String("block")); + block = appD->qmljsDebugArgumentsString().contains(QLatin1String("block")); if (ok) { server = new QDeclarativeDebugServer(port); @@ -221,7 +221,7 @@ QDeclarativeDebugServer *QDeclarativeDebugServer::instance() } else { qWarning(QString::fromAscii("QDeclarativeDebugServer: Ignoring \"-qmljsdebugger=%1\". " "Format is -qmljsdebugger=port:[,block]").arg( - appD->qmljsDebugArguments).toAscii().constData()); + appD->qmljsDebugArgumentsString()).toAscii().constData()); } } #endif diff --git a/src/gui/kernel/qapplication.cpp b/src/gui/kernel/qapplication.cpp index 3323fbc..6c4004e 100644 --- a/src/gui/kernel/qapplication.cpp +++ b/src/gui/kernel/qapplication.cpp @@ -497,7 +497,7 @@ bool QApplicationPrivate::fade_tooltip = false; bool QApplicationPrivate::animate_toolbox = false; bool QApplicationPrivate::widgetCount = false; bool QApplicationPrivate::load_testability = false; -QString QApplicationPrivate::qmljsDebugArguments; +QString QApplicationPrivate::qmljs_debug_arguments; #ifdef QT_KEYPAD_NAVIGATION # ifdef Q_OS_SYMBIAN Qt::NavigationMode QApplicationPrivate::navigationMode = Qt::NavigationModeKeypadDirectional; @@ -570,7 +570,7 @@ void QApplicationPrivate::process_cmdline() if (arg == "-qdevel" || arg == "-qdebug") { // obsolete argument } else if (arg.indexOf("-qmljsdebugger=", 0) != -1) { - qmljsDebugArguments = QString::fromLocal8Bit(arg.right(arg.length() - 15)); + qmljs_debug_arguments = QString::fromLocal8Bit(arg.right(arg.length() - 15)); } else if (arg.indexOf("-style=", 0) != -1) { s = QString::fromLocal8Bit(arg.right(arg.length() - 7).toLower()); } else if (arg == "-style" && i < argc-1) { @@ -6086,6 +6086,11 @@ QPixmap QApplicationPrivate::getPixmapCursor(Qt::CursorShape cshape) return QPixmap(); } +QString QApplicationPrivate::qmljsDebugArgumentsString() +{ + return qmljs_debug_arguments; +} + QT_END_NAMESPACE #include "moc_qapplication.cpp" diff --git a/src/gui/kernel/qapplication_p.h b/src/gui/kernel/qapplication_p.h index 9c5095d..a0e1452 100644 --- a/src/gui/kernel/qapplication_p.h +++ b/src/gui/kernel/qapplication_p.h @@ -446,7 +446,8 @@ public: static bool animate_toolbox; static bool widgetCount; // Coupled with -widgetcount switch static bool load_testability; // Coupled with -testability switch - static QString qmljsDebugArguments; // a string containing arguments for js/qml debugging. + static QString qmljs_debug_arguments; // a string containing arguments for js/qml debugging. + static QString qmljsDebugArgumentsString(); // access string from other libraries #ifdef Q_WS_MAC static bool native_modal_dialog_active; diff --git a/src/s60installs/bwins/QtGuiu.def b/src/s60installs/bwins/QtGuiu.def index aacc03a..afc89ae 100644 --- a/src/s60installs/bwins/QtGuiu.def +++ b/src/s60installs/bwins/QtGuiu.def @@ -12890,8 +12890,10 @@ EXPORTS ?lastRightBearing@QFontEngine@@IAE?AUQFixed@@ABUQGlyphLayout@@_N@Z @ 12889 NONAME ; struct QFixed QFontEngine::lastRightBearing(struct QGlyphLayout const &, bool) ?childrenBoundingRectHelper@QGraphicsItemPrivate@@QAEXPAVQTransform@@PAVQRectF@@PAVQGraphicsItem@@@Z @ 12890 NONAME ; void QGraphicsItemPrivate::childrenBoundingRectHelper(class QTransform *, class QRectF *, class QGraphicsItem *) ?setTimeout@QTapAndHoldGesture@@SAXH@Z @ 12891 NONAME ; void QTapAndHoldGesture::setTimeout(int) - ?qmljsDebugArguments@QApplicationPrivate@@2VQString@@A @ 12892 NONAME ; class QString QApplicationPrivate::qmljsDebugArguments + ?qmljsDebugArguments@QApplicationPrivate@@2VQString@@A @ 12892 NONAME ABSENT ; class QString QApplicationPrivate::qmljsDebugArguments ?effectiveBoundingRect@QGraphicsItemPrivate@@QBE?AVQRectF@@PAVQGraphicsItem@@@Z @ 12893 NONAME ; class QRectF QGraphicsItemPrivate::effectiveBoundingRect(class QGraphicsItem *) const ?maxTextureHeight@QTextureGlyphCache@@UBEHXZ @ 12894 NONAME ; int QTextureGlyphCache::maxTextureHeight(void) const ?maxTextureWidth@QTextureGlyphCache@@UBEHXZ @ 12895 NONAME ; int QTextureGlyphCache::maxTextureWidth(void) const + ?qmljs_debug_arguments@QApplicationPrivate@@2VQString@@A @ 12896 NONAME ; class QString QApplicationPrivate::qmljs_debug_arguments + ?qmljsDebugArgumentsString@QApplicationPrivate@@SA?AVQString@@XZ @ 12897 NONAME ; class QString QApplicationPrivate::qmljsDebugArgumentsString(void) diff --git a/src/s60installs/eabi/QtGuiu.def b/src/s60installs/eabi/QtGuiu.def index 4442d33..aa050f9 100644 --- a/src/s60installs/eabi/QtGuiu.def +++ b/src/s60installs/eabi/QtGuiu.def @@ -12094,7 +12094,9 @@ EXPORTS _ZN18QTapAndHoldGesture7timeoutEv @ 12093 NONAME _ZN20QGraphicsItemPrivate26childrenBoundingRectHelperEP10QTransformP6QRectFb @ 12094 NONAME ABSENT _ZN20QGraphicsItemPrivate14children_clearEP24QDeclarativeListPropertyI15QGraphicsObjectE @ 12095 NONAME - _ZN19QApplicationPrivate19qmljsDebugArgumentsE @ 12096 NONAME DATA 4 + _ZN19QApplicationPrivate19qmljsDebugArgumentsE @ 12096 NONAME DATA 4 ABSENT _ZN20QGraphicsItemPrivate26childrenBoundingRectHelperEP10QTransformP6QRectFP13QGraphicsItem @ 12097 NONAME _ZNK20QGraphicsItemPrivate21effectiveBoundingRectEP13QGraphicsItem @ 12098 NONAME + _ZN19QApplicationPrivate21qmljs_debug_argumentsE @ 12099 NONAME DATA 4 + _ZN19QApplicationPrivate25qmljsDebugArgumentsStringEv @ 12100 NONAME -- cgit v0.12 From 44f6ed77eb3b80b28ebc967b64a1640347a83060 Mon Sep 17 00:00:00 2001 From: Alessandro Portale Date: Thu, 28 Oct 2010 19:52:00 +0200 Subject: Readded .def file entries after a little stunt --- src/s60installs/bwins/QtGuiu.def | 2 ++ src/s60installs/eabi/QtGuiu.def | 2 ++ 2 files changed, 4 insertions(+) diff --git a/src/s60installs/bwins/QtGuiu.def b/src/s60installs/bwins/QtGuiu.def index afc89ae..c91b22c 100644 --- a/src/s60installs/bwins/QtGuiu.def +++ b/src/s60installs/bwins/QtGuiu.def @@ -12896,4 +12896,6 @@ EXPORTS ?maxTextureWidth@QTextureGlyphCache@@UBEHXZ @ 12895 NONAME ; int QTextureGlyphCache::maxTextureWidth(void) const ?qmljs_debug_arguments@QApplicationPrivate@@2VQString@@A @ 12896 NONAME ; class QString QApplicationPrivate::qmljs_debug_arguments ?qmljsDebugArgumentsString@QApplicationPrivate@@SA?AVQString@@XZ @ 12897 NONAME ; class QString QApplicationPrivate::qmljsDebugArgumentsString(void) + ?convertToPostscriptFontFamilyName@QFontEngine@@SA?AVQByteArray@@ABV2@@Z @ 12898 NONAME ; class QByteArray QFontEngine::convertToPostscriptFontFamilyName(class QByteArray const &) + ?lastResortFont@QFont@@QBE?AVQString@@XZ @ 12899 NONAME ; class QString QFont::lastResortFont(void) const diff --git a/src/s60installs/eabi/QtGuiu.def b/src/s60installs/eabi/QtGuiu.def index aa050f9..f772bcc 100644 --- a/src/s60installs/eabi/QtGuiu.def +++ b/src/s60installs/eabi/QtGuiu.def @@ -12099,4 +12099,6 @@ EXPORTS _ZNK20QGraphicsItemPrivate21effectiveBoundingRectEP13QGraphicsItem @ 12098 NONAME _ZN19QApplicationPrivate21qmljs_debug_argumentsE @ 12099 NONAME DATA 4 _ZN19QApplicationPrivate25qmljsDebugArgumentsStringEv @ 12100 NONAME + _ZNK5QFont14lastResortFontEv @ 12101 NONAME + _ZN11QFontEngine33convertToPostscriptFontFamilyNameERK10QByteArray @ 12102 NONAME -- cgit v0.12 From eea4ef7bcbababd1af07c75e6711f34aaa4b69e5 Mon Sep 17 00:00:00 2001 From: Alessandro Portale Date: Thu, 28 Oct 2010 22:10:13 +0200 Subject: Making the buttons less finger unfriendly I did not dare to apply the same fix to the samegame tutorials, since those are completely diverged from the demo. --- demos/declarative/samegame/SamegameCore/Button.qml | 4 ++-- demos/declarative/samegame/samegame.qml | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/demos/declarative/samegame/SamegameCore/Button.qml b/demos/declarative/samegame/SamegameCore/Button.qml index 7fb7b65..140b196 100644 --- a/demos/declarative/samegame/SamegameCore/Button.qml +++ b/demos/declarative/samegame/SamegameCore/Button.qml @@ -48,7 +48,7 @@ Rectangle { signal clicked - width: buttonLabel.width + 20; height: buttonLabel.height + 6 + width: buttonLabel.width + 20; height: buttonLabel.height + 20 smooth: true border { width: 1; color: Qt.darker(activePalette.button) } radius: 8 @@ -70,6 +70,6 @@ Rectangle { MouseArea { id: mouseArea; anchors.fill: parent; onClicked: container.clicked() } Text { - id: buttonLabel; text: container.text; anchors.centerIn: container; color: activePalette.buttonText + id: buttonLabel; text: container.text; anchors.centerIn: container; color: activePalette.buttonText; font.pixelSize: 24 } } diff --git a/demos/declarative/samegame/samegame.qml b/demos/declarative/samegame/samegame.qml index f66c40e..b66c5a6 100644 --- a/demos/declarative/samegame/samegame.qml +++ b/demos/declarative/samegame/samegame.qml @@ -133,7 +133,7 @@ Rectangle { Rectangle { id: toolBar - width: parent.width; height: 32 + width: parent.width; height: 58 color: activePalette.window anchors.bottom: screen.bottom @@ -156,6 +156,7 @@ Rectangle { anchors { right: parent.right; rightMargin: 3; verticalCenter: parent.verticalCenter } text: "Score: " + gameCanvas.score font.bold: true + font.pixelSize: 24 color: activePalette.windowText } } -- cgit v0.12