diff options
author | harish095 <kandalaharish95@gmail.com> | 2015-03-17 05:09:54 +0300 |
---|---|---|
committer | harish095 <kandalaharish95@gmail.com> | 2015-03-21 18:24:14 +0300 |
commit | ef5f956224d7c2bb8d44732ca0ee846e664f5724 (patch) | |
tree | 382f472514a61232661ee4f711540668414f7498 /js/console.js | |
parent | a48dca876d417d889e69a4e8f65958731018e619 (diff) |
Dark Theme for Console
Signed-off-by: Harish Kandala <kandalaharish95@gmail.com>
Diffstat (limited to 'js/console.js')
-rw-r--r-- | js/console.js | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/js/console.js b/js/console.js index 1df00038cf..c5e811fdb2 100644 --- a/js/console.js +++ b/js/console.js @@ -110,6 +110,10 @@ var PMA_console = { if(ConsoleEnterExecutes === true) { $('#pma_console_options input[name=enter_executes]').prop('checked', true); } + if(tempConfig.darkTheme === true) { + $('#pma_console_options input[name=dark_theme]').prop('checked', true); + $('#pma_console>.content').addClass('console_dark_theme'); + } } else { $('#pma_console_options input[name=current_query]').prop('checked', true); } @@ -171,6 +175,7 @@ var PMA_console = { $('#pma_console_options input[name=start_history]').prop('checked', false); $('#pma_console_options input[name=current_query]').prop('checked', true); $('#pma_console_options input[name=enter_executes]').prop('checked', false); + $('#pma_console_options input[name=dark_theme]').prop('checked', false); PMA_console.updateConfig(); }); @@ -398,9 +403,16 @@ var PMA_console = { alwaysExpand: $('#pma_console_options input[name=always_expand]').prop('checked'), startHistory: $('#pma_console_options input[name=start_history]').prop('checked'), currentQuery: $('#pma_console_options input[name=current_query]').prop('checked'), - enterExecutes: $('#pma_console_options input[name=enter_executes]').prop('checked') + enterExecutes: $('#pma_console_options input[name=enter_executes]').prop('checked'), + darkTheme: $('#pma_console_options input[name=dark_theme]').prop('checked') }; $.cookie('pma_console_config', JSON.stringify(PMA_console.config)); + /*Setting the dark theme of the console*/ + if(PMA_console.config.darkTheme) { + $('#pma_console>.content').addClass('console_dark_theme'); + } else { + $('#pma_console>.content').removeClass('console_dark_theme'); + } }, isSelect: function (queryString) { var reg_exp = /^SELECT\s+/i; |