From 0807da1bdd3a79b60870ad167a2fddd4aa18c818 Mon Sep 17 00:00:00 2001 From: Andrew Ozz Date: Mon, 31 Aug 2015 22:44:40 +0000 Subject: [PATCH] TinyMCE: disable the native fullscreen plugin on mobile devices by default. Props iseulde. Fixes #33137; git-svn-id: https://develop.svn.wordpress.org/trunk@33835 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/class-wp-editor.php | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/wp-includes/class-wp-editor.php b/src/wp-includes/class-wp-editor.php index 1baafde3d0..b83454e463 100644 --- a/src/wp-includes/class-wp-editor.php +++ b/src/wp-includes/class-wp-editor.php @@ -593,10 +593,12 @@ final class _WP_Editors { } else { $mce_buttons = array( 'bold', 'italic', 'strikethrough', 'bullist', 'numlist', 'blockquote', 'hr', 'alignleft', 'aligncenter', 'alignright', 'link', 'unlink', 'wp_more', 'spellchecker' ); - if ( $set['_content_editor_dfw'] ) { - $mce_buttons[] = 'dfw'; - } else { - $mce_buttons[] = 'fullscreen'; + if ( ! wp_is_mobile() ) { + if ( $set['_content_editor_dfw'] ) { + $mce_buttons[] = 'dfw'; + } else { + $mce_buttons[] = 'fullscreen'; + } } $mce_buttons[] = 'wp_adv';