From 3833c12ccce59bcc49c4cfa892401973558f604d Mon Sep 17 00:00:00 2001 From: Frederic Guillot Date: Mon, 2 Jan 2017 17:01:27 -0500 Subject: Refactoring/rewrite of modal boxes handling --- assets/js/src/Dropdown.js | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) (limited to 'assets/js/src/Dropdown.js') diff --git a/assets/js/src/Dropdown.js b/assets/js/src/Dropdown.js index d97b925e..ec033b3e 100644 --- a/assets/js/src/Dropdown.js +++ b/assets/js/src/Dropdown.js @@ -2,6 +2,7 @@ Kanboard.Dropdown = function(app) { this.app = app; }; +// TODO: rewrite this code Kanboard.Dropdown.prototype.listen = function() { var self = this; @@ -9,10 +10,6 @@ Kanboard.Dropdown.prototype.listen = function() { self.close(); }); - $(document).on('click', '#popover-content', function() { - self.close(); - }); - $(document).on('click', '.dropdown-menu', function(e) { e.preventDefault(); e.stopImmediatePropagation(); @@ -56,7 +53,3 @@ Kanboard.Dropdown.prototype.listen = function() { Kanboard.Dropdown.prototype.close = function() { $("#dropdown").remove(); }; - -Kanboard.Dropdown.prototype.onPopoverOpened = function() { - this.close(); -}; -- cgit v1.2.3