projects
/
scorecard
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
d9ba8ec
)
Fix compiler warnings
author
Sakari Poussa
<spoussa@gmail.com>
Thu, 11 Mar 2010 13:35:14 +0000
(15:35 +0200)
committer
Sakari Poussa
<spoussa@gmail.com>
Thu, 11 Mar 2010 13:35:14 +0000
(15:35 +0200)
src/course-dialog.cpp
patch
|
blob
|
history
src/data.cpp
patch
|
blob
|
history
src/score-dialog.cpp
patch
|
blob
|
history
src/stat-model.cpp
patch
|
blob
|
history
src/table-model.cpp
patch
|
blob
|
history
src/table-model.h
patch
|
blob
|
history
diff --git
a/src/course-dialog.cpp
b/src/course-dialog.cpp
index
fff235e
..
9f2f3f7
100644
(file)
--- a/
src/course-dialog.cpp
+++ b/
src/course-dialog.cpp
@@
-111,6
+111,7
@@
void CourseDialog::createLayout(QWidget *parent)
void CourseDialog::createButton(QWidget *parent)
{
void CourseDialog::createButton(QWidget *parent)
{
+ Q_UNUSED(parent);
pushButtonUp = new QPushButton(tr("+"));
connect(pushButtonUp, SIGNAL(clicked()), this, SLOT(up()));
pushButtonUp = new QPushButton(tr("+"));
connect(pushButtonUp, SIGNAL(clicked()), this, SLOT(up()));
diff --git
a/src/data.cpp
b/src/data.cpp
index
270e04b
..
19be40a
100644
(file)
--- a/
src/data.cpp
+++ b/
src/data.cpp
@@
-252,6
+252,7
@@
int Course::update(QVector<QString> &par,
QVector<QString> &hcp,
QVector<QString> &len)
{
QVector<QString> &hcp,
QVector<QString> &len)
{
+ Q_UNUSED(len);
for (int i = 0; i < par.size(); i++) {
Hole *hole = holeList.at(i);
if (hole->getPar() != par[i])
for (int i = 0; i < par.size(); i++) {
Hole *hole = holeList.at(i);
if (hole->getPar() != par[i])
diff --git
a/src/score-dialog.cpp
b/src/score-dialog.cpp
index
e02294c
..
958e7ce
100644
(file)
--- a/
src/score-dialog.cpp
+++ b/
src/score-dialog.cpp
@@
-177,6
+177,7
@@
void ScoreDialog::createTable(QWidget *parent)
void ScoreDialog::createButton(QWidget *parent)
{
void ScoreDialog::createButton(QWidget *parent)
{
+ Q_UNUSED(parent);
pushButtonUp = new QPushButton(tr("+"));
connect(pushButtonUp, SIGNAL(clicked()), this, SLOT(up()));
pushButtonUp = new QPushButton(tr("+"));
connect(pushButtonUp, SIGNAL(clicked()), this, SLOT(up()));
diff --git
a/src/stat-model.cpp
b/src/stat-model.cpp
index
f9b7f41
..
605fc8d
100644
(file)
--- a/
src/stat-model.cpp
+++ b/
src/stat-model.cpp
@@
-17,11
+17,13
@@
StatModel::StatModel(QList<Club *> &cList, QList<Score *> &sList) : clubList(cLi
int StatModel::rowCount(const QModelIndex & parent) const
{
int StatModel::rowCount(const QModelIndex & parent) const
{
+ Q_UNUSED(parent);
return ROWS;
}
int StatModel::columnCount(const QModelIndex & parent) const
{
return ROWS;
}
int StatModel::columnCount(const QModelIndex & parent) const
{
+ Q_UNUSED(parent);
return COLS;
}
return COLS;
}
diff --git
a/src/table-model.cpp
b/src/table-model.cpp
index
3bcf1b3
..
a77be1f
100644
(file)
--- a/
src/table-model.cpp
+++ b/
src/table-model.cpp
@@
-185,8
+185,6
@@
QModelIndex ScoreTableModel::index(int row, int column, const QModelIndex &paren
QVariant ScoreTableModel::data(const QModelIndex &index, int role) const
{
QVariant ScoreTableModel::data(const QModelIndex &index, int role) const
{
- // TODO: move away from the stack
-
if (!index.isValid())
return QVariant();
if (!index.isValid())
return QVariant();
@@
-211,6
+209,7
@@
QVariant ScoreTableModel::data(const QModelIndex &index, int role) const
// the empty cell.
if ((row == ROW_HOLE && col != 10) || row == ROW_HOLE_2) {
QBrush brush(ScoreColor::holeBg());
// the empty cell.
if ((row == ROW_HOLE && col != 10) || row == ROW_HOLE_2) {
QBrush brush(ScoreColor::holeBg());
+ //QBrush brush(Qt::red);
return brush;
}
if (score && course && (row == ROW_SCORE || row == ROW_SCORE_2)) {
return brush;
}
if (score && course && (row == ROW_SCORE || row == ROW_SCORE_2)) {
diff --git
a/src/table-model.h
b/src/table-model.h
index
9c07f25
..
62bfdd2
100644
(file)
--- a/
src/table-model.h
+++ b/
src/table-model.h
@@
-14,7
+14,6
@@
#define ROW_COUNT 3
#define COL_COUNT 9
#define ROW_COUNT 3
#define COL_COUNT 9
-// TODO: change name to ScoreTableModel
class ScoreTableModel : public QAbstractTableModel
{
class ScoreTableModel : public QAbstractTableModel
{