ExpressionNode flags are now set in it's constructor.

This commit is contained in:
dfighter1985 2014-09-17 16:02:28 +02:00
parent 55264978ad
commit e18e3ac358
2 changed files with 2 additions and 1 deletions

View file

@ -239,7 +239,6 @@ void ExpressionEditor::onItemDblClicked( QTreeWidgetItem *item )
m_nodeCount++;
ExpressionNode *node = new ExpressionNode( n, info->slotNames.count() );
node->setFlags( QGraphicsItem::ItemIsSelectable | QGraphicsItem::ItemIsMovable );
node->setSlotNames( info->slotNames );
node->setVariable( info->variable );
node->setIsValue( info->value );

View file

@ -101,6 +101,8 @@ private:
ExpressionNode::ExpressionNode( const QString &name, int slotCount, QGraphicsItem *parent ) :
QGraphicsItem( parent )
{
setFlags( QGraphicsItem::ItemIsSelectable | QGraphicsItem::ItemIsMovable );
m_w = 100;
m_h = 100;
m_hh = 20.0;