From 233e81454717f7932baf909cd6c8863d3530df6a Mon Sep 17 00:00:00 2001 From: Pedro Algarvio Date: Fri, 22 Apr 2011 11:33:45 +0100 Subject: [PATCH] Late import twisted's reactor, it allows the gtk reactor to be proper installed. --- deluge/config.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/deluge/config.py b/deluge/config.py index 2e42fa5fc..482415c95 100644 --- a/deluge/config.py +++ b/deluge/config.py @@ -72,7 +72,6 @@ import logging import shutil import os -from twisted.internet import reactor import deluge.common json = deluge.common.json @@ -220,6 +219,7 @@ what is currently in the config and it could not convert the value self.__config[key] = value # Run the set_function for this key if any + from twisted.internet import reactor try: for func in self.__set_functions[key]: reactor.callLater(0, func, key, value) @@ -288,6 +288,7 @@ what is currently in the config and it could not convert the value """ del self.__config[key] # We set the save_timer for 5 seconds if not already set + from twisted.internet import reactor if not self._save_timer or not self._save_timer.active(): self._save_timer = reactor.callLater(5, self.save)