[IMP]Container added for tooltip.

bzr revid: bth@tinyerp.com-20131205064903-222sb09tcsy4x79u
This commit is contained in:
bth-openerp 2013-12-05 12:19:03 +05:30
parent 3fd24e1cb5
commit ff5cc4d5d3
5 changed files with 6 additions and 7 deletions

View File

@ -641,9 +641,6 @@
left: 12% !important;
margin-top: 0.5px;
}
.tooltip.bottom {
padding: 5px 0 !important;
}
.openerp .oe_notebook {
margin: 8px 0;
padding: 0 16px;

View File

@ -1262,7 +1262,7 @@ instance.web.Client = instance.web.Widget.extend({
bind_events: function() {
var self = this;
this.$el.on('mouseenter', '.oe_systray > div:not([data-toggle=tooltip])', function() {
$(this).attr('data-toggle', 'tooltip').tooltip({placement: 'bottom', html: true}).trigger('mouseenter');
$(this).attr('data-toggle', 'tooltip').tooltip({placement: 'bottom', html: true, container: 'body'}).trigger('mouseenter');
});
this.$el.on('click', '.oe_dropdown_toggle', function(ev) {
ev.preventDefault();

View File

@ -1159,6 +1159,7 @@ instance.web.Sidebar = instance.web.Widget.extend({
self.$("[title]").tooltip({
'html': true,
'container': 'body',
'delayIn': 500,
});
},

View File

@ -626,7 +626,7 @@ instance.web_kanban.KanbanGroup = instance.web.Widget.extend({
this.$records.data('widget', this);
this.$has_been_started.resolve();
var add_btn = this.$el.find('.oe_kanban_add');
add_btn.tooltip({delayIn: 500, delayOut: 1000});
add_btn.tooltip({html: true, container: 'body', delayIn: 500, delayOut: 1000});
this.$records.find(".oe_kanban_column_cards").click(function (ev) {
if (ev.target == ev.currentTarget) {
if (!self.state.folded) {
@ -666,7 +666,7 @@ instance.web_kanban.KanbanGroup = instance.web.Widget.extend({
return (new instance.web.Model(field.relation)).query([options.tooltip_on_group_by])
.filter([["id", "=", this.value]]).first().then(function(res) {
self.tooltip = res[options.tooltip_on_group_by];
self.$(".oe_kanban_group_title_text").attr("title", self.tooltip || self.title || "").tooltip({html: true, placement: 'bottom'});
self.$(".oe_kanban_group_title_text").attr("title", self.tooltip || self.title || "").tooltip({html: true, placement: 'bottom', container: 'body'});
});
}
},
@ -905,6 +905,7 @@ instance.web_kanban.KanbanRecord = instance.web.Widget.extend({
placement: 'bottom',
html: true,
opacity: 0.8,
container: 'body'
});
// If no draghandle is found, make the whole card as draghandle (provided one can edit)

View File

@ -27,7 +27,7 @@ instance.web_kanban.SparklineBarWidget = instance.web_kanban.AbstractField.exten
}
}, self.options);
self.$el.sparkline(value, sparkline_options);
self.$el.tooltip({'html': true, 'title': function(){return title}, 'placement': 'bottom'});
self.$el.tooltip({'html': true, 'title': function(){return title}, 'placement': 'bottom', 'container': 'body'});
}, 0);
},
});