<commit_before>Z.Label.include(/** @lends maptalks.Label.prototype */{
    /**
     * Start to edit the label text
     * @return {maptalks.Label} this
     */
    startEditText: function() {
        if (!this.getMap()) {
            return;
        }
        this.hide();
        this.endEditText();
        this._prepareEditor();
        this.fire('edittextstart', this);
        return this;
    },

    /**
     * End label text edit.
     * @return {maptalks.Label} this
     */
    endEditText: function() {
        if(this._textEditor) {
            this.getMap().off('click', this.endEditText, this);
            var content = this._textEditor.innerText;
            this.setContent(content);
            this.show();
            Z.DomUtil.off(this._textEditor, 'mousedown dblclick', Z.DomUtil.stopPropagation)
                .off(this._textEditor, 'blur', this.endEditText, this);
            Z.DomUtil.removeDomNode(this._container);
            delete this._container;
            delete this._textEditor;
            this.fire('edittextend', this);
        }
        return this;
    },

    /**
     * Whether the label is being edited text.
     * @return {Boolean}
     */
    isEditingText: function () {
        if (this._container) {
            return true;
        }
        return false;
    },

    getEditor: function() {
        return this._textEditor;
    },<commit_msg>remove unused codes in Label.Edit<commit_after>Z.Label.include(/** @lends maptalks.Label.prototype */{
    /**
     * Start to edit the label text
     * @return {maptalks.Label} this
     */
    startEditText: function() {
        if (!this.getMap()) {
            return;
        }
        this.hide();
        this.endEditText();
        this._prepareEditor();
        this.fire('edittextstart', this);
        return this;
    },

    /**
     * End label text edit.
     * @return {maptalks.Label} this
     */
    endEditText: function() {
        if(this._textEditor) {
            var content = this._textEditor.innerText;
            this.setContent(content);
            this.show();
            Z.DomUtil.off(this._textEditor, 'mousedown dblclick', Z.DomUtil.stopPropagation)
                .off(this._textEditor, 'blur', this.endEditText, this);
            Z.DomUtil.removeDomNode(this._container);
            delete this._container;
            delete this._textEditor;
            this.fire('edittextend', this);
        }
        return this;
    },

    /**
     * Whether the label is being edited text.
     * @return {Boolean}
     */
    isEditingText: function () {
        if (this._container) {
            return true;
        }
        return false;
    },

    getEditor: function() {
        return this._textEditor;
    },
{'fraction_non_alphanumeric': 0.12690909090909092, 'fraction_numerical': 0.0, 'mean_word_length': 1.7565130260521042, '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': '5088287', 'n_tokens_mistral': 804, 'n_tokens_neox': 793, 'n_words': 161}