/// class PD.Manage.Modules.UsersToolbarSegment

PD.Manage.Modules.UsersToolbarSegment =
PD.Web.UI.Controls.ToolbarSegment.extend({

    //===================================
    // EVENT HANDLERS
    //===================================

    onRegisterItems: function (e) {

        e.registerItem(new PD.Web.UI.Controls.CommandButton({
            commandId: "pd/users:user/create-dialog"
        }));

        e.registerItem(new PD.Web.UI.Controls.CommandButton({
            commandId: "pd/users:user/edit-dialog"
        }));

        e.registerItem(new PD.Web.UI.Controls.CommandButton({
            commandId: "pd/users:user/delete"
        }));

        e.registerItem(new PD.Web.UI.Controls.CommandButton({
            commandId: "pd/users:user/bulk-edit"
        }));

        if (PD.ENVIRONMENT.AUTH_MODE !== "Windows") {
            return;
        }

        e.registerItem(new PD.Web.UI.Controls.CommandButton({
            commandId: "pd/users:sync/user"
        }));

        e.registerItem(new PD.Web.UI.Controls.CommandButton({
            commandId: "pd/users:sync/all-users"
        }));

    }

});