Thanks for making these changes. Refactoring over copying is always better, so I appreciate you doing the work upfront to make the maintenance easier.
Dan, please add this patch onto the 3 in this series.
Could you send these in separate mails like the others? My patch apply/test bot doesn't understand multiple patch attachments per email, and if it did, I'm sure I'd have some ordering issues. If it's okay with you, it's much easier for me to keep straight if they show up in ordered and tagged emails like what "hg email" does:
[PATCH][1 of 3] Foo bar...
I can apply them by hand, but it's just much easier for me to let the bot do it and test each one before it does.
Is there some reason that the patchbomb extension doesn't work for you?
Thanks!
--Dan