Compare commits
2 commits
28fb7e2198
...
f2ed11c206
Author | SHA1 | Date | |
---|---|---|---|
|
f2ed11c206 | ||
|
a1570e7fc3 |
2 changed files with 22 additions and 17 deletions
|
@ -126,6 +126,11 @@ const Audio = function(tp, record) {
|
||||||
|
|
||||||
const getAudioMappingOptions = (layer, propTitle) => {
|
const getAudioMappingOptions = (layer, propTitle) => {
|
||||||
if (savedMapping.hasOwnProperty(layer.id()) && savedMapping[layer.id()].hasOwnProperty(propTitle)) {
|
if (savedMapping.hasOwnProperty(layer.id()) && savedMapping[layer.id()].hasOwnProperty(propTitle)) {
|
||||||
|
if (tp.isSequenced(propTitle, layer)) {
|
||||||
|
const m = clone(savedMapping[layer.id()][propTitle]);
|
||||||
|
delete m.letterDelay;
|
||||||
|
return m;
|
||||||
|
}
|
||||||
return savedMapping[layer.id()][propTitle];
|
return savedMapping[layer.id()][propTitle];
|
||||||
} else if (propTitle === 'color') {
|
} else if (propTitle === 'color') {
|
||||||
const mm = getDefaultRange(layer, 'color');
|
const mm = getDefaultRange(layer, 'color');
|
||||||
|
|
|
@ -110,23 +110,23 @@ const Layer = function(tp, layerID, fontsAndAxes, autoInit = true) {
|
||||||
variationAxes[axes[a].name] = tp.core.types.number(axes[a].defaultValue, {
|
variationAxes[axes[a].name] = tp.core.types.number(axes[a].defaultValue, {
|
||||||
range: [axes[a].minValue, axes[a].maxValue],
|
range: [axes[a].minValue, axes[a].maxValue],
|
||||||
});
|
});
|
||||||
if (typeof audio === 'object' &&
|
//if (typeof audio === 'object' &&
|
||||||
typeof audio.getSavedMapping() === 'object' &&
|
//typeof audio.getSavedMapping() === 'object' &&
|
||||||
typeof audio.getSavedMapping()[this.id()] === 'object' &&
|
//typeof audio.getSavedMapping()[this.id()] === 'object' &&
|
||||||
typeof audio.getSavedMapping()[this.id()][`fontVariationAxes.${axes[a].name}`] === 'object' &&
|
//typeof audio.getSavedMapping()[this.id()][`fontVariationAxes.${axes[a].name}`] === 'object' &&
|
||||||
typeof audio.getMapping() === 'object' &&
|
//typeof audio.getMapping() === 'object' &&
|
||||||
typeof audio.getMapping()[this.id()] === 'object' &&
|
//typeof audio.getMapping()[this.id()] === 'object' &&
|
||||||
typeof audio.getMapping()[this.id()][`fontVariationAxes.${axes[a].name}`] === 'object' &&
|
//typeof audio.getMapping()[this.id()][`fontVariationAxes.${axes[a].name}`] === 'object' &&
|
||||||
tp.getPanel() !== null) {
|
//tp.getPanel() !== null) {
|
||||||
//doThese.push(() => {
|
////doThese.push(() => {
|
||||||
//audio.removeAudioOptions(this, `fontVariationAxes.${axes[a].name}`);
|
////audio.removeAudioOptions(this, `fontVariationAxes.${axes[a].name}`);
|
||||||
//audio.removeAudioMapping(this, `fontVariationAxes.${axes[a].name}`);
|
////audio.removeAudioMapping(this, `fontVariationAxes.${axes[a].name}`);
|
||||||
//audio.getSavedMapping()[this.id()][`fontVariationAxes.${axes[a].name}`].min_out = axes[a].minValue;
|
////audio.getSavedMapping()[this.id()][`fontVariationAxes.${axes[a].name}`].min_out = axes[a].minValue;
|
||||||
//audio.getSavedMapping()[this.id()][`fontVariationAxes.${axes[a].name}`].max_out = axes[a].maxValue;
|
////audio.getSavedMapping()[this.id()][`fontVariationAxes.${axes[a].name}`].max_out = axes[a].maxValue;
|
||||||
//audio.addAudioMapping(this, `fontVariationAxes.${axes[a].name}`);
|
////audio.addAudioMapping(this, `fontVariationAxes.${axes[a].name}`);
|
||||||
//audio.addAudioOptions(this, `fontVariationAxes.${axes[a].name}`);
|
////audio.addAudioOptions(this, `fontVariationAxes.${axes[a].name}`);
|
||||||
//});
|
////});
|
||||||
}
|
//}
|
||||||
} else {
|
} else {
|
||||||
console.log('js::layer::selectFont', 'this axis is insane, abort', axes[a]);
|
console.log('js::layer::selectFont', 'this axis is insane, abort', axes[a]);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue