Index: src/wp-admin/admin-ajax.php
===================================================================
--- src/wp-admin/admin-ajax.php	(revision 29173)
+++ src/wp-admin/admin-ajax.php	(working copy)
@@ -60,7 +60,8 @@
 	'wp-remove-post-lock', 'dismiss-wp-pointer', 'upload-attachment', 'get-attachment',
 	'query-attachments', 'save-attachment', 'save-attachment-compat', 'send-link-to-editor',
 	'send-attachment-to-editor', 'save-attachment-order', 'heartbeat', 'get-revision-diffs',
-	'save-user-color-scheme', 'update-widget', 'query-themes', 'parse-embed', 'set-attachment-thumbnail'
+	'save-user-color-scheme', 'update-widget', 'query-themes', 'parse-embed', 'set-attachment-thumbnail',
+	'parse-playlist-shortcode', 'parse-media-shortcode'
 );
 
 // Register core Ajax calls.
Index: src/wp-admin/includes/ajax-actions.php
===================================================================
--- src/wp-admin/includes/ajax-actions.php	(revision 29173)
+++ src/wp-admin/includes/ajax-actions.php	(working copy)
@@ -2613,7 +2613,7 @@
  * @global WP_Embed $wp_embed Embed API instance.
  */
 function wp_ajax_parse_embed() {
-	global $post, $wp_embed;
+	global $post, $wp_embed, $wp_scripts;
 
 	if ( ! $post = get_post( (int) $_REQUEST['post_ID'] ) ) {
 		wp_send_json_error();
@@ -2623,6 +2623,8 @@
 		wp_send_json_error();
 	}
 
+	$wp_scripts->done = array();
+
 	$shortcode = $_POST['shortcode'];
 	$url = str_replace( '[embed]', '', str_replace( '[/embed]', '', $shortcode ) );
 	$parsed = false;
@@ -2666,3 +2668,47 @@
 
 	wp_send_json_success( $parsed );
 }
+
+function wp_ajax_parse_playlist_shortcode() {
+	global $post, $wp_scripts;
+
+	if ( ! $post = get_post( (int) $_REQUEST['post_ID'] ) ) {
+		wp_send_json_error();
+	}
+
+	setup_postdata( $post );
+
+	ob_start();
+
+	wp_media_mce_styles();
+
+	echo do_shortcode( wp_unslash( $_REQUEST['shortcode'] ) );
+
+	wp_underscore_playlist_templates();
+
+	$wp_scripts->done = array();
+	wp_print_scripts( 'wp-playlist' );
+
+	wp_send_json_success( ob_get_clean() );
+}
+
+function wp_ajax_parse_media_shortcode() {
+	global $post, $wp_scripts;
+
+	if ( ! $post = get_post( (int) $_REQUEST['post_ID'] ) ) {
+		wp_send_json_error();
+	}
+
+	setup_postdata( $post );
+
+	ob_start();
+
+	wp_media_mce_styles();
+
+	echo do_shortcode( wp_unslash( $_REQUEST['shortcode'] ) );
+
+	$wp_scripts->done = array();
+	wp_print_scripts( 'wp-mediaelement' );
+
+	wp_send_json_success( ob_get_clean() );
+}
\ No newline at end of file
Index: src/wp-includes/class-wp-editor.php
===================================================================
--- src/wp-includes/class-wp-editor.php	(revision 29173)
+++ src/wp-includes/class-wp-editor.php	(working copy)
@@ -503,48 +503,21 @@
 				$suffix = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '' : '.min';
 				$version = 'ver=' . $GLOBALS['wp_version'];
 				$dashicons = includes_url( "css/dashicons$suffix.css?$version" );
-				$mediaelement = includes_url( "js/mediaelement/mediaelementplayer.min.css?$version" );
-				$wpmediaelement = includes_url( "js/mediaelement/wp-mediaelement.css?$version" );
 
 				// WordPress default stylesheet and dashicons
 				$mce_css = array(
 					$dashicons,
-					$mediaelement,
-					$wpmediaelement,
 					self::$baseurl . '/skins/wordpress/wp-content.css?' . $version
 				);
 
 				// load editor_style.css if the current theme supports it
 				if ( ! empty( $GLOBALS['editor_styles'] ) && is_array( $GLOBALS['editor_styles'] ) ) {
-					$editor_styles = $GLOBALS['editor_styles'];
-
-					$editor_styles = array_unique( array_filter( $editor_styles ) );
-					$style_uri = get_stylesheet_directory_uri();
-					$style_dir = get_stylesheet_directory();
-
-					// Support externally referenced styles (like, say, fonts).
-					foreach ( $editor_styles as $key => $file ) {
-						if ( preg_match( '~^(https?:)?//~', $file ) ) {
-							$mce_css[] = esc_url_raw( $file );
-							unset( $editor_styles[ $key ] );
+					$editor_styles = get_editor_stylesheets();
+					if ( ! empty( $editor_styles ) ) {
+						foreach ( $editor_styles as $style ) {
+							$mce_css[] = $style;
 						}
 					}
-
-					// Look in a parent theme first, that way child theme CSS overrides.
-					if ( is_child_theme() ) {
-						$template_uri = get_template_directory_uri();
-						$template_dir = get_template_directory();
-
-						foreach ( $editor_styles as $key => $file ) {
-							if ( $file && file_exists( "$template_dir/$file" ) )
-								$mce_css[] = "$template_uri/$file";
-						}
-					}
-
-					foreach ( $editor_styles as $file ) {
-						if ( $file && file_exists( "$style_dir/$file" ) )
-							$mce_css[] = "$style_uri/$file";
-					}
 				}
 
 				/**
Index: src/wp-includes/js/mce-view.js
===================================================================
--- src/wp-includes/js/mce-view.js	(revision 29173)
+++ src/wp-includes/js/mce-view.js	(working copy)
@@ -104,6 +104,65 @@
 				}
 			}, this );
 		},
+
+		/* jshint scripturl: true */
+		createIframe: function ( content ) {
+			var MutationObserver = window.MutationObserver || window.WebKitMutationObserver || window.MozMutationObserver,
+				iframe, iframeDoc, i, resize,
+				dom = tinymce.DOM;
+
+			if ( content.indexOf( '<script' ) !== -1 ) {
+				iframe = dom.create( 'iframe', {
+					src: tinymce.Env.ie ? 'javascript:""' : '',
+					frameBorder: '0',
+					allowTransparency: 'true',
+					scrolling: 'no',
+					style: {
+						width: '100%',
+						display: 'block'
+					}
+				} );
+
+				this.setContent( iframe );
+				iframeDoc = iframe.contentWindow.document;
+
+				iframeDoc.open();
+				iframeDoc.write(
+					'<!DOCTYPE html>' +
+					'<html>' +
+						'<head>' +
+							'<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />' +
+						'</head>' +
+						'<body style="padding: 0; margin: 0;">' +
+							content +
+						'</body>' +
+					'</html>'
+				);
+				iframeDoc.close();
+
+				resize = function() {
+					$( iframe ).height( $( iframeDoc.body ).height() );
+				};
+
+				if ( MutationObserver ) {
+					new MutationObserver( _.debounce( function() {
+						resize();
+					}, 100 ) )
+					.observe( iframeDoc.body, {
+						attributes: true,
+						childList: true,
+						subtree: true
+					} );
+				} else {
+					for ( i = 1; i < 6; i++ ) {
+						setTimeout( resize, i * 700 );
+					}
+				}
+			} else {
+				this.setContent( content );
+			}
+		},
+
 		setError: function( message, dashicon ) {
 			this.setContent(
 				'<div class="wpview-error">' +
@@ -421,54 +480,59 @@
 	wp.mce.av = {
 		loaded: false,
 
-		View: _.extend( {}, wp.media.mixin, {
+		View: {
 			overlay: true,
 
+			action: 'parse-media-shortcode',
+
 			initialize: function( options ) {
-				this.players = [];
-				this.shortcode = options.shortcode;
-				_.bindAll( this, 'setPlayer', 'pausePlayers' );
-				$( this ).on( 'ready', this.setPlayer );
-				$( this ).on( 'ready', function( event, editor ) {
-					editor.on( 'hide', this.pausePlayers );
-				} );
-				$( document ).on( 'media:edit', this.pausePlayers );
+				this.shortcode = options.shortcode.string();
+				this.fetching = false;
+
+				_.bindAll( this, 'createIframe', 'setNode', 'fetch' );
+				$( this ).on( 'ready', this.setNode );
 			},
 
-			/**
-			 * Creates the player instance for the current node
-			 *
-			 * @global MediaElementPlayer
-			 *
-			 * @param {Event} event
-			 * @param {Object} editor
-			 * @param {HTMLElement} node
-			 */
-			setPlayer: function( event, editor, node ) {
-				var self = this,
-					media;
+			setNode: function () {
+				if ( this.parsed ) {
+					this.createIframe( this.parsed );
+				} else if ( ! this.fetching ) {
+					this.fetch();
+				}
+			},
 
-				media = $( node ).find( '.wp-' +  this.shortcode.tag + '-shortcode' );
+			fetch: function () {
+				var self = this;
+				this.fetching = true;
 
-				if ( ! this.isCompatible( media ) ) {
-					media.closest( '.wpview-wrap' ).addClass( 'wont-play' );
-					media.replaceWith( '<p>' + media.find( 'source' ).eq(0).prop( 'src' ) + '</p>' );
-					return;
-				} else {
-					media.closest( '.wpview-wrap' ).removeClass( 'wont-play' );
-					if ( this.ua.is( 'ff' ) ) {
-						media.prop( 'preload', 'metadata' );
-					} else {
-						media.prop( 'preload', 'none' );
+				wp.ajax.send( this.action, {
+					data: {
+						post_ID: $( '#post_ID' ).val() || 0,
+						shortcode: this.shortcode
 					}
-				}
+				} )
+				.always( function() {
+					self.fetching = false;
+				} )
+				.done( function( response ) {
+					if ( response ) {
+						self.parsed = response;
+						self.createIframe( response );
+					}
+				} )
+				.fail( function( response ) {
+					if ( response && response.message ) {
+						if ( ( response.type === 'not-embeddable' && self.type === 'embed' ) ||
+							response.type === 'not-ssl' ) {
 
-				media = wp.media.view.MediaDetails.prepareSrc( media.get(0) );
-
-				setTimeout( function() {
-					wp.mce.av.loaded = true;
-					self.players.push( new MediaElementPlayer( media, self.mejsSettings ) );
-				}, wp.mce.av.loaded ? 10 : 500 );
+							self.setError( response.message, 'admin-media' );
+						} else {
+							self.setContent( '<p>' + self.original + '</p>', null, 'replace' );
+						}
+					} else if ( response && response.statusText ) {
+						self.setError( response.statusText, 'admin-media' );
+					}
+				} );
 			},
 
 			/**
@@ -477,19 +541,12 @@
 			 * @returns {string}
 			 */
 			getHtml: function() {
-				var attrs = this.shortcode.attrs.named;
-				attrs.content = this.shortcode.content;
-
-				return this.template({ model: _.defaults(
-					attrs,
-					wp.media[ this.shortcode.tag ].defaults )
-				});
-			},
-
-			unbind: function() {
-				this.unsetPlayers();
+				if ( ! this.parsed ) {
+					return '';
+				}
+				return this.parsed;
 			}
-		} ),
+		},
 
 		/**
 		 * Called when a TinyMCE view is clicked for editing.
@@ -537,10 +594,7 @@
 	 * @mixes wp.mce.av
 	 */
 	wp.mce.views.register( 'video', _.extend( {}, wp.mce.av, {
-		state: 'video-details',
-		View: _.extend( {}, wp.mce.av.View, {
-			template: media.template( 'editor-video' )
-		} )
+		state: 'video-details'
 	} ) );
 
 	/**
@@ -549,10 +603,7 @@
 	 * @mixes wp.mce.av
 	 */
 	wp.mce.views.register( 'audio', _.extend( {}, wp.mce.av, {
-		state: 'audio-details',
-		View: _.extend( {}, wp.mce.av.View, {
-			template: media.template( 'editor-audio' )
-		} )
+		state: 'audio-details'
 	} ) );
 
 	/**
@@ -562,131 +613,8 @@
 	 */
 	wp.mce.views.register( 'playlist', _.extend( {}, wp.mce.av, {
 		state: ['playlist-edit', 'video-playlist-edit'],
-		View: _.extend( {}, wp.media.mixin, {
-			template:  media.template( 'editor-playlist' ),
-			overlay: true,
-
-			initialize: function( options ) {
-				this.players = [];
-				this.data = {};
-				this.attachments = [];
-				this.shortcode = options.shortcode;
-
-				$( this ).on( 'ready', function( event, editor ) {
-					editor.on( 'hide', this.pausePlayers );
-				} );
-				$( document ).on( 'media:edit', this.pausePlayers );
-
-				this.fetch();
-
-				$( this ).on( 'ready', this.setPlaylist );
-			},
-
-			/**
-			 * Asynchronously fetch the shortcode's attachments
-			 */
-			fetch: function() {
-				this.attachments = wp.media.playlist.attachments( this.shortcode );
-				this.dfd = this.attachments.more().done( _.bind( this.render, this ) );
-			},
-
-			setPlaylist: function( event, editor, element ) {
-				if ( ! this.data.tracks ) {
-					return;
-				}
-
-				this.players.push( new WPPlaylistView( {
-					el: $( element ).find( '.wp-playlist' ).get( 0 ),
-					metadata: this.data
-				} ).player );
-			},
-
-			/**
-			 * Set the data that will be used to compile the Underscore template,
-			 *  compile the template, and then return it.
-			 *
-			 * @returns {string}
-			 */
-			getHtml: function() {
-				var data = this.shortcode.attrs.named,
-					model = wp.media.playlist,
-					options,
-					attachments,
-					tracks = [];
-
-				// Don't render errors while still fetching attachments
-				if ( this.dfd && 'pending' === this.dfd.state() && ! this.attachments.length ) {
-					return '';
-				}
-
-				_.each( model.defaults, function( value, key ) {
-					data[ key ] = model.coerce( data, key );
-				});
-
-				options = {
-					type: data.type,
-					style: data.style,
-					tracklist: data.tracklist,
-					tracknumbers: data.tracknumbers,
-					images: data.images,
-					artists: data.artists
-				};
-
-				if ( ! this.attachments.length ) {
-					return this.template( options );
-				}
-
-				attachments = this.attachments.toJSON();
-
-				_.each( attachments, function( attachment ) {
-					var size = {}, resize = {}, track = {
-						src : attachment.url,
-						type : attachment.mime,
-						title : attachment.title,
-						caption : attachment.caption,
-						description : attachment.description,
-						meta : attachment.meta
-					};
-
-					if ( 'video' === data.type ) {
-						size.width = attachment.width;
-						size.height = attachment.height;
-						if ( media.view.settings.contentWidth ) {
-							resize.width = media.view.settings.contentWidth - 22;
-							resize.height = Math.ceil( ( size.height * resize.width ) / size.width );
-							if ( ! options.width ) {
-								options.width = resize.width;
-								options.height = resize.height;
-							}
-						} else {
-							if ( ! options.width ) {
-								options.width = attachment.width;
-								options.height = attachment.height;
-							}
-						}
-						track.dimensions = {
-							original : size,
-							resized : _.isEmpty( resize ) ? size : resize
-						};
-					} else {
-						options.width = 400;
-					}
-
-					track.image = attachment.image;
-					track.thumb = attachment.thumb;
-
-					tracks.push( track );
-				} );
-
-				options.tracks = tracks;
-				this.data = options;
-
-				return this.template( options );
-			},
-
-			unbind: function() {
-				this.unsetPlayers();
-			}
+		View: _.extend( {}, wp.mce.av.View, {
+			action: 'parse-playlist-shortcode'
 		} )
 	} ) );
 
@@ -693,10 +621,10 @@
 	/**
 	 * TinyMCE handler for the embed shortcode
 	 */
-	wp.mce.embedView = _.extend( {}, wp.media.mixin, {
+	wp.mce.embedView = _.extend( {}, wp.mce.av.View, {
 		overlay: true,
+		action: 'parse-embed',
 		initialize: function( options ) {
-			this.players = [];
 			this.content = options.content;
 			this.fetching = false;
 			this.parsed = false;
@@ -708,122 +636,8 @@
 				this.shortcode = options.shortcode.string();
 			}
 
-			_.bindAll( this, 'setHtml', 'setNode', 'fetch' );
+			_.bindAll( this, 'createIframe', 'setNode', 'fetch' );
 			$( this ).on( 'ready', this.setNode );
-		},
-		unbind: function() {
-			var self = this;
-			_.each( this.players, function ( player ) {
-				player.pause();
-				self.removePlayer( player );
-			} );
-			this.players = [];
-		},
-		setNode: function () {
-			if ( this.parsed ) {
-				this.setHtml( this.parsed );
-				this.parseMediaShortcodes();
-			} else if ( ! this.fetching ) {
-				this.fetch();
-			}
-		},
-		fetch: function () {
-			var self = this;
-
-			this.fetching = true;
-
-			wp.ajax.send( 'parse-embed', {
-				data: {
-					post_ID: $( '#post_ID' ).val() || 0,
-					shortcode: this.shortcode
-				}
-			} )
-			.always( function() {
-				self.fetching = false;
-			} )
-			.done( function( response ) {
-				if ( response ) {
-					self.parsed = response;
-					self.setHtml( response );
-				}
-			} )
-			.fail( function( response ) {
-				if ( response && response.message ) {
-					if ( ( response.type === 'not-embeddable' && self.type === 'embed' ) ||
-						response.type === 'not-ssl' ) {
-
-						self.setError( response.message, 'admin-media' );
-					} else {
-						self.setContent( '<p>' + self.original + '</p>', null, 'replace' );
-					}
-				} else if ( response && response.statusText ) {
-					self.setError( response.statusText, 'admin-media' );
-				}
-			} );
-		},
-		/* jshint scripturl: true */
-		setHtml: function ( content ) {
-			var MutationObserver = window.MutationObserver || window.WebKitMutationObserver || window.MozMutationObserver,
-				iframe, iframeDoc, i, resize,
-				dom = tinymce.DOM;
-
-			if ( content.indexOf( '<script' ) !== -1 ) {
-				iframe = dom.create( 'iframe', {
-					src: tinymce.Env.ie ? 'javascript:""' : '',
-					frameBorder: '0',
-					allowTransparency: 'true',
-					style: {
-						width: '100%',
-						display: 'block'
-					}
-				} );
-
-				this.setContent( iframe );
-				iframeDoc = iframe.contentWindow.document;
-
-				iframeDoc.open();
-				iframeDoc.write(
-					'<!DOCTYPE html>' +
-					'<html>' +
-						'<head>' +
-							'<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />' +
-						'</head>' +
-						'<body>' +
-							content +
-						'</body>' +
-					'</html>'
-				);
-				iframeDoc.close();
-
-				resize = function() {
-					$( iframe ).height( $( iframeDoc ).height() );
-				};
-
-				if ( MutationObserver ) {
-					new MutationObserver( _.debounce( function() {
-						resize();
-					}, 100 ) )
-					.observe( iframeDoc.body, {
-						attributes: true,
-						childList: true,
-						subtree: true
-					} );
-				} else {
-					for ( i = 1; i < 6; i++ ) {
-						setTimeout( resize, i * 700 );
-					}
-				}
-			} else {
-				this.setContent( content );
-			}
-
-			this.parseMediaShortcodes();
-		},
-		parseMediaShortcodes: function () {
-			var self = this;
-			$( '.wp-audio-shortcode, .wp-video-shortcode', this.node ).each( function ( i, element ) {
-				self.players.push( new MediaElementPlayer( element, self.mejsSettings ) );
-			} );
 		}
 	} );
 
Index: src/wp-includes/js/media-audiovideo.js
===================================================================
--- src/wp-includes/js/media-audiovideo.js	(revision 29173)
+++ src/wp-includes/js/media-audiovideo.js	(working copy)
@@ -47,103 +47,6 @@
 		},
 
 		/**
-		 * Utility to identify the user's browser
-		 */
-		ua: {
-			is : function( browser ) {
-				var passes = false, ua = window.navigator.userAgent;
-
-				switch ( browser ) {
-					case 'oldie':
-						passes = ua.match(/MSIE [6-8]/gi) !== null;
-					break;
-					case 'ie':
-						passes = /MSIE /.test( ua ) || ( /Trident\//.test( ua ) && /rv:\d/.test( ua ) ); // IE11
-					break;
-					case 'ff':
-						passes = ua.match(/firefox/gi) !== null;
-					break;
-					case 'opera':
-						passes = ua.match(/OPR/) !== null;
-					break;
-					case 'safari':
-						passes = ua.match(/safari/gi) !== null && ua.match(/chrome/gi) === null;
-					break;
-					case 'chrome':
-						passes = ua.match(/safari/gi) !== null && ua.match(/chrome/gi) !== null;
-					break;
-				}
-
-				return passes;
-			}
-		},
-
-		/**
-		 * Specify compatibility for native playback by browser
-		 */
-		compat :{
-			'opera' : {
-				audio: ['ogg', 'wav'],
-				video: ['ogg', 'webm']
-			},
-			'chrome' : {
-				audio: ['ogg', 'mpeg'],
-				video: ['ogg', 'webm', 'mp4', 'm4v', 'mpeg']
-			},
-			'ff' : {
-				audio: ['ogg', 'mpeg'],
-				video: ['ogg', 'webm']
-			},
-			'safari' : {
-				audio: ['mpeg', 'wav'],
-				video: ['mp4', 'm4v', 'mpeg', 'x-ms-wmv', 'quicktime']
-			},
-			'ie' : {
-				audio: ['mpeg'],
-				video: ['mp4', 'm4v', 'mpeg']
-			}
-		},
-
-		/**
-		 * Determine if the passed media contains a <source> that provides
-		 *  native playback in the user's browser
-		 *
-		 * @param {jQuery} media
-		 * @returns {Boolean}
-		 */
-		isCompatible: function( media ) {
-			if ( ! media.find( 'source' ).length ) {
-				return false;
-			}
-
-			var ua = this.ua, test = false, found = false, sources;
-
-			if ( ua.is( 'oldIE' ) ) {
-				return false;
-			}
-
-			sources = media.find( 'source' );
-
-			_.find( this.compat, function( supports, browser ) {
-				if ( ua.is( browser ) ) {
-					found = true;
-					_.each( sources, function( elem ) {
-						var audio = new RegExp( 'audio\/(' + supports.audio.join('|') + ')', 'gi' ),
-							video = new RegExp( 'video\/(' + supports.video.join('|') + ')', 'gi' );
-
-						if ( elem.type.match( video ) !== null || elem.type.match( audio ) !== null ) {
-							test = true;
-						}
-					} );
-				}
-
-				return test || found;
-			} );
-
-			return test;
-		},
-
-		/**
 		 * Override the MediaElement method for removing a player.
 		 *	MediaElement tries to pull the audio/video tag out of
 		 *	its container and re-add it to the DOM.
Index: src/wp-includes/js/mediaelement/wp-playlist.js
===================================================================
--- src/wp-includes/js/mediaelement/wp-playlist.js	(revision 29173)
+++ src/wp-includes/js/mediaelement/wp-playlist.js	(working copy)
@@ -7,7 +7,6 @@
 		initialize : function (options) {
 			this.index = 0;
 			this.settings = {};
-			this.compatMode = $( 'body' ).hasClass( 'wp-admin' ) && $( '#content_ifr' ).length;
 			this.data = options.metadata || $.parseJSON( this.$('script').html() );
 			this.playerNode = this.$( this.data.type );
 
@@ -27,9 +26,7 @@
 				this.renderTracks();
 			}
 
-			if ( this.isCompatibleSrc() ) {
-				this.playerNode.attr( 'src', this.current.get( 'src' ) );
-			}
+			this.playerNode.attr( 'src', this.current.get( 'src' ) );
 
 			_.bindAll( this, 'bindPlayer', 'bindResetPlayer', 'setPlayer', 'ended', 'clickTrack' );
 
@@ -47,27 +44,9 @@
 
 		bindResetPlayer : function (mejs) {
 			this.bindPlayer( mejs );
-			if ( this.isCompatibleSrc() ) {
-				this.playCurrentSrc();
-			}
+			this.playCurrentSrc();
 		},
 
-		isCompatibleSrc: function () {
-			var testNode;
-
-			if ( this.compatMode ) {
-				testNode = $( '<span><source type="' + this.current.get( 'type' ) + '" /></span>' );
-
-				if ( ! wp.media.mixin.isCompatible( testNode ) ) {
-					this.playerNode.removeAttr( 'src' );
-					this.playerNode.removeAttr( 'poster' );
-					return;
-				}
-			}
-
-			return true;
-		},
-
 		setPlayer: function (force) {
 			if ( this.player ) {
 				this.player.pause();
@@ -76,9 +55,7 @@
 			}
 
 			if (force) {
-				if ( this.isCompatibleSrc() ) {
-					this.playerNode.attr( 'src', this.current.get( 'src' ) );
-				}
+				this.playerNode.attr( 'src', this.current.get( 'src' ) );
 				this.settings.success = this.bindResetPlayer;
 			}
 
@@ -188,11 +165,9 @@
 	});
 
     $(document).ready(function () {
-		if ( ! $( 'body' ).hasClass( 'wp-admin' ) || $( 'body' ).hasClass( 'about-php' ) ) {
-			$('.wp-playlist').each(function () {
-				return new WPPlaylistView({ el: this });
-			});
-		}
+		$('.wp-playlist').each( function() {
+			return new WPPlaylistView({ el: this });
+		} );
     });
 
 	window.WPPlaylistView = WPPlaylistView;
Index: src/wp-includes/media-template.php
===================================================================
--- src/wp-includes/media-template.php	(revision 29173)
+++ src/wp-includes/media-template.php	(working copy)
@@ -1216,35 +1216,6 @@
 		<# } #>
 	</script>
 
-	<script type="text/html" id="tmpl-editor-audio">
-		<?php wp_underscore_audio_template() ?>
-	</script>
-
-	<script type="text/html" id="tmpl-editor-video">
-		<?php wp_underscore_video_template() ?>
-	</script>
-
-	<?php wp_underscore_playlist_templates() ?>
-
-	<script type="text/html" id="tmpl-editor-playlist">
-		<# if ( data.tracks ) { #>
-			<div class="wp-playlist wp-{{ data.type }}-playlist wp-playlist-{{ data.style }}">
-				<# if ( 'audio' === data.type ){ #>
-				<div class="wp-playlist-current-item"></div>
-				<# } #>
-				<{{ data.type }} controls="controls" preload="none" <#
-					if ( data.width ) { #> width="{{ data.width }}"<# }
-					#><# if ( data.height ) { #> height="{{ data.height }}"<# } #>></{{ data.type }}>
-				<div class="wp-playlist-next"></div>
-				<div class="wp-playlist-prev"></div>
-			</div>
-		<# } else { #>
-			<div class="wpview-error">
-				<div class="dashicons dashicons-video-alt3"></div><p><?php _e( 'No items found.' ); ?></p>
-			</div>
-		<# } #>
-	</script>
-
 	<script type="text/html" id="tmpl-crop-content">
 		<img class="crop-image" src="{{ data.url }}">
 		<div class="upload-errors"></div>
Index: src/wp-includes/media.php
===================================================================
--- src/wp-includes/media.php	(revision 29173)
+++ src/wp-includes/media.php	(working copy)
@@ -1531,7 +1531,8 @@
 		'src'      => '',
 		'loop'     => '',
 		'autoplay' => '',
-		'preload'  => 'none'
+		'preload'  => 'none',
+		'scripts'  => false
 	);
 	foreach ( $default_types as $type ) {
 		$defaults_atts[$type] = '';
@@ -1573,6 +1574,7 @@
 		array_unshift( $default_types, 'src' );
 	}
 
+	$scripts = '';
 	/**
 	 * Filter the media library used for the audio shortcode.
 	 *
@@ -1582,8 +1584,15 @@
 	 */
 	$library = apply_filters( 'wp_audio_shortcode_library', 'mediaelement' );
 	if ( 'mediaelement' === $library && did_action( 'init' ) ) {
-		wp_enqueue_style( 'wp-mediaelement' );
-		wp_enqueue_script( 'wp-mediaelement' );
+		if ( $atts['scripts'] ) {
+			ob_start();
+			wp_print_styles( 'wp-mediaelement' );
+			wp_print_scripts( 'wp-mediaelement' );
+			$scripts = ob_get_clean();
+		} else {
+			wp_enqueue_style( 'wp-mediaelement' );
+			wp_enqueue_script( 'wp-mediaelement' );
+		}
 	}
 
 	/**
@@ -1637,7 +1646,9 @@
 		$html .= wp_mediaelement_fallback( $fileurl );
 	}
 	$html .= '</audio>';
-
+	if ( ! empty( $scripts ) ) {
+		$html .= $scripts;
+	}
 	/**
 	 * Filter the audio shortcode output.
 	 *
@@ -1736,6 +1747,7 @@
 		'preload'  => 'metadata',
 		'width'    => 640,
 		'height'   => 360,
+		'scripts'  => false,
 	);
 
 	foreach ( $default_types as $type ) {
@@ -1796,6 +1808,7 @@
 		array_unshift( $default_types, 'src' );
 	}
 
+	$scripts = '';
 	/**
 	 * Filter the media library used for the video shortcode.
 	 *
@@ -1805,8 +1818,15 @@
 	 */
 	$library = apply_filters( 'wp_video_shortcode_library', 'mediaelement' );
 	if ( 'mediaelement' === $library && did_action( 'init' ) ) {
-		wp_enqueue_style( 'wp-mediaelement' );
-		wp_enqueue_script( 'wp-mediaelement' );
+		if ( $atts['scripts'] ) {
+			ob_start();
+			wp_print_styles( 'wp-mediaelement' );
+			wp_print_scripts( 'wp-mediaelement' );
+			$scripts = ob_get_clean();
+		} else {
+			wp_enqueue_style( 'wp-mediaelement' );
+			wp_enqueue_script( 'wp-mediaelement' );
+		}
 	}
 
 	/**
@@ -1873,6 +1893,9 @@
 		$html .= wp_mediaelement_fallback( $fileurl );
 	}
 	$html .= '</video>';
+	if ( ! empty( $scripts ) ) {
+		$html .= $scripts;
+	}
 
 	$output = sprintf( '<div style="width: %dpx; max-width: 100%%;" class="wp-video">%s</div>', $atts['width'], $html );
 
@@ -2324,7 +2347,11 @@
  * @return string The embed HTML.
  */
 function wp_embed_handler_audio( $matches, $attr, $url, $rawattr ) {
-	$audio = sprintf( '[audio src="%s" /]', esc_url( $url ) );
+	if ( defined( 'DOING_AJAX' ) && DOING_AJAX && 'parse-embed' === $_REQUEST['action'] ) {
+		$audio = sprintf( '[audio scripts="1" src="%s"]', esc_url( $url ) );
+	} else {
+		$audio = sprintf( '[audio src="%s"]', esc_url( $url ) );
+	}
 
 	/**
 	 * Filter the audio embed output.
@@ -2356,7 +2383,11 @@
 		$dimensions .= sprintf( 'width="%d" ', (int) $rawattr['width'] );
 		$dimensions .= sprintf( 'height="%d" ', (int) $rawattr['height'] );
 	}
-	$video = sprintf( '[video %s src="%s" /]', $dimensions, esc_url( $url ) );
+	if ( defined( 'DOING_AJAX' ) && DOING_AJAX && 'parse-embed' === $_REQUEST['action'] ) {
+		$video = sprintf( '[video scripts="1" %s src="%s"]', $dimensions, esc_url( $url ) );
+	} else {
+		$video = sprintf( '[video %s src="%s"]', $dimensions, esc_url( $url ) );
+	}
 
 	/**
 	 * Filter the video embed output.
@@ -3256,3 +3287,23 @@
 		return (int) $post_id;
 	}
 }
+
+function wp_media_mce_styles() {
+	$version = 'ver=' . $GLOBALS['wp_version'];
+	$dashicons = includes_url( "css/dashicons.css?$version" );
+	$skin = includes_url( 'js/tinymce/skins/wordpress/wp-content.css?' . $version );
+	$mediaelement = includes_url( "js/mediaelement/mediaelementplayer.min.css?$version" );
+	$wpmediaelement = includes_url( "js/mediaelement/wp-mediaelement.css?$version" );
+
+	$styles = array( $dashicons, $skin, $mediaelement, $wpmediaelement );
+	foreach ( $styles as $style ) {
+		printf( '<link rel="stylesheet" href="%s"/>', $style );
+	}
+
+	$editor_styles = get_editor_stylesheets();
+	if ( ! empty( $editor_styles ) ) {
+		foreach ( $editor_styles as $style ) {
+			printf( '<link rel="stylesheet" href="%s"/>', $style );
+		}
+	}
+}
Index: src/wp-includes/theme.php
===================================================================
--- src/wp-includes/theme.php	(revision 29173)
+++ src/wp-includes/theme.php	(working copy)
@@ -1395,6 +1395,51 @@
 }
 
 /**
+ *
+ * @since 4.0.0
+ *
+ * @return array
+ */
+function get_editor_stylesheets() {
+	$stylesheets = array();
+	// load editor_style.css if the current theme supports it
+	if ( ! empty( $GLOBALS['editor_styles'] ) && is_array( $GLOBALS['editor_styles'] ) ) {
+		$editor_styles = $GLOBALS['editor_styles'];
+
+		$editor_styles = array_unique( array_filter( $editor_styles ) );
+		$style_uri = get_stylesheet_directory_uri();
+		$style_dir = get_stylesheet_directory();
+
+		// Support externally referenced styles (like, say, fonts).
+		foreach ( $editor_styles as $key => $file ) {
+			if ( preg_match( '~^(https?:)?//~', $file ) ) {
+				$stylesheets[] = esc_url_raw( $file );
+				unset( $editor_styles[ $key ] );
+			}
+		}
+
+		// Look in a parent theme first, that way child theme CSS overrides.
+		if ( is_child_theme() ) {
+			$template_uri = get_template_directory_uri();
+			$template_dir = get_template_directory();
+
+			foreach ( $editor_styles as $key => $file ) {
+				if ( $file && file_exists( "$template_dir/$file" ) ) {
+					$stylesheets[] = "$template_uri/$file";
+				}
+			}
+		}
+
+		foreach ( $editor_styles as $file ) {
+			if ( $file && file_exists( "$style_dir/$file" ) ) {
+				$stylesheets[] = "$style_uri/$file";
+			}
+		}
+	}
+	return $stylesheets;
+}
+
+/**
  * Allows a theme to register its support of a certain feature
  *
  * Must be called in the theme's functions.php file to work.
