Commit 3ee719e0 authored by Dirk Wilden's avatar Dirk Wilden

removed warnings

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@10628 383ad7c9-94d9-4d36-a494-682f7c89f535
parent eb85b89d
......@@ -83,7 +83,7 @@ class Type {
virtual bool hasWidget () { return false; };
/// Returns the configuration widget
virtual TypeWidget *widget (QMap<QString, QString> _hints, QString _typeName, QWidget *_parent = NULL) { return 0; };
virtual TypeWidget *widget (QMap<QString, QString> /*_hints*/, QString /*_typeName*/, QWidget */*_parent*/ = NULL) { return 0; };
protected:
QStringList types_;
......
......@@ -53,7 +53,7 @@ namespace VSI {
//=============================================================================
/// Constructor
TypeWidget::TypeWidget(QMap< QString, QString > &_hints, QString _typeName, QWidget* _parent) :
TypeWidget::TypeWidget(QMap< QString, QString > &/*_hints*/, QString /*_typeName*/, QWidget* _parent) :
QWidget (_parent)
{
}
......
......@@ -107,7 +107,7 @@ Arrow::~Arrow ()
//------------------------------------------------------------------------------
// make the widget opaque if the mouse is over it
void Arrow::hoverEnterEvent (QGraphicsSceneHoverEvent *_event)
void Arrow::hoverEnterEvent (QGraphicsSceneHoverEvent */*_event*/)
{
setOpacity (1.0);
}
......@@ -115,7 +115,7 @@ void Arrow::hoverEnterEvent (QGraphicsSceneHoverEvent *_event)
//------------------------------------------------------------------------------
// make the widget transparent if the mouse leaves it
void Arrow::hoverLeaveEvent (QGraphicsSceneHoverEvent *_event)
void Arrow::hoverLeaveEvent (QGraphicsSceneHoverEvent */*_event*/)
{
setOpacity ((highlight_)? 0.5 : 0.2);
}
......@@ -266,7 +266,7 @@ void Arrow::setGeometry (const QRectF &_rect)
//------------------------------------------------------------------------------
// return size information for layouting
QSizeF Arrow::sizeHint (Qt::SizeHint _which, const QSizeF &_constraint) const
QSizeF Arrow::sizeHint (Qt::SizeHint _which, const QSizeF &/*_constraint*/) const
{
QSizeF sh;
switch (_which) {
......
......@@ -61,6 +61,7 @@ class GraphicsScene;
class Arrow : public QObject, public QGraphicsPixmapItem, public QGraphicsLayoutItem
{
Q_OBJECT
Q_INTERFACES(QGraphicsLayoutItem)
public:
......
......@@ -94,7 +94,7 @@ Button::~Button ()
//------------------------------------------------------------------------------
// glow on mouse enter
void Button::hoverEnterEvent (QGraphicsSceneHoverEvent *_event)
void Button::hoverEnterEvent (QGraphicsSceneHoverEvent */*_event*/)
{
glow_ = true;
update ();
......@@ -108,7 +108,7 @@ void Button::hoverEnterEvent (QGraphicsSceneHoverEvent *_event)
//------------------------------------------------------------------------------
// stop glowing on mouse leave
void Button::hoverLeaveEvent (QGraphicsSceneHoverEvent *_event)
void Button::hoverLeaveEvent (QGraphicsSceneHoverEvent */*_event*/)
{
glow_ = false;
update ();
......
......@@ -108,7 +108,7 @@ void ConnectionPoint::setGeometry (const QRectF &_rect)
//------------------------------------------------------------------------------
// size informations for layouting
QSizeF ConnectionPoint::sizeHint (Qt::SizeHint _which, const QSizeF &_constraint) const
QSizeF ConnectionPoint::sizeHint (Qt::SizeHint _which, const QSizeF &/*_constraint*/) const
{
QSizeF sh;
switch (_which) {
......@@ -186,7 +186,7 @@ void ConnectionPoint::setState(State _state)
//------------------------------------------------------------------------------
// highlight connection if mouse over
void ConnectionPoint::hoverEnterEvent (QGraphicsSceneHoverEvent *_event)
void ConnectionPoint::hoverEnterEvent (QGraphicsSceneHoverEvent */*_event*/)
{
foreach (Connection *c, inout_->connections ())
{
......@@ -205,7 +205,7 @@ void ConnectionPoint::hoverEnterEvent (QGraphicsSceneHoverEvent *_event)
//------------------------------------------------------------------------------
// remove highlight
void ConnectionPoint::hoverLeaveEvent (QGraphicsSceneHoverEvent *_event)
void ConnectionPoint::hoverLeaveEvent (QGraphicsSceneHoverEvent */*_event*/)
{
foreach (Connection *c, inout_->connections ())
{
......@@ -239,7 +239,6 @@ void ConnectionPoint::paint(QPainter *_painter, const QStyleOptionGraphicsItem *
float wH = width_ / 2.0;
float wT = width_ / 3.0;
float wF = width_ / 4.0;
float wS = width_ / 6.0;
QPainterPath path;
......
......@@ -66,6 +66,7 @@ class ElementInOut;
class ConnectionPoint : public QObject, public QGraphicsEllipseItem, public QGraphicsLayoutItem
{
Q_OBJECT
Q_INTERFACES(QGraphicsLayoutItem)
public:
......
......@@ -61,6 +61,7 @@ class SceneElement;
class ElementArea : public QObject, public QGraphicsItem
{
Q_OBJECT
Q_INTERFACES(QGraphicsItem)
public:
......@@ -83,7 +84,7 @@ class ElementArea : public QObject, public QGraphicsItem
const QList<SceneElement *>& elements () const;
/// for QGraphicsItem
void paint (QPainter *_painter, const QStyleOptionGraphicsItem *_option, QWidget *_widget = 0) {};
void paint (QPainter */*_painter*/, const QStyleOptionGraphicsItem */*_option*/, QWidget */*_widget*/ = 0) {};
private:
GraphicsScene *scene_;
......
......@@ -149,8 +149,6 @@ void FunctionDisplay::paint (QPainter *_painter, const QStyleOptionGraphicsItem
int w = geometry().width();
int h = geometry().height();
int div = 2;
_painter->setRenderHint(QPainter::Antialiasing, true);
_painter->setBrush(QBrush(QColor(BACKGROUND_RED,
......@@ -172,8 +170,6 @@ void FunctionDisplay::paint (QPainter *_painter, const QStyleOptionGraphicsItem
path.lineTo (0, 0);
_painter->drawPath (path);
float wH = w / 2.0;
float wT = w / 3.0;
QLinearGradient lG;
QRadialGradient rG;
......
......@@ -1117,7 +1117,7 @@ void GraphicsScene::contentChange ()
//------------------------------------------------------------------------------
void VSI::GraphicsScene::sceneResized(const QRectF & _rect)
void VSI::GraphicsScene::sceneResized(const QRectF & /*_rect*/)
{
if (dontMoveStart_)
return;
......
......@@ -250,7 +250,6 @@ SceneElement::SceneElement (GraphicsScene *_scene, Element *_element) :
{
ElementFunction *ef = new ElementFunction (f, this);
QGraphicsLinearLayout *hl = new QGraphicsLinearLayout (Qt::Horizontal);
Button *config = new Button ("Edit:" + f->shortDescription (), this);
config->setBrush (Qt::black);
config->setBackgroundBrush (Qt::lightGray);
......@@ -363,8 +362,6 @@ void SceneElement::paint (QPainter *_painter, const QStyleOptionGraphicsItem *_o
int w = geometry().width() - 20;
int h = geometry().height();
int div = 2;
_painter->setRenderHint(QPainter::Antialiasing, true);
if (isSelected ())
_painter->setBrush(QBrush(QColor(SELECTED_BACKGROUND_RED,
......
......@@ -132,7 +132,7 @@ void Text::setGeometry (const QRectF &_rect)
//------------------------------------------------------------------------------
// size information for layouting
QSizeF Text::sizeHint (Qt::SizeHint _which, const QSizeF &_constraint) const
QSizeF Text::sizeHint (Qt::SizeHint _which, const QSizeF &/*_constraint*/) const
{
QFontMetrics fn (font ());
QSizeF sh;
......@@ -185,11 +185,6 @@ void Text::paint (QPainter *_painter, const QStyleOptionGraphicsItem *_option, Q
if (backgroundSet_)
{
float w = geometry ().size ().width ();
float wH = w / 2.0;
float wT = w / 3.0;
QPainterPath path;
path.moveTo (geometry ().size ().width () / 2, 0);
......
......@@ -66,6 +66,7 @@ class GraphicsScene;
class Text : public QObject, public QGraphicsSimpleTextItem, public QGraphicsLayoutItem
{
Q_OBJECT
Q_INTERFACES(QGraphicsLayoutItem)
public:
......
......@@ -84,7 +84,7 @@ Trash::~Trash ()
//------------------------------------------------------------------------------
// make the trash opaque if mouse is over and we have selected elements
void Trash::hoverEnterEvent (QGraphicsSceneHoverEvent *_event)
void Trash::hoverEnterEvent (QGraphicsSceneHoverEvent */*_event*/)
{
if (!scene_->selectedItems ().isEmpty ())
setOpacity (1.0);
......@@ -93,7 +93,7 @@ void Trash::hoverEnterEvent (QGraphicsSceneHoverEvent *_event)
//------------------------------------------------------------------------------
// make trash transparent on mouse leave
void Trash::hoverLeaveEvent (QGraphicsSceneHoverEvent *_event)
void Trash::hoverLeaveEvent (QGraphicsSceneHoverEvent */*_event*/)
{
setOpacity (0.4);
}
......@@ -101,7 +101,7 @@ void Trash::hoverLeaveEvent (QGraphicsSceneHoverEvent *_event)
//------------------------------------------------------------------------------
// delete selected elements on mouse press
void Trash::mousePressEvent (QGraphicsSceneMouseEvent *_event)
void Trash::mousePressEvent (QGraphicsSceneMouseEvent */*_event*/)
{
if (!scene_->selectedItems ().isEmpty ())
foreach (QGraphicsItem *e, scene_->selectedItems ())
......@@ -140,7 +140,7 @@ void Trash::setGeometry (const QRectF &_rect)
//------------------------------------------------------------------------------
// size information for layouting
QSizeF Trash::sizeHint (Qt::SizeHint _which, const QSizeF &_constraint) const
QSizeF Trash::sizeHint (Qt::SizeHint _which, const QSizeF &/*_constraint*/) const
{
QSizeF sh;
switch (_which) {
......
......@@ -62,6 +62,7 @@ class GraphicsScene;
class Trash : public QObject, public QGraphicsPixmapItem, public QGraphicsLayoutItem
{
Q_OBJECT
Q_INTERFACES(QGraphicsLayoutItem)
public:
......
......@@ -95,7 +95,7 @@ ZoomButton::~ZoomButton ()
//------------------------------------------------------------------------------
// make the widget opaque if the mouse is over it
void ZoomButton::hoverEnterEvent (QGraphicsSceneHoverEvent *_event)
void ZoomButton::hoverEnterEvent (QGraphicsSceneHoverEvent */*_event*/)
{
setOpacity (1.0);
}
......@@ -103,7 +103,7 @@ void ZoomButton::hoverEnterEvent (QGraphicsSceneHoverEvent *_event)
//------------------------------------------------------------------------------
// make the widget transparent if the mouse leaves it
void ZoomButton::hoverLeaveEvent (QGraphicsSceneHoverEvent *_event)
void ZoomButton::hoverLeaveEvent (QGraphicsSceneHoverEvent */*_event*/)
{
setOpacity (0.4);
}
......@@ -206,7 +206,7 @@ void ZoomButton::setGeometry (const QRectF &_rect)
//------------------------------------------------------------------------------
// size information for layouting
QSizeF ZoomButton::sizeHint (Qt::SizeHint _which, const QSizeF &_constraint) const
QSizeF ZoomButton::sizeHint (Qt::SizeHint _which, const QSizeF &/*_constraint*/) const
{
QSizeF sh;
switch (_which) {
......
......@@ -59,6 +59,7 @@ class GraphicsScene;
class ZoomButton : public QObject, public QGraphicsPixmapItem, public QGraphicsLayoutItem
{
Q_OBJECT
Q_INTERFACES(QGraphicsLayoutItem)
public:
......
......@@ -102,7 +102,7 @@ ToolBoxElement::~ToolBoxElement ()
//------------------------------------------------------------------------------
// Paint a rounded rect as background
void ToolBoxElement::paintEvent(QPaintEvent *_event)
void ToolBoxElement::paintEvent(QPaintEvent */*_event*/)
{
QPainter p (this);
p.setRenderHint(QPainter::Antialiasing);
......
......@@ -60,7 +60,7 @@ TypeAny::TypeAny()
//------------------------------------------------------------------------------
bool TypeAny::canConvertTo(QString _type)
bool TypeAny::canConvertTo(QString /*_type*/)
{
return true;
}
......
......@@ -155,9 +155,6 @@ Qt::ItemFlags TreeModel::flags(const QModelIndex &index) const
else
flags = Qt::ItemIsEnabled;
// Get the corresponding tree item
TreeItem *item = static_cast<TreeItem*>(index.internalPointer());
return flags;
}
......
......@@ -177,7 +177,7 @@ void ObjectPickDialog::activated(const QModelIndex & _index)
//------------------------------------------------------------------------------
void ObjectPickDialog::slotMouseEventClick(QMouseEvent * _event, bool _double)
void ObjectPickDialog::slotMouseEventClick(QMouseEvent * _event, bool /*_double*/)
{
unsigned int nodeIdx, targetIdx;
......
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