]> www.vanbest.org Git - motioneye-debian/commitdiff
removed reboot button as it's pointless
authorCalin Crisan <ccrisan@gmail.com>
Sat, 27 Sep 2014 08:34:38 +0000 (11:34 +0300)
committerCalin Crisan <ccrisan@gmail.com>
Sat, 27 Sep 2014 08:37:47 +0000 (11:37 +0300)
src/handlers.py
src/server.py
static/css/main.css
static/js/main.js
templates/main.html

index f01f2532cad63742f5a0f44bc31c8ab18ca7d257..f65ce0c960db983b63acc3746eb131f8f88dddab 100644 (file)
@@ -956,9 +956,6 @@ class PowerHandler(BaseHandler):
     def post(self, op):
         if op == 'shutdown':
             powerctl.shut_down()
-            
-        elif op == 'reboot':
-            powerctl.reboot()
 
 
 class VersionHandler(BaseHandler):
index ec35fbbeefbdadbe1d6c62ff32abdb01a010e30d..8df6d92091fd50162d007320a4b7763232fb2b99 100644 (file)
@@ -49,7 +49,7 @@ application = Application(
         (r'^/movie/(?P<camera_id>\d+)/(?P<op>list)/?$', handlers.MovieHandler),
         (r'^/movie/(?P<camera_id>\d+)/(?P<op>download|preview)/(?P<filename>.+)/?$', handlers.MovieHandler),
         (r'^/update/?$', handlers.UpdateHandler),
-        (r'^/power/(?P<op>shutdown|reboot)/?$', handlers.PowerHandler),
+        (r'^/power/(?P<op>shutdown)/?$', handlers.PowerHandler),
         (r'^/version/?$', handlers.VersionHandler),
         (r'^.*$', handlers.NotFoundHandler),
     ],
index abe2a14e96af2a0001868a677ae4e8043d6f0c02..e1e43ef4cc2e391e96395d3b6bd4907e55a932a6 100644 (file)
@@ -339,31 +339,24 @@ img.apply-progress {
 }
 
 div.update-button,
-div.shut-down-button,
-div.reboot-button {
+div.shut-down-button {
     position: relative;
     height: 1.5em;
     line-height: 1.5em;
     text-align: center;
     margin: 2px 0px;
     color: white;
-    font-size: 1em;
+    font-size: 0.9em;
     border-radius: 3px;
     transition: all 0.1s linear;
+    width: 7em;
 }
 
 div.update-button {
-    width: 4em;
     background: #317CAD;
 }
 
 div.shut-down-button {
-    width: 8em;
-    background: #c0392b;
-}
-
-div.reboot-button {
-    width: 8em;
     background: #c0392b;
 }
 
@@ -375,10 +368,6 @@ div.shut-down-button:HOVER {
     background: #D43F2F;
 }
 
-div.reboot-button:HOVER {
-    background: #D43F2F;
-}
-
 div.update-button:ACTIVE {
     background: #317CAD;
 }
@@ -387,10 +376,6 @@ div.shut-down-button:ACTIVE {
     background: #B03427;
 }
 
-div.reboot-button:ACTIVE {
-    background: #B03427;
-}
-
 div.settings-top-bar.open #cameraSelect {
     display: inline;
 }
index 950ce126bd853f2ae138994f54686d4626b2f1b7..441efa9a2336fbc4ab9a93155eccdcaa6be5dd7d 100644 (file)
@@ -371,11 +371,6 @@ function initUI() {
         doShutDown();
     });
     
-    /* reboot button */
-    $('#rebootButton').click(function () {
-        doReboot();
-    });
-    
     /* whenever the window is resized,
      * if a modal dialog is visible, it should be repositioned */
     $(window).resize(updateModalDialogPosition);
@@ -1229,12 +1224,6 @@ function doShutDown() {
     });
 }
 
-function doReboot() {
-    runConfirmDialog('Really reboot?', function () {
-        ajax('POST', '/power/reboot/');
-    });
-}
-
 function doRemCamera() {
     if (Object.keys(pushConfigs).length) {
         return runAlertDialog('Please apply the modified settings first!');
index 9f5d3ee3a1dbcd5868149256ccb6f6f1e8a3a1f8..035c93261760d5679736a09e7b80f171b0feb049 100644 (file)
                         <td class="settings-item-value"><div class="button shut-down-button" id="shutDownButton">Shut Down</div></td>
                         <td><span class="help-mark" title="shuts down the system">?</span></td>
                     </tr>
-                    <tr class="settings-item advanced-setting{% if not enable_reboot %} hidden{% endif %}">
-                        <td class="settings-item-label"></td>
-                        <td class="settings-item-value"><div class="button reboot-button" id="rebootButton">Reboot</div></td>
-                        <td><span class="help-mark" title="reboots the system">?</span></td>
-                    </tr>
                 </table>
                 
                 <div class="settings-section-title advanced-setting{% if not wpa_supplicant %} hidden{% endif %}"><input type="checkbox" class="styled section wifi" id="wifiSwitch">Wireless Network</div>