예제 #1
0
파일: main.py 프로젝트: ArildF/rogie
    config = Config.getConfig()
    
    protocol = config.getString("login", "protocol")
    
    #init the protocol we are going to use
    Protocol.initProtocol( protocol )
    
    protocol = Protocol.getProtocol()   
    
    
    #first get the cookie and id's     
    nick = config.getString( "login", "username" )
    passwd = config.getString( "login", "password" )

    events = Events.getEvents()
    events.addListener( Display.getDisplay() )
    events.addListener( SpamFilter.getInstance() )

    #create the socket
    sock = socket.socket( socket.AF_INET, socket.SOCK_STREAM )
    sock.settimeout( 120.0 )
    chatserver = config.getString( "login", "chatserver" )
    chatport = config.getInt( "login", "chatport" ) 


    #recreate the acl?
    if sys.argv.count( "-newacl" ):
        os.unlink( Acl.ACLFILE )

    chatRoom = config.getString( "login", "chatroom" )
예제 #2
0
파일: Packet.py 프로젝트: ArildF/rogie
 def send( self, sock ):
     """override send to display the pm"""
     Packet.send( self, sock )
     Display.getDisplay().pmTo( self.destination, self.statement )
예제 #3
0
파일: Ack.py 프로젝트: ArildF/rogie
 def __init__( self, aSocket, theRoom, theLength ):
     self.sock = aSocket
     self.length = theLength        
     self.display = Display.getDisplay()        
     self.room = theRoom