/// class PD.Web.UI.Controls.ViewGridShowBoundsColumnsDialogCommand
/// using PD.Web.UI.Controls.ViewGridCommand

PD.Web.UI.Controls.ViewGridShowBoundsColumnsDialogCommand =
PD.Web.UI.Controls.ViewGridCommand.extend({

    //===================================
    // PUBLIC METHODS
    //===================================

    setDefaults: function () {
        this._super();
        this.props("id", "view-grid/bounds-columns-dialog");
        this.props("enabled", true);
        this.props("icon", "plus.14px.font"),
        this.props("label", "Bounds Columns...");
        this.props("tooltip", "Bounds Columns");
    },

    execute: function (e) {
        this._super(e);

        PDJS.Shared.Views.ColumnsDialog.open({
            viewStateId: this.get_viewStateId(),
            componentType: "bounds",
            select: {
                ok: () => {
                    this.get_viewGrid().build();
                }
            }
        });

    },

    //===================================
    // PRIVATE METHODS
    //===================================

    _isVisible: function () {
        return this.get_viewGrid().get_configuration().get_settings().isEditor;
    }

});