5 ui.MenuButton = app.ui.Button.extend({
9 _baseCls: "uiButton uiMenuButton",
10 init: function(parent) {
12 this.menu = this.config.menu;
13 this.on("click", this.openMenu_handler);
14 this.menu.on("open", function() { this.el.addClass("active"); }.bind(this));
15 this.menu.on("close", function() { this.el.removeClass("active"); }.bind(this));
17 openMenu_handler: function(jEv) {
18 this.menu && this.menu.open(jEv);
22 })( this.jQuery, this.app );