From d469d5e12635a6bad54fe8bc9404c1fdf209635c Mon Sep 17 00:00:00 2001 From: Michael Brasser Date: Fri, 7 Aug 2009 09:25:03 +1000 Subject: Fix warnings. --- src/declarative/fx/qfxlayoutitem.cpp | 3 ++- src/declarative/fx/qfxscalegrid.cpp | 4 ++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/src/declarative/fx/qfxlayoutitem.cpp b/src/declarative/fx/qfxlayoutitem.cpp index 446a8d7..1f814e8 100644 --- a/src/declarative/fx/qfxlayoutitem.cpp +++ b/src/declarative/fx/qfxlayoutitem.cpp @@ -78,7 +78,7 @@ QML_DEFINE_TYPE(Qt,4,6,(QT_VERSION&0x00ff00)>>8,LayoutItem,QFxLayoutItem) */ QFxLayoutItem::QFxLayoutItem(QFxItem* parent) - : QFxItem(parent), m_maximumSize(INT_MAX,INT_MAX), m_preferredSize(100,100), m_minimumSize(0,0) + : QFxItem(parent), m_maximumSize(INT_MAX,INT_MAX), m_minimumSize(0,0), m_preferredSize(100,100) { setGraphicsItem(this); } @@ -93,6 +93,7 @@ void QFxLayoutItem::setGeometry(const QRectF & rect) QSizeF QFxLayoutItem::sizeHint(Qt::SizeHint w, const QSizeF &constraint) const { + Q_UNUSED(constraint); if(w == Qt::MinimumSize){ return m_minimumSize; }else if(w == Qt::MaximumSize){ diff --git a/src/declarative/fx/qfxscalegrid.cpp b/src/declarative/fx/qfxscalegrid.cpp index 198ac6d..da3b4a3 100644 --- a/src/declarative/fx/qfxscalegrid.cpp +++ b/src/declarative/fx/qfxscalegrid.cpp @@ -41,6 +41,7 @@ #include #include +#include #include "qfxscalegrid_p.h" @@ -210,6 +211,9 @@ QFxScaleGrid::TileRule QFxGridScaledImage::stringToRule(const QString &s) const return QFxScaleGrid::Repeat; if (s == QLatin1String("Round")) return QFxScaleGrid::Round; + + qWarning() << "Unknown tile rule specified. Using Stretch"; + return QFxScaleGrid::Stretch; } bool QFxGridScaledImage::isValid() const -- cgit v0.12