diff options
author | Richard Purdie <rpurdie@linux.intel.com> | 2008-04-27 11:13:59 +0000 |
---|---|---|
committer | Richard Purdie <rpurdie@linux.intel.com> | 2008-04-27 11:13:59 +0000 |
commit | 4d376349347de388b92f477f102d1bbf299328af (patch) | |
tree | 288f38de4d0fdda530f04e76eb140771b1f9080d /lib/bb/ui/uihelper.py | |
parent | 06560a3a3747d69d22d4bd0ab247eae37e21d0e4 (diff) | |
download | bitbake-4d376349347de388b92f477f102d1bbf299328af.tar.gz |
uihelper.py: Fill out the code a bit more
Diffstat (limited to 'lib/bb/ui/uihelper.py')
-rw-r--r-- | lib/bb/ui/uihelper.py | 28 |
1 files changed, 19 insertions, 9 deletions
diff --git a/lib/bb/ui/uihelper.py b/lib/bb/ui/uihelper.py index 0532ce93e..246844c9d 100644 --- a/lib/bb/ui/uihelper.py +++ b/lib/bb/ui/uihelper.py @@ -19,21 +19,31 @@ class BBUIHelper: def __init__(self): + self.needUpdate = False self.running_tasks = {} + self.failed_tasks = {} def eventHandler(self, event): if event[0].startswith('bb.build.TaskStarted'): self.running_tasks["%s %s\n" % (event[1]['_package'], event[1]['_task'])] = "" + self.needUpdate = True if event[0].startswith('bb.build.TaskSucceeded'): del self.running_tasks["%s %s\n" % (event[1]['_package'], event[1]['_task'])] - if event[0].startswith('bb.runqueue.runQueueTaskCompleted'): - a = 1 - if event[0].startswith('bb.runqueue.runQueueTaskStarted'): - a = 1 - if event[0].startswith('bb.runqueue.runQueueTaskFailed'): - a = 1 - if event[0].startswith('bb.runqueue.runQueueExitWait'): - a = 1 + self.needUpdate = True + if event[0].startswith('bb.build.TaskFailed'): + del self.running_tasks["%s %s\n" % (event[1]['_package'], event[1]['_task'])] + self.failed_tasks["%s %s\n" % (event[1]['_package'], event[1]['_task'])] = "" + self.needUpdate = True + + # Add runqueue event handling + #if event[0].startswith('bb.runqueue.runQueueTaskCompleted'): + # a = 1 + #if event[0].startswith('bb.runqueue.runQueueTaskStarted'): + # a = 1 + #if event[0].startswith('bb.runqueue.runQueueTaskFailed'): + # a = 1 + #if event[0].startswith('bb.runqueue.runQueueExitWait'): + # a = 1 def getTasks(self): - return self.running_tasks + return (self.running_tasks, self.failed_tasks) |