Webclient: shared context menu code (#602).

New method in Webclient API:
{{{
dm4c.open_context_menu(commands, pos)
}}}
Builds a context menu from a set of commands and opens it.
The method is available to several topicmap renderer implementations.

New method in JavaScript utilities:
{{{
js.delete(array, filter)
}}}
Deletes array elements that match a filter function. The array is manipulated in-place.

See #602.