diff options
author | Oli <olivier.belanger@umontreal.ca> | 2007-07-19 00:39:38 (GMT) |
---|---|---|
committer | Oli <olivier.belanger@umontreal.ca> | 2007-07-19 00:39:38 (GMT) |
commit | 2f077d6fe08a46cd583287e1985f79f116329bcc (patch) | |
tree | 7ec305dc33cabc8ed8519603eaac4ca6114d2410 /Util | |
parent | b7a6ecf47a6090b5fa4566f9a5e1147d1a099ba3 (diff) |
loop settings
Diffstat (limited to 'Util')
-rw-r--r-- | Util/CSoundClient.py | 2 | ||||
-rw-r--r-- | Util/LoopSettings.py | 15 |
2 files changed, 12 insertions, 5 deletions
diff --git a/Util/CSoundClient.py b/Util/CSoundClient.py index 53a4788..242461f 100644 --- a/Util/CSoundClient.py +++ b/Util/CSoundClient.py @@ -77,7 +77,7 @@ class _CSoundClientPlugin: def load_ls_instrument( self, inst ): fileName = Config.PREF_DIR + '/' + inst - sc_inputMessage("perf.InputMessage('f4999 0 0 -1 \"%s\" 0 0 0')\n" % fileName) + sc_inputMessage(Config.CSOUND_LOAD_LS_INSTRUMENT % fileName) def load_instruments( self ): for instrumentSoundFile in Config.INSTRUMENTS.keys(): diff --git a/Util/LoopSettings.py b/Util/LoopSettings.py index f953c0c..a6ac667 100644 --- a/Util/LoopSettings.py +++ b/Util/LoopSettings.py @@ -7,11 +7,12 @@ import Config Tooltips = Config.Tooltips() class LoopSettings( gtk.VBox ): - def __init__( self, popup, playFunction ): + def __init__( self, popup, playFunction, setChannelFunction ): gtk.VBox.__init__( self ) self.tooltips = gtk.Tooltips() self.popup = popup self.playFunction = playFunction + self.setChannel = setChannelFunction self.settingsBox = gtk.HBox() self.pack_start(self.settingsBox) @@ -141,13 +142,19 @@ class LoopSettings( gtk.VBox ): self.registerButton.set_label(self.registerList[self.register]) def handleStart(self, widget, data=None): - self.startEntry.set_text(str(self.startAdjust.value)) + self.start = self.startAdjust.value + self.startEntry.set_text(str(self.start)) + self.setChannel('lstart', self.start) def handleEnd(self, widget, data=None): - self.endEntry.set_text(str(self.endAdjust.value)) + self.end = self.endAdjust.value + self.endEntry.set_text(str(self.end)) + self.setChannel('lend', self.end) def handleDur(self, widget, data=None): - self.durEntry.set_text(str(self.durAdjust.value)) + self.dur = self.durAdjust.value + self.durEntry.set_text(str(self.dur)) + self.setChannel('ldur', self.dur) def handlePlayButton(self, widget, data=None): self.playFunction(widget.get_active())
\ No newline at end of file |