[wp-trac] [WordPress Trac] #20052: Support sprites for admin menu icons in register_post_type and add_menu_page

WordPress Trac wp-trac at lists.automattic.com
Fri Jul 27 14:43:10 UTC 2012


#20052: Support sprites for admin menu icons in register_post_type and
add_menu_page
----------------------------+-----------------------------
 Reporter:  helenyhou       |       Owner:
     Type:  enhancement     |      Status:  new
 Priority:  normal          |   Milestone:  Future Release
Component:  Administration  |     Version:
 Severity:  normal          |  Resolution:
 Keywords:  has-patch       |
----------------------------+-----------------------------

Comment (by kovshenin):

 Replying to [comment:33 bradyvercher]:

 Thanks for your feedback. None of the arguments to 2x are required, every
 single one is optional including background_size. This allows us to use a
 single image and just have different background positions for regular and
 2x, like I described in my comment earlier.

 If you take a look at the [https://gist.github.com/3187740 gist I
 published] you'll see the three post types with three different approaches
 to menu_icon, and the first one is an image URL passed as a string. The
 back-compatibility code is at around line 262. If it's not working for you
 for some reason, please let me know.

 With regards to `add_menu_page` and `screen_icon`, I'll just reuse the
 same code, as soon it's working well for `menu_icon` in
 `register_post_type` :)

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/20052#comment:34>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list