Subversion Repositories HomeAutomation

Rev

Rev 741 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | SVN | RSS feed

Rev 741 Rev 742
Line 107... Line 107...
107
 
107
 
108
        self.cfg = DaemonConfig()
108
        self.cfg = DaemonConfig()
109
   
109
   
110
    class IfNotifier():
110
    class IfNotifier():
111
        """ Used by if threads to send messages to the main program thread """
111
        """ Used by if threads to send messages to the main program thread """
-
 
112
       
-
 
113
        parent = None
112
        UNDEFINED = 0
114
        UNDEFINED = 0
113
        TERMINATE = 1
115
        TERMINATE = 1
-
 
116
       
-
 
117
        def __init__(self, parent):
-
 
118
            self.parent = parent
114
   
119
   
115
        def notify(self, msg):
120
        def notify(self, msg):
116
            if msg == self.TERMINATE:
121
            if msg == self.TERMINATE:
117
                print 'Main terminate notify'
122
                print 'Main terminate notify'
118
                self.terminated = True
-
 
119
            else:
123
            else:
120
                print 'UNDEFINED NOTIFY'
124
                print 'UNDEFINED NOTIFY'
121
       
125
       
122
   
126
   
123
    def __rightAdjust(self, refstr, str):
127
    def __rightAdjust(self, refstr, str):