define(["require", "exports", "./views-group", "./zoom-group", "./show-group", "../ribbon-base/ribbon-constants"], function (require, exports, views_group_1, zoom_group_1, show_group_1, ribbon_constants_1) {
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.VIEW_TAB_ID = '_view_tab';
var ViewTab = (function () {
function ViewTab(container) {
this.container = container;
this.viewsGroup = new views_group_1.ViewsGroup(container);
this.zoomGroup = new zoom_group_1.ZoomGroup(container);
this.showGroup = new show_group_1.ShowGroup(container);
}
ViewTab.prototype.getViewTab = function () {
return {
id: this.container.element.id + ribbon_constants_1.RIBBON_ID + exports.VIEW_TAB_ID,
header: this.container.localObj.getConstant('View'),
keyTip: 'W',
groups: [
this.viewsGroup.getGroupModel(),
this.zoomGroup.getGroupModel(),
this.showGroup.getGroupModel()
]
};
};
ViewTab.prototype.onSelectionChange = function () {
this.viewsGroup.updateSelection();
this.showGroup.updateSelection();
};
ViewTab.prototype.destroy = function () {
Eif (this.viewsGroup) {
this.viewsGroup.destroy();
}
Eif (this.zoomGroup) {
this.zoomGroup.destroy();
}
Eif (this.showGroup) {
this.showGroup.destroy();
}
this.viewsGroup = undefined;
this.zoomGroup = undefined;
this.showGroup = undefined;
this.container = undefined;
};
return ViewTab;
}());
exports.ViewTab = ViewTab;
});
|