aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Runge <dave@sleepmap.de>2016-07-14 13:19:07 +0200
committerDavid Runge <dave@sleepmap.de>2016-07-14 13:19:07 +0200
commit94f11724534098ac0f08bb6d084d35979f673e5a (patch)
tree1a0981d7b751a65fd8b9264ba5cb359ce4d1429f
parent32f7a4f35d3b63ef9f12f396cd7fb7f9dc18a351 (diff)
downloadbowelyzer-94f11724534098ac0f08bb6d084d35979f673e5a.tar.gz
bowelyzer-94f11724534098ac0f08bb6d084d35979f673e5a.tar.bz2
bowelyzer-94f11724534098ac0f08bb6d084d35979f673e5a.tar.xz
bowelyzer-94f11724534098ac0f08bb6d084d35979f673e5a.zip
classes/BowelyzerGUI.sc: Setting channel View names type String, too. classes/Bowelyzer.sc: Casting update type String, when checking for empty String on rename.
-rw-r--r--classes/Bowelyzer.sc2
-rw-r--r--classes/BowelyzerGUI.sc9
2 files changed, 4 insertions, 7 deletions
diff --git a/classes/Bowelyzer.sc b/classes/Bowelyzer.sc
index cea4c55..1841cb7 100644
--- a/classes/Bowelyzer.sc
+++ b/classes/Bowelyzer.sc
@@ -63,7 +63,7 @@ Bowelyzer{
switch(type,
\name,{
// if the name is not empty and not used, change to it
- if((update != "") && config.config.at(\inputs).includesKey(update).not, {
+ if((update.asString != "") && config.config.at(\inputs).includesKey(update).not, {
//move the controls
config.config.at(\controls).put(update.asSymbol, config.config.at(\controls).at(name));
config.config.at(\controls).removeAt(name.asSymbol);
diff --git a/classes/BowelyzerGUI.sc b/classes/BowelyzerGUI.sc
index 862d999..fd20cab 100644
--- a/classes/BowelyzerGUI.sc
+++ b/classes/BowelyzerGUI.sc
@@ -332,7 +332,7 @@ BowelyzerGUI{
// adding name textfield of input
headView = View(channelView.asView, Rect(0, 0, headViewWidth, headViewHeight));
headView.asView.background = Color.fromHexString("#DDEFDD");
- headView.name = \inputs;
+ headView.name = "inputs";
headView.layout = HLayout();
headView.layout.spacing = 4;
headView.layout.margins = [4,0,4,0];
@@ -349,7 +349,7 @@ BowelyzerGUI{
controlMeterContainerView = View(channelView.asView, Rect(0, 0, controlMeterContainerViewWidth, controlMeterContainerViewHeight));
controlMeterContainerView.asView.background = Color.fromHexString("#DDDDEF");
- controlMeterContainerView.name = \meterAndControls;
+ controlMeterContainerView.name = "meterAndControls";
controlMeterContainerView.layout = HLayout();
controlMeterContainerView.layout.spacing = 0;
controlMeterContainerView.layout.margins = [0,0,0,0];
@@ -374,18 +374,16 @@ BowelyzerGUI{
controlsView = View(controlMeterContainerView.asView, Rect(0,0, controlsViewWidth, controlsViewHeight));
controlsView.asView.background = Color.fromHexString("#EEEFEE");
- controlsView.name = \controls;
+ controlsView.name = "controls";
controlsView.layout = VLayout();
controlsView.layout.spacing = 0;
controlsView.layout.margins = [2,0,2,0];
//TODO: add ranger for amplitude and pitch threshold/region
//TODO: rearrange sliders/rangers/knobs in groups (maybe even tabs)
- //Routine{
config.at(\controls).at(name).order.do({|control, i|
var value = config.at(\controls).at(name).at(control),
controlIs = BowelyzerConfig.controlContainedIn(control);
- //(0.1).wait;
switch(
controlIs.asSymbol,
\knob, {this.setupEZKnob(controlsView, control, value, \controls, name).view.children.do({|item| if(item.isKindOf(NumberBox),{item.align_(\right)})})},
@@ -393,7 +391,6 @@ BowelyzerGUI{
\ranger, {this.setupEZRanger(controlsView, control, value, \controls, name).view.children.do({|item| if(item.isKindOf(NumberBox),{item.align_(\right)})})}
);
});
- //}.play(AppClock);
// add channelView to the container and the global Dictionary for better access
channelContainerView.layout.add(channelView);
channels.add(channelView);