little cleaning

This commit is contained in:
Marcos Pinto 2008-10-17 21:36:03 +00:00
parent d12019cbc4
commit 8d2a658789
4 changed files with 5 additions and 5 deletions

View File

@ -113,7 +113,7 @@ class PGZip(TextBase):
def next(self):
try:
ret = self.reader.next()
if ret == False:
if not ret:
# This bit is repeated below and could be moved into a
# new procedure. However I'm not clear on how this
# would effect tail recursion, so it remains

View File

@ -444,7 +444,7 @@ class AddTorrentDialog(component.Component):
files_list = []
for file_dict in self.files[torrent_id]:
if file_dict["download"] == False:
if not file_dict["download"]:
files_list.append(0)
else:
files_list.append(1)

View File

@ -144,13 +144,13 @@ class MainWindow(component.Component):
h = self.config["window_height"]
self.window.move(x, y)
self.window.resize(w, h)
if self.config["window_maximized"] == True:
if self.config["window_maximized"]:
self.window.maximize()
self.vpaned.set_position(
self.config["window_height"] - self.config["window_pane_position"])
def on_window_configure_event(self, widget, event):
if self.config["window_maximized"] == False and self.visible:
if not self.config["window_maximized"] and self.visible:
self.config.set("window_x_pos", self.window.get_position()[0])
self.config.set("window_y_pos", self.window.get_position()[1])
self.config.set("window_width", event.width)

View File

@ -62,7 +62,7 @@ class SignalReceiver(ThreadingMixIn, SimpleXMLRPCServer.SimpleXMLRPCServer):
def start_server(self, port=None):
# Setup the xmlrpc server
host = "127.0.0.1"
if self.remote == True:
if self.remote:
host = ""
server_ready = False