<commit_before>/*---------------------------------------------------------
 * OpenERP base library
 *---------------------------------------------------------*/

openerp.base.views = function(openerp) {

openerp.base.ActionManager = openerp.base.Controller.extend({
// process all kind of actions
    init: function(session, element_id) {
        this._super(session, element_id);
        this.viewmanager = null;
        // Temporary linking view_manager to session.
        // Will use controller_parent to find it when implementation will be done.
        session.view_manager = this;
    },
    /**
     * Process an action
     * Supported actions: act_window
     */
    do_action: function(action) {
        // instantiate the right controllers by understanding the action
        if(action.type == "ir.actions.act_window") {
            if (this.viewmanager) {
                this.viewmanager.stop();
            }
            this.viewmanager = new openerp.base.ViewManagerAction(this.session,this.element_id, action, true);
            this.viewmanager.start();
        }
    }
});

/**
 * Registry for all the main views
 */
openerp.base.views = new openerp.base.Registry();

openerp.base.ViewManager =  openerp.base.Controller.extend({
    init: function(session, element_id, dataset, views) {
        this._super(session, element_id);
        this.model = dataset.model;
        this.dataset = dataset;<commit_msg>[FIX] Fixed typo from last commit<commit_after>/*---------------------------------------------------------
 * OpenERP base library
 *---------------------------------------------------------*/

openerp.base.views = function(openerp) {

openerp.base.ActionManager = openerp.base.Controller.extend({
// process all kind of actions
    init: function(session, element_id) {
        this._super(session, element_id);
        this.viewmanager = null;
        // Temporary linking view_manager to session.
        // Will use controller_parent to find it when implementation will be done.
        session.action_manager = this;
    },
    /**
     * Process an action
     * Supported actions: act_window
     */
    do_action: function(action) {
        // instantiate the right controllers by understanding the action
        if(action.type == "ir.actions.act_window") {
            if (this.viewmanager) {
                this.viewmanager.stop();
            }
            this.viewmanager = new openerp.base.ViewManagerAction(this.session,this.element_id, action, true);
            this.viewmanager.start();
        }
    }
});

/**
 * Registry for all the main views
 */
openerp.base.views = new openerp.base.Registry();

openerp.base.ViewManager =  openerp.base.Controller.extend({
    init: function(session, element_id, dataset, views) {
        this._super(session, element_id);
        this.model = dataset.model;
        this.dataset = dataset;
{'fraction_non_alphanumeric': 0.1813759555246699, 'fraction_numerical': 0.0, 'mean_word_length': 1.943762781186094, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1537362', 'n_tokens_mistral': 772, 'n_tokens_neox': 752, 'n_words': 178}