Call refresh on widget clear, instead of every cursor enter.
Make widgets come back after permalinks

This is still a bit sketchy.  When I look for widget messages, there is the possibility that the editor text will change underneath during the widget replacement, which will probably corrupt everything.