]> www.vanbest.org Git - motioneye-debian/commitdiff
- Minor spacing fixes.
authorDermot Duffy <dermot.duffy@gmail.com>
Mon, 6 Jun 2016 20:11:03 +0000 (21:11 +0100)
committerDermot Duffy <dermot.duffy@gmail.com>
Mon, 6 Jun 2016 20:11:03 +0000 (21:11 +0100)
motioneye/handlers.py
motioneye/static/js/main.js

index 63b67fdda03091eaf9b47baf5531e243e9e1e1ce..549d8f4b79f727098e1853ba49600ddcbe1b82f9 100644 (file)
@@ -1397,12 +1397,12 @@ class MovieHandler(BaseHandler):
                 if error:
                     return self.finish_json({'error': 'Failed to download movie from %(url)s: %(msg)s.' % {
                             'url': remote.pretty_camera_url(camera_config), 'msg': error}})
-               # Copy certain critical headers out of the remote response and
-               # into our response. Propogating these headers are necessary to
-               # support in-brower playback of remote movies. Also copy the 
+                # Copy certain critical headers out of the remote response and
+                # into our response. Propogating these headers are necessary to
+                # support in-brower playback of remote movies. Also copy the 
                 # response code which might be 200 or 206 (partial content, for range
                 # requests).
-               self.set_status(response.code)
+                self.set_status(response.code)
                 for header in ('Content-Type', 'Content-Range', 'Content-Length', 'Content-Disposition'):
                     if header in response.headers:
                         self.set_header(header, response.headers[header])
index 8c45c815c64f59d07d87803e360826b3a604406b..fae95cc54371a1e005769e3d298a401e228ea104 100644 (file)
@@ -2965,18 +2965,18 @@ function runPictureDialog(entries, pos, mediaType) {
         img.attr('src', addAuthParams('GET', basePath + mediaType + '/' + entry.cameraId + '/preview' + entry.path));
 
         if (playable) {
-         playButton.on('click', function() {
-            video_source.attr('src', addAuthParams('GET', basePath + mediaType + '/' + entry.cameraId + '/download' + entry.path));
-            video_container.show();
-            video_container.get(0).load();  /* Must call load() after changing <video> source */
-            img.hide();
-            playButton.hide();
-            video_container.on('canplay', function() {
-              video_container.get(0).play();  /* Automatically play the video once the browser is ready */
+            playButton.on('click', function() {
+                video_source.attr('src', addAuthParams('GET', basePath + mediaType + '/' + entry.cameraId + '/download' + entry.path));
+                video_container.show();
+                video_container.get(0).load();  /* Must call load() after changing <video> source */
+                img.hide();
+                playButton.hide();
+                video_container.on('canplay', function() {
+                   video_container.get(0).play();  /* Automatically play the video once the browser is ready */
+                });
             });
-          });
 
-          playButton.show();
+            playButton.show();
         }
 
         img.load(function () {