<commit_before>goog.provide("hydra.Button");
goog.provide("hydra.ScrollPreventer");

goog.require("hydra.Sprite");
goog.require("hydra.dom");

/**
 * @constructor
 * @extends hydra.Sprite
 * @param {Element=} element
 */
hydra.Button = function (element) {
    goog.base(this, element);

    /**
     * @private
     * @type {boolean}
     */
    this.toggled = false;

    hydra.dom.addClass(this.element, "button");

    this.registerListener(this.element, "touchstart", this);
    this.registerListener(this.element, "touchend", this);
    this.registerListener(this.element, "touchcancel", this);
}
goog.inherits(hydra.Button, hydra.Sprite);

hydra.Button.prototype.onTap = function () { }

/**
 * @param {string} className
 * @return {hydra.Button}
 */
hydra.Button.div = function (className) {
    return new hydra.Button(hydra.dom.div(className));
}

/**
 * @param {boolean} t<commit_msg>Always inline this.<commit_after>goog.provide("hydra.Button");
goog.provide("hydra.ScrollPreventer");

goog.require("hydra.Sprite");
goog.require("hydra.dom");

/**
 * @constructor
 * @extends hydra.Sprite
 * @param {Element=} element
 */
hydra.Button = function (element) {
    goog.base(this, element);

    /**
     * @private
     * @type {boolean}
     */
    this.toggled = false;

    hydra.dom.addClass(this.element, "button");

    this.registerListener(this.element, "touchstart", this);
    this.registerListener(this.element, "touchend", this);
    this.registerListener(this.element, "touchcancel", this);
}
goog.inherits(hydra.Button, hydra.Sprite);

hydra.Button.prototype.onTap = function () { }

/**
 * @inline
 * @param {string} className
 * @return {hydra.Button}
 */
hydra.Button.div = function (className) {
    return new hydra.Button(hydra.dom.div(className));
}

/**
 * @param {boolean} t
{'fraction_non_alphanumeric': 0.17653569452130602, 'fraction_numerical': 0.0, 'mean_word_length': 4.008310249307479, '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': '4952807', 'n_tokens_mistral': 646, 'n_tokens_neox': 604, 'n_words': 100}