From 630e79ccb62dd0604ee32aed8b3fb239e0df20f2 Mon Sep 17 00:00:00 2001 From: Ruud Date: Tue, 6 Sep 2011 10:46:07 +0200 Subject: [PATCH] More directory selection fixes --- couchpotato/core/_base/_core/__init__.py | 7 +++--- couchpotato/static/scripts/page/settings.js | 9 ++++++++ couchpotato/static/style/page/settings.css | 24 +++++++++++++++------ 3 files changed, 30 insertions(+), 10 deletions(-) diff --git a/couchpotato/core/_base/_core/__init__.py b/couchpotato/core/_base/_core/__init__.py index 4bd909d4..4e14d69e 100644 --- a/couchpotato/core/_base/_core/__init__.py +++ b/couchpotato/core/_base/_core/__init__.py @@ -66,7 +66,8 @@ config = [{ { 'name': 'data_dir', 'label': 'Data dir', - 'description': 'Where cache/logs/etc are stored.', + 'type': 'directory', + 'description': 'Where cache/logs/etc are stored. Keep empty for ./_data.', }, { 'name': 'url_base', @@ -78,13 +79,13 @@ config = [{ 'name': 'permission_folder', 'default': 0755, 'label': 'Folder CHMOD', - 'description': 'Permission for creating/copying folders', + 'description': 'Permission (octal) for creating/copying folders.', }, { 'name': 'permission_file', 'default': 0755, 'label': 'File CHMOD', - 'description': 'Permission for creating/copying files', + 'description': 'Permission (octal) for creating/copying files', }, ], }, diff --git a/couchpotato/static/scripts/page/settings.js b/couchpotato/static/scripts/page/settings.js index ef8040bc..c1076330 100644 --- a/couchpotato/static/scripts/page/settings.js +++ b/couchpotato/static/scripts/page/settings.js @@ -549,6 +549,15 @@ Option.Directory = new Class({ } }), new Element('div.actions').adopt( + new Element('a.clear.button', { + 'text': 'Clear', + 'events': { + 'click': function(e){ + self.input.set('text', ''); + self.hideBrowser(e, true); + } + } + }), new Element('a.cancel', { 'text': 'Cancel', 'events': { diff --git a/couchpotato/static/style/page/settings.css b/couchpotato/static/style/page/settings.css index 940dca3e..ee0641ce 100644 --- a/couchpotato/static/style/page/settings.css +++ b/couchpotato/static/style/page/settings.css @@ -110,7 +110,7 @@ .page.settings .ctrlHolder .formHint { float: right; width: 47%; - margin: -25px 0; + margin: -18px 0; padding: 0; color: #fff; } @@ -219,9 +219,10 @@ } .page.settings .directory_list ul { - width: 100%; - height: 200px; + width: 92%; + height: 300px; overflow: auto; + margin: 0 4%; } .page.settings .directory_list li { @@ -241,15 +242,14 @@ .page.settings .directory_list .actions { clear: both; - padding: 10px; + padding: 4% 4% 2%; + min-height: 25px; } - - .page.settings .directory_list .actions {} .page.settings .directory_list .actions label { float: right; width: auto; - padding: 5px 3px; + padding: 0; } .page.settings .directory_list .actions .inlay { margin: -2px 0 0 7px; @@ -259,10 +259,14 @@ font-weight: bold; width: 160px; display: inline-block; + padding: 0; + line-height: 120%; + vertical-align: top; } .page.settings .directory_list .actions:last-child { float: right; + padding: 4%; } .page.settings .directory_list .actions:last-child > span { @@ -270,6 +274,12 @@ text-shadow: none; } + .page.settings .directory_list .actions:last-child > .clear { + left: -90%; + position: relative; + background-color: #af3128; +} + .page.settings .directory_list .actions:last-child > .cancel { font-weight: bold; color: #ddd;