Commit fc0d3a4c authored by David Partyka's avatar David Partyka

Fix lots of unused variable warnings.

parent 471545fe
......@@ -39,5 +39,13 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#define QT_TESTING_EVENT_PLAYBACK_DELAY @QT_TESTING_EVENT_PLAYBACK_DELAY@
//
// This macro is used to quiet compiler warnings about unused parameters
// to methods. Only use it when the parameter really shouldn't be used.
// Don't use it as a way to shut up the compiler while you take your
// sweet time getting around to implementing the method.
//
#define pqNotUsed(x)
#endif // _QtTestingConfigure_h
......@@ -47,7 +47,7 @@ pq3DViewEventPlayer::pq3DViewEventPlayer(const QByteArray& classname, QObject *
bool pq3DViewEventPlayer::playEvent(QObject* Object,
const QString& Command,
const QString& Arguments,
bool& Error)
bool& pqNotUsed(Error))
{
QWidget* widget = qobject_cast<QWidget*>(Object);
if(widget && Object->inherits(mClassType.data()))
......
......@@ -63,26 +63,26 @@ namespace
QString filename;
QStringList filenames;
QString dir_hook(QWidget* parent, const QString& caption, const QString& dir,
QFileDialog::Options options)
QString dir_hook(QWidget* pqNotUsed(parent), const QString& pqNotUsed(caption), const QString& pqNotUsed(dir),
QFileDialog::Options pqNotUsed(options))
{
// wait for next event played to give us a filename
loop->exec();
return filename;
}
QString filename_hook(QWidget* parent, const QString& caption, const QString& dir,
const QString& filter, QString *selectedFilter,
QFileDialog::Options options)
QString filename_hook(QWidget* pqNotUsed(parent), const QString& pqNotUsed(caption), const QString& pqNotUsed(dir),
const QString& pqNotUsed(filter), QString * pqNotUsed(selectedFilter),
QFileDialog::Options pqNotUsed(options))
{
// wait for next event played to give us a filename
loop->exec();
return filename;
}
QStringList filenames_hook(QWidget* parent, const QString& caption, const QString& dir,
const QString& filter, QString *selectedFilter,
QFileDialog::Options options)
QStringList filenames_hook(QWidget* pqNotUsed(parent), const QString& pqNotUsed(caption), const QString& pqNotUsed(dir),
const QString& pqNotUsed(filter), QString *pqNotUsed(selectedFilter),
QFileDialog::Options pqNotUsed(options))
{
// wait for next event played to give us a filename
loop->exec();
......@@ -144,7 +144,7 @@ void pqNativeFileDialogEventPlayer::stop()
qt_filedialog_save_filename_hook = old_save_filename_hook;
}
bool pqNativeFileDialogEventPlayer::playEvent(QObject* Object, const QString& Command, const QString& Arguments, bool& Error)
bool pqNativeFileDialogEventPlayer::playEvent(QObject* Object, const QString& Command, const QString& Arguments, bool& pqNotUsed(Error))
{
if(!qobject_cast<QApplication*>(Object))
......
......@@ -153,8 +153,8 @@ void pqNativeFileDialogEventTranslator::stop()
qt_filedialog_save_filename_hook = old_save_filename_hook;
}
bool pqNativeFileDialogEventTranslator::translateEvent(QObject* Object, QEvent* Event,
bool& /*Error*/)
bool pqNativeFileDialogEventTranslator::translateEvent(QObject* Object, QEvent* pqNotUsed(Event),
bool& pqNotUsed(Error))
{
// capture events under a filedialog and consume them
QObject* tmp = Object;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment