DotNodeGadget::DotNodeGadget( Gaffer::NodePtr node ) : StandardNodeGadget( node ) { if( !runTimeCast<Dot>( node ) ) { throw Exception( "DotNodeGadget requires a Dot" ); } // Set the contents to have a small size, so the size of the Dot is controlled // largely by the nodeGadget:padding Metadata. setContents( new SpacerGadget( Box3f( V3f( -0.25 ), V3f( 0.25 ) ) ) ); node->plugDirtiedSignal().connect( boost::bind( &DotNodeGadget::plugDirtied, this, ::_1 ) ); node->nameChangedSignal().connect( boost::bind( &DotNodeGadget::nameChanged, this, ::_1 ) ); dragEnterSignal().connect( boost::bind( &DotNodeGadget::dragEnter, this, ::_2 ) ); dropSignal().connect( boost::bind( &DotNodeGadget::drop, this, ::_2 ) ); updateUpstreamNameChangedConnection(); updateLabel(); }