diff --git a/couchpotato/core/plugins/movie/static/search.js b/couchpotato/core/plugins/movie/static/search.js index a94b3438..53a8d399 100644 --- a/couchpotato/core/plugins/movie/static/search.js +++ b/couchpotato/core/plugins/movie/static/search.js @@ -285,6 +285,8 @@ Block.Search.Item = new Class({ var self = this; (e).preventDefault(); + self.loadingMask(); + Api.request('movie.add', { 'data': { 'identifier': self.info.imdb, @@ -358,6 +360,25 @@ Block.Search.Item = new Class({ }, + loadingMask: function(){ + var self = this; + + var s = self.options.getSize(); + + self.mask = new Element('span.mask', { + 'styles': { + 'width': s.x, + 'height': s.y + } + }).inject(self.options).fade('hide').position({ + 'relativeTo': self.options + }) + + createSpinner(self.mask) + self.mask.fade('in') + + }, + toElement: function(){ return this.el }