Changeset 22815 for trunk/wp-admin/includes/template.php
- Timestamp:
- 11/22/2012 09:24:11 AM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/includes/template.php
r22723 r22815 1670 1670 $registered_pointers = array( 1671 1671 'index.php' => 'wp330_toolbar', 1672 'post-new.php' => 'wp3 30_media_uploader',1673 'post.php' => 'wp3 30_media_uploader',1672 'post-new.php' => 'wp350_media', 1673 'post.php' => 'wp350_media', 1674 1674 'themes.php' => array( 'wp330_saving_widgets', 'wp340_customize_current_theme_link' ), 1675 1675 'appearance_page_custom-header' => 'wp340_choose_image_from_library', 1676 1676 'appearance_page_custom-background' => 'wp340_choose_image_from_library', 1677 'plugin-install.php' => 'wp350_favorites', 1677 1678 ); 1678 1679 … … 1684 1685 1685 1686 $caps_required = array( 1686 'wp330_media_uploader' => array( 'upload_files' ),1687 1687 'wp330_saving_widgets' => array( 'edit_theme_options', 'switch_themes' ), 1688 1688 'wp340_customize_current_theme_link' => array( 'edit_theme_options' ), 1689 1689 'wp340_choose_image_from_library' => array( 'edit_theme_options' ), 1690 'wp350_media' => array( 'upload_files' ), 1690 1691 ); 1691 1692 … … 1779 1780 * @since 3.3.0 1780 1781 */ 1781 public static function pointer_wp330_media_uploader() { 1782 $content = '<h3>' . __( 'Updated Media Uploader' ) . '</h3>'; 1783 $content .= '<p>' . __( 'The single media icon now launches the uploader for all file types, and the new drag and drop interface makes uploading a breeze.' ) . '</p>'; 1784 1785 WP_Internal_Pointers::print_js( 'wp330_media_uploader', '#content-add_media', array( 1786 'content' => $content, 1787 'position' => array( 'edge' => is_rtl() ? 'right' : 'left', 'align' => 'center' ), 1788 ) ); 1789 } 1782 public static function pointer_wp330_media_uploader() {} 1790 1783 1791 1784 /** … … 1835 1828 } 1836 1829 1830 public static function pointer_wp350_media() { 1831 $content = '<h3>' . ( 'New Media Uploader' ) . '</h3>'; 1832 $content .= '<p>' . ( 'Uploading and inserting images and other files has never been easier.' ) . '</p>'; 1833 1834 self::print_js( 'wp350_media', '.insert-media', array( 1835 'content' => $content, 1836 'position' => array( 'edge' => is_rtl() ? 'right' : 'left', 'align' => 'center' ), 1837 ) ); 1838 } 1839 1840 public static function pointer_wp350_favorites() { 1841 $content = '<h3>' . __( 'New Feature: Plugin Favorites' ) . '</h3>'; 1842 $content .= '<p>' . __( 'If you have favorited plugins on WordPress.org, you can now install them directly from this tab.' ) . '</p>'; 1843 1844 self::print_js( 'wp350_favorites', '.plugin-install-favorites', array( 1845 'content' => $content, 1846 'position' => array( 'edge' => 'top', 'align' => is_rtl() ? 'right' : 'left', 'offset' => is_rtl() ? '40 0' : '-40 0' ), 1847 ) ); 1848 } 1849 1837 1850 /** 1838 1851 * Prevents new users from seeing existing 'new feature' pointers. … … 1841 1854 */ 1842 1855 public static function dismiss_pointers_for_new_users( $user_id ) { 1843 add_user_meta( $user_id, 'dismissed_wp_pointers', 'wp330_toolbar,wp330_ media_uploader,wp330_saving_widgets,wp340_choose_image_from_library,wp340_customize_current_theme_link' );1856 add_user_meta( $user_id, 'dismissed_wp_pointers', 'wp330_toolbar,wp330_saving_widgets,wp340_choose_image_from_library,wp340_customize_current_theme_link,wp350_media,wp350_favorites' ); 1844 1857 } 1845 1858 }
Note: See TracChangeset
for help on using the changeset viewer.