1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18 import gettext
19 import os
20
21 from zope.interface import implements
22
23 from flumotion.admin.assistant.interfaces import IProducerPlugin
24 from flumotion.admin.assistant.models import AudioProducer
25 from flumotion.admin.gtk.basesteps import AudioProducerStep
26
27 __version__ = "$Rev$"
28 _ = gettext.gettext
29
30
38
39
41 name = 'TestAudioProducer'
42 title = _('Test Audio Producer')
43 icon = 'soundcard.png'
44 gladeFile = os.path.join(os.path.dirname(os.path.abspath(__file__)),
45 'wizard.glade')
46 docSection = 'help-configuration-assistant-producer-audio-test'
47 docAnchor = ''
48 docVersion = 'local'
49
50
51
53 self.samplerate.data_type = str
54 self.volume.data_type = float
55 self.wave.data_type = int
56
57 self.samplerate.prefill(['8000',
58 '16000',
59 '32000',
60 '44100'])
61
62 self.wave.prefill([(_('Sine'), 0),
63 (_('Square'), 1),
64 (_('Saw'), 2),
65 (_('Ticks'), 8)])
66
67 self.add_proxy(self.model.properties,
68 ['frequency', 'volume', 'samplerate', 'wave'])
69
70 self.samplerate.set_sensitive(True)
71
75
78
79
89