Commit Graph

18374 Commits

Author SHA1 Message Date
nacin
f283ed40c6 Remove theme tags from the themes.php UI. They just take up room and are redundant with the feature filter. The installer already does not show tags. props DH-Shredder, fixes #20147.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20065 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-01 23:58:10 +00:00
nacin
d4005958ec Line up elements on themes.php. Line up 'Available Themes' header and search/feature form. Switch to padding instead of margin for #current-theme to prevent margin-uncollapse jitters when animating the feature filter. Move 'Current Theme' inside #current-theme so it is hidden by the feature filter. see #20147.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20064 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-01 23:55:09 +00:00
nacin
db15a20fb1 New wp_die_app_handler context in wp_die() for APP requests. Introduces _scalar_wp_die_handler() as a generic handler that wraps die(), for use by plugins. Move deprecated function to the end of the wp-app.php file (same as xmlrpc.php). see #20042.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20063 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-01 21:35:15 +00:00
ryan
3dd02adc17 wp-app.php cleanup:
* Put the atom server class in class-wp-atom-server.php
* Remove log_api calls
* Update the query filter
* Replace exit calls with wp_die() for unit test compat
* Add override handler for wp_die()
* Allow plugins to replace the atom class
* Whitespace cleanup

Props kurtpayne. fixes #20042


git-svn-id: http://svn.automattic.com/wordpress/trunk@20062 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-01 21:15:44 +00:00
bumpbot
2fa6df8637 Compress scripts/styles: 3.4-alpha-20061.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20061 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-01 19:00:20 +00:00
ryan
4f47fe6e31 Introduce jQuery Masonry. Use it to arrange header thumbnails on custom header screen. Props aaroncampbell. fixes #17242
git-svn-id: http://svn.automattic.com/wordpress/trunk@20060 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-01 18:57:28 +00:00
azaozz
dd45b9c2ca Don't pass non-existing rtl stylesheet to TinyMCE, update phpdoc for add_editor_style(), see #19437
git-svn-id: http://svn.automattic.com/wordpress/trunk@20059 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-01 00:18:26 +00:00
koopersmith
db721d86c7 Theme Customizer: Use wp_loaded for customize setting registration. see #19910.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20058 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-01 00:14:51 +00:00
koopersmith
ea9d2e26af Theme Customizer: Use home_url instead of get_home_url. props nacin, fixes #20137, see #19910.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20057 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 23:28:13 +00:00
bumpbot
8c1c5bc112 Compress scripts/styles: 3.4-alpha-20056.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20056 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 23:15:21 +00:00
koopersmith
2f229d3b7c Theme Customizer: Use a late priority when registering customize settings to ensure we catch any theme settings added earlier on init (such as nav menus). see #19910.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20055 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 23:09:38 +00:00
azaozz
839edd2e27 Improve adding more css classes to the editor body, add "rtl", "ie7", "ie8", "ie9" so they can be targeted in editor-style.css, see #19437
git-svn-id: http://svn.automattic.com/wordpress/trunk@20054 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 23:06:24 +00:00
nacin
71aa5ca72a Strict comparisons for the $allowed arg for wp_get_themes(). Otherwise 'network' does == true. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20053 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 23:04:25 +00:00
nacin
57f8d7715f Remove extra $. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20052 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 22:54:50 +00:00
koopersmith
cba9bc1cfb Theme Customizer: Load the preview iframe with the same scheme as the admin to prevent security warnings. props ocean90. fixes #20137, see #19910.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20051 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 22:43:12 +00:00
bumpbot
89b3c4f3b1 Compress scripts/styles: 3.4-alpha-20050.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20050 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 22:30:20 +00:00
koopersmith
cc784490da Theme Customizer: Bind the preview iframe load event when triggering refresh instead of when creating the iframe. see #19910.
The loaded event should only fire when we've actually triggered a refresh. If loaded is bound when the iframe is created, sometimes the blank iframe will fire a 'load' event before a refresh is triggered (this occurred with relative frequency in firefox). By binding the loaded event in the refresh function, we prevent this from occurring.

git-svn-id: http://svn.automattic.com/wordpress/trunk@20049 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 22:24:46 +00:00
nacin
b1621b75bb In WP_Themes_List_Table, don't perform unnecessary sanitization on search terms or filter features. We only use these for case-insensitive comparison. see #19815.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20048 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 22:19:18 +00:00
nacin
814d899e88 Add widget_comments_args and widget_post_args filters. props ramiy, fixes #16159.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20047 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 21:56:24 +00:00
nacin
f11938fde4 'Network Activate' should be the bulk action on network/plugins.php, to match the action link. props ampt, fixes #19946.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20046 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 21:52:27 +00:00
nacin
a48a695ba7 Use correct variable; return correct value for get_screenshot() when value is uncached. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20045 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 20:46:41 +00:00
nacin
8570f2dcd2 Remove debug cruft. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20044 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 20:41:01 +00:00
nacin
8ba92a52f8 Have WP_Theme::get_screenshot() default to an absolute URI. Allow 'relative' to be requested. see #20103, see #19816.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20043 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 20:31:56 +00:00
nacin
5a4f7349e8 Can haz recursion? get_current_theme() is deprecated in favor of wp_get_theme(), not itself. props duck_. see #20138.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20042 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 20:22:16 +00:00
nacin
0dc52c8043 Translate page template names! Have WP_Theme::get_page_templates() return templates keyed by filename, not by template name, as it makes more sense. Flip this in get_page_templates() to be compatible. fixes #6007.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20041 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 20:18:53 +00:00
nacin
a8d45a288f Deprecate get_current_theme(). Use (string) wp_get_theme() to get the translated name of the theme. Keep the current_theme option for now. see #20103, see #20138.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20040 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 20:07:22 +00:00
nacin
bf97881f98 (string) WP_Theme is now the theme name, translated. Good replacement for get_current_theme(); better than wp_get_theme()->display('Name'). see #20103, see #20138.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20039 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 19:27:54 +00:00
nacin
966a27513f Use proper object. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20038 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 18:11:49 +00:00
nacin
6321f9060c Use wp_get_theme() rather than get_theme_data() in the verify theme deletion (multisite network) screen. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20037 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 07:50:56 +00:00
bumpbot
a9b4a2fe6c Compress scripts/styles: 3.4-alpha-20036.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20036 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 06:31:00 +00:00
koopersmith
0f960750b0 Theme Customizer: Don't switch themes and update settings when the enter key is pressed. see #19910.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20035 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 06:28:02 +00:00
koopersmith
b198c61062 Theme Customizer: Trigger UI updates only when necessary.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20034 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 06:18:17 +00:00
nacin
b599bef67a Update switch_theme() to use wp_get_theme(). see #20103, #20138.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20033 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 05:09:29 +00:00
bumpbot
1e5baa0ca0 Compress scripts/styles: 3.4-alpha-20032.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20032 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 01:31:04 +00:00
koopersmith
cc9b31a388 Improve page loads in the theme customizer by layering loading iframes. Automate refreshing, but debounce multiple refresh events to prevent hammering the server with requests. see #19910.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20031 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 01:17:21 +00:00
koopersmith
abd1d5e599 Update customize-controls.php to use new WP_Theme API. see #19910, [20029].
git-svn-id: http://svn.automattic.com/wordpress/trunk@20030 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 21:41:19 +00:00
nacin
d130a63e25 Introduce WP_Theme, wp_get_themes(), and wp_get_theme() to replace get_themes(), get_theme(), get_theme_data(), current_theme_info(), and others.
* Getters and Helpers: Introduces a series of methods to allow for easy generation of headers for display, and other theme metadata, including page templates.
 * Screenshots: Handles support for multiple screenshots. (see # Additional screenshots must be PNG and start with screenshot-2.png, and be sequential to be counted. see #19816.
 * Error Handling: Broken themes have a WP_Error object attached to them.
 * Caching: Introduces a wp_cache_themes_persistently filter (also in [20020]) to enable persistent caching of all filesystem and sanitization operations normally handled by WP_Theme (and formerly get_file_data() and get_themes()). Themes are cached individually and across five different cache keys for different data pieces.
 * Compatibility: A WP_Theme object is backwards compatible with a theme's array formerly returned by get_themes() and get_theme(), and an stdClass object formerly returned by current_theme_info().
 * i18n/L10n: Theme headers are now localizable with proper Text Domain and Domain Path headers, like plugins. (Language packs may remove the requirement for headers.) For page templates, see #6007 (not fixed yet, but will be easy now). For headers, fixes #15858.
 * PHP and CSS files: New methods that fetch a list of theme files (for the theme editor) only on demand, rather than only loading them into memory. fixes #11214.

Functions deprecated:
 * get_themes(), get_allowed_themes() and get_broken_themes() -- use wp_get_themes()
 * get_theme() and current_theme_info() -- use wp_get_theme()
 * get_site_allowed_themes() -- use WP_Theme::get_allowed_on_network()
 * wpmu_get_blog_allowedthemes() -- use WP_theme::get_allowed_on_site()

see also [20016], [20018], [20019], [20020], [20021], [20022], [20025], [20026], [20027]. also fixes #19244.

see #20103.



git-svn-id: http://svn.automattic.com/wordpress/trunk@20029 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 21:24:44 +00:00
koopersmith
f596a23899 Theme Customizer: Strip slashes when sanitizing previewed values. see #19910.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20028 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 21:21:16 +00:00
nacin
7959828e48 Faster theme searching. Only calculate what is necessary -- if the theme doesn't have all of the features, bail. If a word matches a tag or header, jump to the next word, we don't care how many times it matches. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20027 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 20:51:19 +00:00
nacin
2a15b783aa Don't sanitize theme tags while trying to search through them, as it is unnecessary. It is also very expensive -- 50% of the pageload for a search was spent sanitizing tags. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20026 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 20:41:53 +00:00
nacin
9b49096f5e Add argument to get_theme_feature_list() to allow the tags to be returned without hitting the WP.org API. We'll be using this to translate tags. Remove trailing space in the 'Light' string. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20025 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 20:38:09 +00:00
ryan
207ca8ce44 Return to apply_filters_ref_array() for back compat with callbacks that specify a ref for the args. Props scribu. see #18536
git-svn-id: http://svn.automattic.com/wordpress/trunk@20024 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 20:37:47 +00:00
duck_
a395e06896 Reduce references to the $wp_rewrite global because it's no longer used or a wrapper function can be used instead. Fixes #14546.#14546.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20023 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 20:29:33 +00:00
nacin
b367a71d1a Do not save the last visited tab on the multisite Network Themes page and Site Themes tab. These are poor UX, see #18810 for plugins. Entering these screens will always default to 'all' themes view. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20022 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 20:13:21 +00:00
nacin
0cb8aed823 Theme root transient caching is now in search_theme_directories(), not get_themes(). see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20021 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 20:08:08 +00:00
nacin
c77de588d4 Rewrite search_theme_directories() -- better performance and allow for caching.
* Update it to use PHP5 scandir().
 * Don't scan individual theme dirs -- we only need to check for style.css. (Solid performance gains.)
 * Improve and simplify branching.
 * Introduce wp_cache_themes_persistently filter to enable persistent caching of the return value, based on the theme_roots transient.

see #20103.


git-svn-id: http://svn.automattic.com/wordpress/trunk@20020 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 20:05:00 +00:00
duck_
bb94e702f8 Drop image resizing code from wp_handle_upload(). Fixes #19800.
This code stops wp_handle_upload() from reporting errors when the upload couldn't be moved to its final local and it was a non-JS fallback that is unused.


git-svn-id: http://svn.automattic.com/wordpress/trunk@20019 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 20:02:43 +00:00
nacin
7df034983a Clarify second argument for get_raw_theme_root() as the multiple negatives can get confusing. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20018 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 19:59:53 +00:00
lancewillett
e3813d7b68 Twenty Twelve: make proper use of the cached jQuery collection in navigation.js, props mattwiebe. Fixes #20131.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20017 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 19:17:04 +00:00
nacin
d131a8951a Fix the return value of get_theme_root() when the theme root is outside of WP_CONTENT_DIR, thus making it absolute rather than the typical relative theme root.
Make get_theme_root_uri() tolerate an absolute path for a theme root. It will now make an attempt to find a corresponding URL for absolute paths as well.

see #17597.



git-svn-id: http://svn.automattic.com/wordpress/trunk@20016 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 18:02:21 +00:00