re-factored code into a generic class-tabbed-settings.php for better reuse.