Fix warnings in manual tests.
- Constructor order. - Unused variables. - size_t -> int conversions. Change-Id: Ic5b016f41d01a4d8153ae0900b607bf946523c1d Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
This commit is contained in:
parent
76f536d661
commit
cdc221ae00
@ -148,7 +148,7 @@ void MiniHttpServerConnection::handlePendingRequest()
|
||||
return;
|
||||
}
|
||||
|
||||
QUrl uri = QUrl::fromEncoded(request.mid(4, eol - strlen(http11) - 4));
|
||||
QUrl uri = QUrl::fromEncoded(request.mid(4, eol - int(strlen(http11)) - 4));
|
||||
source.setFileName(":" + uri.path());
|
||||
|
||||
// connection-close?
|
||||
|
@ -537,7 +537,7 @@ void tst_NetworkStressTest::blockingMultipleRequests()
|
||||
qWarning() << "no content-length:" << QString(buffer);
|
||||
break;
|
||||
}
|
||||
pos += strlen("\r\ncontent-length: ");
|
||||
pos += int(strlen("\r\ncontent-length: "));
|
||||
|
||||
int eol = buffer.indexOf("\r\n", pos + 2);
|
||||
if (eol == -1) {
|
||||
|
@ -80,7 +80,7 @@ CustomGroup::CustomGroup() :
|
||||
setFlag(QGraphicsItem::ItemIsSelectable);
|
||||
}
|
||||
|
||||
void CustomGroup::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget)
|
||||
void CustomGroup::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *)
|
||||
{
|
||||
if (option->state & QStyle::State_Selected)
|
||||
painter->setOpacity(1.);
|
||||
|
@ -46,8 +46,8 @@
|
||||
#include <QtWidgets>
|
||||
|
||||
struct Statistics {
|
||||
Statistics() : output(0),
|
||||
setGeometryCount(0), currentBenchmarkIteration(0), relayoutClicked(false), sleepMsecs(0)
|
||||
Statistics() : setGeometryCount(0), sleepMsecs(0), output(0),
|
||||
currentBenchmarkIteration(0), relayoutClicked(false)
|
||||
{
|
||||
}
|
||||
QMap<QGraphicsWidget*, int> setGeometryTracker;
|
||||
|
@ -83,7 +83,7 @@ void DownloadManager::upload(const QUrl &url, const QString &user, const QString
|
||||
connect(ul, SIGNAL(downloadFinished(TransferItem*)), SLOT(downloadFinished(TransferItem*)));
|
||||
}
|
||||
|
||||
void DownloadManager::finished(QNetworkReply *reply)
|
||||
void DownloadManager::finished(QNetworkReply *)
|
||||
{
|
||||
}
|
||||
|
||||
@ -121,7 +121,7 @@ void DownloadManager::authenticationRequired(QNetworkReply *reply, QAuthenticato
|
||||
qDebug() << "authenticationRequired" << reply;
|
||||
TransferItem *transfer = findTransfer(reply);
|
||||
//provide the credentials exactly once, so that it fails if credentials are incorrect.
|
||||
if (transfer && !transfer->user.isEmpty() || !transfer->password.isEmpty()) {
|
||||
if ((transfer && !transfer->user.isEmpty()) || !transfer->password.isEmpty()) {
|
||||
auth->setUser(transfer->user);
|
||||
auth->setPassword(transfer->password);
|
||||
transfer->user.clear();
|
||||
@ -129,7 +129,7 @@ void DownloadManager::authenticationRequired(QNetworkReply *reply, QAuthenticato
|
||||
}
|
||||
}
|
||||
|
||||
void DownloadManager::proxyAuthenticationRequired(const QNetworkProxy &proxy, QAuthenticator *auth)
|
||||
void DownloadManager::proxyAuthenticationRequired(const QNetworkProxy &, QAuthenticator *auth)
|
||||
{
|
||||
//provide the credentials exactly once, so that it fails if credentials are incorrect.
|
||||
if (!proxyUser.isEmpty() || !proxyPassword.isEmpty()) {
|
||||
|
@ -94,7 +94,7 @@ bool TabletWidget::eventFilter(QObject *, QEvent *ev)
|
||||
return false;
|
||||
}
|
||||
|
||||
void TabletWidget::paintEvent(QPaintEvent *event)
|
||||
void TabletWidget::paintEvent(QPaintEvent *)
|
||||
{
|
||||
QPainter painter(this);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user