[FIX] correct css computation to remove unnecessary toolbar
authorGéry Debongnie <ged@odoo.com>
Thu, 4 Sep 2014 10:11:40 +0000 (12:11 +0200)
committerGéry Debongnie <ged@odoo.com>
Thu, 4 Sep 2014 10:13:14 +0000 (12:13 +0200)
addons/mail/static/src/js/announcement.js

index 9cc1d8b..7afb25a 100644 (file)
@@ -36,11 +36,13 @@ openerp_announcement = function(instance) {
                             $('.openerp_webclient_container').css('height', 'calc(100% - 34px)');                            
                         }, 400);
                     };
+                    var height = $('#announcement_bar_table').outerHeight() 
+                                + $('#oe_main_menu_navbar').outerHeight();
+                    $('.openerp_webclient_container').css('height', 'calc(100% - ' + height + 'px)');
                     $bar.find('.close').on('click', close);
                     self.trigger('ab_loaded', $bar);
                 });
 
-                $('.openerp_webclient_container').css('height', 'calc(100% - 64px)');
                 $('head').append($css);
             }).fail(function(result, ev){
                 ev.preventDefault();