Changeset 29049
- Timestamp:
- 07/09/2014 10:05:06 PM (10 years ago)
- Location:
- trunk/src
- Files:
-
- 3 added
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/css/edit.css
r28703 r29049 38 38 #titlediv { 39 39 position: relative; 40 margin-bottom: 10px;41 40 } 42 41 … … 338 337 -webkit-box-shadow: 0 1px 1px rgba(0,0,0,0.04); 339 338 box-shadow: 0 1px 1px rgba(0,0,0,0.04); 340 cursor: row-resize;339 z-index: 999; 341 340 } 342 341 … … 346 345 347 346 .autosave-info { 348 padding: 2px ;347 padding: 2px 10px; 349 348 text-align: right; 350 349 } … … 366 365 display: block; 367 366 padding: 2px 10px; 367 } 368 369 #wp-content-editor-container { 370 position: relative; 371 } 372 373 #content-textarea-clone { 374 z-index: -1; 375 position: absolute; 376 top: 0; 377 visibility: hidden; 378 overflow: hidden; 368 379 } 369 380 … … 1349 1360 } 1350 1361 1351 #wp-content-editor-tools {1352 overflow: hidden;1353 padding: 20px 15px 1px 0;1354 top: 1px;1355 }1356 1357 1362 a.wp-switch-editor { 1358 1363 font-size: 16px; -
trunk/src/wp-admin/edit-form-advanced.php
r28837 r29049 12 12 13 13 wp_enqueue_script('post'); 14 wp_enqueue_script('editor-expand'); 14 15 15 16 if ( wp_is_mobile() ) … … 493 494 'tinymce' => array( 494 495 'resize' => false, 496 'wp_autoresize_on' => true, 495 497 'add_unload_trigger' => false, 496 498 ), -
trunk/src/wp-admin/js/common.js
r28869 r29049 180 180 181 181 $('#collapse-menu').on('click.collapse-menu', function() { 182 var body = $( document.body ), respWidth ;182 var body = $( document.body ), respWidth, state; 183 183 184 184 // reset any compensation for submenus near the bottom of the screen … … 198 198 setUserSetting('unfold', 1); 199 199 setUserSetting('mfold', 'o'); 200 state = 'open'; 200 201 } else { 201 202 body.addClass('auto-fold'); 202 203 setUserSetting('unfold', 0); 204 state = 'folded'; 203 205 } 204 206 } else { … … 206 208 body.removeClass('folded'); 207 209 setUserSetting('mfold', 'o'); 210 state = 'open'; 208 211 } else { 209 212 body.addClass('folded'); 210 213 setUserSetting('mfold', 'f'); 211 } 212 } 214 state = 'folded'; 215 } 216 } 217 218 $( document ).trigger( 'wp-collapse-menu', { state: state } ); 213 219 }); 214 220 … … 722 728 }); 723 729 724 // make Windows 8 devices playing along nicely730 // Make Windows 8 devices play along nicely. 725 731 (function(){ 726 732 if ( '-ms-user-select' in document.documentElement.style && navigator.userAgent.match(/IEMobile\/10\.0/) ) { -
trunk/src/wp-admin/js/post.js
r28771 r29049 1005 1005 var editor, offset, mce, 1006 1006 $textarea = $('textarea#content'), 1007 $handle = $('#post-status-info'); 1007 $handle = $('#post-status-info'), 1008 $contentWrap = $('#wp-content-wrap'); 1008 1009 1009 1010 // No point for touch devices … … 1013 1014 1014 1015 function dragging( event ) { 1016 if ( $contentWrap.hasClass( 'wp-editor-expand' ) ) { 1017 return; 1018 } 1019 1015 1020 if ( mce ) { 1016 1021 editor.theme.resizeTo( null, offset + event.pageY ); … … 1024 1029 function endDrag() { 1025 1030 var height, toolbarHeight; 1031 1032 if ( $contentWrap.hasClass( 'wp-editor-expand' ) ) { 1033 return; 1034 } 1026 1035 1027 1036 if ( mce ) { … … 1075 1084 var editor, body, format = this.id; 1076 1085 1077 if ( format && $( this ).prop('checked') ) { 1078 editor = tinymce.get( 'content' ); 1079 1080 if ( editor ) { 1081 body = editor.getBody(); 1082 body.className = body.className.replace( /\bpost-format-[^ ]+/, '' ); 1083 editor.dom.addClass( body, format == 'post-format-0' ? 'post-format-standard' : format ); 1084 } 1086 if ( format && $( this ).prop( 'checked' ) && ( editor = tinymce.get( 'content' ) ) ) { 1087 body = editor.getBody(); 1088 body.className = body.className.replace( /\bpost-format-[^ ]+/, '' ); 1089 editor.dom.addClass( body, format == 'post-format-0' ? 'post-format-standard' : format ); 1090 $( document ).trigger( 'editor-classchange' ); 1085 1091 } 1086 1092 }); -
trunk/src/wp-admin/js/postbox.js
r28940 r29049 160 160 el.className = el.className.replace(/columns-\d+/, 'columns-' + n); 161 161 } 162 163 $( document ).trigger( 'postboxes-columnchange' ); 162 164 }, 163 165 -
trunk/src/wp-includes/class-wp-editor.php
r28945 r29049 348 348 'fullscreen', 349 349 'wordpress', 350 'wpautoresize', 350 351 'wpeditimage', 351 352 'wpgallery', -
trunk/src/wp-includes/css/editor.css
r28236 r29049 149 149 border-bottom: 1px solid #dedede; 150 150 background: #f5f5f5; 151 padding: 0; 152 position: relative; 153 z-index: 999; 154 } 155 156 div.mce-toolbar-grp > div { 151 157 padding: 3px; 152 position: relative;153 158 } 154 159 … … 162 167 163 168 div.mce-statusbar { 164 border-top: 1px solid #e ee;169 border-top: 1px solid #e5e5e5; 165 170 } 166 171 167 172 div.mce-path { 168 padding: 0 8px 2px;173 padding: 2px 10px; 169 174 margin: 0; 175 } 176 177 .mce-path, 178 .mce-path-item, 179 .mce-path .mce-divider { 180 font-size: 12px; 181 line-height: 18px; 182 } 183 184 .mce-path-item:focus { 185 background: none; 186 color: inherit; 170 187 } 171 188 … … 732 749 733 750 .mce-i-wp_code:before { 734 content: '\ e017';751 content: '\f475'; 735 752 } 736 753 … … 741 758 742 759 .wp-editor-tools { 760 background-color: #f1f1f1; 761 padding-top: 20px; 743 762 position: relative; 744 z-index: 1; 763 z-index: 1000; 764 } 765 766 .wp-editor-tools:after { 767 clear: both; 768 content: ''; 769 display: table; 745 770 } 746 771 … … 762 787 -moz-box-sizing: border-box; 763 788 box-sizing: border-box; 764 }765 766 .wp-editor-tools {767 padding: 0;768 789 } 769 790 -
trunk/src/wp-includes/js/tinymce/plugins/wordpress/plugin.js
r28932 r29049 53 53 } 54 54 } 55 56 editor.fire( 'wp-toolbar-toggle' ); 55 57 } 56 58 -
trunk/src/wp-includes/js/tinymce/plugins/wpfullscreen/plugin.js
r28455 r29049 4 4 */ 5 5 tinymce.PluginManager.add( 'wpfullscreen', function( editor ) { 6 var settings = editor.settings, 7 oldSize = 0; 8 9 function resize( e ) { 10 var deltaSize, myHeight, 11 d = editor.getDoc(), 12 body = d.body, 13 DOM = tinymce.DOM, 14 resizeHeight = 250; 15 16 if ( ( e && e.type === 'setcontent' && e.initial ) || editor.settings.inline ) { 17 return; 18 } 19 20 // Get height differently depending on the browser used 21 myHeight = tinymce.Env.ie ? body.scrollHeight : ( tinymce.Env.webkit && body.clientHeight === 0 ? 0 : body.offsetHeight ); 22 23 // Don't make it smaller than 250px 24 if ( myHeight > 250 ) { 25 resizeHeight = myHeight; 26 } 27 28 body.scrollTop = 0; 29 30 // Resize content element 31 if ( resizeHeight !== oldSize ) { 32 deltaSize = resizeHeight - oldSize; 33 DOM.setStyle( DOM.get( editor.id + '_ifr' ), 'height', resizeHeight + 'px' ); 34 oldSize = resizeHeight; 35 36 // WebKit doesn't decrease the size of the body element until the iframe gets resized 37 // So we need to continue to resize the iframe down until the size gets fixed 38 if ( tinymce.isWebKit && deltaSize < 0 ) { 39 resize( e ); 40 } 41 } 42 } 43 44 // Register the command 45 editor.addCommand( 'wpAutoResize', resize ); 6 var settings = editor.settings; 46 7 47 8 function fullscreenOn() { 48 9 settings.wp_fullscreen = true; 49 10 editor.dom.addClass( editor.getDoc().documentElement, 'wp-fullscreen' ); 50 // Add listeners forauto-resizing51 editor. on( 'change setcontent paste keyup', resize);11 // Start auto-resizing 12 editor.execCommand( 'wpAutoResizeOn' ); 52 13 } 53 14 … … 55 16 settings.wp_fullscreen = false; 56 17 editor.dom.removeClass( editor.getDoc().documentElement, 'wp-fullscreen' ); 57 // Remove listeners for auto-resizing 58 editor.off( 'change setcontent paste keyup', resize ); 59 oldSize = 0; 18 // Stop auto-resizing 19 editor.execCommand( 'wpAutoResizeOff' ); 60 20 } 61 21 -
trunk/src/wp-includes/js/tinymce/plugins/wpview/plugin.js
r29038 r29049 647 647 return { 648 648 getViewText: getViewText, 649 setViewText: setViewText 649 setViewText: setViewText, 650 getView: getView 650 651 }; 651 652 }); -
trunk/src/wp-includes/js/tinymce/skins/wordpress/wp-content.css
r29019 r29049 15 15 line-height: 19px; 16 16 color: #333; 17 margin: 10px; 17 margin: 9px 10px; 18 } 19 20 body.wp-autoresize { 21 max-width: 100%; 22 overflow: visible !important; 23 /* The padding ensures margins of the children are contained in the body. */ 24 padding-top: 1px !important; 25 padding-bottom: 1px !important; 26 padding-left: 0 !important; 27 padding-right: 0 !important; 18 28 } 19 29 -
trunk/src/wp-includes/script-loader.php
r29025 r29049 460 460 ) ); 461 461 462 $scripts->add( 'editor-expand', "/wp-admin/js/editor-expand$suffix.js", array( 'jquery' ), false, 1 ); 463 462 464 $scripts->add( 'link', "/wp-admin/js/link$suffix.js", array( 'wp-lists', 'postbox' ), false, 1 ); 463 465
Note: See TracChangeset
for help on using the changeset viewer.