summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorThierry Bastian <thierry.bastian@nokia.com>2009-09-03 14:16:57 (GMT)
committerThierry Bastian <thierry.bastian@nokia.com>2009-09-03 14:17:34 (GMT)
commitd05aa6a493b532b90466cc106c0f8bb05d8ca41f (patch)
tree707242b26c1dea7e8f0326f4f35faff6301f1f75 /examples
parent99929a28df4812c86b4aabc4d02490d9fac87e85 (diff)
downloadQt-d05aa6a493b532b90466cc106c0f8bb05d8ca41f.zip
Qt-d05aa6a493b532b90466cc106c0f8bb05d8ca41f.tar.gz
Qt-d05aa6a493b532b90466cc106c0f8bb05d8ca41f.tar.bz2
Fix more warnings for mingw
Diffstat (limited to 'examples')
-rw-r--r--examples/itemviews/addressbook/addresswidget.cpp2
-rw-r--r--examples/multitouch/pinchzoom/mouse.h5
-rw-r--r--examples/script/context2d/context2d.cpp4
3 files changed, 5 insertions, 6 deletions
diff --git a/examples/itemviews/addressbook/addresswidget.cpp b/examples/itemviews/addressbook/addresswidget.cpp
index 6d05c22..c8dcb57 100644
--- a/examples/itemviews/addressbook/addresswidget.cpp
+++ b/examples/itemviews/addressbook/addresswidget.cpp
@@ -104,7 +104,7 @@ void AddressWidget::editEntry()
QModelIndex index, i;
QString name;
QString address;
- int row;
+ int row = -1;
foreach (index, indexes) {
row = proxy->mapToSource(index).row();
diff --git a/examples/multitouch/pinchzoom/mouse.h b/examples/multitouch/pinchzoom/mouse.h
index bd47245..e4ecb75 100644
--- a/examples/multitouch/pinchzoom/mouse.h
+++ b/examples/multitouch/pinchzoom/mouse.h
@@ -42,11 +42,10 @@
#ifndef MOUSE_H
#define MOUSE_H
-#include <QGraphicsItem>
-#include <QObject>
+#include <QGraphicsObject>
//! [0]
-class Mouse : public QObject, public QGraphicsItem
+class Mouse : public QGraphicsObject
{
Q_OBJECT
diff --git a/examples/script/context2d/context2d.cpp b/examples/script/context2d/context2d.cpp
index 5b4a1cf..05352cd 100644
--- a/examples/script/context2d/context2d.cpp
+++ b/examples/script/context2d/context2d.cpp
@@ -369,7 +369,7 @@ void Context2D::setLineCap(const QString &capString)
style = Qt::RoundCap;
else if (capString == "square")
style = Qt::SquareCap;
- else if (capString == "butt")
+ else //if (capString == "butt")
style = Qt::FlatCap;
m_state.lineCap = style;
m_state.flags |= DirtyLineCap;
@@ -397,7 +397,7 @@ void Context2D::setLineJoin(const QString &joinString)
style = Qt::RoundJoin;
else if (joinString == "bevel")
style = Qt::BevelJoin;
- else if (joinString == "miter")
+ else //if (joinString == "miter")
style = Qt::MiterJoin;
m_state.lineJoin = style;
m_state.flags |= DirtyLineJoin;