move refresh menu table out of UIManager

no need to clutter a core file of the whole UI concept with definitions
of UI elements
change setDirty/refresh API

See documentation in the code.
In short: There is now one single method, setDirty(), that triggers
repaints and/or refreshes.
All variables in UIManager are gone - at least from an external
perspective. Everything is done through setDirty().
This also allows for easier debugging, since all requests come
in via function calls.
adapt widgets to new refresh/repaint API
update base: use new refresh wait queue

also pull refresh emulation improvement for emulator.
reader config dialog: properly refresh config pane

This serves as a good example for the way refreshes are done:
setDirty("all", function() ... end)
* the "all" will have all widgets on screen repainted.
  In this case that is needed because the config pane has
  different sizes, covering different parts of underlying
  widgets. So they need to be repainted every time.
* the function will return the area to refresh and is evaluated
  after painting. In this example, we take the area that is covered
  by the config pane before switching it (if present at all), and
  hand it to the refresh area function as an upvalue.
  When the function is called later after painting, it will
  use that saved area and combine it with the area that is covered
  then by the widget. That way, parts that are covered no more are
  included in the refresh area, too.
refresh fixes for the menus

this will only refresh the areas that actually need to be refreshed.
Merge pull request #1306 from hwhw/master

Refresh refactoring, frontend/UIManager side