- init: function(element, model, template) {
- this.element = $(element);
- this.model = $(model).get(0);
- this.template = template || this.template;
- this.element.html(render_template(this.template, {}));
-
- this.model
- .addObserver(this, 'xml-freeze')
- .addObserver(this, 'xml-unfreeze');
+ init: function(element, model, parent, template) {
+ this._super(element, model, template);
+ this.parent = parent;
+ this.buttonToolbar = new ButtonToolbarView(
+ $('.xmlview-toolbar', this.element),
+ this.model.toolbarButtonsModel, parent);
+
+ $('.xmlview-toolbar', this.element).bind('resize.xmlview', this.resized.bind(this));