1
0
mirror of https://github.com/avatao-content/test-tutorial-framework synced 2024-10-05 08:23:37 +00:00

Use ServerUplinkConnector with new name TFWServerConnector

This commit is contained in:
Kristóf Tóth 2018-04-06 16:23:20 +02:00
parent de4c534568
commit 4fa9895854

View File

@ -1,7 +1,7 @@
from tornado.ioloop import IOLoop from tornado.ioloop import IOLoop
from tfw.components import SourceCodeEventHandler, TerminadoEventHandler, ProcessManagingEventHandler, BashMonitor from tfw.components import SourceCodeEventHandler, TerminadoEventHandler, ProcessManagingEventHandler, BashMonitor
from tfw.networking import MessageSender, ServerUplinkConnector from tfw.networking import MessageSender, TFWServerConnector
from tfw.config import TFWENV from tfw.config import TFWENV
from tfw.config.logs import logging from tfw.config.logs import logging
@ -17,7 +17,7 @@ def selectdir(history):
try: try:
cmd = history[-1].split() cmd = history[-1].split()
if cmd[0] == 'selectdir': if cmd[0] == 'selectdir':
ServerUplinkConnector().send_to_eventhandler('webide', TFWServerConnector().send_to_eventhandler('webide',
{'data': {'command': 'selectdir', {'data': {'command': 'selectdir',
'directory': cmd[1]}}) 'directory': cmd[1]}})
except IndexError: except IndexError:
@ -29,7 +29,7 @@ def toggle_next(history):
try: try:
cmd = history[-1].split() cmd = history[-1].split()
if cmd[0] == 'togglenext': if cmd[0] == 'togglenext':
ServerUplinkConnector().send('messagecontrol', TFWServerConnector().send('messagecontrol',
{'data': {'command': 'showbutton', {'data': {'command': 'showbutton',
'next_visibility': toggle_next.button_state}}) 'next_visibility': toggle_next.button_state}})
except IndexError: except IndexError: