4 * based on jquery fullcalendar
11 * @extends Roo.Component
12 * Bootstrap Calendar class
15 * Create a new Container
16 * @param {Object} config The config object
19 Roo.CalendarPanel = function(config){
21 Roo.log("cal panel ctr");
23 this.wrapper = Roo.DomHelper.append(document.body, // wrapper for IE7 strict & safari scroll issue
24 {tag: "div", cls: "x-layout-grid-wrapper x-layout-inactive-content"}, true);
26 //this.wrapper.dom.appendChild(grid.getGridEl().dom);
28 Roo.CalendarPanel.superclass.constructor.call(this, this.wrapper, config);
31 this.toolbar.el.insertBefore(this.wrapper.dom.firstChild);
33 // xtype created footer. - not sure if will work as we normally have to render first..
34 if (this.footer && !this.footer.el && this.footer.xtype) {
36 //this.footer.container = this.grid.getView().getFooterPanel(true);
37 //this.footer.dataSource = this.grid.dataSource;
38 //this.footer = Roo.factory(this.footer, Roo);
42 this.on('activate', function()
49 //console.log('render tree');
56 * Fires when a date is selected
57 * @param {DatePicker} this
58 * @param {Date} date The selected date
63 * Fires when the displayed month changes
64 * @param {DatePicker} this
65 * @param {Date} date The selected month
70 * Fires when mouse over an event
71 * @param {Calendar} this
72 * @param {event} Event
77 * Fires when the mouse leaves an
78 * @param {Calendar} this
84 * Fires when the mouse click an
85 * @param {Calendar} this
93 //this.grid.getGridEl().replaceClass("x-layout-inactive-content", "x-layout-component-panel");
96 Roo.extend(Roo.CalendarPanel, Roo.ContentPanel, {
101 setSize : function(width, height){
102 if(!this.ignoreResize(width, height)){
103 var grid = this.grid;
104 var size = this.adjustForComponents(width, height);
105 grid.getGridEl().setSize(size.width, size.height);
110 beforeSlide : function(){
111 this.grid.getView().scroller.clip();
114 afterSlide : function(){
115 this.grid.getView().scroller.unclip();
118 destroy : function(){
119 // this.grid.destroy();
121 Roo.GridPanel.superclass.destroy.call(this);
128 Roo.log("render calendar");