mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-27 09:09:04 +01:00
Allow mouse over tooltip
This commit is contained in:
parent
d2e689d897
commit
41380c589f
@ -44,15 +44,32 @@ var et2_calendar_event = et2_valueWidget.extend([et2_IDetachedDOM],
|
|||||||
init: function() {
|
init: function() {
|
||||||
this._super.apply(this, arguments);
|
this._super.apply(this, arguments);
|
||||||
|
|
||||||
|
var event = this;
|
||||||
|
|
||||||
// Main container
|
// Main container
|
||||||
this.div = $j(document.createElement("div"))
|
this.div = $j(document.createElement("div"))
|
||||||
.addClass("calendar_calEvent")
|
.addClass("calendar_calEvent")
|
||||||
.addClass(this.options.class)
|
.addClass(this.options.class)
|
||||||
.css('width',this.options.width)
|
.css('width',this.options.width)
|
||||||
.on('mouseenter', function() {
|
.on('mouseenter', function() {
|
||||||
// Hacky to remove egw's tooltip border
|
// Hacky to remove egw's tooltip border and let the mouse in
|
||||||
window.setTimeout(function() {
|
window.setTimeout(function() {
|
||||||
$j('body .egw_tooltip').css('border','none');
|
$j('body .egw_tooltip')
|
||||||
|
.css('border','none')
|
||||||
|
.on('mouseenter', function() {
|
||||||
|
event.div.off('mouseleave.tooltip');
|
||||||
|
$j('body.egw_tooltip').remove();
|
||||||
|
$j('body').append(this);
|
||||||
|
$j(this).stop(true).fadeTo(400, 1)
|
||||||
|
.on('mouseleave', function() {
|
||||||
|
$j(this).fadeOut('400', function() {
|
||||||
|
$j(this).remove();
|
||||||
|
// Set up to work again
|
||||||
|
event.set_statustext(event._tooltip());
|
||||||
|
});
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
},105);
|
},105);
|
||||||
});
|
});
|
||||||
this.title = $j(document.createElement('div'))
|
this.title = $j(document.createElement('div'))
|
||||||
|
@ -634,14 +634,11 @@ var et2_calendar_timegrid = et2_valueWidget.extend([et2_IDetachedDOM, et2_IResiz
|
|||||||
.css('height', (this.options.height - this.gridHeader.outerHeight(true))+'px');
|
.css('height', (this.options.height - this.gridHeader.outerHeight(true))+'px');
|
||||||
|
|
||||||
var new_height = this.scrolling.height() / rowsToDisplay;
|
var new_height = this.scrolling.height() / rowsToDisplay;
|
||||||
if(new_height != this.rowHeight)
|
|
||||||
{
|
|
||||||
this.rowHeight = new_height;
|
this.rowHeight = new_height;
|
||||||
var rows = $j('.calendar_calTimeRow',this.scrolling).height(this.rowHeight);
|
var rows = $j('.calendar_calTimeRow',this.scrolling).height(this.rowHeight);
|
||||||
this.days.css('height', (this.rowHeight*rows.length)+'px');
|
this.days.css('height', (this.rowHeight*rows.length)+'px');
|
||||||
|
|
||||||
$j('.calendar_calAddEvent',this.scrolling).height(this.rowHeight);
|
$j('.calendar_calAddEvent',this.scrolling).height(this.rowHeight);
|
||||||
}
|
|
||||||
// Scroll to start of day
|
// Scroll to start of day
|
||||||
this._top_time = (wd_start * this.rowHeight) / this.options.granularity;
|
this._top_time = (wd_start * this.rowHeight) / this.options.granularity;
|
||||||
this.scrolling.scrollTop(this._top_time);
|
this.scrolling.scrollTop(this._top_time);
|
||||||
|
Loading…
Reference in New Issue
Block a user