From c49c35ca0fdd4d3972748a8846c0c71f50c80b16 Mon Sep 17 00:00:00 2001 From: Thomas Bruederli Date: Sat, 28 Sep 2013 12:03:20 +0200 Subject: Generate settings tabs with a template object 'settingstabs' and let plugins register themselves there using the 'settings_actions' hook --- skins/classic/functions.js | 4 ++-- skins/classic/includes/settingstabs.html | 6 ++---- skins/larry/includes/header.html | 2 +- skins/larry/includes/settingstabs.html | 4 +--- 4 files changed, 6 insertions(+), 10 deletions(-) (limited to 'skins') diff --git a/skins/classic/functions.js b/skins/classic/functions.js index af561c37b..4ad13136f 100644 --- a/skins/classic/functions.js +++ b/skins/classic/functions.js @@ -10,7 +10,7 @@ function rcube_init_settings_tabs() { var el, cl, container = $('#tabsbar'), last_tab = $('span:last', container), - tab = '#settingstabdefault', + tab = '#settingstabpreferences', action = window.rcmail && rcmail.env.action ? rcmail.env.action : null; // move About tab to the end @@ -22,7 +22,7 @@ function rcube_init_settings_tabs() // get selected tab if (action) - tab = '#settingstab' + (action == 'preferences' ? 'default' : (action.indexOf('identity')>0 ? 'identities' : action.replace(/\./g, ''))); + tab = '#settingstab' + (action.indexOf('identity')>0 ? 'identities' : action.replace(/\./g, '')); $(tab).addClass('tablink-selected'); $('a', tab).removeAttr('onclick').click(function() { return false; }); diff --git a/skins/classic/includes/settingstabs.html b/skins/classic/includes/settingstabs.html index 0aea80b67..a47db2274 100644 --- a/skins/classic/includes/settingstabs.html +++ b/skins/classic/includes/settingstabs.html @@ -1,8 +1,6 @@
- - - - + +
diff --git a/skins/larry/includes/header.html b/skins/larry/includes/header.html index 5a934d89b..69e8b8aa6 100644 --- a/skins/larry/includes/header.html +++ b/skins/larry/includes/header.html @@ -29,7 +29,7 @@ -