[wp-trac] [WordPress Trac] #18785: Modernize screen functions
WordPress Trac
wp-trac at lists.automattic.com
Sun Oct 23 19:26:28 UTC 2011
#18785: Modernize screen functions
------------------------------+-----------------------
Reporter: nacin | Owner: nacin
Type: task (blessed) | Status: assigned
Priority: normal | Milestone: 3.3
Component: Administration | Version: 3.3
Severity: normal | Resolution:
Keywords: has-patch commit |
------------------------------+-----------------------
Comment (by nacin):
Replying to [comment:58 scribu]:
> Replying to [comment:57 nacin]:
> > It makes WP_Screen behave as a registry of singletons.
>
> [http://en.wikipedia.org/wiki/Singleton_pattern Singleton] does not
accept plural form. :)
Well, it's technically called a multiton, but also known as a basic
registry pattern.
> WP_Screen::get( $hook_name )->set_as_current();
I don't have a problem with chaining here (definitely makes sense for this
usage), but I'm not sure what you mean by coding standards.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/18785#comment:59>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list