diff options
author | Dries Buytaert <dries@buytaert.net> | 2009-07-31 11:20:43 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2009-07-31 11:20:43 +0000 |
commit | 9f44fd1b86fdcc412a0ce7b2d3d2048e8564a979 (patch) | |
tree | c1b88928743e476c3f0ca18410c6682c1c373627 | |
parent | 9e0e109d1d498521aa606567bfe628e55a75d912 (diff) | |
download | brdo-9f44fd1b86fdcc412a0ce7b2d3d2048e8564a979.tar.gz brdo-9f44fd1b86fdcc412a0ce7b2d3d2048e8564a979.tar.bz2 |
- Patch #536440 by Gábor Hojtsy: the attached patch moves the Structure >> Themes section to the top level Appearance item as outlined in the D7UX IA.
-rw-r--r-- | modules/block/block.test | 6 | ||||
-rw-r--r-- | modules/color/color.module | 2 | ||||
-rw-r--r-- | modules/help/help.module | 2 | ||||
-rw-r--r-- | modules/system/system.admin.inc | 4 | ||||
-rw-r--r-- | modules/system/system.css | 2 | ||||
-rw-r--r-- | modules/system/system.module | 25 | ||||
-rw-r--r-- | modules/system/system.test | 6 | ||||
-rw-r--r-- | modules/update/update.compare.inc | 2 | ||||
-rw-r--r-- | modules/update/update.module | 2 |
9 files changed, 25 insertions, 26 deletions
diff --git a/modules/block/block.test b/modules/block/block.test index 6459fc663..d32f7f2aa 100644 --- a/modules/block/block.test +++ b/modules/block/block.test @@ -217,7 +217,7 @@ class NonDefaultBlockAdmin extends DrupalWebTestCase { function testNonDefaultBlockAdmin() { $admin_user = $this->drupalCreateUser(array('administer blocks', 'administer site configuration')); $this->drupalLogin($admin_user); - $this->drupalPost('admin/structure/themes', array('status[stark]' => 1), t('Save configuration')); + $this->drupalPost('admin/appearance', array('status[stark]' => 1), t('Save configuration')); $this->drupalGet('admin/structure/block/list/stark'); $this->assertRaw('stark/layout.css', t('Stark CSS found')); } @@ -258,7 +258,7 @@ class NewDefaultThemeBlocks extends DrupalWebTestCase { // Turn on the Stark theme and ensure that it contains all of the blocks // that Garland did. - $this->drupalPost('admin/structure/themes', array('theme_default' => 'stark'), t('Save configuration')); + $this->drupalPost('admin/appearance', array('theme_default' => 'stark'), t('Save configuration')); $result = db_query("SELECT * FROM {block} WHERE theme='stark'"); foreach ($result as $block) { unset($block->theme, $block->bid); @@ -293,7 +293,7 @@ class BlockAdminThemeTestCase extends DrupalWebTestCase { // Enable admin theme and confirm that tab is accessible. $edit['admin_theme'] = 'stark'; - $this->drupalPost('admin/structure/themes', $edit, t('Save configuration')); + $this->drupalPost('admin/appearance', $edit, t('Save configuration')); $this->drupalGet('admin/structure/block/list/stark'); $this->assertResponse(200, t('The block admin page for the admin theme can be accessed')); } diff --git a/modules/color/color.module b/modules/color/color.module index db7db4843..dab080f39 100644 --- a/modules/color/color.module +++ b/modules/color/color.module @@ -9,7 +9,7 @@ function color_help($path, $arg) { case 'admin/help#color': $output = '<p>' . t('The color module allows a site administrator to quickly and easily change the color scheme of certain themes. Although not all themes support color module, both Garland (the default theme) and Minnelli were designed to take advantage of its features. By using color module with a compatible theme, you can easily change the color of links, backgrounds, text, and other theme elements. Color module requires that your <a href="@url">file download method</a> be set to public.', array('@url' => url('admin/settings/file-system'))) . '</p>'; $output .= '<p>' . t("It is important to remember that color module saves a modified copy of the theme's specified stylesheets in the files directory. This means that if you make any manual changes to your theme's stylesheet, you must save your color settings again, even if they haven't changed. This causes the color module generated version of the stylesheets in the files directory to be recreated using the new version of the original file.") . '</p>'; - $output .= '<p>' . t('To change the color settings for a compatible theme, select the "configure" link for the theme on the <a href="@themes">themes administration page</a>.', array('@themes' => url('admin/structure/themes'))) . '</p>'; + $output .= '<p>' . t('To change the color settings for a compatible theme, select the "configure" link for the theme on the <a href="@themes">themes administration page</a>.', array('@themes' => url('admin/appearance'))) . '</p>'; $output .= '<p>' . t('For more information, see the online handbook entry for <a href="@color">Color module</a>.', array('@color' => 'http://drupal.org/handbook/modules/color/')) . '</p>'; return $output; diff --git a/modules/help/help.module b/modules/help/help.module index 6efc1e1b0..c925d5be1 100644 --- a/modules/help/help.module +++ b/modules/help/help.module @@ -40,7 +40,7 @@ function help_help($path, $arg) { $output .= '<ol>'; $output .= '<li>' . t('<strong>Configure your website</strong> Once logged in, visit the <a href="@admin">administration section</a>, where you can <a href="@config">customize and configure</a> all aspects of your website.', array('@admin' => url('admin'), '@config' => url('admin/settings'))) . '</li>'; $output .= '<li>' . t('<strong>Enable additional functionality</strong> Next, visit the <a href="@modules">module list</a> and enable features which suit your specific needs. You can find additional modules in the <a href="@download_modules">Drupal modules download section</a>.', array('@modules' => url('admin/structure/modules'), '@download_modules' => 'http://drupal.org/project/modules')) . '</li>'; - $output .= '<li>' . t('<strong>Customize your website design</strong> To change the "look and feel" of your website, visit the <a href="@themes">themes section</a>. You may choose from one of the included themes or download additional themes from the <a href="@download_themes">Drupal themes download section</a>.', array('@themes' => url('admin/structure/themes'), '@download_themes' => 'http://drupal.org/project/themes')) . '</li>'; + $output .= '<li>' . t('<strong>Customize your website design</strong> To change the "look and feel" of your website, visit the <a href="@themes">themes section</a>. You may choose from one of the included themes or download additional themes from the <a href="@download_themes">Drupal themes download section</a>.', array('@themes' => url('admin/appearance'), '@download_themes' => 'http://drupal.org/project/themes')) . '</li>'; $output .= '<li>' . t('<strong>Start posting content</strong> Finally, you can <a href="@content">add new content</a> for your website.', array('@content' => url('node/add'))) . '</li>'; $output .= '</ol>'; $output .= '<p>' . t('For more information, please refer to the specific topics listed in the next section, or the <a href="@handbook">online Drupal handbooks</a>. You may also post at the <a href="@forum">Drupal forum</a>, or view the wide range of <a href="@support">other support options</a> available.', array('@help' => url('admin/help'), '@handbook' => 'http://drupal.org/handbooks', '@forum' => 'http://drupal.org/forum', '@support' => 'http://drupal.org/support')) . '</p>'; diff --git a/modules/system/system.admin.inc b/modules/system/system.admin.inc index 2b569dee4..e62799808 100644 --- a/modules/system/system.admin.inc +++ b/modules/system/system.admin.inc @@ -167,7 +167,7 @@ function system_themes_form() { $options[$theme->name] = $theme->info['name']; if (!empty($theme->status) || $theme->name == variable_get('admin_theme', 0)) { - $form[$theme->name]['operations'] = array('#markup' => l(t('configure'), 'admin/structure/themes/settings/' . $theme->name) ); + $form[$theme->name]['operations'] = array('#markup' => l(t('configure'), 'admin/appearance/settings/' . $theme->name) ); } else { // Dummy element for drupal_render. Cleaner than adding a check in the theme function. @@ -293,7 +293,7 @@ function system_themes_form_submit($form, &$form_state) { menu_rebuild(); drupal_theme_rebuild(); drupal_set_message(t('The configuration options have been saved.')); - $form_state['redirect'] = 'admin/structure/themes'; + $form_state['redirect'] = 'admin/appearance'; // Notify locale module about new themes being enabled, so translations can // be imported. This might start a batch, and only return to the redirect diff --git a/modules/system/system.css b/modules/system/system.css index beaf2503b..81f625f86 100644 --- a/modules/system/system.css +++ b/modules/system/system.css @@ -512,7 +512,7 @@ html.js .js-hide { } /* -** Styles for the system themes page (admin/structure/themes) +** Styles for the system themes page (admin/appearance) */ #system-themes-form div.incompatible { font-weight: bold; diff --git a/modules/system/system.module b/modules/system/system.module index 1fb124faa..05a68fb3d 100644 --- a/modules/system/system.module +++ b/modules/system/system.module @@ -93,7 +93,7 @@ function system_help($path, $arg) { $output = '<p>' . t('The system module is at the foundation of your Drupal website, and provides basic but extensible functionality for use by other modules and themes. Some integral elements of Drupal are contained in and managed by the system module, including caching, enabling or disabling of modules and themes, preparing and displaying the administrative page, and configuring fundamental site settings. A number of key system maintenance operations are also part of the system module.') . '</p>'; $output .= '<p>' . t('The system module provides:') . '</p>'; $output .= '<ul><li>' . t('support for enabling and disabling <a href="@modules">modules</a>. Drupal comes packaged with a number of core modules; each module provides a discrete set of features and may be enabled depending on the needs of your site. A wide array of additional modules contributed by members of the Drupal community are available for download at the <a href="@drupal-modules">Drupal.org module page</a>.', array('@modules' => url('admin/structure/modules'), '@drupal-modules' => 'http://drupal.org/project/modules')) . '</li>'; - $output .= '<li>' . t('support for enabling and disabling <a href="@themes">themes</a>, which determine the design and presentation of your site. Drupal comes packaged with several core themes and additional contributed themes are available at the <a href="@drupal-themes">Drupal.org theme page</a>.', array('@themes' => url('admin/structure/themes'), '@drupal-themes' => 'http://drupal.org/project/themes')) . '</li>'; + $output .= '<li>' . t('support for enabling and disabling <a href="@themes">themes</a>, which determine the design and presentation of your site. Drupal comes packaged with several core themes and additional contributed themes are available at the <a href="@drupal-themes">Drupal.org theme page</a>.', array('@themes' => url('admin/appearance'), '@drupal-themes' => 'http://drupal.org/project/themes')) . '</li>'; $output .= '<li>' . t('a robust <a href="@cache-settings">caching system</a> that allows the efficient re-use of previously-constructed web pages and web page components. Drupal stores the pages requested by anonymous users in a compressed format; depending on your site configuration and the amount of your web traffic tied to anonymous visitors, Drupal\'s caching system may significantly increase the speed of your site.', array('@cache-settings' => url('admin/settings/performance'))) . '</li>'; $output .= '<li>' . t('a set of routine administrative operations that rely on a correctly-configured <a href="@cron">cron maintenance task</a> to run automatically. A number of other modules, including the feed aggregator, and search also rely on <a href="@cron">cron maintenance tasks</a>. For more information, see the online handbook entry for <a href="@handbook">configuring cron jobs</a>.', array('@cron' => url('admin/reports/status'), '@handbook' => 'http://drupal.org/cron')) . '</li>'; $output .= '<li>' . t('basic configuration options for your site, including <a href="@regional-settings">date and time settings</a>, <a href="@file-system">file system settings</a>, <a href="@clean-url">clean URL support</a>, <a href="@site-info">site name and other information</a>, and a <a href="@maintenance-mode">maintenance mode</a> for taking your site temporarily offline.', array('@regional-settings' => url('admin/settings/regional-settings'), '@file-system' => url('admin/settings/file-system'), '@clean-url' => url('admin/settings/clean-urls'), '@site-info' => url('admin/settings/site-information'), '@maintenance-mode' => url('admin/settings/maintenance-mode'))) . '</li></ul>'; @@ -101,15 +101,15 @@ function system_help($path, $arg) { return $output; case 'admin/by-module': return '<p>' . t('This page shows you all available administration tasks for each module.') . '</p>'; - case 'admin/structure/themes': + case 'admin/appearance': $output = '<p>' . t('Select which themes are available to your users and specify the default theme. To configure site-wide display settings, click the "configure" task above. Alternatively, to override these settings in a specific theme, click the "configure" link for that theme. Note that different themes may have different regions available for displaying content; for consistency in presentation, you may wish to enable only one theme.') . '</p>'; $output .= '<p>' . t('To change the appearance of your site, a number of <a href="@themes">contributed themes</a> are available.', array('@themes' => 'http://drupal.org/project/themes')) . '</p>'; return $output; - case 'admin/structure/themes/settings/' . $arg[4]: + case 'admin/appearance/settings/' . $arg[4]: $reference = explode('.', $arg[4], 2); $theme = array_pop($reference); - return '<p>' . t('These options control the display settings for the <code>%template</code> theme. When your site is displayed using this theme, these settings will be used. By clicking "Reset to defaults," you can choose to use the <a href="@global">global settings</a> for this theme.', array('%template' => $theme, '@global' => url('admin/structure/themes/settings'))) . '</p>'; - case 'admin/structure/themes/settings': + return '<p>' . t('These options control the display settings for the <code>%template</code> theme. When your site is displayed using this theme, these settings will be used. By clicking "Reset to defaults," you can choose to use the <a href="@global">global settings</a> for this theme.', array('%template' => $theme, '@global' => url('admin/appearance/settings'))) . '</p>'; + case 'admin/appearance/settings': return '<p>' . t('These options control the default display settings for your entire site, across all themes. Unless they have been overridden by a specific theme, these settings will be used.') . '</p>'; case 'admin/structure/modules': $output = '<p>' . t('Modules are plugins that extend Drupal\'s core functionality. To further extend your site\'s functionality, a number of <a href="@modules">contributed modules</a> are available for download.', array('@permissions' => url('admin/user/permissions'), '@modules' => 'http://drupal.org/project/modules')) . '</p>'; @@ -538,35 +538,34 @@ function system_menu() { 'access callback' => 'system_admin_menu_block_access', 'access arguments' => array('admin/structure', 'access administration pages'), ); - // Themes. - $items['admin/structure/themes'] = array( - 'title' => 'Themes', - 'description' => 'Change which theme your site uses or allows users to set.', + // Appearance. + $items['admin/appearance'] = array( + 'title' => 'Appearance', 'page callback' => 'drupal_get_form', 'page arguments' => array('system_themes_form'), 'access arguments' => array('administer site configuration'), ); - $items['admin/structure/themes/select'] = array( + $items['admin/appearance/select'] = array( 'title' => 'List', 'description' => 'Select the default theme for your site.', 'type' => MENU_DEFAULT_LOCAL_TASK, 'weight' => -1, ); - $items['admin/structure/themes/settings'] = array( + $items['admin/appearance/settings'] = array( 'title' => 'Configure', 'page arguments' => array('system_theme_settings'), 'access arguments' => array('administer site configuration'), 'type' => MENU_LOCAL_TASK, ); // Theme configuration subtabs. - $items['admin/structure/themes/settings/global'] = array( + $items['admin/appearance/settings/global'] = array( 'title' => 'Global settings', 'type' => MENU_DEFAULT_LOCAL_TASK, 'weight' => -1, ); foreach (list_themes() as $theme) { - $items['admin/structure/themes/settings/' . $theme->name] = array( + $items['admin/appearance/settings/' . $theme->name] = array( 'title' => $theme->info['name'], 'page arguments' => array('system_theme_settings', $theme->name), 'type' => MENU_LOCAL_TASK, diff --git a/modules/system/system.test b/modules/system/system.test index f037f73d6..48526c735 100644 --- a/modules/system/system.test +++ b/modules/system/system.test @@ -919,7 +919,7 @@ class SystemThemeFunctionalTest extends DrupalWebTestCase { 'admin_theme' => 'garland', 'node_admin_theme' => TRUE, ); - $this->drupalPost('admin/structure/themes', $edit, t('Save configuration')); + $this->drupalPost('admin/appearance', $edit, t('Save configuration')); $this->drupalGet('admin'); $this->assertRaw('themes/garland', t('Administration theme used on an administration page.')); @@ -937,7 +937,7 @@ class SystemThemeFunctionalTest extends DrupalWebTestCase { $edit = array( 'node_admin_theme' => FALSE, ); - $this->drupalPost('admin/structure/themes', $edit, t('Save configuration')); + $this->drupalPost('admin/appearance', $edit, t('Save configuration')); $this->drupalGet('admin'); $this->assertRaw('themes/garland', t('Administration theme used on an administration page.')); @@ -951,7 +951,7 @@ class SystemThemeFunctionalTest extends DrupalWebTestCase { 'admin_theme' => '0', 'node_admin_theme' => FALSE, ); - $this->drupalPost('admin/structure/themes', $edit, t('Save configuration')); + $this->drupalPost('admin/appearance', $edit, t('Save configuration')); $this->drupalGet('admin'); $this->assertRaw('themes/garland', t('Site default theme used on administration page.')); diff --git a/modules/update/update.compare.inc b/modules/update/update.compare.inc index 65e5822cc..9e62cbdd1 100644 --- a/modules/update/update.compare.inc +++ b/modules/update/update.compare.inc @@ -616,7 +616,7 @@ function update_project_cache($cid) { // On certain paths, we should clear the cache and recompute the projects or // update status of the site to avoid presenting stale information. $q = $_GET['q']; - $paths = array('admin/structure/modules', 'admin/structure/themes', 'admin/reports', 'admin/reports/updates', 'admin/reports/status', 'admin/reports/updates/check'); + $paths = array('admin/structure/modules', 'admin/appearance', 'admin/reports', 'admin/reports/updates', 'admin/reports/status', 'admin/reports/updates/check'); if (in_array($q, $paths)) { _update_cache_clear($cid); } diff --git a/modules/update/update.module b/modules/update/update.module index 2ba9add43..e99353a03 100644 --- a/modules/update/update.module +++ b/modules/update/update.module @@ -72,7 +72,7 @@ function update_help($path, $arg) { $output .= '<p>' . t('To extend the functionality or to change the look of your site, a number of contributed <a href="@modules">modules</a> and <a href="@themes">themes</a> are available.', array('@modules' => 'http://drupal.org/project/modules', '@themes' => 'http://drupal.org/project/themes')) . '</p>'; $output .= '<p>' . t('Each time Drupal core or a contributed module or theme is updated, it is important that <a href="@update-php">update.php</a> is run.', array('@update-php' => url($base_url . '/update.php', array('external' => TRUE)))) . '</p>'; return $output; - case 'admin/structure/themes': + case 'admin/appearance': case 'admin/structure/modules': include_once DRUPAL_ROOT . '/includes/install.inc'; $status = update_requirements('runtime'); |