def _start_cleanup():
import mediafiles
+ ioloop = tornado.ioloop.IOLoop.instance()
+
def do_cleanup():
- ioloop = tornado.ioloop.IOLoop.instance()
if ioloop._stopped:
return
ioloop.add_timeout(datetime.timedelta(seconds=settings.CLEANUP_INTERVAL), do_cleanup)
- do_cleanup()
+ ioloop.add_timeout(datetime.timedelta(seconds=settings.CLEANUP_INTERVAL), do_cleanup)
def _start_movie_thumbnailer():
import mediafiles
+ ioloop = tornado.ioloop.IOLoop.instance()
+
def do_next_movie_thumbail():
- ioloop = tornado.ioloop.IOLoop.instance()
if ioloop._stopped:
return
'msg': unicode(e)})
ioloop.add_timeout(datetime.timedelta(seconds=settings.MJPG_CLIENT_TIMEOUT), do_next_movie_thumbail)
-
- do_next_movie_thumbail()
+
+ ioloop.add_timeout(datetime.timedelta(seconds=settings.MJPG_CLIENT_TIMEOUT), do_next_movie_thumbail)
if __name__ == '__main__':
/* dialogs */
+
+table.add-camera-dialog {
+ margin: auto;
+}
table.add-camera-dialog select,
table.add-camera-dialog input[type=text],
div.media-dialog-groups {
text-align: center;
+ overflow: auto;
+ white-space: nowrap;
}
div.media-dialog-group-button {
runAlertDialog('motionEye was successfully updated!', function () {
window.location.reload(true);
});
- }, 2000);
+ }, 10000);
}
else {
runAlertDialog('Update failed!', function () {
var parts = path.split('/');
var keyParts = parts.splice(0, parts.length - 1);
var key = keyParts.join('/');
+
+ if (key.indexOf('/') === 0) {
+ key = key.substring(1);
+ }
+
var list = (groups[key] = groups[key] || []);
list.push({
mediaListDiv.html('');
-// var groupDiv = $('<div class="media-list-group-title">' + (key || '(ungrouped)') + '</div>');
-// dialogDiv.append(groupDiv);
-
var entries = groups[key];
entries.forEach(function (entry) {
mediaListDiv.append(entry.div);