diff --git a/sickbeard/__init__.py b/sickbeard/__init__.py index 0d7feb97..4936673c 100755 --- a/sickbeard/__init__.py +++ b/sickbeard/__init__.py @@ -426,6 +426,7 @@ DATE_PRESET = None TIME_PRESET = None TIME_PRESET_W_SECONDS = None TIMEZONE_DISPLAY = None +THEME_NAME = None USE_SUBTITLES = False SUBTITLES_LANGUAGES = [] @@ -494,7 +495,7 @@ def initialize(consoleLogging=True): USE_EMAIL, EMAIL_HOST, EMAIL_PORT, EMAIL_TLS, EMAIL_USER, EMAIL_PASSWORD, EMAIL_FROM, EMAIL_NOTIFY_ONSNATCH, EMAIL_NOTIFY_ONDOWNLOAD, EMAIL_NOTIFY_ONSUBTITLEDOWNLOAD, EMAIL_LIST, \ USE_LISTVIEW, METADATA_XBMC, METADATA_XBMC_12PLUS, METADATA_MEDIABROWSER, METADATA_PS3, metadata_provider_dict, \ NEWZBIN, NEWZBIN_USERNAME, NEWZBIN_PASSWORD, GIT_PATH, MOVE_ASSOCIATED_FILES, POSTPONE_IF_SYNC_FILES, dailySearchScheduler, NFO_RENAME, \ - GUI_NAME, HOME_LAYOUT, HISTORY_LAYOUT, DISPLAY_SHOW_SPECIALS, COMING_EPS_LAYOUT, COMING_EPS_SORT, COMING_EPS_DISPLAY_PAUSED, COMING_EPS_MISSED_RANGE, FUZZY_DATING, TRIM_ZERO, DATE_PRESET, TIME_PRESET, TIME_PRESET_W_SECONDS, \ + GUI_NAME, HOME_LAYOUT, HISTORY_LAYOUT, DISPLAY_SHOW_SPECIALS, COMING_EPS_LAYOUT, COMING_EPS_SORT, COMING_EPS_DISPLAY_PAUSED, COMING_EPS_MISSED_RANGE, FUZZY_DATING, TRIM_ZERO, DATE_PRESET, TIME_PRESET, TIME_PRESET_W_SECONDS, THEME_NAME, \ METADATA_WDTV, METADATA_TIVO, METADATA_MEDE8ER, IGNORE_WORDS, REQUIRE_WORDS, CALENDAR_UNPROTECTED, CREATE_MISSING_SHOW_DIRS, \ ADD_SHOWS_WO_DIR, USE_SUBTITLES, SUBTITLES_LANGUAGES, SUBTITLES_DIR, SUBTITLES_SERVICES_LIST, SUBTITLES_SERVICES_ENABLED, SUBTITLES_HISTORY, SUBTITLES_FINDER_FREQUENCY, subtitlesFinderScheduler, \ USE_FAILED_DOWNLOADS, DELETE_FAILED, ANON_REDIRECT, LOCALHOST_IP, TMDB_API_KEY, DEBUG, PROXY_SETTING, \ @@ -559,6 +560,8 @@ def initialize(consoleLogging=True): GUI_NAME = check_setting_str(CFG, 'GUI', 'gui_name', 'slick') + THEME_NAME = check_setting_str(CFG, 'GUI', 'theme_name', 'dark') + ACTUAL_LOG_DIR = check_setting_str(CFG, 'General', 'log_dir', 'Logs') # put the log dir inside the data dir, unless an absolute path LOG_DIR = os.path.normpath(os.path.join(DATA_DIR, ACTUAL_LOG_DIR)) @@ -1765,6 +1768,7 @@ def save_config(): new_config['GUI'] = {} new_config['GUI']['gui_name'] = GUI_NAME + new_config['GUI']['theme_name'] = THEME_NAME new_config['GUI']['home_layout'] = HOME_LAYOUT new_config['GUI']['history_layout'] = HISTORY_LAYOUT new_config['GUI']['display_show_specials'] = int(DISPLAY_SHOW_SPECIALS) diff --git a/sickbeard/webserve.py b/sickbeard/webserve.py index 62c7ef24..6986236f 100644 --- a/sickbeard/webserve.py +++ b/sickbeard/webserve.py @@ -1487,7 +1487,7 @@ class ConfigGeneral(MainHandler): handle_reverse_proxy=None, sort_article=None, auto_update=None, notify_on_update=None, proxy_setting=None, anon_redirect=None, git_path=None, calendar_unprotected=None, fuzzy_dating=None, trim_zero=None, date_preset=None, date_preset_na=None, time_preset=None, - indexer_timeout=None, play_videos=None, rootDir=None, use_imdbwl=None, imdbWatchlistCsv=None): + indexer_timeout=None, play_videos=None, rootDir=None, use_imdbwl=None, imdbWatchlistCsv=None, theme_name=None): results = [] @@ -1555,6 +1555,8 @@ class ConfigGeneral(MainHandler): sickbeard.HANDLE_REVERSE_PROXY = config.checkbox_to_value(handle_reverse_proxy) + sickbeard.THEME_NAME = theme_name + sickbeard.save_config() if len(results) > 0: