* examples/ARcue.py:

* examples/gtkcrc.py:
	* morituri/common/crc.py:
	* morituri/common/task.py:
	  Split out generic task/runner from CRC tasks.
This commit is contained in:
Thomas Vander Stichele
2009-04-11 15:40:03 +00:00
parent 2e93bfb988
commit 8345938584
5 changed files with 20 additions and 310 deletions

View File

@@ -24,7 +24,7 @@ import os
import sys
from morituri.image import cue
from morituri.common import task
from morituri.common import task, crc
import gobject
gobject.threads_init()
@@ -49,10 +49,10 @@ def main(path):
path = '%s.%s' % (noext, ext)
if os.path.exists(path):
print 'CRCing %s from CD frame %r for %r' % (path, offset, length)
crctask = task.CRCAudioRipTask(path,
crctask = crc.CRCAudioRipTask(path,
trackNumber=trackIndex + 1, trackCount=len(cuefile.tracks),
frameStart=offset * task.FRAMES_PER_DISC_FRAME,
frameLength=length * task.FRAMES_PER_DISC_FRAME)
frameStart=offset * crc.FRAMES_PER_DISC_FRAME,
frameLength=length * crc.FRAMES_PER_DISC_FRAME)
if not crctask:
print 'ERROR: path %s not found' % file.path

View File

@@ -30,7 +30,7 @@ gobject.threads_init()
import gtk
from morituri.common import task
from morituri.common import task, crc
class TaskProgress(gtk.VBox, task.TaskRunner):
__gsignals__ = {
@@ -89,7 +89,7 @@ try:
except:
pass
crctask = task.CRC32Task(path, start, end)
crctask = crc.CRC32Task(path, start, end)
# this is a Dummy task that can be used if this works at all
class DummyTask(task.Task):