From a908d2d4b188975469bc3cf16ceac912492995cc Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Sat, 17 Oct 2015 01:21:25 +0000 Subject: [PATCH] Embeds: Rename files, functions, and hooks added in [34903] to make it more clear what is oEmbed-specific and what isn't. See https://core.trac.wordpress.org/ticket/34272#comment:7 for full list of renamed functions and hooks. Props swissspidy. Fixes #34272. Built from https://develop.svn.wordpress.org/trunk@35235 git-svn-id: http://core.svn.wordpress.org/trunk@35201 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- ...oembed-embed.css => wp-embed-template.css} | 0 ...mbed.min.css => wp-embed-template.min.css} | 0 wp-includes/default-filters.php | 22 +++++++------- wp-includes/embed-functions.php | 28 +++++++++--------- wp-includes/embed-template.php | 20 ++++++------- .../js/tinymce/plugins/wpoembed/plugin.js | 2 +- .../js/tinymce/plugins/wpoembed/plugin.min.js | 2 +- wp-includes/js/tinymce/wp-tinymce.js.gz | Bin 147743 -> 147744 bytes ...p-oembed-embed.js => wp-embed-template.js} | 0 ...-embed.min.js => wp-embed-template.min.js} | 0 wp-includes/js/{wp-oembed.js => wp-embed.js} | 0 .../js/{wp-oembed.min.js => wp-embed.min.js} | 0 wp-includes/version.php | 2 +- 13 files changed, 38 insertions(+), 38 deletions(-) rename wp-includes/css/{wp-oembed-embed.css => wp-embed-template.css} (100%) rename wp-includes/css/{wp-oembed-embed.min.css => wp-embed-template.min.css} (100%) rename wp-includes/js/{wp-oembed-embed.js => wp-embed-template.js} (100%) rename wp-includes/js/{wp-oembed-embed.min.js => wp-embed-template.min.js} (100%) rename wp-includes/js/{wp-oembed.js => wp-embed.js} (100%) rename wp-includes/js/{wp-oembed.min.js => wp-embed.min.js} (100%) diff --git a/wp-includes/css/wp-oembed-embed.css b/wp-includes/css/wp-embed-template.css similarity index 100% rename from wp-includes/css/wp-oembed-embed.css rename to wp-includes/css/wp-embed-template.css diff --git a/wp-includes/css/wp-oembed-embed.min.css b/wp-includes/css/wp-embed-template.min.css similarity index 100% rename from wp-includes/css/wp-oembed-embed.min.css rename to wp-includes/css/wp-embed-template.min.css diff --git a/wp-includes/default-filters.php b/wp-includes/default-filters.php index 75dadfc465..31284d580d 100644 --- a/wp-includes/default-filters.php +++ b/wp-includes/default-filters.php @@ -446,24 +446,24 @@ add_action( 'parse_query', 'wp_oembed_parse_query' ); add_action( 'wp_head', 'wp_oembed_add_discovery_links' ); add_action( 'wp_head', 'wp_oembed_add_host_js' ); -add_action( 'oembed_head', 'print_emoji_detection_script' ); -add_action( 'oembed_head', 'print_emoji_styles' ); -add_action( 'oembed_head', 'print_oembed_embed_styles' ); -add_action( 'oembed_head', 'print_oembed_embed_scripts' ); -add_action( 'oembed_head', 'wp_print_head_scripts', 20 ); -add_action( 'oembed_head', 'wp_print_styles', 20 ); -add_action( 'oembed_head', 'wp_no_robots' ); -add_action( 'oembed_head', 'rel_canonical' ); -add_action( 'oembed_head', 'locale_stylesheet' ); +add_action( 'embed_head', 'print_emoji_detection_script' ); +add_action( 'embed_head', 'print_emoji_styles' ); +add_action( 'embed_head', 'print_embed_styles' ); +add_action( 'embed_head', 'print_embed_scripts' ); +add_action( 'embed_head', 'wp_print_head_scripts', 20 ); +add_action( 'embed_head', 'wp_print_styles', 20 ); +add_action( 'embed_head', 'wp_no_robots' ); +add_action( 'embed_head', 'rel_canonical' ); +add_action( 'embed_head', 'locale_stylesheet' ); add_action( 'oembed_footer', 'wp_print_footer_scripts', 20 ); -add_filter( 'excerpt_more', 'wp_oembed_excerpt_more', 20 ); +add_filter( 'excerpt_more', 'wp_embed_excerpt_more', 20 ); add_filter( 'the_excerpt_embed', 'wptexturize' ); add_filter( 'the_excerpt_embed', 'convert_chars' ); add_filter( 'the_excerpt_embed', 'wpautop' ); add_filter( 'the_excerpt_embed', 'shortcode_unautop' ); -add_filter( 'the_excerpt_embed', 'wp_oembed_excerpt_attachment' ); +add_filter( 'the_excerpt_embed', 'wp_embed_excerpt_attachment' ); add_filter( 'oembed_dataparse', 'wp_filter_oembed_result', 10, 3 ); add_filter( 'oembed_response_data', 'get_oembed_response_data_rich', 10, 4 ); diff --git a/wp-includes/embed-functions.php b/wp-includes/embed-functions.php index 65a23eb7f2..7661efe651 100644 --- a/wp-includes/embed-functions.php +++ b/wp-includes/embed-functions.php @@ -464,17 +464,17 @@ function get_post_embed_html( $post = null, $width, $height ) { $output = "