Logo Search packages:      
Sourcecode: nateon version File versions  Download package

void KNateon::slotGotFR ( const QStringList &  slCommand  )  [private, slot]

CTOC 0 ring0320@nate.com 57 REQC FR 211.234.239.175:5004 10014827278:6301 406378858

내가 client로 상대 서버에 접속했음.

Server이면 ATHC로 상대가 P2PCookie를 보내나, Client일때는 직접 Setting 해야 함.

"ATHC|[My ID] [Your ID] [P2P Cookie] 6004 0\r\n"

파일 전송창

Definition at line 6578 of file knateon.cpp.

References CurrentAccount::getMyID(), and m_pFileTransfer.

Referenced by initializeNateonDPConnection().

{
    if ( isP2PActivedP2PCookie( slCommand[7] ) )
        return;

    QStringList slServerInformation = QStringList::split( ":", slCommand[6] );
    kdDebug() << "Connecting - IP:" << slServerInformation[0] << ", Port:" << slServerInformation[1] << endl;

    NOMP2PBase *pBase = m_pP2PList->add( new NOMP2PBase( this, "p2pbase" ) );
    connect( pBase, SIGNAL( IncomingMessage( const QString & ) ), m_pNetworkWindow, SLOT( addIncomingServerMessage( const QString & ) ) );
    connect( pBase, SIGNAL( OutgoingMessage( const QString & ) ), m_pNetworkWindow, SLOT( addOutgoingServerMessage( const QString & ) ) );
    
    pBase->setType( NOMP2PBase::SEND );
    pBase->setConnectType( NOMP2PBase::CLIENT ); /*! 내가 client로 상대 서버에 접속했음. */
    pBase->setP2PCookie( slCommand[7] ); /*! Server이면 ATHC로 상대가 P2PCookie를 보내나, Client일때는 직접 Setting 해야 함. */
    pBase->setFRCookie( slCommand[8] );
    pBase->setYourID( slCommand[2] );
    pBase->setMyID( m_pCurrentAccount->getMyID() );

    /*! "ATHC|[My ID] [Your ID] [P2P Cookie] 6004 0\r\n" */
    QString sCommand;
    sCommand = "ATHC";
    sCommand += "|";
    sCommand += m_pCurrentAccount->getMyID();
    sCommand += " ";
    sCommand += slCommand[2];
    sCommand += " ";
    sCommand += slCommand[7];
    sCommand += " ";
    sCommand += slCommand[8];
    sCommand += " ";
    sCommand += QString::number( 6004 );
    sCommand += " ";
    sCommand += "0";
    sCommand += "\r\n";
    
    pBase->addQueue( sCommand );

    /* FRIN */
    pBase->connectToFRServer( slServerInformation[0], slServerInformation[1].toInt() );
    
    /*! 파일 전송창 */
    connect( pBase, SIGNAL( updateProgress( const QString &, const unsigned long ) ), m_pFileTransfer, SLOT( updateProgressByByte( const QString &, const unsigned long ) ) );
    connect( pBase, SIGNAL( endProgress( const QString & ) ), m_pFileTransfer, SLOT( endProgressByByte( const QString & ) ) );
}


Generated by  Doxygen 1.6.0   Back to index