def start_content_server(self, check_started=True): from calibre.library.server.main import start_threaded_server from calibre.library.server import server_config self.content_server = start_threaded_server(self.library_view.model().db, server_config().parse()) self.content_server.state_callback = Dispatcher(self.iactions["Connect Share"].content_server_state_changed) if check_started: self.content_server.start_failure_callback = Dispatcher(self.content_server_start_failed)
def start_content_server(self, check_started=True): from calibre.library.server.main import start_threaded_server from calibre.library.server import server_config self.content_server = start_threaded_server( self.library_view.model().db, server_config().parse()) self.content_server.state_callback = Dispatcher( self.iactions['Connect Share'].content_server_state_changed) if check_started: self.content_server.start_failure_callback = \ Dispatcher(self.content_server_start_failed)