<commit_before>/* global $ */
var PanelToggler = require("../side_pannels/SidePanelToggler");

var buttonHandlers = {
    "bottom_toolbar_contact_list": function () {
        BottomToolbar.toggleContactList();
    },
    "bottom_toolbar_film_strip": function () {
        BottomToolbar.toggleFilmStrip();
    },
    "bottom_toolbar_chat": function () {
        BottomToolbar.toggleChat();
    }
};

var BottomToolbar = (function (my) {
    my.init = function () {
        for(var k in buttonHandlers)
            $("#" + k).click(buttonHandlers[k]);
    };

    my.toggleChat = function() {
        PanelToggler.toggleChat();
    };

    my.toggleContactList = function() {
        PanelToggler.toggleContactList();
    };

    my.toggleFilmStrip = function() {
        var filmstrip = $("#remoteVideos");
        filmstrip.toggleClass("hidden");
    };<commit_msg>Add analytics for bottom toolbar events<commit_after>/* global $ */
var PanelToggler = require("../side_pannels/SidePanelToggler");
var AnalyticsAdapter = require("../../statistics/AnalyticsAdapter");

var buttonHandlers = {
    "bottom_toolbar_contact_list": function () {
        AnalyticsAdapter.sendEvent('bottomtoolbar.contacts.toggled');
        BottomToolbar.toggleContactList();
    },
    "bottom_toolbar_film_strip": function () {
        AnalyticsAdapter.sendEvent('bottomtoolbar.filmstrip.toggled');
        BottomToolbar.toggleFilmStrip();
    },
    "bottom_toolbar_chat": function () {
        AnalyticsAdapter.sendEvent('bottomtoolbar.chat.toggled');
        BottomToolbar.toggleChat();
    }
};

var BottomToolbar = (function (my) {
    my.init = function () {
        for(var k in buttonHandlers)
            $("#" + k).click(buttonHandlers[k]);
    };

    my.toggleChat = function() {
        PanelToggler.toggleChat();
    };

    my.toggleContactList = function() {
        PanelToggler.toggleContactList();
    };

    my.toggleFilmStrip = function() {
        var filmstrip = $("#remoteVideos");
        filmstrip.toggleClass("hidden");
    };
{'fraction_non_alphanumeric': 0.14320866141732283, 'fraction_numerical': 0.0, 'mean_word_length': 3.0417495029821073, 'pattern_counts': {'":': 6, '<': 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': '6596109', 'n_tokens_mistral': 601, 'n_tokens_neox': 592, 'n_words': 89}