Example #1
0
def main() :
    try :
        nodeAddr = readAddr( sys.argv[1] )
    except :
        nodeAddr = ('208.78.96.185', 10001) # ('210.210.1.102',10001) 
    seedNodes = [nodeAddr]
    app = QApplication( sys.argv )
    icon = QIcon()
    for iconSize in [48,32,24,16] :
        icon.addPixmap( QPixmap(':/images/cspace%d.png'%iconSize) )
    app.setWindowIcon( icon )
    app.setQuitOnLastWindowClosed( False )
    reactor = Qt4Reactor()
    if not checkSettingsVersion() :
        return
    logFile = LogFile( localSettings() )
    sys.stdout = logFile
    sys.stderr = logFile
    logging.getLogger().addHandler( logging.StreamHandler() )
    initdelaygc( reactor )
    mainWin = MainWindow( seedNodes, reactor )
    mainWin.show()
    app.exec_()
    global execFileAfterExit
    if execFileAfterExit is not None :
        p = execFileAfterExit
        args = [p]
        startingDir = os.path.split( p )[0]
        spawnProcess( p, args, os.environ, startingDir, 0 )
Example #2
0
def main() :
    try :
        nodeAddr = readAddr( sys.argv[1] )
    except :
        nodeAddr = ('210.210.1.102',10001)
    seedNodes = [nodeAddr]
    app = QApplication( sys.argv )
    icon = QIcon()
    for iconSize in [48,32,24,16] :
        icon.addPixmap( QPixmap(':/images/cspace%d.png'%iconSize) )
    app.setWindowIcon( icon )
    app.setQuitOnLastWindowClosed( False )
    reactor = Qt4Reactor()
    if not checkSettingsVersion() :
        return
    logFile = LogFile( localSettings() )
    sys.stdout = logFile
    sys.stderr = logFile
    logging.getLogger().addHandler( logging.StreamHandler() )
    initdelaygc( reactor )
    mainWin = MainWindow( seedNodes, reactor )
    mainWin.show()
    app.exec_()
    global execFileAfterExit
    if execFileAfterExit is not None :
        p = execFileAfterExit
        args = [p]
        startingDir = os.path.split( p )[0]
        spawnProcess( p, args, os.environ, startingDir, 0 )
Example #3
0
def main():
    initializeLogFile('IM.log')
    logging.getLogger().addHandler(logging.StreamHandler())
    global env, app, reactor
    env = CSpaceEnv()
    app = QApplication(sys.argv)
    reactor = Qt4Reactor()
    initdelaygc(reactor)
    IMInitializer(reactor, _onInitialize)
    app.exec_()
Example #4
0
def main() :
    initializeLogFile( 'IM.log' )
    logging.getLogger().addHandler( logging.StreamHandler() )
    global env, app, reactor
    env = CSpaceEnv()
    app = QApplication( sys.argv )
    reactor = Qt4Reactor()
    initdelaygc( reactor )
    IMInitializer( reactor, _onInitialize )
    app.exec_()
Example #5
0
def main():
    initializeLogFile('FileReceiver.log')
    logging.getLogger().addHandler(logging.StreamHandler())
    global env
    env = CSpaceEnv()
    assert env.isIncoming
    app = QApplication(sys.argv)
    reactor = Qt4Reactor()
    initdelaygc(reactor)
    frw = FileReceiverWindow(reactor)
    frw.show()
    app.exec_()
Example #6
0
def main() :
    initializeLogFile( 'FileSender.log' )
    logging.getLogger().addHandler( logging.StreamHandler() )
    global env
    env = CSpaceEnv()
    assert env.isContactAction
    app = QApplication( sys.argv )
    reactor = Qt4Reactor()
    initdelaygc( reactor )
    fsw = FileSenderWindow( reactor )
    fsw.show()
    app.exec_()