{\r
if( this->m_Conn )\r
{\r
- this->m_Conn->setPos2( evt->scenePos( ) );\r
+ if( this->m_Conn->port1( ) == NULL )\r
+ this->m_Conn->setPos1( evt->scenePos( ) );\r
+ else if( this->m_Conn->port2( ) == NULL )\r
+ this->m_Conn->setPos2( evt->scenePos( ) );\r
this->m_Conn->updatePath( );\r
return( true );\r
\r
dynamic_cast< QNEOutputPort* >( this->itemAt( evt->scenePos( ) ) );\r
if( port != NULL )\r
{\r
- this->m_Conn = new QNEConnection( 0, this->m_Scene );\r
- this->m_Conn->setPort1( port );\r
- this->m_Conn->setPos1( port->scenePos( ) );\r
- this->m_Conn->setPos2( evt->scenePos( ) );\r
- this->m_Conn->updatePath( );\r
- return( true );\r
+ if( port->block( ) != NULL )\r
+ {\r
+ this->m_Conn = new QNEConnection( 0, this->m_Scene );\r
+ this->m_Conn->setPort1( port );\r
+ this->m_Conn->setPos1( port->scenePos( ) );\r
+ this->m_Conn->setPos2( evt->scenePos( ) );\r
+ this->m_Conn->updatePath( );\r
+ return( true );\r
+\r
+ } // fi\r
\r
} // fi\r
}\r
dynamic_cast< QNEOutputPort* >( this->itemAt( evt->scenePos( ) ) );\r
if( in_port != NULL )\r
{\r
- if( in_port->connection( ) == NULL )\r
+ if( in_port->connection( ) == NULL && in_port->block( ) != NULL )\r
{\r
this->m_Conn = new QNEConnection( 0, this->m_Scene );\r
this->m_Conn->setPort2( in_port );\r
\r
} // fi\r
}\r
- else if( out_port != NULL )\r
+ else if( out_port != NULL && out_port->block( ) != NULL )\r
{\r
this->m_Conn = new QNEConnection( 0, this->m_Scene );\r
this->m_Conn->setPort1( out_port );\r
dynamic_cast< QNEOutputPort* >(\r
this->itemAt( evt->scenePos( ) )\r
) == NULL\r
- /*&&\r
- port2->connection( ) == NULL*/\r
)\r
{\r
port1 = new QNEOutputPort( NULL, this->m_Scene );\r