Docs: Add missing @since tags for wp-includes/class-wp-editor.php.

See #48303.

git-svn-id: https://develop.svn.wordpress.org/trunk@47022 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Sergey Biryukov 2019-12-31 01:23:11 +00:00
parent e2748f44f4
commit fa0feb0cff

View File

@ -35,6 +35,8 @@ final class _WP_Editors {
/** /**
* Parse default arguments for the editor instance. * Parse default arguments for the editor instance.
* *
* @since 3.3.0
*
* @param string $editor_id ID for the current editor instance. * @param string $editor_id ID for the current editor instance.
* @param array $settings { * @param array $settings {
* Array of editor arguments. * Array of editor arguments.
@ -150,6 +152,8 @@ final class _WP_Editors {
/** /**
* Outputs the HTML for a single instance of the editor. * Outputs the HTML for a single instance of the editor.
* *
* @since 3.3.0
*
* @param string $content The initial content of the editor. * @param string $content The initial content of the editor.
* @param string $editor_id ID for the textarea and TinyMCE and Quicktags instances (can contain only ASCII letters and numbers). * @param string $editor_id ID for the textarea and TinyMCE and Quicktags instances (can contain only ASCII letters and numbers).
* @param array $settings See _WP_Editors::parse_settings() for description. * @param array $settings See _WP_Editors::parse_settings() for description.
@ -309,6 +313,8 @@ final class _WP_Editors {
} }
/** /**
* @since 3.3.0
*
* @global string $tinymce_version * @global string $tinymce_version
* *
* @param string $editor_id * @param string $editor_id
@ -817,6 +823,8 @@ final class _WP_Editors {
} }
/** /**
* @since 3.3.0
*
* @param array $init * @param array $init
* @return string * @return string
*/ */
@ -843,8 +851,7 @@ final class _WP_Editors {
} }
/** /**
* * @since 3.3.0
* @static
* *
* @param bool $default_scripts Optional. Whether default scripts should be enqueued. Default false. * @param bool $default_scripts Optional. Whether default scripts should be enqueued. Default false.
*/ */
@ -1016,6 +1023,9 @@ final class _WP_Editors {
self::wp_link_dialog(); self::wp_link_dialog();
} }
/**
* @since 4.8.0
*/
public static function get_mce_locale() { public static function get_mce_locale() {
if ( empty( self::$mce_locale ) ) { if ( empty( self::$mce_locale ) ) {
$mce_locale = get_user_locale(); $mce_locale = get_user_locale();
@ -1025,6 +1035,9 @@ final class _WP_Editors {
return self::$mce_locale; return self::$mce_locale;
} }
/**
* @since 4.8.0
*/
public static function get_baseurl() { public static function get_baseurl() {
if ( empty( self::$baseurl ) ) { if ( empty( self::$baseurl ) ) {
self::$baseurl = includes_url( 'js/tinymce' ); self::$baseurl = includes_url( 'js/tinymce' );
@ -1037,6 +1050,8 @@ final class _WP_Editors {
* Returns the default TinyMCE settings. * Returns the default TinyMCE settings.
* Doesn't include plugins, buttons, editor selector. * Doesn't include plugins, buttons, editor selector.
* *
* @since 4.8.0
*
* @global string $tinymce_version * @global string $tinymce_version
* *
* @return array * @return array
@ -1104,6 +1119,11 @@ final class _WP_Editors {
return $settings; return $settings;
} }
/**
* @since 4.7.0
*
* @return array
*/
private static function get_translation() { private static function get_translation() {
if ( empty( self::$translation ) ) { if ( empty( self::$translation ) ) {
self::$translation = array( self::$translation = array(
@ -1427,6 +1447,8 @@ final class _WP_Editors {
* Translates the default TinyMCE strings and returns them as JSON encoded object ready to be loaded with tinymce.addI18n(), * Translates the default TinyMCE strings and returns them as JSON encoded object ready to be loaded with tinymce.addI18n(),
* or as JS snippet that should run after tinymce.js is loaded. * or as JS snippet that should run after tinymce.js is loaded.
* *
* @since 3.9.0
*
* @param string $mce_locale The locale used for the editor. * @param string $mce_locale The locale used for the editor.
* @param bool $json_only optional Whether to include the JavaScript calls to tinymce.addI18n() and tinymce.ScriptLoader.markDone(). * @param bool $json_only optional Whether to include the JavaScript calls to tinymce.addI18n() and tinymce.ScriptLoader.markDone().
* @return string Translation object, JSON encoded. * @return string Translation object, JSON encoded.
@ -1487,6 +1509,8 @@ final class _WP_Editors {
* The compressed TinyMCE file cannot deal with custom themes, so this makes * The compressed TinyMCE file cannot deal with custom themes, so this makes
* sure that we use the uncompressed TinyMCE file if a theme is defined. * sure that we use the uncompressed TinyMCE file if a theme is defined.
* Even if we are on a production environment. * Even if we are on a production environment.
*
* @since 5.0.0
*/ */
public static function force_uncompressed_tinymce() { public static function force_uncompressed_tinymce() {
$has_custom_theme = false; $has_custom_theme = false;
@ -1537,6 +1561,8 @@ final class _WP_Editors {
/** /**
* Print (output) the TinyMCE configuration and initialization scripts. * Print (output) the TinyMCE configuration and initialization scripts.
* *
* @since 3.3.0
*
* @global string $tinymce_version * @global string $tinymce_version
*/ */
public static function editor_js() { public static function editor_js() {