Fix a bunch of compiler warnings in the qtbase examples

Change-Id: Id0c615aa72d4f4c5941cfa5ca258c3114694ef67
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
This commit is contained in:
Jake Petroules 2018-02-01 10:23:53 -08:00
parent 5f058a73c8
commit 3343295d80
5 changed files with 5 additions and 3 deletions

View File

@ -81,6 +81,7 @@ glUnmapBuffer
#ifndef Q_OS_MAC
# ifndef APIENTRYP
# ifdef APIENTRY
# undef APIENTRYP
# define APIENTRYP APIENTRY *
# else
# define APIENTRY

View File

@ -174,7 +174,7 @@ void GraphWidget::timerEvent(QTimerEvent *event)
bool itemsMoved = false;
foreach (Node *node, nodes) {
if (node->advance())
if (node->advanceNext())
itemsMoved = true;
}

View File

@ -138,7 +138,7 @@ void Node::calculateForces()
//! [6]
//! [7]
bool Node::advance()
bool Node::advanceNext()
{
if (newPos == pos())
return false;

View File

@ -73,7 +73,7 @@ public:
int type() const override { return Type; }
void calculateForces();
bool advance();
bool advanceNext();
QRectF boundingRect() const override;
QPainterPath shape() const override;

View File

@ -97,6 +97,7 @@ MainWindow::MainWindow(const CustomSizeHintMap &customSizeHints,
QWidget *parent, Qt::WindowFlags flags)
: QMainWindow(parent, flags)
{
Q_UNUSED(message);
setObjectName("MainWindow");
setWindowTitle("Qt Main Window Example");