diff --git a/calendar/js/et2_widget_daycol.js b/calendar/js/et2_widget_daycol.js index 2dd5982d14..db688a97f2 100644 --- a/calendar/js/et2_widget_daycol.js +++ b/calendar/js/et2_widget_daycol.js @@ -1081,16 +1081,21 @@ var et2_calendar_daycol = (function(){ "use strict"; return et2_valueWidget.exte } // Header, all day non-blocking else if (this.header.has(_ev.target).length && !jQuery('.hiddenEventBefore',this.header).has(_ev.target).length || - this.header.is(_ev.target) + this.header.is(_ev.target) ) { // Click on the header, but not the title. That's an all-day non-blocking var end = this.date.getFullYear() + '-' + (this.date.getUTCMonth()+1) + '-' + this.date.getUTCDate() + 'T23:59'; - this.egw().open(null, 'calendar', 'add', { + var options = { start: this.date.toJSON(), end: end, non_blocking: true - } , '_blank'); + } + if (this.options.owner != app.calendar.state.owner) + { + options.owner = this.options.owner; + } + this.egw().open(null, 'calendar', 'add', options, '_blank'); return false; } } diff --git a/calendar/js/et2_widget_timegrid.js b/calendar/js/et2_widget_timegrid.js index 2b48c7e798..89987ccfb1 100644 --- a/calendar/js/et2_widget_timegrid.js +++ b/calendar/js/et2_widget_timegrid.js @@ -1864,6 +1864,8 @@ var et2_calendar_timegrid = (function(){ "use strict"; return et2_calendar_view. */ _mouse_down: function(event) { + if(event.which !== 1) return; + var start = jQuery.extend({},this.gridHover[0].dataset); if(start.date) { @@ -1993,6 +1995,10 @@ var et2_calendar_timegrid = (function(){ "use strict"; return et2_calendar_view. for(var id in this.gridHover[0].dataset) { delete this.gridHover[0].dataset[id]; } + if(this.options.granularity == 0) + { + this.gridHover.css('height',''); + } while(node && node != this.node && node.tagName != 'BODY' && path.length < 10) { path.push(node); @@ -2006,7 +2012,10 @@ var et2_calendar_timegrid = (function(){ "use strict"; return et2_calendar_view. position: 'absolute', top: '', bottom: '0px', - height: $node.css('padding-bottom') + // Use 100% height if we're hiding the day labels to avoid + // any remaining space from the hidden labels + height: $node.height() > parseInt($node.css('line-height')) ? + $node.css('padding-bottom') : '100%' }); day = node; this.gridHover