1
0
mirror of https://bitbucket.org/librepilot/librepilot.git synced 2024-11-30 08:24:11 +01:00

Ground: Suppressing some more random unused variable warnings

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1708 ebee16cc-31ac-478f-84a7-5cbb03baadba
This commit is contained in:
peabody124 2010-09-21 19:29:43 +00:00 committed by peabody124
parent a1a3b0774f
commit af6b6d91a3
9 changed files with 37 additions and 12 deletions

View File

@ -44,7 +44,7 @@ namespace core {
Size operator+(const Size &sz1){return Size(sz1.width+width,sz1.height+height);}
int GetHashCode(){return width^height;}
uint qHash(Size const& rect){return width^height;}
uint qHash(Size const& /*rect*/){return width^height;}
QString ToString(){return "With="+QString::number(width)+" ,Height="+QString::number(height);}
int Width()const {return width;}
int Height()const {return height;}

View File

@ -616,6 +616,8 @@ double LKS94Projection::GetTileMatrixResolution(int const& zoom)
}
double LKS94Projection::GetGroundResolution(int const& zoom, double const& latitude)
{
Q_UNUSED(zoom);
Q_UNUSED(latitude);
return GetTileMatrixResolution(zoom);
}
Size LKS94Projection::GetTileMatrixMinXY(int const& zoom)

View File

@ -86,11 +86,13 @@ double MercatorProjection::Flattening() const
}
Size MercatorProjection::GetTileMatrixMaxXY(const int &zoom)
{
Q_UNUSED(zoom);
int xy = (1 << zoom);
return Size(xy - 1, xy - 1);
}
Size MercatorProjection::GetTileMatrixMinXY(const int &zoom)
{
Q_UNUSED(zoom);
return Size(0, 0);
}
}

View File

@ -40,16 +40,18 @@ namespace mapcontrol
void HomeItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget)
{
painter->drawPixmap(-pic.width()/2,-pic.height()/2,pic);
if(showsafearea)
{
if(safe)
painter->setPen(Qt::green);
else
painter->setPen(Qt::red);
painter->drawEllipse(QPointF(0,0),localsafearea,localsafearea);
// painter->drawRect(QRectF(-localsafearea,-localsafearea,localsafearea*2,localsafearea*2));
}
Q_UNUSED(option);
Q_UNUSED(widget);
painter->drawPixmap(-pic.width()/2,-pic.height()/2,pic);
if(showsafearea)
{
if(safe)
painter->setPen(Qt::green);
else
painter->setPen(Qt::red);
painter->drawEllipse(QPointF(0,0),localsafearea,localsafearea);
// painter->drawRect(QRectF(-localsafearea,-localsafearea,localsafearea*2,localsafearea*2));
}
}
QRectF HomeItem::boundingRect()const

View File

@ -51,7 +51,7 @@ namespace mapcontrol
void MapGraphicItem::resize(const QRectF &rect)
{
Q_UNUSED(rect);
{
this->prepareGeometryChange();
maprect=boundingBox(scene()->sceneRect(),rotation);
@ -143,6 +143,8 @@ namespace mapcontrol
}
void MapGraphicItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget)
{
Q_UNUSED(option);
Q_UNUSED(widget);
if(MapRenderTransform!=1)
{

View File

@ -66,6 +66,8 @@ namespace mapcontrol
}
void WayPointItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget)
{
Q_UNUSED(option);
Q_UNUSED(widget);
painter->drawPixmap(-picture.width()/2,-picture.height(),picture);
if(this->isSelected())
painter->drawRect(QRectF(-picture.width()/2,-picture.height(),picture.width()-1,picture.height()-1));

View File

@ -616,31 +616,41 @@ void OPMapGadgetWidget::OnMapZoomChanged()
void OPMapGadgetWidget::OnMapTypeChanged(MapType::Types type)
{
Q_UNUSED(type);
// to do
}
void OPMapGadgetWidget::OnEmptyTileError(int zoom, core::Point pos)
{
Q_UNUSED(zoom);
Q_UNUSED(pos);
// to do
}
void OPMapGadgetWidget::WPNumberChanged(int const &oldnumber, int const &newnumber, WayPointItem *waypoint)
{
Q_UNUSED(oldnumber);
Q_UNUSED(newnumber);
Q_UNUSED(waypoint);
// to do
}
void OPMapGadgetWidget::WPValuesChanged(WayPointItem *waypoint)
{
Q_UNUSED(waypoint);
// to do
}
void OPMapGadgetWidget::WPInserted(int const &number, WayPointItem *waypoint)
{
Q_UNUSED(number);
Q_UNUSED(waypoint);
// to do
}
void OPMapGadgetWidget::WPDeleted(int const &number)
{
Q_UNUSED(number);
// to do
}

View File

@ -60,6 +60,7 @@ PlotData::PlotData(QString p_uavObject, QString p_uavField)
double PlotData::valueAsDouble(UAVObject* obj, UAVObjectField* field)
{
Q_UNUSED(obj);
QVariant value;
if(haveSubField){
@ -166,5 +167,6 @@ void ChronoPlotData::removeStaleDataTimeout()
bool UAVObjectPlotData::append(UAVObject* obj)
{
Q_UNUSED(obj);
return false;
}

View File

@ -45,6 +45,8 @@ ScopeGadgetOptionsPage::ScopeGadgetOptionsPage(ScopeGadgetConfiguration *config,
//creates options page widget (uses the UI file)
QWidget* ScopeGadgetOptionsPage::createPage(QWidget *parent)
{
Q_UNUSED(parent);
options_page = new Ui::ScopeGadgetOptionsPage();
//main widget
QWidget *optionsPageWidget = new QWidget;
@ -304,5 +306,6 @@ void ScopeGadgetOptionsPage::finish()
*/
void ScopeGadgetOptionsPage::on_lstCurves_currentRowChanged(int currentRow)
{
Q_UNUSED(currentRow);
setYAxisWidgetFromPlotCurve();
}