view src/DML/MainVisBundle/Resources/assets/marionette/modules/RepresentationModule/RepresentationModule.31-Master.view.collection.pitch-histogram.js @ 1:f38015048f48 tip

Added GPL
author Daniel Wolff
date Sat, 13 Feb 2016 20:43:38 +0100
parents 493bcb69166c
children
line wrap: on
line source
"use strict";

App.module("RepresentationModule", function(RepresentationModule, App, Backbone, Marionette, $, _, Logger) {

    RepresentationModule.addInitializer(function(options){

        RepresentationModule.registerMaster({
            id: "view.collection.pitch-histogram",
            inherit: "view.collection._histogram",


            defaultConfigParameterValues: {
                weighting: "none",
                pitchMin: 20,
                pitchMax: 100,
                //quant:    5
            },


            // =================================================================
            // vis instance rendering


            // -----------------------------------------------------------------
            // vis instance rendering - base

            _generateCustomParamsForBasePerspectiveRequestParams: function(viewConfig) {
                var result = {
                        "weighting": this.getConfigParameterValueOrDefaultValue(viewConfig, "weighting", true),
                        "min":       this.getConfigParameterValueOrDefaultValue(viewConfig, "pitchMin", true),
                        "max":       this.getConfigParameterValueOrDefaultValue(viewConfig, "pitchMax", true),
                        //"quant":     this.getConfigParameterValueOrDefaultValue(viewConfig, "quant", true),
                    };
                return result;
            },
        });
    });
}, Logger);