From 13863aaa99b87fce6089e37fb432ddc02d6b1fef Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Fri, 22 Mar 2013 17:23:10 +0100 Subject: [PATCH] [FIX] deferred problems when clicking too quickly on some menu items lp bug: https://launchpad.net/bugs/1100280 fixed bzr revid: nicolas.vanhoren@openerp.com-20130322162310-135hd0hoak8k5oq6 --- addons/web/static/src/js/view_list.js | 2 +- addons/web/static/src/js/views.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/web/static/src/js/view_list.js b/addons/web/static/src/js/view_list.js index b69ec6dbdca..3c89ef7126e 100644 --- a/addons/web/static/src/js/view_list.js +++ b/addons/web/static/src/js/view_list.js @@ -578,7 +578,7 @@ instance.web.ListView = instance.web.View.extend( /** @lends instance.web.ListVi this.no_leaf = !!context['group_by_no_leaf']; this.grouped = !!group_by; - return this.load_view(context).then( + return this.alive(this.load_view(context)).then( this.proxy('reload_content')); }, /** diff --git a/addons/web/static/src/js/views.js b/addons/web/static/src/js/views.js index befbc7fe793..0a7250397f7 100644 --- a/addons/web/static/src/js/views.js +++ b/addons/web/static/src/js/views.js @@ -1011,7 +1011,7 @@ instance.web.ViewManagerAction = instance.web.ViewManager.extend({ switch_mode: function (view_type, no_store, options) { var self = this; - return $.when(this._super.apply(this, arguments)).done(function () { + return this.alive($.when(this._super.apply(this, arguments))).done(function () { var controller = self.views[self.active_view].controller; self.$el.find('.oe_debug_view').html(QWeb.render('ViewManagerDebug', { view: controller,