~ubuntu-branches/ubuntu/oneiric/alarm-clock/oneiric

« back to all changes in this revision

Viewing changes to alarm-clock/SnoozeThread.py

  • Committer: Bazaar Package Importer
  • Author(s): Marco Rodrigues
  • Date: 2008-10-28 19:57:12 UTC
  • mto: (7.1.1 sid) (9.1.1 squeeze) (1.2.3 upstream)
  • mto: This revision was merged to the branch mainline in revision 8.
  • Revision ID: james.westby@ubuntu.com-20081028195712-e8kusg37fc1hnw0s
Tags: upstream-0.9.17
ImportĀ upstreamĀ versionĀ 0.9.17

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
import gtk
5
5
 
6
6
class SnoozeThread(Thread):
7
 
        def __init__(self,c,dl, MainClass):
 
7
        def __init__(self, c, MainClass, Count = False, Remover = False, Loader = False, Prefs = False, UpdateList = None):
8
8
                Thread.__init__(self)
9
9
                self.setDaemon(True)
10
 
                self.dl = dl
11
10
                self.c = c
12
 
 
 
11
                self.Count = Count
 
12
                self.Remover = Remover
 
13
                self.Loader = Loader
 
14
                self.Prefs = Prefs
 
15
                self.UpdateList = UpdateList
13
16
                self.MainClass = MainClass
14
17
 
15
18
        def run(self):
23
26
                        self.count = self.count + 1
24
27
                        if self.count == self.c[39]:
25
28
                                gtk.gdk.threads_enter()
26
 
                                self.MainClass().RunAlarm(self.c)
 
29
                                self.MainClass().RunAlarm(self.c, self.Count, self.Remover, self.Loader, self.Prefs, self.UpdateList)
27
30
                                gtk.gdk.threads_leave()
28
31
                                break