From 616dd6288ab2c6cbb0f3e5e49f6886908e0a4537 Mon Sep 17 00:00:00 2001 From: Andrew Resch Date: Fri, 22 Feb 2008 22:36:31 +0000 Subject: [PATCH] Minor cosmetic touch-ups. Removed some imports that are no longer needed. --- deluge/ui/client.py | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) diff --git a/deluge/ui/client.py b/deluge/ui/client.py index b5ea874d3..0d0882232 100644 --- a/deluge/ui/client.py +++ b/deluge/ui/client.py @@ -33,9 +33,7 @@ # statement from all source files in the program, then also delete it here. import os.path -import pickle import socket -import time import gobject @@ -155,24 +153,22 @@ class BaseClient(object): wraps all calls to core/coreproxy base for AClient and SClient """ - no_callback_list = [ "add_torrent_url", "pause_all_torrents", + no_callback_list = ["add_torrent_url", "pause_all_torrents", "resume_all_torrent", "set_config", "enable_plugin", "disable_plugin", "set_torrent_trackers", "set_torrent_max_connections", "set_torrent_max_upload_slots", "set_torrent_max_upload_speed", "set_torrent_max_download_speed", "set_torrent_private_flag", "set_torrent_file_priorities", - "block_ip_range", - "remove_torrent", "pause_torrent", "move_torrent" , - "resume_torrent","force_reannounce", "force_recheck", - "deregister_client","register_client", - "add_torrent_file"] + "block_ip_range", "remove_torrent", "pause_torrent", "move_torrent", + "resume_torrent", "force_reannounce", "force_recheck", + "deregister_client", "register_client", "add_torrent_file"] def __init__(self): self.core = _core #xml-rpc introspection def list_methods(self): - registered = self.core.rpc_core.system.listMethods( ) + registered = self.core.rpc_core.system.listMethods() return sorted(registered) def methodSignature(self, method_name): @@ -244,7 +240,7 @@ class BaseClient(object): """Get the core URI""" return self.core.get_core_uri() - def set_core_uri(self, uri = 'http://localhost:58846'): + def set_core_uri(self, uri='http://localhost:58846'): """Sets the core uri""" return self.core.set_core_uri(uri) @@ -285,7 +281,7 @@ class AClient(BaseClient): def get_method(self, method_name): if not self.has_callback(method_name): def async_proxy_nocb(*args, **kwargs): - return self.core.call(method_name,None, *args, **kwargs) + return self.core.call(method_name, None, *args, **kwargs) return async_proxy_nocb else: def async_proxy(*args, **kwargs):