HiDPI versions of the generic menu page icon. props empireoflight, lessbloat. see #21019.

git-svn-id: http://core.svn.wordpress.org/trunk@22393 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Andrew Nacin 2012-11-06 00:25:18 +00:00
parent c9c8c0d214
commit 9fadd65859
8 changed files with 74 additions and 22 deletions

View File

@ -1090,8 +1090,10 @@ div.wp-menu-image {
.icon16.icon-settings, .icon16.icon-settings,
.menu-icon-settings div.wp-menu-image, .menu-icon-settings div.wp-menu-image,
.icon16.icon-site, .icon16.icon-site,
.menu-icon-site div.wp-menu-image { .menu-icon-site div.wp-menu-image,
background-image: url('../images/menu-vs.png?ver=20120201'); .icon16.icon-generic,
.menu-icon-generic div.wp-menu-image {
background-image: url(../images/menu-vs.png?ver=20121105);
} }
.icon16.icon-dashboard, .icon16.icon-dashboard,
@ -1225,6 +1227,17 @@ div.wp-menu-image {
#adminmenu .menu-icon-site.current div.wp-menu-image { #adminmenu .menu-icon-site.current div.wp-menu-image {
background-position: -359px -1px; background-position: -359px -1px;
} }
.icon16.icon-generic,
#adminmenu .menu-icon-generic div.wp-menu-image {
background-position: -330px -34px;
}
#adminmenu .menu-icon-generic:hover div.wp-menu-image,
#adminmenu .menu-icon-generic.wp-has-current-submenu div.wp-menu-image,
#adminmenu .menu-icon-generic.current div.wp-menu-image {
background-position: -330px -2px;
}
/* end menu and screen icons */ /* end menu and screen icons */
/* Screen Icons */ /* Screen Icons */
@ -1258,8 +1271,10 @@ div.wp-menu-image {
.icon32.icon-settings, .icon32.icon-settings,
#icon-options-general, #icon-options-general,
.icon32.icon-site, .icon32.icon-site,
#icon-ms-admin { #icon-ms-admin,
background-image: url(../images/icons32-vs.png?ver=20111206); .icon32.icon-generic,
#icon-generic {
background-image: url(../images/icons32-vs.png?ver=20121105);
} }
.icon32.icon-post, .icon32.icon-post,
@ -1329,6 +1344,11 @@ div.wp-menu-image {
background-position: -659px -5px; background-position: -659px -5px;
} }
.icon32.icon-generic,
#icon-generic {
background-position: -708px -5px;
}
/* end screen icons */ /* end screen icons */
/* Diff */ /* Diff */
@ -2077,9 +2097,11 @@ div.widgets-sortables,
.icon32.icon-settings, .icon32.icon-settings,
#icon-options-general, #icon-options-general,
.icon32.icon-site, .icon32.icon-site,
#icon-ms-admin { #icon-ms-admin,
background-image: url("../images/icons32-vs-2x.png?ver=20120916"); .icon32.icon-generic,
background-size: 708px 45px; #icon-generic {
background-image: url(../images/icons32-vs-2x.png?ver=20121105);
background-size: 756px 45px;
} }
.icon16.icon-dashboard, .icon16.icon-dashboard,
@ -2105,8 +2127,10 @@ div.widgets-sortables,
.icon16.icon-settings, .icon16.icon-settings,
.menu-icon-settings div.wp-menu-image, .menu-icon-settings div.wp-menu-image,
.icon16.icon-site, .icon16.icon-site,
.menu-icon-site div.wp-menu-image { .menu-icon-site div.wp-menu-image,
background-image: url("../images/menu-2x.png?ver=20120916"); // @todo needs menu-vs-2x.png .icon16.icon-generic,
.menu-icon-generic div.wp-menu-image {
background-image: url(../images/menu-vs-2x.png?ver=20121105);
background-size: 390px 64px; background-size: 390px 64px;
} }

View File

@ -1046,8 +1046,10 @@ div.wp-menu-image {
.icon16.icon-settings, .icon16.icon-settings,
.menu-icon-settings div.wp-menu-image, .menu-icon-settings div.wp-menu-image,
.icon16.icon-site, .icon16.icon-site,
.menu-icon-site div.wp-menu-image { .menu-icon-site div.wp-menu-image,
background-image: url('../images/menu.png?ver=20120201'); .icon16.icon-generic,
.menu-icon-generic div.wp-menu-image {
background-image: url(../images/menu.png?ver=20121105);
} }
.icon16.icon-dashboard, .icon16.icon-dashboard,
@ -1181,6 +1183,18 @@ div.wp-menu-image {
#adminmenu .menu-icon-site.current div.wp-menu-image { #adminmenu .menu-icon-site.current div.wp-menu-image {
background-position: -359px -1px; background-position: -359px -1px;
} }
.icon16.icon-generic,
#adminmenu .menu-icon-generic div.wp-menu-image {
background-position: -330px -34px;
}
#adminmenu .menu-icon-generic:hover div.wp-menu-image,
#adminmenu .menu-icon-generic.wp-has-current-submenu div.wp-menu-image,
#adminmenu .menu-icon-generic.current div.wp-menu-image {
background-position: -330px -2px;
}
/* end menu and screen icons */ /* end menu and screen icons */
/* Screen Icons */ /* Screen Icons */
@ -1214,8 +1228,10 @@ div.wp-menu-image {
.icon32.icon-settings, .icon32.icon-settings,
#icon-options-general, #icon-options-general,
.icon32.icon-site, .icon32.icon-site,
#icon-ms-admin { #icon-ms-admin,
background-image: url(../images/icons32.png?ver=20111206); .icon32.icon-generic,
#icon-generic {
background-image: url(../images/icons32.png?ver=20121105);
} }
.icon32.icon-post, .icon32.icon-post,
@ -1285,6 +1301,11 @@ div.wp-menu-image {
background-position: -659px -5px; background-position: -659px -5px;
} }
.icon32.icon-generic,
#icon-generic {
background-position: -708px -5px;
}
/* end screen icons */ /* end screen icons */
/* Diff */ /* Diff */
@ -1955,9 +1976,11 @@ div.widgets-sortables,
.icon32.icon-settings, .icon32.icon-settings,
#icon-options-general, #icon-options-general,
.icon32.icon-site, .icon32.icon-site,
#icon-ms-admin { #icon-ms-admin,
background-image: url("../images/icons32-2x.png?ver=20120916"); .icon32.icon-generic,
background-size: 708px 45px; #icon-generic {
background-image: url(../images/icons32-2x.png?ver=20121105);
background-size: 756px 45px;
} }
.icon16.icon-dashboard, .icon16.icon-dashboard,
@ -1983,8 +2006,10 @@ div.widgets-sortables,
.icon16.icon-settings, .icon16.icon-settings,
.menu-icon-settings div.wp-menu-image, .menu-icon-settings div.wp-menu-image,
.icon16.icon-site, .icon16.icon-site,
.menu-icon-site div.wp-menu-image { .menu-icon-site div.wp-menu-image,
background-image: url("../images/menu-2x.png?ver=20120916"); .icon16.icon-generic,
.menu-icon-generic div.wp-menu-image {
background-image: url(../images/menu-2x.png?ver=20121105);
background-size: 390px 64px; background-size: 390px 64px;
} }

Binary file not shown.

Before

Width:  |  Height:  |  Size: 35 KiB

After

Width:  |  Height:  |  Size: 135 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 36 KiB

After

Width:  |  Height:  |  Size: 147 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 84 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 83 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.8 KiB

After

Width:  |  Height:  |  Size: 72 KiB

View File

@ -902,12 +902,15 @@ function add_menu_page( $page_title, $menu_title, $capability, $menu_slug, $func
if ( !empty( $function ) && !empty( $hookname ) && current_user_can( $capability ) ) if ( !empty( $function ) && !empty( $hookname ) && current_user_can( $capability ) )
add_action( $hookname, $function ); add_action( $hookname, $function );
if ( empty($icon_url) ) if ( empty($icon_url) ) {
$icon_url = esc_url( admin_url( 'images/generic.png' ) ); $icon_url = 'none';
else $icon_class = 'menu-icon-generic ';
} else {
$icon_url = set_url_scheme( $icon_url ); $icon_url = set_url_scheme( $icon_url );
$icon_class = '';
}
$new_menu = array( $menu_title, $capability, $menu_slug, $page_title, 'menu-top ' . $hookname, $hookname, $icon_url ); $new_menu = array( $menu_title, $capability, $menu_slug, $page_title, 'menu-top ' . $icon_class . $hookname, $hookname, $icon_url );
if ( null === $position ) if ( null === $position )
$menu[] = $new_menu; $menu[] = $new_menu;