Put 'mode' and 'edit' into consts
Handle auto-recovery on failure
Auto reload the event
Do not execute a query twice at startup
Add MetricTools to handle conversion (dp, pixel, etc.)