Alphabetize
When modifying a WML menu item, make a copy first.

This takes advantage of the implicit buffering provided by smart pointers.
If the menu item object is being used, that object will not be changed,
but instead will be destroyed when it is done. Eventually, this will
allow the explicit buffering of menu items to be eliminated, but there
is some functionality to shift around first.
When modifying a menu item's event, do it via remove/add.

This allows the change to be buffered by the manager, so this code
can be moved (in a future commit) from commit_change() to the
codepath followed when the change is initiated.
Optimization: no need to add an empty event handler for a menu item.
Save hotkeys each time one is changed by [set_menu_item].

This will degrade performance in some cases, but it will make
some other changes easier. I'll come back to the performance
aspect after making those changes.
Move contents of wmi_container::commit_change to wml_menu_item.

The code has not been cleaned up yet; this was intended to be
as close to an exact copy as reasonable.
Simplify wml_menu_item::update_command().

This is just adapting the code to take advantage of being a member
of wml_menu_item.
Reorder wml_menu_item::update_command() to simplify some logic.
Merge codepaths that initialize event handlers for menu items.

As part of this, I moved a comment from init_handler() to the only
place from which it was called, as the comment does not apply to
the new use of init_handler().
Remove an extraneous object, and clean up some debugging messages.
Add a const-qualifier.
Break out saving a single hotkey into its own function.

This is really part of my next commit, but this might make the
changes easier to follow.
Push hotkey saving from wml_menu_item to hotkeys.cpp.

This means other modules don't need to know as much about the inner
workings of hotkeys, which should make things easier to maintain.

This also means that adding a new menu item does not cause all menu
item hotkeys to be regenerated; instead the new one is simply appended
to the existing list. This should more than make up for the
performance hit I caused in cde7f6af710eee6d802e3215d3cca8c77b4f7c6d.
Correcting a comment.
Create wml_menu_item::finish_handler() to balance init_handler().

One consequence is that associated hotkeys are now removed.
Don't require an inline command for hotkey support.